{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://pointcast.xyz/internships/roles.schema.json",
  "title": "PointCast Internship Roles",
  "type": "object",
  "required": ["title", "canonical_url", "program_lead", "operating_model", "conduct_expectations", "roles"],
  "properties": {
    "title": { "type": "string" },
    "canonical_url": { "type": "string", "format": "uri" },
    "status": { "type": "string" },
    "program_lead": {
      "type": "object",
      "required": ["name", "role", "note"],
      "properties": {
        "name": { "type": "string" },
        "role": { "type": "string" },
        "note": { "type": "string" }
      }
    },
    "operating_model": {
      "type": "object",
      "required": ["format", "cadence", "participation_url", "reward_url", "terms_note"],
      "properties": {
        "format": { "type": "string" },
        "cadence": { "type": "string" },
        "participation_url": { "type": "string", "format": "uri" },
        "reward_url": { "type": "string", "format": "uri" },
        "program_script_url": { "type": "string", "format": "uri" },
        "nouns_interest_url": { "type": "string", "format": "uri" },
        "terms_note": { "type": "string" }
      }
    },
    "interest_paths": {
      "type": "array",
      "items": { "type": "object" }
    },
    "conduct_expectations": {
      "type": "array",
      "items": { "type": "string" }
    },
    "roles": {
      "type": "array",
      "items": { "$ref": "#/$defs/role" }
    },
    "regional_missions": {
      "type": "array",
      "items": {
        "type": "object",
        "required": ["region", "focus"],
        "properties": {
          "region": { "type": "string" },
          "focus": { "type": "string" }
        }
      }
    }
  },
  "$defs": {
    "role": {
      "type": "object",
      "required": ["id", "title", "track", "mission", "tasks", "interests"],
      "properties": {
        "id": { "type": "string" },
        "title": { "type": "string" },
        "track": { "type": "string" },
        "mission": { "type": "string" },
        "tasks": {
          "type": "array",
          "items": { "type": "string" }
        },
        "interests": {
          "type": "array",
          "items": { "type": "string" }
        },
        "pathway_ids": {
          "type": "array",
          "items": { "type": "string" }
        }
      }
    }
  }
}
