{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/cavuno-com/json-schema/cavuno-com-job-schema.json",
  "title": "Job",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/cavuno-com-openapi.json#/components/schemas/Job",
  "allOf": [
    {
      "$ref": "#/$defs/JobSummary"
    },
    {
      "type": "object",
      "properties": {
        "links": {
          "allOf": [
            {
              "$ref": "#/$defs/ResourceLinks"
            },
            {
              "type": "object",
              "properties": {
                "public": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "uri",
                  "description": "Canonical public URL for this job, or `null` when the job has no slug or no associated company slug (so a stable URL cannot be assembled)."
                }
              }
            }
          ],
          "description": "Public + admin URLs for this job. `public` may be `null` if the job lacks a slug or company-slug."
        },
        "resolvedCollectionFields": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/ResolvedJobCollectionField"
          },
          "description": "Collection selections resolved to current live names, logos, and public record details."
        },
        "description": {
          "type": [
            "string",
            "null"
          ],
          "description": "Long-form description of the role (HTML), or `null` if not specified."
        },
        "applicationUrl": {
          "type": [
            "string",
            "null"
          ],
          "description": "Where candidates apply, or `null` if not specified. An HTTPS URL or `mailto:` URI."
        },
        "remotePermits": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string"
              },
              "value": {
                "type": "string"
              },
              "code": {
                "type": "string",
                "description": "UN M.49 area code of a `continent`, `region` or `subregion` entry (e.g. `\"150\"` for Europe, `\"019\"` for the Americas, `\"155\"` for Western Europe). It is a code `Intl.DisplayNames` with `type: \"region\"` accepts, so a client can name the area in any language: `new Intl.DisplayNames([\"de\"], { type: \"region\" }).of(\"150\")` is `\"Europa\"`. Absent for areas without a standard code (e.g. \"Central Europe\"), for `world_region` and `custom` entries, and for `country` and `subdivision` entries, whose `value` is already an ISO 3166-1 alpha-2 or ISO 3166-2 code."
              }
            },
            "required": [
              "type",
              "value"
            ]
          },
          "description": "Hierarchical permit selection authored by the caller. Lossless round-trip with the input: `[{type:\"world_region\",value:\"EMEA\"}]` goes in and comes out the same. The three `remoteWorkPermit*` and `remoteWorldwide` fields below are read-only derived projections of this list."
        },
        "remoteWorldwide": {
          "type": [
            "boolean",
            "null"
          ],
          "description": "Read-only: derived from `remotePermits`. `true` only when the authored selection is a single `{type:\"worldwide\"}` entry."
        },
        "remoteTimezones": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string"
              },
              "value": {
                "type": "string"
              },
              "plusMinus": {
                "type": "number"
              }
            },
            "required": [
              "type",
              "value"
            ]
          },
          "description": "Hierarchical timezone selection. Lossless round-trip with the authored input. When omitted on POST, the server auto-derives this from `remotePermits` (or `[{all,all}]` if neither was provided). PATCH never auto-re-derives: once set, only an explicit replacement updates the stored value. The flat `remoteAllowedTzOffsets` field below is the read-only derived projection used by search."
        },
        "remoteAllowedTzOffsets": {
          "type": "array",
          "items": {
            "type": "number"
          },
          "description": "Read-only: derived from `remoteTimezones` (per-country/per-region offset fan-out). UTC hour offsets used by the job-search index."
        },
        "remoteWorkPermitCountryCodes": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "Read-only: derived from `remotePermits` (hierarchical groups fan out to alpha2 sets; subdivisions auto-add the parent country). ISO 3166-1 alpha-2 codes."
        },
        "remoteWorkPermitSubdivisionCodes": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "Read-only: derived from `remotePermits` (subdivision entries only). ISO 3166-2 codes."
        },
        "remoteSponsorship": {
          "type": "string",
          "enum": [
            "yes",
            "no",
            "unknown"
          ],
          "description": "Whether the employer sponsors visas for remote candidates. One of `yes`, `no`, or `unknown`."
        },
        "educationRequirements": {
          "type": "array",
          "items": {
            "type": "string",
            "enum": [
              "high_school",
              "associate_degree",
              "bachelor_degree",
              "professional_certificate",
              "postgraduate_degree",
              "no_requirements"
            ]
          },
          "description": "Required education credentials. Each value is one of `high_school`, `associate_degree`, `bachelor_degree`, `professional_certificate`, `postgraduate_degree`, or `no_requirements`."
        },
        "experienceMonths": {
          "type": [
            "number",
            "null"
          ],
          "description": "Minimum required experience in months, or `null` if not specified."
        },
        "experienceInPlaceOfEducation": {
          "type": [
            "boolean",
            "null"
          ],
          "description": "If `true`, equivalent experience may substitute for the listed education requirements. `null` if not specified."
        },
        "inOfficePeriod": {
          "type": [
            "string",
            "null"
          ],
          "enum": [
            "per_week",
            "per_month",
            "per_year"
          ],
          "description": "Period denominator for `inOfficeFrequency`, or `null` if not specified."
        },
        "inOfficeFrequency": {
          "type": [
            "number",
            "null"
          ],
          "description": "How often the candidate must be in-office over `inOfficePeriod`, or `null` if not specified."
        },
        "company": {
          "$ref": "#/$defs/JobCompany"
        },
        "officeLocations": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/JobOfficeLocation"
          },
          "description": "Physical office locations associated with the job."
        }
      },
      "required": [
        "resolvedCollectionFields",
        "description",
        "applicationUrl",
        "remotePermits",
        "remoteWorldwide",
        "remoteTimezones",
        "remoteAllowedTzOffsets",
        "remoteWorkPermitCountryCodes",
        "remoteWorkPermitSubdivisionCodes",
        "remoteSponsorship",
        "educationRequirements",
        "experienceMonths",
        "experienceInPlaceOfEducation",
        "inOfficePeriod",
        "inOfficeFrequency",
        "company",
        "officeLocations"
      ]
    }
  ],
  "$defs": {
    "AdminOnlyResourceLinks": {
      "type": "object",
      "properties": {
        "admin": {
          "type": "string",
          "format": "uri",
          "description": "URL inside the Cavuno app where the authenticated owner can manage this resource."
        }
      },
      "required": [
        "admin"
      ],
      "description": "Links related to this resource. List responses carry the operator URL; detail responses may also carry the public URL."
    },
    "JobCompany": {
      "type": [
        "object",
        "null"
      ],
      "properties": {
        "id": {
          "type": "string",
          "description": "Unique identifier for the company."
        },
        "name": {
          "type": [
            "string",
            "null"
          ],
          "description": "Display name of the company, or `null` if not yet set."
        },
        "slug": {
          "type": [
            "string",
            "null"
          ],
          "description": "URL slug of the company, or `null` if not yet set."
        },
        "logoUrl": {
          "type": [
            "string",
            "null"
          ],
          "description": "URL of the company logo, or `null` if no logo is set."
        },
        "website": {
          "type": [
            "string",
            "null"
          ],
          "description": "Company website URL, or `null` if no website is set."
        }
      },
      "required": [
        "id",
        "name",
        "slug",
        "logoUrl",
        "website"
      ],
      "description": "Embedded company resource for the job, or `null` if no company is attached."
    },
    "JobOfficeLocation": {
      "type": "object",
      "properties": {
        "countryCode": {
          "type": [
            "string",
            "null"
          ],
          "description": "ISO 3166-1 alpha-2 country code, or `null` if the location was not resolved."
        },
        "country": {
          "type": [
            "string",
            "null"
          ],
          "description": "Full country name, or `null` if the location was not resolved."
        },
        "locality": {
          "type": [
            "string",
            "null"
          ],
          "description": "Neighborhood or sub-locality, or `null` if not resolved."
        },
        "city": {
          "type": [
            "string",
            "null"
          ],
          "description": "City, or `null` if not resolved."
        },
        "region": {
          "type": [
            "string",
            "null"
          ],
          "description": "Region, state, or province name, or `null` if not resolved."
        },
        "regionCode": {
          "type": [
            "string",
            "null"
          ],
          "description": "Region or state code (e.g. `CA` for California), or `null` if not resolved."
        },
        "postalCode": {
          "type": [
            "string",
            "null"
          ],
          "description": "Postal or ZIP code, or `null` if not resolved."
        },
        "displayName": {
          "type": [
            "string",
            "null"
          ],
          "description": "Pre-formatted display name for the location, or `null` if not resolved."
        }
      },
      "required": [
        "countryCode",
        "country",
        "locality",
        "city",
        "region",
        "regionCode",
        "postalCode",
        "displayName"
      ]
    },
    "JobSummary": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "Unique identifier for the object. Use this value as the `{id}` path parameter for the job endpoints (e.g. `GET /v1/jobs/{id}`)."
        },
        "object": {
          "type": "string",
          "enum": [
            "job"
          ],
          "description": "String representing the object's type. Objects of the same type share the same value."
        },
        "title": {
          "type": "string",
          "description": "The job title."
        },
        "slug": {
          "type": [
            "string",
            "null"
          ],
          "description": "URL-friendly slug used in public board URLs, or `null` if no slug is set."
        },
        "status": {
          "type": "string",
          "enum": [
            "draft",
            "published",
            "expired",
            "archived",
            "pending_approval"
          ],
          "description": "Current status of the job. One of `draft`, `published`, `expired`, `archived`, or `pending_approval`. A `pending_approval` job is waiting for an operator to approve it: approve with `POST /v1/jobs/:id/publish`, reject with `DELETE /v1/jobs/:id`. It is not public, like a draft."
        },
        "companyId": {
          "type": [
            "string",
            "null"
          ],
          "description": "Identifier of the company the job belongs to, or `null` if no company is attached."
        },
        "employmentType": {
          "type": [
            "string",
            "null"
          ],
          "enum": [
            "full_time",
            "part_time",
            "contract",
            "internship",
            "temporary",
            "volunteer",
            "other"
          ],
          "description": "Employment type of the role, or `null` if not specified. For a job with a custom employment type, this is the Google equivalent of the custom type."
        },
        "customEmploymentType": {
          "type": [
            "object",
            "null"
          ],
          "properties": {
            "key": {
              "type": "string",
              "description": "Stable key of the custom employment type. Never changes."
            },
            "label": {
              "type": "string",
              "description": "Display name of the custom employment type, as configured."
            }
          },
          "required": [
            "key",
            "label"
          ],
          "description": "The board's custom employment type for this job (for example `Casual`), or `null` when the job uses a built-in type only. A deleted custom type reads back as `null` and the job shows its built-in `employmentType`."
        },
        "remoteOption": {
          "type": [
            "string",
            "null"
          ],
          "enum": [
            "on_site",
            "hybrid",
            "remote"
          ],
          "description": "Whether the role is on-site, hybrid, or fully remote. `null` only on older jobs saved without one; create requires it and `PATCH` cannot clear it."
        },
        "seniority": {
          "type": [
            "string",
            "null"
          ],
          "enum": [
            "entry_level",
            "associate",
            "mid_level",
            "senior",
            "lead",
            "principal",
            "director",
            "executive"
          ],
          "description": "Seniority level of the role, or `null` if not specified."
        },
        "salaryMin": {
          "type": [
            "number",
            "null"
          ],
          "description": "Minimum salary in `salaryCurrency` units, or `null` if not specified."
        },
        "salaryMax": {
          "type": [
            "number",
            "null"
          ],
          "description": "Maximum salary in `salaryCurrency` units, or `null` if not specified."
        },
        "salaryCurrency": {
          "type": [
            "string",
            "null"
          ],
          "description": "Three-letter ISO 4217 currency code for the salary range, or `null` if no salary is specified."
        },
        "salaryTimeframe": {
          "type": [
            "string",
            "null"
          ],
          "enum": [
            "per_year",
            "per_month",
            "per_week",
            "per_day",
            "per_hour"
          ],
          "description": "Period the salary range is quoted against, or `null` if no salary is specified."
        },
        "isFeatured": {
          "type": "boolean",
          "description": "Whether the job appears in featured slots on the public board."
        },
        "publishedAt": {
          "type": [
            "string",
            "null"
          ],
          "description": "Time at which the job was first published, or `null` if not yet published. ISO 8601 datetime."
        },
        "expiresAt": {
          "type": [
            "string",
            "null"
          ],
          "description": "Time at which the job expires as an ISO 8601 datetime. `null` can appear when the expiry requirement does not apply, including for drafts and sponsored jobs; ordinary published jobs always have an expiry."
        },
        "createdAt": {
          "type": "string",
          "description": "Time at which the job was created. ISO 8601 datetime."
        },
        "updatedAt": {
          "type": "string",
          "description": "Time at which the job was last updated. ISO 8601 datetime."
        },
        "revision": {
          "type": "integer",
          "minimum": 0,
          "description": "Monotonic Job lifecycle revision used to reconcile webhook events. Legacy rows are 0 until the rollout backfill runs."
        },
        "skills": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "Canonical skill slugs assigned to the job."
        },
        "categories": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "Canonical category slugs assigned to the job."
        },
        "externalId": {
          "type": [
            "string",
            "null"
          ],
          "description": "External identifier supplied by the caller on create, used for deduplication via `GET /v1/jobs?externalId=...`. `null` when no external identifier was set."
        },
        "customFieldValues": {
          "type": "object",
          "additionalProperties": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              {
                "type": "boolean"
              },
              {
                "type": "number"
              }
            ]
          },
          "description": "Board-defined custom-field values for this job, keyed by the field `key` (the definitions are published at `GET /v1/settings/job-form`). Each value is returned as stored: a string (`short_text` / `long_text` / a `single_select` option key), a string array (`multi_select` option keys), a boolean, or a number. Always an object: `{}` when the job has no custom-field values, never `null` or a missing field. Only real values are stored, so this never contains `null` or empty values."
        },
        "collectionValues": {
          "type": "object",
          "additionalProperties": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "maxItems": 100
          },
          "description": "Operator-facing collection record IDs keyed by job collection field. Always an object; values are arrays even for single-select fields. Fields whose collection is archived are omitted."
        },
        "proposedCompany": {
          "type": [
            "object",
            "null"
          ],
          "properties": {
            "name": {
              "type": "string",
              "description": "Name of the proposed company."
            },
            "website": {
              "type": [
                "string",
                "null"
              ],
              "description": "Website URL of the proposed company, or `null` if the source gives none."
            }
          },
          "required": [
            "name",
            "website"
          ],
          "description": "Present only while the job has no company: the company the job's source names, which isn't on your board yet. Read-only. Publishing the job (`POST /jobs/{id}/publish`) adds this company to your board, or uses an existing company with the same website. To publish under a different company, set `companyId` first with `PATCH /jobs/{id}`. `null` when the job has a company."
        },
        "companyLocked": {
          "type": "boolean",
          "description": "`true` once an operator has changed the job's company (in the dashboard or with `companyId` on `PATCH /jobs/{id}`). A locked job keeps its company when the job's source refreshes or republishes it, even when the source names another company. Read-only."
        },
        "links": {
          "$ref": "#/$defs/AdminOnlyResourceLinks"
        }
      },
      "required": [
        "id",
        "object",
        "title",
        "slug",
        "status",
        "companyId",
        "employmentType",
        "customEmploymentType",
        "remoteOption",
        "seniority",
        "salaryMin",
        "salaryMax",
        "salaryCurrency",
        "salaryTimeframe",
        "isFeatured",
        "publishedAt",
        "expiresAt",
        "createdAt",
        "updatedAt",
        "revision",
        "skills",
        "categories",
        "externalId",
        "customFieldValues",
        "collectionValues",
        "proposedCompany",
        "companyLocked",
        "links"
      ]
    },
    "ResolvedJobCollectionField": {
      "type": "object",
      "properties": {
        "key": {
          "type": "string"
        },
        "label": {
          "type": "string"
        },
        "entries": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "slug": {
                "type": "string",
                "description": "URL-safe identifier, unique within the collection. Changing it keeps the previous value reserved."
              },
              "logoUrl": {
                "type": "string",
                "description": "The entry's logo: the image in the collection's logo field, or a legacy logo URL on older entries. Absent when the entry has neither."
              },
              "title": {
                "type": "string",
                "description": "The entry's title on this job: the job's `titleOverride` when set, otherwise the entry name. Render this."
              },
              "description": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The entry's description on this job: the job's `descriptionOverride` when set, otherwise the value of the field's default description field, or `null` when neither exists. Sanitised HTML when the default description field is rich text, with a plain-text override escaped into paragraphs. Render this."
              },
              "titleOverride": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The title this job set for the entry, or `null` when it uses the entry name."
              },
              "descriptionOverride": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The plain-text description this job set for the entry, or `null` when it uses the default description."
              },
              "fields": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string"
                    },
                    "label": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string",
                      "enum": [
                        "short_text",
                        "long_text",
                        "rich_text",
                        "single_select",
                        "multi_select",
                        "boolean",
                        "number",
                        "date",
                        "url",
                        "email",
                        "phone",
                        "image",
                        "image_gallery",
                        "file",
                        "reference"
                      ]
                    },
                    "helpText": {
                      "type": "string"
                    },
                    "options": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key": {
                            "type": "string"
                          },
                          "label": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "key",
                          "label"
                        ]
                      }
                    }
                  },
                  "required": [
                    "key",
                    "label",
                    "type"
                  ]
                }
              },
              "values": {
                "type": "object",
                "additionalProperties": {
                  "anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    {
                      "type": "boolean"
                    },
                    {
                      "type": "number"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string"
                        },
                        "contentType": {
                          "type": "string"
                        },
                        "sizeBytes": {
                          "type": "number"
                        },
                        "url": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "contentType",
                        "sizeBytes",
                        "url"
                      ]
                    },
                    {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "contentType": {
                            "type": "string"
                          },
                          "sizeBytes": {
                            "type": "number"
                          },
                          "url": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "contentType",
                          "sizeBytes",
                          "url"
                        ]
                      }
                    }
                  ]
                }
              },
              "references": {
                "type": "object",
                "additionalProperties": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string"
                      },
                      "slug": {
                        "type": "string",
                        "description": "URL-safe identifier, unique within the collection. Changing it keeps the previous value reserved."
                      },
                      "fields": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "key": {
                              "type": "string"
                            },
                            "label": {
                              "type": "string"
                            },
                            "type": {
                              "type": "string",
                              "enum": [
                                "short_text",
                                "long_text",
                                "rich_text",
                                "single_select",
                                "multi_select",
                                "boolean",
                                "number",
                                "date",
                                "url",
                                "email",
                                "phone",
                                "image",
                                "image_gallery",
                                "file",
                                "reference"
                              ]
                            },
                            "helpText": {
                              "type": "string"
                            },
                            "options": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "key": {
                                    "type": "string"
                                  },
                                  "label": {
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "key",
                                  "label"
                                ]
                              }
                            }
                          },
                          "required": [
                            "key",
                            "label",
                            "type"
                          ]
                        }
                      },
                      "values": {
                        "type": "object",
                        "additionalProperties": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            {
                              "type": "boolean"
                            },
                            {
                              "type": "number"
                            },
                            {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "name": {
                                  "type": "string"
                                },
                                "contentType": {
                                  "type": "string"
                                },
                                "sizeBytes": {
                                  "type": "number"
                                },
                                "url": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "id",
                                "name",
                                "contentType",
                                "sizeBytes",
                                "url"
                              ]
                            },
                            {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string"
                                  },
                                  "name": {
                                    "type": "string"
                                  },
                                  "contentType": {
                                    "type": "string"
                                  },
                                  "sizeBytes": {
                                    "type": "number"
                                  },
                                  "url": {
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "id",
                                  "name",
                                  "contentType",
                                  "sizeBytes",
                                  "url"
                                ]
                              }
                            }
                          ]
                        }
                      }
                    },
                    "required": [
                      "id",
                      "name",
                      "fields",
                      "values"
                    ]
                  }
                }
              }
            },
            "required": [
              "id",
              "name",
              "title",
              "description",
              "titleOverride",
              "descriptionOverride",
              "fields",
              "values"
            ]
          }
        }
      },
      "required": [
        "key",
        "label",
        "entries"
      ]
    },
    "ResourceLinks": {
      "type": "object",
      "properties": {
        "public": {
          "type": "string",
          "format": "uri",
          "description": "Canonical public URL for this resource on the board. Honours the configured custom domain when present, otherwise uses the board subdomain."
        },
        "admin": {
          "type": "string",
          "format": "uri",
          "description": "URL inside the Cavuno app where the authenticated owner can manage this resource."
        }
      },
      "required": [
        "public",
        "admin"
      ]
    }
  }
}