{
  "openapi": "3.0.2",
  "info": {
    "title": "Polymath API Service",
    "description": "Polymath API service to interact with a real or simulated polymath-powered robot",
    "termsOfService": "https://www.polymathrobotics.com/legal/terms-of-service",
    "contact": {
      "name": "Polymath Support",
      "url": "https://www.polymathrobotics.com",
      "email": "api@polymathrobotics.com"
    },
    "license": {
      "name": "All rights reserved",
      "url": "https://www.polymathrobotics.com/legal/privacy-policy"
    },
    "version": "2.0.0"
  },
  "paths": {
    "/v2/version": {
      "get": {
        "tags": [
          "Health Check"
        ],
        "summary": "Get the version of the Polymath system",
        "description": "Returns the current Polymath Synapse and polymath_core commit SHAs.",
        "operationId": "get_version",
        "responses": {
          "200": {
            "description": "Polymath Synapse and polymath_core commit SHAs.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VersionResponse"
                }
              }
            }
          }
        }
      }
    },
    "/v2/health": {
      "get": {
        "tags": [
          "Health Check"
        ],
        "summary": "System health check endpoint",
        "description": "Returns a summary of the system fault status, Reports an overall `health_summary` and per-subsystem states, each subsystem carrying its list of active faults. If the fault source is unreachable, `fault_source_available` is false and the summary state is `UNKNOWN`.",
        "operationId": "get_health",
        "responses": {
          "200": {
            "description": "System fault-status summary.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HealthStatusResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/health"
        }
      }
    },
    "/v2/uuid": {
      "get": {
        "tags": [
          "Health Check"
        ],
        "summary": "Get the UUID of the Polymath system",
        "description": "Returns the device UUID derived from its MAC address. Deprecated; use `/health`.",
        "operationId": "get_device_uuid",
        "responses": {
          "200": {
            "description": "Device UUID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UUIDResponse"
                }
              }
            }
          },
          "404": {
            "description": "Resource not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "deprecated": true
      }
    },
    "/v2/polymath-feedback": {
      "get": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Get the combined Autonomy, Navigation and Vehicle feedback from the Polymath system",
        "description": "Returns combined autonomy, navigation, and vehicle feedback from the Polymath system.",
        "operationId": "polymath_feedback",
        "responses": {
          "200": {
            "description": "Combined autonomy, navigation, and vehicle feedback.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PolymathFeedbackResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/feedback"
        }
      }
    },
    "/v2/costmap/boundary": {
      "get": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Get global costmap boundary coordinates",
        "description": "Returns the latest latitude/longitude coordinates for the four corners of the global costmap boundary.",
        "operationId": "costmap_boundary",
        "responses": {
          "200": {
            "description": "Costmap boundary corner coordinates.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CostmapBoundaryResponse"
                }
              }
            }
          },
          "404": {
            "description": "Costmap boundary data unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/v2/navigation-path-options": {
      "get": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Get the available Navigation Path Options and associated Parameters",
        "description": "Returns available navigation path options and configurable parameters.",
        "operationId": "navigation_path_options",
        "responses": {
          "200": {
            "description": "Available navigation path options and parameters.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PathLogicOptionResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/navigation-path-options"
        }
      }
    },
    "/v2/vehicle-commands": {
      "get": {
        "tags": [
          "Vehicle Operations"
        ],
        "summary": "Get the available Vehicle Commands and associated Parameters",
        "description": "Returns available vehicle command options and configurable parameters.",
        "operationId": "vehicle_commands",
        "responses": {
          "200": {
            "description": "Available vehicle command options and parameters.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VehicleCommandOptionResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/vehicle-commands"
        }
      }
    },
    "/v2/motion-commands": {
      "get": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Get the available motion commands",
        "description": "Returns available motion commands that can be sent to the Polymath system.",
        "operationId": "get_nav_cmds",
        "responses": {
          "200": {
            "description": "Available motion command names and numeric alternatives.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MotionCommandListResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/motion-commands"
        }
      }
    },
    "/v2/reference-targets": {
      "get": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Get all previously set reference targets",
        "description": "Returns all previously set reference targets.",
        "operationId": "reference_targets",
        "responses": {
          "200": {
            "description": "All previously set reference targets.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReferenceTargetsResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/reference-targets"
        }
      },
      "post": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Set the location and details of a reference location or an object",
        "description": "Sets one or more reference targets for relative navigation. Each target may include optional `time_validity` and `recorded_speed_m_s` metadata. Use `POST /relative-waypoints` to send waypoints relative to these targets.",
        "operationId": "set_reference_targets",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReferenceTargetsModel"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Sent reference targets and upstream service response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReferenceTargetSetResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/reference-targets"
        }
      }
    },
    "/v2/reference-targets/current-location": {
      "post": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Set a reference target at the current robot location",
        "description": "Creates a `previous_location` reference target from the robot's current GPS pose for subsequent relative navigation.",
        "operationId": "set_reference_target_current_location",
        "responses": {
          "200": {
            "description": "Generated current-location reference target and upstream service response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReferenceTargetSetResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/reference-targets/current-location"
        }
      }
    },
    "/v2/gps-waypoints": {
      "post": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Send a set of gps waypoints to the robot",
        "description": "Sends GPS waypoints and navigation options to the robot.",
        "operationId": "gps_waypoints",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GPSWaypoints"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Sent GPS waypoints and upstream service response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GPSWaypointTransmissionResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/gps-waypoints"
        }
      }
    },
    "/v2/relative-waypoints": {
      "post": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Send a set of relative waypoints to the robot",
        "description": "Sends relative waypoints and navigation options to the robot.",
        "operationId": "relative_waypoints",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RelativeWaypoints"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Sent relative waypoints and upstream service response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RelativeWaypointTransmissionResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/relative-waypoints"
        }
      }
    },
    "/v2/motion-command": {
      "post": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Send a motion command to the robot to change its current state",
        "description": "Sends a motion command to change the robot motion state. Supported commands: `STOP` (0), `PAUSE` (1), and `RESUME` (2).",
        "operationId": "nav_cmd",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MotionCommandAction"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Motion command execution response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MotionCommandExecutionResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/motion-command"
        }
      }
    },
    "/v2/vehicle-command": {
      "post": {
        "tags": [
          "Vehicle Operations"
        ],
        "summary": "Send a vehicle command to the robot",
        "description": "Sends a vehicle command to the robot.",
        "operationId": "vehicle_command",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VehicleCommandAction"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Sent vehicle command and upstream service response.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VehicleCommandResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/vehicle-command"
        }
      }
    },
    "/v2/command-history": {
      "get": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Get the history of commands the robot has finished",
        "description": "Returns command records that have reached a terminal state, newest first, from cortex's bounded history ring. Each record carries the command id that was returned when the command was submitted, so a caller can look up how one of its own commands ended. Filters are optional and combine.",
        "operationId": "get_command_history",
        "parameters": [
          {
            "description": "Maximum number of records to return. Zero means no limit.",
            "required": false,
            "schema": {
              "title": "Max Count",
              "maximum": 4294967295.0,
              "minimum": 0.0,
              "type": "integer",
              "description": "Maximum number of records to return. Zero means no limit.",
              "default": 0
            },
            "name": "max_count",
            "in": "query"
          },
          {
            "description": "Only return records completed at or after this time, in seconds. Zero disables.",
            "required": false,
            "schema": {
              "title": "Since Sec",
              "maximum": 2147483647.0,
              "minimum": 0.0,
              "type": "integer",
              "description": "Only return records completed at or after this time, in seconds. Zero disables.",
              "default": 0
            },
            "name": "since_sec",
            "in": "query"
          },
          {
            "description": "Nanosecond part of the since filter.",
            "required": false,
            "schema": {
              "title": "Since Nanosec",
              "maximum": 4294967295.0,
              "minimum": 0.0,
              "type": "integer",
              "description": "Nanosecond part of the since filter.",
              "default": 0
            },
            "name": "since_nanosec",
            "in": "query"
          },
          {
            "description": "Only return the record with this command id. Empty disables the filter.",
            "required": false,
            "schema": {
              "title": "Command Id",
              "type": "string",
              "description": "Only return the record with this command id. Empty disables the filter.",
              "default": ""
            },
            "name": "command_id",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Terminal command records, newest first.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CommandHistoryResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/command-history"
        }
      }
    },
    "/v2/command-queue": {
      "get": {
        "tags": [
          "Vehicle Autonomy"
        ],
        "summary": "Get the commands the robot has queued up",
        "description": "Returns a snapshot of the live command queue in dispatch order, plus the id of the command currently being executed. The snapshot is refreshed once per cortex tick, so it may lag the live queue by one tick.",
        "operationId": "get_command_queue",
        "responses": {
          "200": {
            "description": "Queued command records, the active command id, and the number remaining.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CommandQueueResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/command-queue"
        }
      }
    },
    "/v2/media/streams": {
      "get": {
        "tags": [
          "Media"
        ],
        "summary": "List Media Devices",
        "operationId": "list_media_devices",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "title": "Response List Media Devices V2 Media Streams Get",
                  "type": "array",
                  "items": {
                    "anyOf": [
                      {
                        "$ref": "#/components/schemas/BaseStream"
                      },
                      {
                        "$ref": "#/components/schemas/BaseStream"
                      }
                    ]
                  }
                }
              }
            }
          }
        }
      }
    },
    "/v2/livekit/config": {
      "get": {
        "tags": [
          "Livekit"
        ],
        "summary": "Get LiveKit discovery configuration",
        "description": "Returns the configured discovery values and effective LiveKit URL.",
        "operationId": "get_livekit_config",
        "responses": {
          "200": {
            "description": "Effective LiveKit discovery values.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LivekitConfigResponse"
                }
              }
            }
          }
        }
      }
    },
    "/v2/livekit/token": {
      "post": {
        "tags": [
          "Livekit"
        ],
        "summary": "Generate a Livekit access token",
        "description": "Generates a LiveKit access token for the specified identity and room.",
        "operationId": "generate_livekit_token",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Identity",
              "type": "string"
            },
            "name": "identity",
            "in": "query"
          },
          {
            "required": true,
            "schema": {
              "title": "Room Name",
              "type": "string"
            },
            "name": "room_name",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Generated LiveKit access token.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LivekitTokenResponse"
                }
              }
            }
          },
          "400": {
            "description": "Failed to generate token",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPExceptionResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v2/livekit/room": {
      "get": {
        "tags": [
          "Livekit"
        ],
        "summary": "Get the current status of the room",
        "description": "Returns the current LiveKit room status.",
        "operationId": "get_room",
        "responses": {
          "200": {
            "description": "Current LiveKit room status.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LivekitRoomResponse"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Livekit"
        ],
        "summary": "Create a livekit room on this robot",
        "description": "Connects this robot to the specified LiveKit room.",
        "operationId": "create_room",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Room Name",
              "type": "string"
            },
            "name": "room_name",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Room status after connecting to LiveKit.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LivekitRoomResponse"
                }
              }
            }
          },
          "400": {
            "description": "Invalid room request (for example, empty or invalid room name)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPExceptionResponse"
                }
              }
            }
          },
          "500": {
            "description": "Failed to connect to the room",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPExceptionResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Livekit"
        ],
        "summary": "Disconnect from the current room",
        "description": "Disconnects this robot from the current LiveKit room.",
        "operationId": "delete_room",
        "responses": {
          "200": {
            "description": "Room status after disconnecting from LiveKit.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LivekitRoomResponse"
                }
              }
            }
          },
          "500": {
            "description": "Failed to disconnect the room",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPExceptionResponse"
                }
              }
            }
          }
        }
      }
    },
    "/v2/livekit/room/track": {
      "post": {
        "tags": [
          "Livekit"
        ],
        "summary": "Create a track on the current room",
        "description": "Creates and publishes a track in the current LiveKit room.",
        "operationId": "create_track",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Fps",
              "type": "integer",
              "default": 30
            },
            "name": "fps",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/CodecEnum"
                }
              ],
              "default": "H264"
            },
            "name": "codec",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/MediaTypeEnum"
                }
              ],
              "default": "media_device"
            },
            "name": "media_type",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Stream Path",
              "type": "string"
            },
            "name": "stream_path",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Use Experimental Reader",
              "type": "boolean",
              "default": false
            },
            "name": "use_experimental_reader",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Width",
              "type": "integer"
            },
            "name": "width",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Height",
              "type": "integer"
            },
            "name": "height",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Max Bitrate Kbps",
              "type": "integer"
            },
            "name": "max_bitrate_kbps",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Room status after track creation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LivekitRoomResponse"
                }
              }
            }
          },
          "400": {
            "description": "Invalid track request (for example, no room, invalid configuration, or duplicate track name)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPExceptionResponse"
                }
              }
            }
          },
          "500": {
            "description": "Failed to publish track",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPExceptionResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Livekit"
        ],
        "summary": "Delete a track from the current room",
        "description": "Deletes a track from the current LiveKit room.",
        "operationId": "delete_track",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Room status after track deletion.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LivekitRoomResponse"
                }
              }
            }
          },
          "400": {
            "description": "Invalid track delete request (for example, no room or track does not exist)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPExceptionResponse"
                }
              }
            }
          },
          "500": {
            "description": "Failed to delete track",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPExceptionResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v2/canbus/interfaces": {
      "get": {
        "tags": [
          "CANBus"
        ],
        "summary": "Get the list of available CAN interfaces on the system",
        "description": "Returns available CAN interfaces on the system.",
        "operationId": "get_can_interfaces",
        "responses": {
          "200": {
            "description": "Available CAN interfaces.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CanInterfaceListResponse"
                }
              }
            }
          },
          "404": {
            "description": "Failed to retrieve CAN interfaces",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "An unexpected error occurred",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/v2/teleop-control/acquire": {
      "post": {
        "tags": [
          "Teleop Control"
        ],
        "summary": "Acquire control lease granting exclusive access to teleop",
        "description": "Acquire control lease if none exists or has expired.",
        "operationId": "acquire_lease",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ControlResponse"
                }
              }
            }
          },
          "403": {
            "description": "Lease is unavailable or not held by the requesting user",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Authentication required",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {
            "HTTPBearer": []
          }
        ]
      }
    },
    "/v2/teleop-control/renew": {
      "post": {
        "tags": [
          "Teleop Control"
        ],
        "summary": "Renew existing control lease",
        "description": "Renew an existing lease. Only the current lease holder can renew.",
        "operationId": "renew_lease",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ControlResponse"
                }
              }
            }
          },
          "403": {
            "description": "Lease is unavailable or not held by the requesting user",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Authentication required",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {
            "HTTPBearer": []
          }
        ]
      }
    },
    "/v2/teleop-control/release": {
      "post": {
        "tags": [
          "Teleop Control"
        ],
        "summary": "Release the current control lease",
        "description": "Explicitly release the current lease.",
        "operationId": "release_lease",
        "parameters": [
          {
            "description": "If true, release the lease regardless of who holds it. Requires valid bearer token; no additional admin validation exists.",
            "required": false,
            "schema": {
              "title": "Force",
              "type": "boolean",
              "description": "If true, release the lease regardless of who holds it. Requires valid bearer token; no additional admin validation exists.",
              "default": false
            },
            "name": "force",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ControlResponse"
                }
              }
            }
          },
          "403": {
            "description": "Lease is unavailable or not held by the requesting user",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Authentication required",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "HTTPBearer": []
          }
        ]
      }
    },
    "/v2/teleop-control/transfer": {
      "post": {
        "tags": [
          "Teleop Control"
        ],
        "summary": "Transfer control lease to another user",
        "description": "Transfer the lease to another user. Only the current lease holder can transfer.",
        "operationId": "transfer_lease",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TransferLeaseRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ControlResponse"
                }
              }
            }
          },
          "403": {
            "description": "Lease is unavailable or not held by the requesting user",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Authentication required",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "security": [
          {
            "HTTPBearer": []
          }
        ]
      }
    },
    "/v2/teleop-control/status": {
      "get": {
        "tags": [
          "Teleop Control"
        ],
        "summary": "Get current control lease status",
        "description": "Get current lease status and lease holder identity.",
        "operationId": "get_lease_status",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ControlResponse"
                }
              }
            }
          }
        }
      }
    },
    "/v2/systemd/{path}": {
      "get": {
        "tags": [
          "systemd"
        ],
        "summary": "Proxy Systemd Request",
        "description": "Reverse proxy for Polymath systemd API requests. Please refer to the API documentation for details on available endpoints.\n\nForwards all requests under /v2/systemd/* to the systemd API service\nat POLYMATH_SYSTEMD_API_IP:POLYMATH_SYSTEMD_API_PORT.\n\nE.g. to list user services, send a GET request to: `/v2/systemd/list/user`",
        "operationId": "proxy_systemd_request",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Path",
              "type": "string"
            },
            "name": "path",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "systemd"
        ],
        "summary": "Proxy Systemd Request",
        "description": "Reverse proxy for Polymath systemd API requests. Please refer to the API documentation for details on available endpoints.\n\nForwards all requests under /v2/systemd/* to the systemd API service\nat POLYMATH_SYSTEMD_API_IP:POLYMATH_SYSTEMD_API_PORT.\n\nE.g. to list user services, send a GET request to: `/v2/systemd/list/user`",
        "operationId": "proxy_systemd_request",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Path",
              "type": "string"
            },
            "name": "path",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v2/fs/health": {
      "get": {
        "tags": [
          "filesystem",
          "filesystem"
        ],
        "summary": "Health check for dufs service",
        "description": "Checks whether the dufs service is reachable. Always returns HTTP 200 and reports health in the response body.",
        "operationId": "health_check",
        "responses": {
          "200": {
            "description": "Service health status (healthy or degraded)",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          }
        }
      }
    },
    "/v2/fs/recursive-list": {
      "get": {
        "tags": [
          "filesystem",
          "filesystem"
        ],
        "summary": "List files and directories recursively",
        "description": "Returns a recursive file and directory tree from the robot data directory.",
        "operationId": "list_files_and_directories",
        "parameters": [
          {
            "required": false,
            "schema": {
              "title": "Depth",
              "type": "integer",
              "default": 5
            },
            "name": "depth",
            "in": "query"
          },
          {
            "required": false,
            "schema": {
              "title": "Path",
              "type": "string",
              "default": "/"
            },
            "name": "path",
            "in": "query"
          }
        ],
        "responses": {
          "200": {
            "description": "List of files and directories",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "503": {
            "description": "Service unavailable"
          },
          "504": {
            "description": "Request timed out"
          },
          "500": {
            "description": "Internal server error"
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v2/fs/{path}": {
      "get": {
        "tags": [
          "filesystem",
          "filesystem"
        ],
        "summary": "Get file or directory",
        "description": "Returns file content or a directory listing from the robot data directory. Use `?zip` to download a zip archive. Use `?json` for directory listings in JSON format.",
        "operationId": "get_file_or_directory",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Path",
              "type": "string"
            },
            "name": "path",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "File content or directory listing",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "404": {
            "description": "File or directory not found"
          },
          "503": {
            "description": "Service unavailable"
          },
          "504": {
            "description": "Request timed out"
          },
          "500": {
            "description": "Internal server error"
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "filesystem",
          "filesystem"
        ],
        "summary": "Delete file or directory",
        "description": "Deletes a file or directory from the robot data directory.",
        "operationId": "delete_file_or_directory",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Path",
              "type": "string"
            },
            "name": "path",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "204": {
            "description": "File or directory deleted successfully"
          },
          "404": {
            "description": "File or directory not found"
          },
          "503": {
            "description": "Service unavailable"
          },
          "504": {
            "description": "Request timed out"
          },
          "500": {
            "description": "Internal server error"
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v2/ros/{path}": {
      "get": {
        "tags": [
          "ros"
        ],
        "summary": "Proxy Systemd Request",
        "description": "Reverse proxy for RESTful ROS2 API requests. Please refer to the API documentation for details on available endpoints.",
        "operationId": "proxy_systemd_request",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Path",
              "type": "string"
            },
            "name": "path",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "ros"
        ],
        "summary": "Proxy Systemd Request",
        "description": "Reverse proxy for RESTful ROS2 API requests. Please refer to the API documentation for details on available endpoints.",
        "operationId": "proxy_systemd_request",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Path",
              "type": "string"
            },
            "name": "path",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v2/sites/{name}": {
      "get": {
        "tags": [
          "Site Management"
        ],
        "summary": "Read a named site in full",
        "operationId": "read_site",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReadSiteResponse"
                }
              }
            }
          },
          "404": {
            "description": "Site not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/sites/{name}"
        }
      },
      "put": {
        "tags": [
          "Site Management"
        ],
        "summary": "Update an existing site",
        "description": "Updates an existing site with this name by replacing the entire site.",
        "operationId": "update_site",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WriteSiteRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WriteSiteResponse"
                }
              }
            }
          },
          "400": {
            "description": "Site failed server-side validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Site to update was not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Request body failed validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/sites/{name}"
        }
      },
      "post": {
        "tags": [
          "Site Management"
        ],
        "summary": "Create a site",
        "description": "Creates a new site for vehicle operation.",
        "operationId": "create_site",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WriteSiteRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Confirmation that the site was created.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WriteSiteResponse"
                }
              }
            }
          },
          "400": {
            "description": "Site failed server-side validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "A site with this name already exists",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Request body failed validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/sites/{name}"
        }
      },
      "delete": {
        "tags": [
          "Site Management"
        ],
        "summary": "Delete a named site",
        "operationId": "delete_site",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelSuccessResponse"
                }
              }
            }
          },
          "404": {
            "description": "Site not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/sites/{name}"
        }
      }
    },
    "/v2/sites": {
      "get": {
        "tags": [
          "Site Management"
        ],
        "summary": "List all sites on the vehicle",
        "operationId": "list_sites",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ListSitesResponse"
                }
              }
            }
          },
          "404": {
            "description": "No sites found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/sites"
        }
      }
    },
    "/v2/active_site": {
      "get": {
        "tags": [
          "Site Management"
        ],
        "summary": "Read the currently active site",
        "description": "Reads the site that is currently active for vehicle operation. This will not return the site that is staged for activation to take effect on next restart, only the site that with activation in-effect.",
        "operationId": "read_active_site",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReadSiteResponse"
                }
              }
            }
          },
          "404": {
            "description": "No site is currently active",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/active-site"
        }
      }
    },
    "/v2/sites/{name}/activate": {
      "post": {
        "tags": [
          "Site Management"
        ],
        "summary": "Stage a site for activation",
        "description": "Stages the named site for activation. The activation will take effect the next time the vehicle starts. Optionally, a route and zone set can be provided, which will be loaded everytime the vehicle starts while this site remains active.",
        "operationId": "activate_site",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ActivateSiteRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelSuccessResponse"
                }
              }
            }
          },
          "404": {
            "description": "Site, route, or zone set not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/sites/{name}/activate"
        }
      }
    },
    "/v2/routes/{name}": {
      "get": {
        "tags": [
          "Route Management"
        ],
        "summary": "Read a named route in full",
        "operationId": "read_route",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReadRouteGraphResponse"
                }
              }
            }
          },
          "404": {
            "description": "Route not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/routes/{name}"
        }
      },
      "put": {
        "tags": [
          "Route Management"
        ],
        "summary": "Update existing route",
        "description": "Updates an existing route with this name by replacing the entire route.",
        "operationId": "update_route",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WriteRouteGraphRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WriteRouteGraphResponse"
                }
              }
            }
          },
          "400": {
            "description": "Route failed server-side validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Route to update was not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Request body failed validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/routes/{name}"
        }
      },
      "post": {
        "tags": [
          "Route Management"
        ],
        "summary": "Create a route",
        "description": "Creates a new route. The route is validated and written as a single whole artifact.",
        "operationId": "create_route",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WriteRouteGraphRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Confirmation that the route was created or updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WriteRouteGraphResponse"
                }
              }
            }
          },
          "400": {
            "description": "Route failed server-side validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "A route with this name already exists",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Request body failed validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/routes/{name}"
        }
      },
      "delete": {
        "tags": [
          "Route Management"
        ],
        "summary": "Delete a named route",
        "description": "Deletes the route with the given name.",
        "operationId": "delete_route",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelSuccessResponse"
                }
              }
            }
          },
          "404": {
            "description": "Route not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/routes/{name}"
        }
      }
    },
    "/v2/routes": {
      "get": {
        "tags": [
          "Route Management"
        ],
        "summary": "List all routes on the vehicle",
        "operationId": "list_routes",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ListRoutesResponse"
                }
              }
            }
          },
          "404": {
            "description": "No routes found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/routes"
        }
      }
    },
    "/v2/loaded_route": {
      "get": {
        "tags": [
          "Route Management"
        ],
        "summary": "Read the currently loaded route",
        "operationId": "read_loaded_route",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReadRouteGraphResponse"
                }
              }
            }
          },
          "404": {
            "description": "No route is currently loaded",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/loaded-route"
        }
      }
    },
    "/v2/routes/{name}/load": {
      "post": {
        "tags": [
          "Route Management"
        ],
        "summary": "Load a route for navigation",
        "description": "Loads the named route for navigation.",
        "operationId": "load_route",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelSuccessResponse"
                }
              }
            }
          },
          "404": {
            "description": "Route not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/routes/{name}/load"
        }
      }
    },
    "/v2/zone_sets/{name}": {
      "get": {
        "tags": [
          "Zone Set Management"
        ],
        "summary": "Read a named zone set in full",
        "operationId": "read_zone_set",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReadZoneSetResponse"
                }
              }
            }
          },
          "404": {
            "description": "Zone set not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/zone-sets/{name}"
        }
      },
      "put": {
        "tags": [
          "Zone Set Management"
        ],
        "summary": "Update an existing zone set",
        "description": "Replaces the entire zone set with this name.",
        "operationId": "update_zone_set",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WriteZoneSetRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WriteZoneSetResponse"
                }
              }
            }
          },
          "400": {
            "description": "Zone set failed server-side validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Zone set to update was not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Request body failed validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/zone-sets/{name}"
        }
      },
      "post": {
        "tags": [
          "Zone Set Management"
        ],
        "summary": "Create a zone set",
        "description": "Creates a new zone set. Validated and written as a single whole artifact.",
        "operationId": "create_zone_set",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WriteZoneSetRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WriteZoneSetResponse"
                }
              }
            }
          },
          "400": {
            "description": "Zone set failed server-side validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "A zone set with this name already exists",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Request body failed validation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/zone-sets/{name}"
        }
      },
      "delete": {
        "tags": [
          "Zone Set Management"
        ],
        "summary": "Delete a named zone set",
        "operationId": "delete_zone_set",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelSuccessResponse"
                }
              }
            }
          },
          "404": {
            "description": "Zone set not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/zone-sets/{name}"
        }
      }
    },
    "/v2/zone_sets": {
      "get": {
        "tags": [
          "Zone Set Management"
        ],
        "summary": "List all zone sets on the vehicle",
        "operationId": "list_zone_sets",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ListZoneSetsResponse"
                }
              }
            }
          },
          "404": {
            "description": "No zone sets found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/zone-sets"
        }
      }
    },
    "/v2/loaded_zone_set": {
      "get": {
        "tags": [
          "Zone Set Management"
        ],
        "summary": "Read the currently loaded zone set",
        "operationId": "read_loaded_zone_set",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReadZoneSetResponse"
                }
              }
            }
          },
          "404": {
            "description": "No zone set is currently loaded",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/loaded-zone-set"
        }
      }
    },
    "/v2/zone_sets/{name}/load": {
      "post": {
        "tags": [
          "Zone Set Management"
        ],
        "summary": "Load a zone set for navigation",
        "operationId": "load_zone_set",
        "parameters": [
          {
            "required": true,
            "schema": {
              "title": "Name",
              "type": "string"
            },
            "name": "name",
            "in": "path"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelSuccessResponse"
                }
              }
            }
          },
          "404": {
            "description": "Zone set not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/zone-sets/{name}/load"
        }
      }
    },
    "/v2/loaded_zone_set/clear": {
      "post": {
        "tags": [
          "Zone Set Management"
        ],
        "summary": "Clear the currently loaded zone set",
        "operationId": "clear_zone_set",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelSuccessResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/loaded-zone-set/clear"
        }
      }
    },
    "/v2/loaded_zone_set/enabled": {
      "patch": {
        "tags": [
          "Zone Set Management"
        ],
        "summary": "Enable/disable individual zones in the loaded set",
        "description": "Enables or disables named zones within the currently loaded zone set. Adjusts runtime state only, does not modify any saved artifact.",
        "operationId": "set_zones_enabled",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetZonesEnabledRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelSuccessResponse"
                }
              }
            }
          },
          "404": {
            "description": "A named zone was not found in the active set",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "No zone set is currently loaded",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "500": {
            "description": "Internal server error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorldModelErrorResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        },
        "x-polymath-public-route": {
          "path": "/v1/vehicles/{vehicleId}/loaded-zone-set/enabled"
        }
      }
    }
  },
  "components": {
    "schemas": {
      "ActivateSiteRequest": {
        "title": "ActivateSiteRequest",
        "type": "object",
        "properties": {
          "route": {
            "title": "Route",
            "type": "string",
            "description": "Optional route to load every time the vehicle starts while operating with this site as active. "
          },
          "zone_set": {
            "title": "Zone Set",
            "type": "string",
            "description": "Optional zone set to load every time the vehicle starts while operating with this site as active. "
          }
        },
        "example": {
          "route": "",
          "zone_set": ""
        }
      },
      "ActiveAlert": {
        "title": "ActiveAlert",
        "required": [
          "fault_code",
          "severity",
          "status"
        ],
        "type": "object",
        "properties": {
          "fault_code": {
            "title": "Fault Code",
            "type": "string"
          },
          "severity": {
            "title": "Severity",
            "type": "string"
          },
          "status": {
            "title": "Status",
            "type": "string"
          },
          "description": {
            "title": "Description",
            "type": "string",
            "default": ""
          },
          "occurrence_count": {
            "title": "Occurrence Count",
            "type": "integer",
            "default": 0
          },
          "reporting_sources": {
            "title": "Reporting Sources",
            "type": "array",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "first_occurred": {
            "title": "First Occurred",
            "type": "object",
            "additionalProperties": {
              "type": "integer"
            }
          },
          "last_occurred": {
            "title": "Last Occurred",
            "type": "object",
            "additionalProperties": {
              "type": "integer"
            }
          }
        }
      },
      "BaseStream": {
        "title": "BaseStream",
        "required": [
          "media_type"
        ],
        "type": "object",
        "properties": {
          "media_type": {
            "$ref": "#/components/schemas/MediaTypeEnum"
          },
          "data": {
            "title": "Data"
          }
        },
        "description": "Abstract base class for generic types.\n\nOn Python 3.12 and newer, generic classes implicitly inherit from\nGeneric when they declare a parameter list after the class's name::\n\n    class Mapping[KT, VT]:\n        def __getitem__(self, key: KT) -> VT:\n            ...\n        # Etc.\n\nOn older versions of Python, however, generic classes have to\nexplicitly inherit from Generic.\n\nAfter a class has been declared to be generic, it can then be used as\nfollows::\n\n    def lookup_name[KT, VT](mapping: Mapping[KT, VT], key: KT, default: VT) -> VT:\n        try:\n            return mapping[key]\n        except KeyError:\n            return default"
      },
      "CanInterfaceListResponse": {
        "title": "CanInterfaceListResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "title": "Data",
            "type": "array",
            "items": {
              "type": "object"
            }
          }
        }
      },
      "CodecEnum": {
        "title": "CodecEnum",
        "enum": [
          "VP8",
          "H264",
          "AV1",
          "VP9"
        ],
        "type": "string",
        "description": "An enumeration."
      },
      "CommandHistoryData": {
        "title": "CommandHistoryData",
        "type": "object",
        "properties": {
          "records": {
            "title": "Records",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CortexCommandRecordModel"
            },
            "description": "Terminal command records, newest first."
          }
        }
      },
      "CommandHistoryResponse": {
        "title": "CommandHistoryResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/CommandHistoryData"
          }
        }
      },
      "CommandMode": {
        "title": "CommandMode",
        "enum": [
          0,
          1
        ],
        "description": "An enumeration."
      },
      "CommandQueueData": {
        "title": "CommandQueueData",
        "required": [
          "active_command_id",
          "number_commands_remaining"
        ],
        "type": "object",
        "properties": {
          "queued": {
            "title": "Queued",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CortexCommandRecordModel"
            },
            "description": "Queued commands in dispatch order. The active command, if any, is the front entry and is reported with state ACTIVE."
          },
          "active_command_id": {
            "title": "Active Command Id",
            "type": "string",
            "description": "Id of the currently active command, in canonical UUID string form. The nil UUID when nothing is active."
          },
          "number_commands_remaining": {
            "title": "Number Commands Remaining",
            "type": "integer",
            "description": "Number of commands remaining in the queue."
          }
        }
      },
      "CommandQueueResponse": {
        "title": "CommandQueueResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/CommandQueueData"
          }
        }
      },
      "ControlLease": {
        "title": "ControlLease",
        "type": "object",
        "properties": {
          "holder_id": {
            "title": "Holder Id",
            "type": "string"
          },
          "expires_at": {
            "title": "Expires At",
            "type": "string",
            "format": "date-time"
          }
        }
      },
      "ControlResponse": {
        "title": "ControlResponse",
        "required": [
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status",
            "default": "success"
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human readable message"
          },
          "data": {
            "title": "Data",
            "allOf": [
              {
                "$ref": "#/components/schemas/ControlLease"
              }
            ],
            "description": "Current lease data"
          }
        },
        "description": "Model for successful responses in the control API"
      },
      "CortexCommandOutcomeEnum": {
        "title": "CortexCommandOutcomeEnum",
        "enum": [
          0,
          1,
          2,
          3,
          4,
          5
        ],
        "description": "Terminal outcome of a cortex command; mirrors CortexCommandRecord's outcome constants."
      },
      "CortexCommandRecordModel": {
        "title": "CortexCommandRecordModel",
        "required": [
          "id",
          "queued_time",
          "started_time",
          "completed_time"
        ],
        "type": "object",
        "properties": {
          "id": {
            "title": "Id",
            "type": "string",
            "description": "Cortex-assigned command id, in canonical UUID string form."
          },
          "summary": {
            "title": "Summary",
            "type": "string",
            "description": "Short human-readable description of the command.",
            "default": ""
          },
          "state": {
            "allOf": [
              {
                "$ref": "#/components/schemas/CortexCommandStateEnum"
              }
            ],
            "description": "Lifecycle state. Pass the integer value."
          },
          "state_text": {
            "title": "State Text",
            "type": "string",
            "description": "Name of the state, e.g. TERMINAL.",
            "default": ""
          },
          "outcome": {
            "allOf": [
              {
                "$ref": "#/components/schemas/CortexCommandOutcomeEnum"
              }
            ],
            "description": "Terminal outcome, OUTCOME_UNKNOWN until the command finishes. Pass the integer value."
          },
          "outcome_text": {
            "title": "Outcome Text",
            "type": "string",
            "description": "Name of the outcome, e.g. REJECTED.",
            "default": ""
          },
          "detail": {
            "title": "Detail",
            "type": "string",
            "description": "Outcome context, e.g. the validation message for a rejection.",
            "default": ""
          },
          "queued_time": {
            "title": "Queued Time",
            "allOf": [
              {
                "$ref": "#/components/schemas/Stamp"
              }
            ],
            "description": "Time the command was accepted and queued."
          },
          "started_time": {
            "title": "Started Time",
            "allOf": [
              {
                "$ref": "#/components/schemas/Stamp"
              }
            ],
            "description": "Time the command became active. Zero until started."
          },
          "completed_time": {
            "title": "Completed Time",
            "allOf": [
              {
                "$ref": "#/components/schemas/Stamp"
              }
            ],
            "description": "Time the command reached a terminal state. Zero until terminal."
          }
        },
        "description": "Cortex's bookkeeping record for a single command: its identity, lifecycle and outcome.",
        "example": {
          "id": "25b0db0f-083c-4cb4-9e7f-dc91613071b7",
          "summary": "NAVIGATION: geo path with 3 waypoints",
          "state": 2,
          "state_text": "TERMINAL",
          "outcome": 1,
          "outcome_text": "SUCCEEDED",
          "detail": "",
          "queued_time": {
            "sec": 1786949841,
            "nanosec": 893512222
          },
          "started_time": {
            "sec": 1786949842,
            "nanosec": 100000000
          },
          "completed_time": {
            "sec": 1786949844,
            "nanosec": 112000000
          }
        }
      },
      "CortexCommandStateEnum": {
        "title": "CortexCommandStateEnum",
        "enum": [
          0,
          1,
          2
        ],
        "description": "Lifecycle state of a cortex command; mirrors CortexCommandRecord's state constants."
      },
      "CortexNavigationOptions": {
        "title": "CortexNavigationOptions",
        "type": "object",
        "properties": {
          "path_option": {
            "title": "Path Option",
            "allOf": [
              {
                "$ref": "#/components/schemas/CortexOption"
              }
            ],
            "description": "Navigation path logic option to set. See the GET /navigation-path-options endpoint for the available path options and their parameters.",
            "example": {
              "name": "target_follower",
              "params": [
                {
                  "key": "speed",
                  "value": "0.5"
                }
              ]
            }
          },
          "mode": {
            "allOf": [
              {
                "$ref": "#/components/schemas/CommandMode"
              }
            ],
            "description": "Mode of execution of previous and current waypoints. Available options: 'ADD','PREEMPT'. ADD or 0: Add a new waypoint to existing queue of waypoints, PREEMPT or 1: Delete the existing queue and adds the new waypoint.",
            "default": 0,
            "example": "ADD"
          }
        }
      },
      "CortexOption": {
        "title": "CortexOption",
        "required": [
          "name",
          "params"
        ],
        "type": "object",
        "properties": {
          "name": {
            "title": "Name",
            "type": "string"
          },
          "params": {
            "title": "Params",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KeyValuePair"
            }
          }
        }
      },
      "CortexStatus": {
        "title": "CortexStatus",
        "type": "object",
        "properties": {
          "status": {
            "$ref": "#/components/schemas/CortexStatusEnum"
          },
          "status_text": {
            "title": "Status Text",
            "type": "string",
            "default": ""
          },
          "description": {
            "title": "Description",
            "type": "string"
          }
        }
      },
      "CortexStatusEnum": {
        "title": "CortexStatusEnum",
        "enum": [
          0,
          1,
          2,
          3,
          4
        ],
        "description": "An enumeration."
      },
      "CostmapBoundaryResponse": {
        "title": "CostmapBoundaryResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/GeofenceBoundary"
          }
        }
      },
      "ErrorDetails": {
        "title": "ErrorDetails",
        "required": [
          "details"
        ],
        "type": "object",
        "properties": {
          "details": {
            "title": "Details",
            "type": "string"
          }
        }
      },
      "ErrorResponse": {
        "title": "ErrorResponse",
        "required": [
          "status",
          "message"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "error"
            ],
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "error": {
            "$ref": "#/components/schemas/ErrorDetails"
          }
        }
      },
      "GPSWaypointTransmissionData": {
        "title": "GPSWaypointTransmissionData",
        "required": [
          "sent"
        ],
        "type": "object",
        "properties": {
          "sent": {
            "$ref": "#/components/schemas/GPSWaypoints"
          },
          "received": {
            "title": "Received"
          },
          "command_ids": {
            "title": "Command Ids",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Cortex-assigned ids for the accepted commands, aligned 1:1 with the commands sent and in the same order. Each is the goal id for its command; pass one to GET /command-history as command_id to look that command up once it finishes. Empty when cortex handled the request without queueing commands, as a RESUME motion command does."
          }
        }
      },
      "GPSWaypointTransmissionResponse": {
        "title": "GPSWaypointTransmissionResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/GPSWaypointTransmissionData"
          }
        }
      },
      "GPSWaypoints": {
        "title": "GPSWaypoints",
        "required": [
          "goals"
        ],
        "type": "object",
        "properties": {
          "timestamp_utc": {
            "title": "Timestamp Utc",
            "type": "string",
            "description": "Timestamp in UTC ISO format. Should be provided in ISO 8601 format: 'YYYY-MM-DDTHH:MM:SSZ'. If not provided, it will default to the current UTC time.",
            "default": ""
          },
          "goals": {
            "title": "Goals",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/GoalPoses"
            },
            "description": "Ordered list of GPS waypoints. When multiple waypoints are provided, the robot navigates through them continuously as a single path rather than stopping discretely at each one."
          },
          "navigation_options": {
            "title": "Navigation Options",
            "allOf": [
              {
                "$ref": "#/components/schemas/CortexNavigationOptions"
              }
            ],
            "description": "Optional navigation options for this command, including the path logic option and execution mode. See the GET /navigation-path-options endpoint for the available path options and their parameters."
          }
        }
      },
      "GeoPoint": {
        "title": "GeoPoint",
        "required": [
          "lat",
          "lon"
        ],
        "type": "object",
        "properties": {
          "lat": {
            "title": "Lat",
            "type": "number",
            "description": "Latitude"
          },
          "lon": {
            "title": "Lon",
            "type": "number",
            "description": "Longitude"
          },
          "altitude": {
            "title": "Altitude",
            "type": "number",
            "description": "Altitude (meters)"
          },
          "yaw": {
            "title": "Yaw",
            "type": "number",
            "description": "Yaw (radians). Robot body frame: x forward, y left, z up; positive yaw is counter-clockwise."
          }
        }
      },
      "GeofenceBoundary": {
        "title": "GeofenceBoundary",
        "required": [
          "bottom_left",
          "bottom_right",
          "top_left",
          "top_right"
        ],
        "type": "object",
        "properties": {
          "bottom_left": {
            "$ref": "#/components/schemas/NavSatFixModel"
          },
          "bottom_right": {
            "$ref": "#/components/schemas/NavSatFixModel"
          },
          "top_left": {
            "$ref": "#/components/schemas/NavSatFixModel"
          },
          "top_right": {
            "$ref": "#/components/schemas/NavSatFixModel"
          }
        }
      },
      "GoalInfo": {
        "title": "GoalInfo",
        "required": [
          "stamp"
        ],
        "type": "object",
        "properties": {
          "goal_id": {
            "$ref": "#/components/schemas/UUID"
          },
          "stamp": {
            "$ref": "#/components/schemas/Stamp"
          }
        }
      },
      "GoalPoses": {
        "title": "GoalPoses",
        "required": [
          "lat",
          "lon"
        ],
        "type": "object",
        "properties": {
          "timestamp_utc": {
            "title": "Timestamp Utc",
            "type": "string",
            "description": "Timestamp in UTC ISO format. Should be provided in ISO 8601 format: 'YYYY-MM-DDTHH:MM:SSZ'. If not provided, it will default to the current UTC time.",
            "default": ""
          },
          "lat": {
            "title": "Lat",
            "type": "number",
            "description": "Latitude"
          },
          "lon": {
            "title": "Lon",
            "type": "number",
            "description": "Longitude"
          },
          "yaw": {
            "title": "Yaw",
            "type": "number",
            "description": "Yaw (radians). 0.0 indicates east. positive yaw is counter-clockwise."
          }
        }
      },
      "HTTPExceptionResponse": {
        "title": "HTTPExceptionResponse",
        "required": [
          "detail"
        ],
        "type": "object",
        "properties": {
          "detail": {
            "title": "Detail",
            "type": "string"
          }
        },
        "description": "Response model for HTTPException errors."
      },
      "HTTPValidationError": {
        "title": "HTTPValidationError",
        "type": "object",
        "properties": {
          "detail": {
            "title": "Detail",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ValidationError"
            }
          }
        }
      },
      "Header": {
        "title": "Header",
        "required": [
          "stamp",
          "frame_id"
        ],
        "type": "object",
        "properties": {
          "stamp": {
            "$ref": "#/components/schemas/Stamp"
          },
          "frame_id": {
            "title": "Frame Id",
            "type": "string"
          }
        }
      },
      "HealthStatusResponse": {
        "title": "HealthStatusResponse",
        "type": "object",
        "properties": {
          "fault_source_available": {
            "title": "Fault Source Available",
            "type": "boolean",
            "default": false
          },
          "health_summary": {
            "$ref": "#/components/schemas/HealthSummary"
          },
          "subsystems": {
            "title": "Subsystems",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SubsystemHealth"
            },
            "default": []
          }
        }
      },
      "HealthSummary": {
        "title": "HealthSummary",
        "required": [
          "summary",
          "highest_severity"
        ],
        "type": "object",
        "properties": {
          "summary": {
            "title": "Summary",
            "type": "string"
          },
          "highest_severity": {
            "title": "Highest Severity",
            "type": "string"
          },
          "highest_severity_alert": {
            "title": "Highest Severity Alert",
            "type": "string"
          },
          "active_alert_count": {
            "title": "Active Alert Count",
            "type": "integer",
            "default": 0
          }
        }
      },
      "KeyValuePair": {
        "title": "KeyValuePair",
        "required": [
          "key",
          "value"
        ],
        "type": "object",
        "properties": {
          "key": {
            "title": "Key",
            "type": "string"
          },
          "value": {
            "title": "Value",
            "type": "string"
          }
        }
      },
      "ListRoutesResponse": {
        "title": "ListRoutesResponse",
        "required": [
          "message",
          "routes_list"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status.",
            "default": "success"
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message."
          },
          "routes_list": {
            "title": "Routes List",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Names of all saved routes available."
          }
        }
      },
      "ListSitesResponse": {
        "title": "ListSitesResponse",
        "required": [
          "message",
          "sites_list"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status.",
            "default": "success"
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message."
          },
          "sites_list": {
            "title": "Sites List",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "List of all saved sites."
          }
        }
      },
      "ListZoneSetsResponse": {
        "title": "ListZoneSetsResponse",
        "required": [
          "message",
          "zone_sets_list"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status.",
            "default": "success"
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message."
          },
          "zone_sets_list": {
            "title": "Zone Sets List",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Names of all saved zone sets."
          }
        }
      },
      "LivekitConfigResponse": {
        "title": "LivekitConfigResponse",
        "type": "object",
        "properties": {
          "room_name": {
            "title": "Room Name",
            "type": "string"
          },
          "bridge_identity": {
            "title": "Bridge Identity",
            "type": "string"
          },
          "livekit_url": {
            "title": "Livekit Url",
            "type": "string"
          }
        },
        "description": "Response model for environment-backed LiveKit discovery configuration."
      },
      "LivekitRoomDetails": {
        "title": "LivekitRoomDetails",
        "type": "object",
        "properties": {
          "room": {
            "$ref": "#/components/schemas/LivekitRoomInfo"
          },
          "hostname": {
            "title": "Hostname",
            "type": "string"
          },
          "tracks": {
            "title": "Tracks",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/LivekitTrack"
            },
            "default": []
          }
        },
        "description": "Details about the current LiveKit room state."
      },
      "LivekitRoomInfo": {
        "title": "LivekitRoomInfo",
        "required": [
          "name"
        ],
        "type": "object",
        "properties": {
          "name": {
            "title": "Name",
            "type": "string"
          }
        },
        "description": "Information about a connected LiveKit room."
      },
      "LivekitRoomResponse": {
        "title": "LivekitRoomResponse",
        "required": [
          "alive",
          "message",
          "room"
        ],
        "type": "object",
        "properties": {
          "alive": {
            "title": "Alive",
            "type": "boolean"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "room": {
            "$ref": "#/components/schemas/LivekitRoomDetails"
          }
        },
        "description": "Response model for LiveKit room operations."
      },
      "LivekitTokenResponse": {
        "title": "LivekitTokenResponse",
        "required": [
          "token"
        ],
        "type": "object",
        "properties": {
          "token": {
            "title": "Token",
            "type": "string"
          }
        },
        "description": "Response model for LiveKit token generation."
      },
      "LivekitTrack": {
        "title": "LivekitTrack",
        "required": [
          "name",
          "codec",
          "fps",
          "media_type",
          "stream_path",
          "use_experimental_reader",
          "stats"
        ],
        "type": "object",
        "properties": {
          "name": {
            "title": "Name",
            "type": "string"
          },
          "sid": {
            "title": "Sid",
            "type": "string"
          },
          "codec": {
            "$ref": "#/components/schemas/CodecEnum"
          },
          "fps": {
            "title": "Fps",
            "type": "number"
          },
          "media_type": {
            "$ref": "#/components/schemas/MediaTypeEnum"
          },
          "stream_path": {
            "title": "Stream Path",
            "type": "string"
          },
          "use_experimental_reader": {
            "title": "Use Experimental Reader",
            "type": "boolean"
          },
          "stats": {
            "$ref": "#/components/schemas/LivekitTrackStats"
          },
          "width": {
            "title": "Width",
            "type": "integer"
          },
          "height": {
            "title": "Height",
            "type": "integer"
          },
          "max_bitrate_kbps": {
            "title": "Max Bitrate Kbps",
            "type": "integer"
          }
        },
        "description": "Track information for API responses, including configuration and runtime data."
      },
      "LivekitTrackStats": {
        "title": "LivekitTrackStats",
        "type": "object",
        "properties": {
          "timestamp": {
            "title": "Timestamp",
            "type": "number",
            "default": 0.0
          },
          "fps": {
            "title": "Fps",
            "allOf": [
              {
                "$ref": "#/components/schemas/Metric"
              }
            ],
            "default": {
              "p50": 0.0,
              "p95": 0.0,
              "p99": 0.0
            }
          },
          "size_bytes": {
            "title": "Size Bytes",
            "type": "integer",
            "default": 0
          }
        }
      },
      "MapPoint": {
        "title": "MapPoint",
        "required": [
          "x",
          "y"
        ],
        "type": "object",
        "properties": {
          "x": {
            "title": "X",
            "type": "number",
            "description": "X position in the map frame (meters)."
          },
          "y": {
            "title": "Y",
            "type": "number",
            "description": "Y position in the map frame (meters)."
          }
        }
      },
      "MediaTypeEnum": {
        "title": "MediaTypeEnum",
        "enum": [
          "media_device",
          "rtsp",
          "ros",
          "gstream"
        ],
        "type": "string",
        "description": "An enumeration."
      },
      "Metric": {
        "title": "Metric",
        "required": [
          "p50",
          "p95",
          "p99"
        ],
        "type": "object",
        "properties": {
          "p50": {
            "title": "P50",
            "type": "number"
          },
          "p95": {
            "title": "P95",
            "type": "number"
          },
          "p99": {
            "title": "P99",
            "type": "number"
          }
        }
      },
      "MotionCommandAction": {
        "title": "MotionCommandAction",
        "type": "object",
        "properties": {
          "motion_command": {
            "allOf": [
              {
                "$ref": "#/components/schemas/MotionCommandOptions"
              }
            ],
            "description": "Motion command options. STOP (0) will cancel all current and queued navigation or vehicle commands. When in STOP, no new commands will be added to the queue until resumed. PAUSE (1) will pause the current command execution, leaving remaining commands in the queue, and RESUME (2) will resume the paused waypoint execution and place the autonomy state back to IDLE if the queue is empty.",
            "default": 0
          },
          "mode": {
            "allOf": [
              {
                "$ref": "#/components/schemas/CommandMode"
              }
            ],
            "description": "Mode of execution of previous and current waypoints. Available options: 'ADD','PREEMPT'. ADD or 0: Add a new waypoint to existing queue of waypoints, PREEMPT or 1: Delete the existing queue and adds the new waypoint.",
            "default": 1,
            "example": "PREEMPT"
          }
        }
      },
      "MotionCommandExecutionData": {
        "title": "MotionCommandExecutionData",
        "type": "object",
        "properties": {
          "received": {
            "title": "Received"
          },
          "command_ids": {
            "title": "Command Ids",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Cortex-assigned ids for the accepted commands, aligned 1:1 with the commands sent and in the same order. Each is the goal id for its command; pass one to GET /command-history as command_id to look that command up once it finishes. Empty when cortex handled the request without queueing commands, as a RESUME motion command does."
          }
        }
      },
      "MotionCommandExecutionResponse": {
        "title": "MotionCommandExecutionResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/MotionCommandExecutionData"
          }
        }
      },
      "MotionCommandListResponse": {
        "title": "MotionCommandListResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "title": "Data",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MotionCommandSummary"
            }
          }
        }
      },
      "MotionCommandOptions": {
        "title": "MotionCommandOptions",
        "enum": [
          0,
          1,
          2
        ],
        "description": "An enumeration."
      },
      "MotionCommandSummary": {
        "title": "MotionCommandSummary",
        "required": [
          "motion_command",
          "alternative"
        ],
        "type": "object",
        "properties": {
          "motion_command": {
            "title": "Motion Command",
            "type": "string"
          },
          "alternative": {
            "title": "Alternative",
            "type": "integer"
          }
        }
      },
      "NavSatFixModel": {
        "title": "NavSatFixModel",
        "required": [
          "latitude",
          "longitude",
          "altitude"
        ],
        "type": "object",
        "properties": {
          "latitude": {
            "title": "Latitude",
            "type": "number"
          },
          "longitude": {
            "title": "Longitude",
            "type": "number"
          },
          "altitude": {
            "title": "Altitude",
            "type": "number"
          }
        }
      },
      "NavigationFeedback": {
        "title": "NavigationFeedback",
        "type": "object",
        "properties": {
          "nav2_goal_status": {
            "$ref": "#/components/schemas/NavigationGoalStatus"
          },
          "total_distance_remaining": {
            "title": "Total Distance Remaining",
            "type": "number",
            "description": "Total remaining distance to the goal, in meters."
          },
          "target_pose": {
            "$ref": "#/components/schemas/PoseWithHeader"
          },
          "final_pose": {
            "$ref": "#/components/schemas/PoseWithHeader"
          },
          "current_pose_index": {
            "title": "Current Pose Index",
            "type": "integer"
          },
          "number_of_poses_remaining": {
            "title": "Number Of Poses Remaining",
            "type": "integer"
          },
          "navigation_time": {
            "title": "Navigation Time",
            "allOf": [
              {
                "$ref": "#/components/schemas/Stamp"
              }
            ],
            "description": "Elapsed navigation time as a duration (seconds and nanoseconds)."
          },
          "estimated_time_remaining": {
            "title": "Estimated Time Remaining",
            "allOf": [
              {
                "$ref": "#/components/schemas/Stamp"
              }
            ],
            "description": "Estimated time remaining as a duration (seconds and nanoseconds)."
          }
        }
      },
      "NavigationGoalStatus": {
        "title": "NavigationGoalStatus",
        "required": [
          "goal_info",
          "status"
        ],
        "type": "object",
        "properties": {
          "goal_info": {
            "$ref": "#/components/schemas/GoalInfo"
          },
          "status": {
            "$ref": "#/components/schemas/Ros2ActionServerGoalStatus"
          },
          "status_text": {
            "title": "Status Text",
            "type": "string"
          },
          "text": {
            "title": "Text",
            "type": "string"
          }
        }
      },
      "Orientation": {
        "title": "Orientation",
        "required": [
          "x",
          "y",
          "z",
          "w"
        ],
        "type": "object",
        "properties": {
          "x": {
            "title": "X",
            "type": "number"
          },
          "y": {
            "title": "Y",
            "type": "number"
          },
          "z": {
            "title": "Z",
            "type": "number"
          },
          "w": {
            "title": "W",
            "type": "number"
          }
        }
      },
      "PathLogicOptionResponse": {
        "title": "PathLogicOptionResponse",
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "title": "Data",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CortexOption"
            }
          }
        }
      },
      "PolymathFeedback": {
        "title": "PolymathFeedback",
        "required": [
          "navigation_feedback",
          "vehicle_feedback",
          "current_pose",
          "current_command_index",
          "number_commands_remaining"
        ],
        "type": "object",
        "properties": {
          "timestamp_utc": {
            "title": "Timestamp Utc",
            "allOf": [
              {
                "$ref": "#/components/schemas/TimeStamp"
              }
            ],
            "default": {}
          },
          "cortex_status": {
            "$ref": "#/components/schemas/CortexStatus"
          },
          "navigation_feedback": {
            "$ref": "#/components/schemas/NavigationFeedback"
          },
          "vehicle_feedback": {
            "$ref": "#/components/schemas/VehicleFeedback"
          },
          "current_pose": {
            "$ref": "#/components/schemas/PoseWithHeader"
          },
          "current_command_index": {
            "title": "Current Command Index",
            "type": "integer",
            "description": "DEPRECATED: has always meant \"front of queue\". Use current_command_id instead."
          },
          "current_command_id": {
            "title": "Current Command Id",
            "type": "string",
            "description": "Id of the command currently executing, in canonical UUID string form. Matches one of the command_ids returned when the command was submitted. The nil UUID when nothing is active.",
            "default": ""
          },
          "number_commands_remaining": {
            "title": "Number Commands Remaining",
            "type": "integer"
          }
        }
      },
      "PolymathFeedbackData": {
        "title": "PolymathFeedbackData",
        "required": [
          "polymath_feedback"
        ],
        "type": "object",
        "properties": {
          "polymath_feedback": {
            "$ref": "#/components/schemas/PolymathFeedback"
          }
        }
      },
      "PolymathFeedbackResponse": {
        "title": "PolymathFeedbackResponse",
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/PolymathFeedbackData"
          }
        }
      },
      "Pose": {
        "title": "Pose",
        "required": [
          "position",
          "orientation"
        ],
        "type": "object",
        "properties": {
          "position": {
            "$ref": "#/components/schemas/Position"
          },
          "orientation": {
            "$ref": "#/components/schemas/Orientation"
          }
        }
      },
      "PoseWithHeader": {
        "title": "PoseWithHeader",
        "required": [
          "header",
          "pose"
        ],
        "type": "object",
        "properties": {
          "header": {
            "$ref": "#/components/schemas/Header"
          },
          "pose": {
            "$ref": "#/components/schemas/Pose"
          }
        }
      },
      "Position": {
        "title": "Position",
        "required": [
          "latitude",
          "longitude",
          "altitude"
        ],
        "type": "object",
        "properties": {
          "latitude": {
            "title": "Latitude",
            "type": "number"
          },
          "longitude": {
            "title": "Longitude",
            "type": "number"
          },
          "altitude": {
            "title": "Altitude",
            "type": "number"
          }
        }
      },
      "ReadRouteGraphResponse": {
        "title": "ReadRouteGraphResponse",
        "required": [
          "message",
          "route"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status.",
            "default": "success"
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message."
          },
          "route": {
            "title": "Route",
            "allOf": [
              {
                "$ref": "#/components/schemas/RouteGraph"
              }
            ],
            "description": "The requested route."
          }
        }
      },
      "ReadSiteResponse": {
        "title": "ReadSiteResponse",
        "required": [
          "message",
          "site"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status.",
            "default": "success"
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message."
          },
          "site": {
            "title": "Site",
            "allOf": [
              {
                "$ref": "#/components/schemas/Site"
              }
            ],
            "description": "The requested site."
          }
        }
      },
      "ReadZoneSetResponse": {
        "title": "ReadZoneSetResponse",
        "required": [
          "message",
          "zone_set"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status.",
            "default": "success"
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message."
          },
          "zone_set": {
            "title": "Zone Set",
            "allOf": [
              {
                "$ref": "#/components/schemas/ZoneSet"
              }
            ],
            "description": "The requested zone set."
          }
        }
      },
      "ReferenceTarget": {
        "title": "ReferenceTarget",
        "required": [
          "pose"
        ],
        "type": "object",
        "properties": {
          "target_id": {
            "title": "Target Id",
            "type": "string",
            "description": "Unique name or ID of the reference target",
            "default": "string"
          },
          "timestamp_utc": {
            "title": "Timestamp Utc",
            "type": "string",
            "description": "Timestamp in UTC ISO format. Should be provided in ISO 8601 format: 'YYYY-MM-DDTHH:MM:SSZ'. If not provided, it will default to the current UTC time."
          },
          "pose": {
            "$ref": "#/components/schemas/GeoPoint"
          },
          "time_validity": {
            "title": "Time Validity",
            "type": "number",
            "description": "Time validity in seconds. -1 means forever.",
            "default": -1
          },
          "recorded_speed_m_s": {
            "title": "Recorded Speed M S",
            "type": "number",
            "description": "Recorded speed of the object in m/s. `None` indicates no measurement available."
          }
        }
      },
      "ReferenceTargetSetData": {
        "title": "ReferenceTargetSetData",
        "required": [
          "sent"
        ],
        "type": "object",
        "properties": {
          "sent": {
            "$ref": "#/components/schemas/ReferenceTargetsModel"
          },
          "received": {
            "title": "Received"
          }
        }
      },
      "ReferenceTargetSetResponse": {
        "title": "ReferenceTargetSetResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/ReferenceTargetSetData"
          }
        }
      },
      "ReferenceTargetsModel": {
        "title": "ReferenceTargetsModel",
        "required": [
          "reference_targets"
        ],
        "type": "object",
        "properties": {
          "reference_targets": {
            "title": "Reference Targets",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ReferenceTarget"
            }
          }
        }
      },
      "ReferenceTargetsResponse": {
        "title": "ReferenceTargetsResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/ReferenceTargetsModel"
          }
        }
      },
      "RelativeCommand": {
        "title": "RelativeCommand",
        "type": "object",
        "properties": {
          "timestamp_utc": {
            "title": "Timestamp Utc",
            "type": "string",
            "description": "Timestamp in UTC ISO format. Should be provided in ISO 8601 format: 'YYYY-MM-DDTHH:MM:SSZ'. If not provided, it will default to the current UTC time.",
            "default": ""
          },
          "x": {
            "title": "X",
            "type": "number",
            "description": "Offset distance in meters along the X axis.",
            "default": 0.0
          },
          "y": {
            "title": "Y",
            "type": "number",
            "description": "Offset distance in meters along the Y axis.",
            "default": 0.0
          },
          "z": {
            "title": "Z",
            "type": "number",
            "description": "Offset distance in meters along the Z axis.",
            "default": 0.0
          },
          "yaw": {
            "title": "Yaw",
            "type": "number",
            "description": "Yaw (radians) angular offset indicating the direction the robot should face relative to the target.",
            "default": 0.0
          }
        }
      },
      "RelativeWaypointTransmissionData": {
        "title": "RelativeWaypointTransmissionData",
        "required": [
          "sent"
        ],
        "type": "object",
        "properties": {
          "sent": {
            "$ref": "#/components/schemas/RelativeWaypoints"
          },
          "received": {
            "title": "Received"
          },
          "command_ids": {
            "title": "Command Ids",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Cortex-assigned ids for the accepted commands, aligned 1:1 with the commands sent and in the same order. Each is the goal id for its command; pass one to GET /command-history as command_id to look that command up once it finishes. Empty when cortex handled the request without queueing commands, as a RESUME motion command does."
          }
        }
      },
      "RelativeWaypointTransmissionResponse": {
        "title": "RelativeWaypointTransmissionResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/RelativeWaypointTransmissionData"
          }
        }
      },
      "RelativeWaypoints": {
        "title": "RelativeWaypoints",
        "required": [
          "move_to"
        ],
        "type": "object",
        "properties": {
          "relative_to": {
            "title": "Relative To",
            "anyOf": [
              {
                "type": "string"
              },
              {
                "$ref": "#/components/schemas/ReferenceTarget"
              }
            ],
            "description": "The target that waypoints are specified relative to. Accepts either a name as string or a fully specified ReferenceTarget. The name can be 'current_position', a previously set ReferenceTarget, or the name of a frame in the transform tree, such as 'base_link'. Unknown strings are passed through verbatim and will fail downstream if the reference does not exist. Defaults to 'current_position' so waypoints are interpreted relative to the robot's current pose.",
            "default": "current_position"
          },
          "timestamp_utc": {
            "title": "Timestamp Utc",
            "type": "string",
            "description": "Timestamp in UTC ISO format. Should be provided in ISO 8601 format: 'YYYY-MM-DDTHH:MM:SSZ'. If not provided, it will default to the current UTC time.",
            "default": ""
          },
          "move_to": {
            "title": "Move To",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RelativeCommand"
            },
            "description": "Ordered list of relative waypoints. When multiple waypoints are provided, the robot navigates through them continuously as a single path rather than stopping discretely at each one. Robot body frame: x forward, y left, z up; positive yaw is counter-clockwise."
          },
          "navigation_options": {
            "title": "Navigation Options",
            "allOf": [
              {
                "$ref": "#/components/schemas/CortexNavigationOptions"
              }
            ],
            "description": "Optional navigation options for this command, including the path logic option and execution mode. See the GET /navigation-path-options endpoint for the available path options and their parameters."
          }
        }
      },
      "Ros2ActionServerGoalStatus": {
        "title": "Ros2ActionServerGoalStatus",
        "enum": [
          0,
          1,
          2,
          3,
          4,
          5,
          6
        ],
        "description": "An enumeration."
      },
      "RouteEdge": {
        "title": "RouteEdge",
        "required": [
          "from_node_id",
          "to_node_id",
          "id"
        ],
        "type": "object",
        "properties": {
          "from_node_id": {
            "title": "From Node Id",
            "maximum": 65535.0,
            "minimum": 0.0,
            "type": "integer",
            "description": "ID of the node this edge starts from."
          },
          "to_node_id": {
            "title": "To Node Id",
            "maximum": 65535.0,
            "minimum": 0.0,
            "type": "integer",
            "description": "ID of the node this edge ends at."
          },
          "id": {
            "title": "Id",
            "maximum": 65535.0,
            "minimum": 0.0,
            "type": "integer",
            "description": "16-bit unique identifier of this edge."
          },
          "cost": {
            "title": "Cost",
            "maximum": 20000.0,
            "minimum": 0.0,
            "type": "integer",
            "description": "Cost/penalty of traversing this edge.",
            "default": 0
          }
        }
      },
      "RouteGraph": {
        "title": "RouteGraph",
        "required": [
          "name",
          "nodes",
          "edges"
        ],
        "type": "object",
        "properties": {
          "name": {
            "title": "Name",
            "type": "string",
            "description": "Name of the route."
          },
          "nodes": {
            "title": "Nodes",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RouteNode"
            },
            "description": "Nodes that make up the route."
          },
          "edges": {
            "title": "Edges",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RouteEdge"
            },
            "description": "Edges connecting the nodes."
          }
        }
      },
      "RouteNode": {
        "title": "RouteNode",
        "required": [
          "id"
        ],
        "type": "object",
        "properties": {
          "id": {
            "title": "Id",
            "maximum": 65535.0,
            "minimum": 0.0,
            "type": "integer",
            "description": "16-bit unique identifier of the node within this route graph, which can also be used to send a navigation goal later."
          },
          "coordinate_system": {
            "allOf": [
              {
                "$ref": "#/components/schemas/RouteNodeCoordinateSystem"
              }
            ],
            "description": "Coordinate system for this node's position. <MagicMock name='mock.RouteNode.WGS84' id='139939899717920'>: use wgs84_position. <MagicMock name='mock.RouteNode.MAP' id='139939854777472'>: use map_position. Pass the integer value.",
            "default": {}
          },
          "wgs84_position": {
            "title": "Wgs84 Position",
            "allOf": [
              {
                "$ref": "#/components/schemas/GeoPoint"
              }
            ],
            "description": "Node position in WGS84 lat/lon. Required when coordinate_system is WGS84."
          },
          "map_position": {
            "title": "Map Position",
            "allOf": [
              {
                "$ref": "#/components/schemas/MapPoint"
              }
            ],
            "description": "Node position in the map frame. Required when coordinate_system is MAP."
          },
          "name": {
            "title": "Name",
            "type": "string",
            "description": "Optional human-readable name for the node, which can be used to send a navigation goal later.",
            "default": ""
          }
        }
      },
      "RouteNodeCoordinateSystem": {
        "title": "RouteNodeCoordinateSystem",
        "enum": [
          {},
          {}
        ],
        "description": "An enumeration."
      },
      "SetZonesEnabledRequest": {
        "title": "SetZonesEnabledRequest",
        "type": "object",
        "properties": {
          "enable_zones": {
            "title": "Enable Zones",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Zone names to enable in the active set."
          },
          "disable_zones": {
            "title": "Disable Zones",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Zone names to disable in the active set."
          }
        }
      },
      "Site": {
        "title": "Site",
        "required": [
          "name",
          "boundary"
        ],
        "type": "object",
        "properties": {
          "name": {
            "title": "Name",
            "type": "string",
            "description": "Name of the site."
          },
          "boundary": {
            "title": "Boundary",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SiteGeoPoint"
            },
            "description": "Boundary vertices of the site in WGS84 lat/lon."
          }
        }
      },
      "SiteGeoPoint": {
        "title": "SiteGeoPoint",
        "required": [
          "latitude",
          "longitude"
        ],
        "type": "object",
        "properties": {
          "latitude": {
            "title": "Latitude",
            "type": "number",
            "description": "Latitude"
          },
          "longitude": {
            "title": "Longitude",
            "type": "number",
            "description": "Longitude"
          }
        }
      },
      "Stamp": {
        "title": "Stamp",
        "type": "object",
        "properties": {
          "sec": {
            "title": "Sec",
            "type": "integer"
          },
          "nanosec": {
            "title": "Nanosec",
            "type": "integer"
          }
        }
      },
      "SubsystemHealth": {
        "title": "SubsystemHealth",
        "required": [
          "name",
          "severity"
        ],
        "type": "object",
        "properties": {
          "name": {
            "title": "Name",
            "type": "string"
          },
          "severity": {
            "title": "Severity",
            "type": "string"
          },
          "faults": {
            "title": "Faults",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ActiveAlert"
            },
            "default": []
          }
        }
      },
      "TimeStamp": {
        "title": "TimeStamp",
        "type": "object",
        "properties": {
          "sec": {
            "title": "Sec",
            "type": "integer"
          },
          "nanosec": {
            "title": "Nanosec",
            "type": "integer"
          }
        }
      },
      "TransferLeaseRequest": {
        "title": "TransferLeaseRequest",
        "required": [
          "to"
        ],
        "type": "object",
        "properties": {
          "to": {
            "title": "To",
            "type": "string",
            "description": "User ID to transfer lease to"
          }
        }
      },
      "UUID": {
        "title": "UUID",
        "required": [
          "uuid"
        ],
        "type": "object",
        "properties": {
          "uuid": {
            "title": "Uuid",
            "type": "array",
            "items": {
              "type": "integer"
            }
          }
        }
      },
      "UUIDData": {
        "title": "UUIDData",
        "required": [
          "uuid"
        ],
        "type": "object",
        "properties": {
          "uuid": {
            "title": "Uuid",
            "type": "string"
          }
        }
      },
      "UUIDResponse": {
        "title": "UUIDResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/UUIDData"
          }
        }
      },
      "ValidationError": {
        "title": "ValidationError",
        "required": [
          "loc",
          "msg",
          "type"
        ],
        "type": "object",
        "properties": {
          "loc": {
            "title": "Location",
            "type": "array",
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer"
                }
              ]
            }
          },
          "msg": {
            "title": "Message",
            "type": "string"
          },
          "type": {
            "title": "Error Type",
            "type": "string"
          }
        }
      },
      "VehicleCommandAction": {
        "title": "VehicleCommandAction",
        "type": "object",
        "properties": {
          "vehicle_command": {
            "title": "Vehicle Command",
            "allOf": [
              {
                "$ref": "#/components/schemas/CortexOption"
              }
            ],
            "description": "Vehicle command to execute"
          },
          "mode": {
            "allOf": [
              {
                "$ref": "#/components/schemas/CommandMode"
              }
            ],
            "description": "Mode of execution of previous and current waypoints. Available options: 'ADD','PREEMPT'. ADD or 0: Add a new waypoint to existing queue of waypoints, PREEMPT or 1: Delete the existing queue and adds the new waypoint.",
            "default": 0,
            "example": "ADD"
          }
        }
      },
      "VehicleCommandData": {
        "title": "VehicleCommandData",
        "required": [
          "sent",
          "received"
        ],
        "type": "object",
        "properties": {
          "sent": {
            "$ref": "#/components/schemas/VehicleCommandAction"
          },
          "received": {
            "title": "Received",
            "type": "object"
          },
          "command_ids": {
            "title": "Command Ids",
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Cortex-assigned ids for the accepted commands, aligned 1:1 with the commands sent and in the same order. Each is the goal id for its command; pass one to GET /command-history as command_id to look that command up once it finishes. Empty when cortex handled the request without queueing commands, as a RESUME motion command does."
          }
        }
      },
      "VehicleCommandOptionResponse": {
        "title": "VehicleCommandOptionResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "title": "Data",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CortexOption"
            }
          }
        }
      },
      "VehicleCommandResponse": {
        "title": "VehicleCommandResponse",
        "required": [
          "status",
          "message",
          "data"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "type": "string"
          },
          "message": {
            "title": "Message",
            "type": "string"
          },
          "data": {
            "$ref": "#/components/schemas/VehicleCommandData"
          }
        }
      },
      "VehicleFeedback": {
        "title": "VehicleFeedback",
        "type": "object",
        "properties": {
          "state": {
            "title": "State",
            "type": "string"
          },
          "description": {
            "title": "Description",
            "type": "string"
          },
          "data": {
            "title": "Data",
            "type": "array",
            "items": {}
          }
        }
      },
      "VersionResponse": {
        "title": "VersionResponse",
        "required": [
          "commit_sha",
          "polymath_core_commit_sha"
        ],
        "type": "object",
        "properties": {
          "commit_sha": {
            "title": "Commit Sha",
            "type": "string"
          },
          "polymath_core_commit_sha": {
            "title": "Polymath Core Commit Sha",
            "type": "string"
          }
        }
      },
      "WorldModelErrorResponse": {
        "title": "WorldModelErrorResponse",
        "required": [
          "message"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "error"
            ],
            "type": "string",
            "description": "JSend status.",
            "default": "error"
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message, propagated from the ROS service."
          }
        },
        "example": {
          "status": "error",
          "message": "string"
        }
      },
      "WorldModelSuccessResponse": {
        "title": "WorldModelSuccessResponse",
        "required": [
          "message"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status.",
            "default": "success"
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message, propagated from the ROS service."
          }
        },
        "example": {
          "status": "success",
          "message": "string"
        }
      },
      "WriteRouteGraphRequest": {
        "title": "WriteRouteGraphRequest",
        "required": [
          "nodes",
          "edges"
        ],
        "type": "object",
        "properties": {
          "nodes": {
            "title": "Nodes",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RouteNode"
            },
            "description": "Nodes that make up the route."
          },
          "edges": {
            "title": "Edges",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/RouteEdge"
            },
            "description": "Edges connecting the nodes, referencing node IDs via from_node_id/to_node_id."
          }
        },
        "example": {
          "nodes": [
            {
              "id": 0,
              "coordinate_system": 0,
              "wgs84_position": {
                "lat": 37.7749,
                "lon": -122.4194
              }
            },
            {
              "id": 1,
              "coordinate_system": 0,
              "wgs84_position": {
                "lat": 37.7752,
                "lon": -122.4189
              }
            }
          ],
          "edges": [
            {
              "from_node_id": 0,
              "to_node_id": 1,
              "id": 0,
              "cost": 1
            }
          ]
        }
      },
      "WriteRouteGraphResponse": {
        "title": "WriteRouteGraphResponse",
        "required": [
          "status",
          "message"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status."
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message, propagated from the ROS service."
          }
        },
        "example": {
          "status": "success",
          "message": "string"
        }
      },
      "WriteSiteRequest": {
        "title": "WriteSiteRequest",
        "required": [
          "boundary"
        ],
        "type": "object",
        "properties": {
          "boundary": {
            "title": "Boundary",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SiteGeoPoint"
            },
            "description": "Boundary vertices of the site in WGS84 lat/lon."
          }
        },
        "example": {
          "boundary": [
            {
              "latitude": 37.828258,
              "longitude": -122.425726
            },
            {
              "latitude": 37.828385,
              "longitude": -122.420642
            },
            {
              "latitude": 37.825124,
              "longitude": -122.420416
            },
            {
              "latitude": 37.825183,
              "longitude": -122.425443
            }
          ]
        }
      },
      "WriteSiteResponse": {
        "title": "WriteSiteResponse",
        "required": [
          "status",
          "message"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status."
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message, propagated from the ROS service."
          }
        }
      },
      "WriteZoneSetRequest": {
        "title": "WriteZoneSetRequest",
        "required": [
          "zones"
        ],
        "type": "object",
        "properties": {
          "zones": {
            "title": "Zones",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ZoneInfo"
            },
            "description": "List of zones that make up the set."
          }
        },
        "example": {
          "zones": [
            {
              "name": "slowdown_zone",
              "type": "speed_limit",
              "enabled": true,
              "coordinate_system": 0,
              "wgs84_polygon": [
                {
                  "latitude": 37.828258,
                  "longitude": -122.425726
                },
                {
                  "latitude": 37.828385,
                  "longitude": -122.420642
                },
                {
                  "latitude": 37.825124,
                  "longitude": -122.420416
                },
                {
                  "latitude": 37.825183,
                  "longitude": -122.425443
                }
              ],
              "condition": {
                "type": 0,
                "params": []
              },
              "params": [
                {
                  "key": "speed_limit_m_s",
                  "value": 5.0
                }
              ]
            }
          ]
        }
      },
      "WriteZoneSetResponse": {
        "title": "WriteZoneSetResponse",
        "required": [
          "status",
          "message"
        ],
        "type": "object",
        "properties": {
          "status": {
            "title": "Status",
            "enum": [
              "success"
            ],
            "type": "string",
            "description": "JSend status."
          },
          "message": {
            "title": "Message",
            "type": "string",
            "description": "Human-readable message, propagated from the ROS service."
          }
        }
      },
      "ZoneConditionInfo": {
        "title": "ZoneConditionInfo",
        "type": "object",
        "properties": {
          "type": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ZoneConditionType"
              }
            ],
            "description": "Condition governing when the zone is active.",
            "default": {}
          },
          "params": {
            "title": "Params",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KeyValuePair"
            },
            "description": "Condition parameters."
          }
        }
      },
      "ZoneConditionType": {
        "title": "ZoneConditionType",
        "enum": [
          {}
        ],
        "description": "An enumeration."
      },
      "ZoneCoordinateSystem": {
        "title": "ZoneCoordinateSystem",
        "enum": [
          {},
          {}
        ],
        "description": "An enumeration."
      },
      "ZoneGeoPoint": {
        "title": "ZoneGeoPoint",
        "required": [
          "latitude",
          "longitude"
        ],
        "type": "object",
        "properties": {
          "latitude": {
            "title": "Latitude",
            "type": "number",
            "description": "Latitude"
          },
          "longitude": {
            "title": "Longitude",
            "type": "number",
            "description": "Longitude"
          }
        }
      },
      "ZoneInfo": {
        "title": "ZoneInfo",
        "required": [
          "name",
          "type"
        ],
        "type": "object",
        "properties": {
          "name": {
            "title": "Name",
            "type": "string",
            "description": "Name of the zone, unique within the set."
          },
          "type": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ZoneType"
              }
            ],
            "description": "Zone type."
          },
          "enabled": {
            "title": "Enabled",
            "type": "boolean",
            "description": "Whether the zone is enabled. Sent on write; returned on a stored read. Not the loaded-set runtime state.",
            "default": true
          },
          "coordinate_system": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ZoneCoordinateSystem"
              }
            ],
            "description": "Coordinate frame the polygon is expressed in. Pass the integer value.",
            "default": {}
          },
          "wgs84_polygon": {
            "title": "Wgs84 Polygon",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ZoneGeoPoint"
            },
            "description": "Boundary vertices in WGS84. Required when coordinate_system is WGS84."
          },
          "map_polygon": {
            "title": "Map Polygon",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MapPoint"
            },
            "description": "Boundary vertices in the map frame. Required when coordinate_system is MAP."
          },
          "condition": {
            "title": "Condition",
            "allOf": [
              {
                "$ref": "#/components/schemas/ZoneConditionInfo"
              }
            ],
            "description": "Activation condition."
          },
          "params": {
            "title": "Params",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/KeyValuePair"
            },
            "description": "Zone parameters."
          },
          "state": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ZoneState"
              }
            ],
            "description": "Runtime state. Only populated when reading the loaded set. Ignored on write."
          }
        }
      },
      "ZoneSet": {
        "title": "ZoneSet",
        "required": [
          "name",
          "zones"
        ],
        "type": "object",
        "properties": {
          "name": {
            "title": "Name",
            "type": "string",
            "description": "Name of the zone set."
          },
          "zones": {
            "title": "Zones",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ZoneInfo"
            },
            "description": "Zones in the set."
          }
        }
      },
      "ZoneState": {
        "title": "ZoneState",
        "enum": [
          {},
          {},
          {},
          {}
        ],
        "description": "An enumeration."
      },
      "ZoneType": {
        "title": "ZoneType",
        "enum": [
          "speed_limit",
          "geofence",
          "keep_out"
        ],
        "description": "An enumeration."
      }
    },
    "securitySchemes": {
      "HTTPBearer": {
        "type": "http",
        "scheme": "bearer"
      }
    }
  },
  "tags": [
    {
      "name": "Health Check",
      "description": "Contains UUID endpoint that can be used to health check the robot"
    },
    {
      "name": "Vehicle Autonomy",
      "description": "All endpoints related to interacting with Robot's autonomy operations here"
    },
    {
      "name": "Vehicle Operations",
      "description": "All endpoints related to interacting with Robot's vehicle operations here"
    },
    {
      "name": "Media",
      "description": "All endpoints related to interacting with Robot's media resources"
    },
    {
      "name": "Teleop Control",
      "description": "Endpoints for managing control leases"
    }
  ]
}
