{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/gloat/main/json-schema/gloat-project-role-object-schema.json",
  "title": "project_role_object",
  "x-generated": "2026-10-14",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/gloat-customer-api-openapi.yml#/components/schemas/project_role_object",
  "type": "object",
  "required": [
    "project_id",
    "job_id",
    "status"
  ],
  "properties": {
    "project_id": {
      "type": "string"
    },
    "job_id": {
      "type": "string"
    },
    "status": {
      "$ref": "#/$defs/job_status"
    },
    "title": {
      "type": "string"
    },
    "description": {
      "type": "string"
    },
    "description_html": {
      "type": "string"
    },
    "department_id": {
      "type": "string"
    },
    "departments": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "experiences": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "function": {
      "type": "string"
    },
    "sub_function": {
      "type": "string"
    },
    "business_unit": {
      "type": "string"
    },
    "job_code": {
      "type": "string"
    },
    "job_family": {
      "type": "string"
    },
    "languages": {
      "$ref": "#/$defs/language_array"
    },
    "location_type": {
      "$ref": "#/$defs/job_location_type"
    },
    "locations": {
      "$ref": "#/$defs/location_array"
    },
    "sites": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "translations": {
      "$ref": "#/$defs/translation_array"
    },
    "unposting_date": {
      "type": "string"
    },
    "owners": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "role": {
            "type": "string",
            "enum": [
              "MN",
              "HR",
              "RC",
              "CO",
              "VI"
            ]
          }
        }
      }
    }
  },
  "$defs": {
    "job_location_type": {
      "type": "string",
      "enum": [
        "GLOBAL",
        "LOCAL",
        "LOCAL_WITH_RELOCATION",
        "REMOTE"
      ]
    },
    "job_status": {
      "type": "string",
      "enum": [
        "OP",
        "CL",
        "CA",
        "PE"
      ],
      "description": "Job status:\n  * `OP` - open\n  * `PE` - pending\n  * `CL` - closed\n  * `CA` - closed for applications (invisible for imob)"
    },
    "language_array": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "code",
          "level"
        ],
        "properties": {
          "code": {
            "type": "string",
            "description": "2 letter language code"
          },
          "level": {
            "type": "string",
            "enum": [
              "BA",
              "AD",
              "FL",
              "NL",
              "NT"
            ],
            "description": "language proficiency level:\n  * `BA` - Basic\n  * `AD` - Advanced\n  * `FL` - Fluent\n  * `NL` - Native Level\n  * `NT` - Native"
          }
        }
      }
    },
    "location_array": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "city",
          "country_code"
        ],
        "properties": {
          "city": {
            "type": "string"
          },
          "country_code": {
            "type": "string"
          },
          "state": {
            "type": "string",
            "default": ""
          }
        }
      }
    },
    "translation_array": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "language",
          "title",
          "description"
        ],
        "properties": {
          "language": {
            "type": "string"
          },
          "title": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "description_html": {
            "type": "string"
          }
        }
      }
    }
  }
}