{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/cavuno-com/json-schema/cavuno-com-candidate-profile-projection-schema.json",
  "title": "CandidateProfileProjection",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/cavuno-com-candidates-api-openapi.yml#/components/schemas/CandidateProfileProjection",
  "type": "object",
  "properties": {
    "headline": {
      "type": [
        "string",
        "null"
      ],
      "description": "Absent key leaves the stored headline unchanged; `null` clears it."
    },
    "bio": {
      "type": [
        "string",
        "null"
      ],
      "description": "Absent key leaves the stored bio unchanged; `null` clears it."
    },
    "location": {
      "type": [
        "string",
        "null"
      ],
      "description": "Absent key leaves the stored location unchanged; `null` clears it."
    },
    "countryCode": {
      "type": [
        "string",
        "null"
      ],
      "description": "Absent key leaves the stored country code unchanged; `null` clears it. Ignored without an error while the candidate has a home place that this request keeps (a changed `location` removes it): the country code is then that place's country."
    },
    "skills": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "maxItems": 200,
      "description": "Absent key leaves the stored skills unchanged. Providing an array replaces the collection wholesale (empty array clears). Maximum 200 rows."
    },
    "languages": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/CandidateProfileLanguageProjection"
      },
      "maxItems": 50,
      "description": "Absent key leaves the stored languages unchanged. Providing an array replaces the collection wholesale (empty array clears). Maximum 50 rows."
    },
    "experience": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/CandidateProfileExperienceProjection"
      },
      "maxItems": 50,
      "description": "Absent key leaves the stored experience unchanged. Providing an array replaces the collection wholesale (empty array clears). Maximum 50 rows."
    },
    "education": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/CandidateProfileEducationProjection"
      },
      "maxItems": 50,
      "description": "Absent key leaves the stored education unchanged. Providing an array replaces the collection wholesale (empty array clears). Maximum 50 rows."
    }
  },
  "additionalProperties": false,
  "$defs": {
    "CandidateProfileEducationProjection": {
      "type": "object",
      "properties": {
        "institutionName": {
          "type": "string",
          "minLength": 1,
          "description": "Institution name."
        },
        "institutionUrl": {
          "type": [
            "string",
            "null"
          ],
          "description": "Institution URL."
        },
        "degree": {
          "type": [
            "string",
            "null"
          ],
          "description": "Degree awarded."
        },
        "fieldOfStudy": {
          "type": [
            "string",
            "null"
          ],
          "description": "Field of study."
        },
        "grade": {
          "type": [
            "string",
            "null"
          ],
          "description": "Grade or GPA."
        },
        "activitiesAndSocieties": {
          "type": [
            "string",
            "null"
          ],
          "description": "Activities and societies."
        },
        "startDate": {
          "type": [
            "string",
            "null"
          ],
          "description": "Start date."
        },
        "endDate": {
          "type": [
            "string",
            "null"
          ],
          "description": "End date."
        },
        "description": {
          "type": [
            "string",
            "null"
          ],
          "description": "Education description."
        },
        "sortOrder": {
          "type": "integer",
          "description": "Display order, lower first."
        }
      },
      "required": [
        "institutionName",
        "sortOrder"
      ],
      "additionalProperties": false
    },
    "CandidateProfileExperienceProjection": {
      "type": "object",
      "properties": {
        "title": {
          "type": "string",
          "minLength": 1,
          "description": "Job title."
        },
        "companyName": {
          "type": "string",
          "minLength": 1,
          "description": "Employer name."
        },
        "companyUrl": {
          "type": [
            "string",
            "null"
          ],
          "description": "Employer URL."
        },
        "location": {
          "type": [
            "string",
            "null"
          ],
          "description": "Role location."
        },
        "employmentType": {
          "type": [
            "string",
            "null"
          ],
          "description": "Employment type."
        },
        "locationType": {
          "type": [
            "string",
            "null"
          ],
          "description": "Location type."
        },
        "foundVia": {
          "type": [
            "string",
            "null"
          ],
          "description": "How the role was found."
        },
        "startDate": {
          "type": "string",
          "minLength": 1,
          "description": "Start date."
        },
        "endDate": {
          "type": [
            "string",
            "null"
          ],
          "description": "End date."
        },
        "description": {
          "type": [
            "string",
            "null"
          ],
          "description": "Role description."
        },
        "experienceSkills": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": "string"
          },
          "maxItems": 50,
          "description": "Per-role skills; replaced with the row."
        },
        "sortOrder": {
          "type": "integer",
          "description": "Display order, lower first."
        }
      },
      "required": [
        "title",
        "companyName",
        "startDate",
        "sortOrder"
      ],
      "additionalProperties": false
    },
    "CandidateProfileLanguageProjection": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1,
          "description": "Language name."
        },
        "proficiency": {
          "type": "string",
          "minLength": 1,
          "description": "Proficiency label."
        },
        "sortOrder": {
          "type": "integer",
          "description": "Display order, lower first."
        }
      },
      "required": [
        "name",
        "proficiency",
        "sortOrder"
      ],
      "additionalProperties": false
    }
  }
}