{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/gupy/json-schema/gupy-job-put-request-schema.json",
  "title": "jobPutRequest",
  "description": "Job to create",
  "x-generated": "2026-12-03",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/gupy-public-api-openapi.yml#/components/schemas/jobPutRequest",
  "type": "object",
  "properties": {
    "code": {
      "description": "Company's job internal code. If not provided, the API will generate one.",
      "type": "string",
      "maxLength": 255
    },
    "name": {
      "description": "Job name",
      "type": "string",
      "maxLength": 255
    },
    "status": {
      "description": "Job status. Refer to https://developers.gupy.io/docs/mudanças-de-estado-de-uma-vaga (portuguese only) for more information on updating the status of a job.",
      "type": "string",
      "maxLength": 255,
      "enum": [
        "draft",
        "waiting_approval",
        "approved",
        "disapproved",
        "published",
        "frozen",
        "closed",
        "canceled"
      ]
    },
    "type": {
      "description": "Job type",
      "type": "string",
      "maxLength": 255,
      "enum": [
        "vacancy_type_apprentice",
        "vacancy_type_associate",
        "vacancy_type_talent_pool",
        "vacancy_type_effective",
        "vacancy_type_internship",
        "vacancy_type_summer",
        "vacancy_type_temporary",
        "vacancy_type_outsource",
        "vacancy_type_trainee",
        "vacancy_type_volunteer",
        "vacancy_legal_entity",
        "vacancy_type_lecturer",
        "vacancy_type_freelancer",
        "vacancy_type_autonomous",
        "vacancy_type_intermittent"
      ]
    },
    "quickApply": {
      "description": "Unable to change quick-apply field value after a job has been created",
      "type": "boolean"
    },
    "publicationType": {
      "description": "Job publication type",
      "type": "string",
      "maxLength": 255,
      "enum": [
        "external",
        "internal"
      ]
    },
    "numVacancies": {
      "description": "The number of open vacancies for this job",
      "type": "integer",
      "format": "int64"
    },
    "departmentId": {
      "description": "Job department or area id",
      "type": "integer",
      "format": "int64"
    },
    "roleId": {
      "description": "Job role id",
      "type": "integer",
      "format": "int64"
    },
    "description": {
      "description": "Job description, shown in the career page (free text)",
      "type": "string",
      "maxLength": 1073741824
    },
    "responsibilities": {
      "description": "Responsibilities of the job, shown in the career page (free text)",
      "type": "string",
      "maxLength": 1073741824
    },
    "prerequisites": {
      "description": "Pre-requisites of the job, shown in the career page (free text)",
      "type": "string",
      "maxLength": 1073741824
    },
    "additionalInformation": {
      "description": "Additional information of the job, shown in the career page (free text)",
      "type": "string",
      "maxLength": 1073741824
    },
    "notes": {
      "description": "Notes about the job (free text)",
      "type": "string",
      "maxLength": 1073741824
    },
    "disabilities": {
      "description": "This job is available to person with disabilities",
      "type": "boolean"
    },
    "addressStreet": {
      "description": "Address street name",
      "type": "string",
      "maxLength": 255
    },
    "addressNumber": {
      "description": "Address number and complements",
      "type": "string",
      "maxLength": 255
    },
    "addressCity": {
      "description": "Address city",
      "type": "string",
      "maxLength": 255
    },
    "addressDistrict": {
      "description": "Job address district",
      "type": "string",
      "maxLength": 255
    },
    "addressComplements": {
      "description": "Job address complements",
      "type": "string",
      "maxLength": 255
    },
    "addressState": {
      "description": "Address state name (eg. São Paulo)",
      "type": "string",
      "maxLength": 255
    },
    "addressStateShortName": {
      "description": "Address state short name (eg. SP)",
      "type": "string",
      "maxLength": 255
    },
    "addressCountry": {
      "description": "Address country name (eg. Brasil)",
      "type": "string",
      "maxLength": 255
    },
    "addressCountryShortName": {
      "description": "Address country short name (eg. BRA)",
      "type": "string",
      "maxLength": 255
    },
    "addressLatitude": {
      "description": "Work location latitude. If not provided, the addressZipCode will be used to get the latitude (this functionality only works with Brazilian postal codes).",
      "type": "number",
      "format": "double"
    },
    "addressLongitude": {
      "description": "Work location longitude. If not provided, the addressZipCode will be used to get the longitude (this functionality only works with Brazilian postal codes).",
      "type": "number",
      "format": "double"
    },
    "branchId": {
      "description": "Job branch id",
      "type": "number",
      "format": "int64"
    },
    "remoteWorking": {
      "deprecated": true,
      "description": "This job is for remote working. This field will soon be deprecated, please use workplaceType instead for setting remoteWorking accurately.",
      "type": "boolean"
    },
    "workplaceType": {
      "description": "Workplace type. If provided, will be used to set the remoteWorking correctly.",
      "type": "string",
      "maxLength": 255,
      "enum": [
        "hybrid",
        "on-site",
        "remote"
      ]
    },
    "salary": {
      "description": "Job salary information (not shown in the career page).",
      "type": "object",
      "required": [
        "currency",
        "startsAt"
      ],
      "properties": {
        "currency": {
          "description": "Job currency code (eg R$, USD)",
          "type": "string",
          "maxLength": 3
        },
        "startsAt": {
          "description": "Starting value",
          "type": "number",
          "format": "double"
        },
        "endsAt": {
          "description": "Ending value",
          "type": "number",
          "format": "double"
        }
      }
    },
    "reason": {
      "description": "Job opening reason",
      "type": "string",
      "maxLength": 255,
      "enum": [
        "staff_increase",
        "staff_replacement"
      ]
    },
    "recruiterEmail": {
      "description": "Job recruiter e-mail. If provided, must be an valid user in Gupy.",
      "type": "string",
      "format": "email",
      "maxLength": 255
    },
    "managerEmail": {
      "description": "Job manager e-mail. If provided, must be an valid user in Gupy.",
      "type": "string",
      "format": "email",
      "maxLength": 255
    },
    "careerPageId": {
      "description": "Id of the career page where the job will be shown. Pass `null` with `isEnableInternalMobility: true` to move to Central-only (scenario A→B / republish Central-only).\n",
      "type": [
        "integer",
        "null"
      ],
      "format": "int64"
    },
    "isEnableInternalMobility": {
      "description": "Enables Career Center (internal mobility) on publish. Requires feature flag `mixed-recruitment` ON for the company. When `true` with `careerPageId`, publishes on the career page and Central (scenario A). When `true` without `careerPageId` (or with `careerPageId: null`), publishes only on Central (scenario B / Central-only). Ignored when the feature flag is OFF.\n",
      "type": "boolean"
    },
    "hiringDeadline": {
      "description": "Deadline for hiring candidates",
      "type": "string",
      "format": "date"
    },
    "applicationDeadline": {
      "description": "Final date for application",
      "type": "string",
      "format": "date"
    },
    "customFields": {
      "description": "Custom fields values defined for this job.",
      "type": "array",
      "items": {
        "$ref": "#/$defs/jobCustomFieldData"
      }
    },
    "cancelReason": {
      "description": "Job cancel reason",
      "type": "string",
      "maxLength": 255,
      "enum": [
        "staff_increase_or_substitution_postponed",
        "cancellation_requested_by_manager",
        "internal_transfer",
        "organizational_restructuring",
        "budget_review",
        "other"
      ]
    },
    "cancelReasonNotes": {
      "description": "Job cancel reason notes provided by user when cancelReason is other",
      "type": "string",
      "maxLength": 255
    },
    "canceledByEmail": {
      "description": "E-mail of the person who canceled the job",
      "type": "string",
      "maxLength": 255,
      "format": "email"
    },
    "videoUrl": {
      "description": "A video url about the job.",
      "type": "string",
      "maxLength": 255
    },
    "approvers": {
      "description": "User ids to be approvers of the job",
      "type": "array",
      "items": {
        "description": "User ids",
        "type": "number"
      }
    },
    "workflowRequestMethod": {
      "description": "Workflow request method",
      "type": "string",
      "maxLength": 255,
      "enum": [
        "all_at_once",
        "in_order"
      ]
    },
    "jobBoards": {
      "description": "Job Boards ids to be published Refer to https://developers.gupy.io/docs/updating-a-job (portuguese only) for more information on updating the jobBoards of a job.",
      "type": "array",
      "items": {
        "description": "Job Boards ids",
        "type": "number"
      }
    }
  },
  "$defs": {
    "jobCustomFieldData": {
      "description": "Custom field data for job creation or update",
      "type": "object",
      "properties": {
        "id": {
          "description": "Custom field id",
          "type": "string",
          "maxLength": 255
        },
        "value": {
          "oneOf": [
            {
              "type": "string",
              "maxLength": 255,
              "description": "Custom field provided value"
            },
            {
              "type": "array",
              "items": {
                "type": "string",
                "maxLength": 255
              },
              "description": "Custom field selected options which must be available in enum of `jobCustomFields`"
            }
          ]
        }
      }
    }
  }
}