{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/sportstatsapi/json-schema/sportstatsapi-dto-biathlon-athlete-response-schema.json",
  "title": "dto.BiathlonAthleteResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/sportstatsapi-biathlon-api-openapi.yml#/components/schemas/dto.BiathlonAthleteResponse",
  "properties": {
    "birth_date": {
      "type": "string"
    },
    "family_name": {
      "type": "string"
    },
    "gender": {
      "enum": [
        "male",
        "female"
      ],
      "type": "string"
    },
    "given_name": {
      "type": "string"
    },
    "id": {
      "type": "integer"
    },
    "name": {
      "type": "string"
    },
    "nation": {
      "type": "string"
    },
    "results": {
      "items": {
        "$ref": "#/$defs/dto.BiathlonAthleteResultResponse"
      },
      "type": "array"
    }
  },
  "type": "object",
  "$defs": {
    "dto.BiathlonAthleteResultResponse": {
      "properties": {
        "athlete_id": {
          "type": "integer"
        },
        "behind": {
          "type": "string"
        },
        "bib": {
          "type": "string"
        },
        "event": {
          "$ref": "#/$defs/dto.BiathlonEventResponse"
        },
        "irm": {
          "type": "string"
        },
        "leg": {
          "type": "integer"
        },
        "legs": {
          "items": {
            "$ref": "#/$defs/dto.BiathlonResultResponse"
          },
          "type": "array"
        },
        "name": {
          "type": "string"
        },
        "nation": {
          "type": "string"
        },
        "penalties": {
          "description": "misses (relays: penalty loops)",
          "type": "integer"
        },
        "race": {
          "$ref": "#/$defs/dto.BiathlonRaceResponse"
        },
        "rank": {
          "type": "integer"
        },
        "shooting": {
          "type": "string"
        },
        "shooting_total": {
          "type": "string"
        },
        "spare_rounds": {
          "type": "integer"
        },
        "total_time": {
          "type": "string"
        },
        "wc_points": {
          "type": "integer"
        }
      },
      "type": "object"
    },
    "dto.BiathlonEventResponse": {
      "properties": {
        "country": {
          "description": "IOC code",
          "type": "string"
        },
        "end_date": {
          "type": "string"
        },
        "id": {
          "type": "integer"
        },
        "kind": {
          "enum": [
            "world-cup",
            "world-championships",
            "olympics",
            "ibu-cup",
            "european-championships",
            "other"
          ],
          "type": "string"
        },
        "level": {
          "enum": [
            "world-cup",
            "ibu-cup"
          ],
          "type": "string"
        },
        "location": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "race_count": {
          "type": "integer"
        },
        "races": {
          "items": {
            "$ref": "#/$defs/dto.BiathlonRaceResponse"
          },
          "type": "array"
        },
        "season": {
          "type": "string"
        },
        "start_date": {
          "type": "string"
        },
        "status_code": {
          "enum": [
            "scheduled",
            "live",
            "final"
          ],
          "type": "string"
        }
      },
      "type": "object"
    },
    "dto.BiathlonRaceResponse": {
      "properties": {
        "discipline": {
          "description": "sprint, pursuit, individual, short-individual, mass-start, relay, single-mixed-relay...",
          "type": "string"
        },
        "distance_km": {
          "type": "string"
        },
        "event_id": {
          "type": "integer"
        },
        "gender": {
          "enum": [
            "men",
            "women",
            "mixed"
          ],
          "type": "string"
        },
        "has_results": {
          "type": "boolean"
        },
        "id": {
          "type": "integer"
        },
        "legs": {
          "type": "integer"
        },
        "name": {
          "type": "string"
        },
        "results": {
          "items": {
            "$ref": "#/$defs/dto.BiathlonResultResponse"
          },
          "type": "array"
        },
        "shootings": {
          "description": "shooting stages (per leg in relays)",
          "type": "integer"
        },
        "start_at": {
          "description": "UTC",
          "type": "string"
        },
        "status": {
          "type": "string"
        },
        "status_code": {
          "enum": [
            "scheduled",
            "live",
            "final",
            "cancelled",
            "postponed"
          ],
          "type": "string"
        },
        "updated_at": {
          "type": "string"
        },
        "winner": {
          "description": "athlete or (relays) nation, once final",
          "type": "string"
        }
      },
      "type": "object"
    },
    "dto.BiathlonResultResponse": {
      "properties": {
        "athlete_id": {
          "type": "integer"
        },
        "behind": {
          "type": "string"
        },
        "bib": {
          "type": "string"
        },
        "irm": {
          "type": "string"
        },
        "leg": {
          "type": "integer"
        },
        "legs": {
          "items": {
            "$ref": "#/$defs/dto.BiathlonResultResponse"
          },
          "type": "array"
        },
        "name": {
          "type": "string"
        },
        "nation": {
          "type": "string"
        },
        "penalties": {
          "description": "misses (relays: penalty loops)",
          "type": "integer"
        },
        "rank": {
          "type": "integer"
        },
        "shooting": {
          "type": "string"
        },
        "shooting_total": {
          "type": "string"
        },
        "spare_rounds": {
          "type": "integer"
        },
        "total_time": {
          "type": "string"
        },
        "wc_points": {
          "type": "integer"
        }
      },
      "type": "object"
    }
  }
}