{
  "openapi": "3.1.1",
  "info": {
    "title": "ProRanked eMSP API",
    "version": "emsp"
  },
  "servers": [
    {
      "url": "https://api.proranked.com"
    }
  ],
  "paths": {
    "/emsp/v1/chargers": {
      "get": {
        "tags": [
          "Chargers"
        ],
        "summary": "List all chargers",
        "description": "Returns a paginated list of chargers in the network.",
        "operationId": "PublicApi_GetChargers",
        "parameters": [
          {
            "name": "page",
            "in": "query",
            "description": "Page number, 1-based. Defaults to 1.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "description": "Number of items per page (1–100). Defaults to 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "status",
            "in": "query",
            "description": "Filter the results by status.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "locationId",
            "in": "query",
            "description": "Location UUID.",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "isPublic",
            "in": "query",
            "description": "Filter by public availability.",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargersListResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargersErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/chargers/{id}": {
      "get": {
        "tags": [
          "Chargers"
        ],
        "summary": "Get charger details",
        "description": "Returns detailed information about a specific charger including its connectors.",
        "operationId": "PublicApi_GetChargerById",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargersDetailResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargersErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/chargers/{id}/reboot": {
      "post": {
        "tags": [
          "Chargers"
        ],
        "summary": "Reboot a charger",
        "description": "Sends a reset command to the charger. Use 'Soft' for firmware restart or 'Hard' for power cycle.",
        "operationId": "PublicApi_RebootCharger",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "null"
                  },
                  {
                    "$ref": "#/components/schemas/RebootChargerRequest"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargersRebootResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargersErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargersErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/chargers/{identifier}/info": {
      "get": {
        "tags": [
          "Chargers"
        ],
        "summary": "Get charger info for QR code scanning",
        "description": "Returns charger information with pricing details for QR code scanning. Accepts UUID, Uid, or SerialNumber as identifier. Only returns public chargers at published locations.",
        "operationId": "PublicApi_GetChargerInfo",
        "parameters": [
          {
            "name": "identifier",
            "in": "path",
            "description": "Charger UUID or its human-readable unique id — either is accepted.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargersInfoResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargersErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/charging/sessions": {
      "get": {
        "tags": [
          "Charging"
        ],
        "summary": "List charging sessions",
        "description": "Returns a paginated list of charging sessions for the network.",
        "operationId": "PublicApi_GetSessions",
        "parameters": [
          {
            "name": "page",
            "in": "query",
            "description": "Page number, 1-based. Defaults to 1.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "description": "Number of items per page (1–100). Defaults to 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "status",
            "in": "query",
            "description": "Filter the results by status.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "chargerId",
            "in": "query",
            "description": "Charger UUID.",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "locationId",
            "in": "query",
            "description": "Location UUID.",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "from",
            "in": "query",
            "description": "Start of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          },
          {
            "name": "to",
            "in": "query",
            "description": "End of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSessionsListResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSessionsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/charging/sessions/{id}": {
      "get": {
        "tags": [
          "Charging"
        ],
        "summary": "Get session details",
        "description": "Returns detailed information about a specific charging session including cost breakdown.",
        "operationId": "PublicApi_GetSessionById",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSessionsDetailResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSessionsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSessionsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/charging/sessions/{id}/receipt": {
      "get": {
        "tags": [
          "Charging"
        ],
        "summary": "Download session receipt (PDF)",
        "description": "Returns a printable PDF receipt for a charging session (the artifact a driver shows post-session / for expense reporting). Driver keys get their own sessions; operator keys their network's.",
        "operationId": "PublicApi_DownloadSessionReceipt",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSessionsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSessionsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/charging/sessions/{id}/meter-values": {
      "get": {
        "tags": [
          "Charging"
        ],
        "summary": "Get a session's energy curve (meter values)",
        "description": "Returns the time-ordered OCPP meter-value samples captured during the charge — the per-session kWh consumption curve (cumulative register + instantaneous power, plus current/voltage/SoC/temperature when the charger reports them). Use it to draw charging graphs or verify delivered energy. Capped by `limit` (default 1000, max 5000); `truncated` flags when the session has more. Driver keys see their own sessions; operator keys their network's.",
        "operationId": "PublicApi_GetSessionMeterValues",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum number of items to return.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSessionMeterValuesResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSessionsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSessionsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/wallet": {
      "get": {
        "tags": [
          "Wallet"
        ],
        "summary": "List the driver's wallet balances (per operator network)",
        "operationId": "Emsp_GetMyWallets",
        "responses": {
          "200": {
            "description": "OK"
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/wallet/ledger": {
      "get": {
        "tags": [
          "Wallet"
        ],
        "summary": "Recent wallet ledger entries for the driver",
        "operationId": "Emsp_GetMyWalletLedger",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum number of items to return.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/charging/start": {
      "post": {
        "tags": [
          "Charging"
        ],
        "summary": "Start a charging session",
        "description": "Initiates a charging session on the specified charger and connector using the provided authorization ID tag.",
        "operationId": "PublicApi_StartSession",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/StartSessionRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargingStartResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargingErrorResponse"
                }
              }
            }
          },
          "402": {
            "description": "Payment Required",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargingErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargingErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargingErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/charging/stop": {
      "post": {
        "tags": [
          "Charging"
        ],
        "summary": "Stop a charging session",
        "description": "Stops an active charging session and returns the final session details with cost breakdown.",
        "operationId": "PublicApi_StopSession",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/StopSessionRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargingStopResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargingErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargingErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspChargingErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/charging/schedule": {
      "post": {
        "tags": [
          "Charging"
        ],
        "summary": "Schedule a charging session for a future time",
        "operationId": "PublicApi_CreateScheduledCharge",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ScheduleChargeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspScheduledChargingResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspScheduledChargingErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspScheduledChargingErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspScheduledChargingErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/charging/schedules": {
      "get": {
        "tags": [
          "Charging"
        ],
        "summary": "List your scheduled charges",
        "operationId": "PublicApi_ListScheduledCharges",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspScheduledChargingListResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/charging/schedule/{id}": {
      "delete": {
        "tags": [
          "Charging"
        ],
        "summary": "Cancel a scheduled charge",
        "operationId": "PublicApi_CancelScheduledCharge",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "No Content"
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspScheduledChargingErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/connectors/{id}/status": {
      "get": {
        "tags": [
          "Connectors"
        ],
        "summary": "Get connector status",
        "description": "Returns the current status and details of a specific connector.",
        "operationId": "PublicApi_GetConnectorStatus",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspConnectorsStatusResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspConnectorsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/users": {
      "post": {
        "tags": [
          "Users"
        ],
        "summary": "Create a new user",
        "description": "Creates a new user/driver in the network. Returns the created user with statistics.",
        "operationId": "PublicApi_CreateUser",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateUserRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspUsersUserResponse"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspUsersErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "get": {
        "tags": [
          "Users"
        ],
        "summary": "List users",
        "description": "Returns a paginated list of users in the network.",
        "operationId": "PublicApi_ListUsers",
        "parameters": [
          {
            "name": "page",
            "in": "query",
            "description": "Page number, 1-based. Defaults to 1.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "description": "Number of items per page (1–100). Defaults to 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "search",
            "in": "query",
            "description": "Free-text search across the resource's principal fields.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspUsersUserListResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspUsersErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/users/{id}": {
      "get": {
        "tags": [
          "Users"
        ],
        "summary": "Get user details",
        "description": "Returns detailed information about a user including charging statistics.",
        "operationId": "PublicApi_GetUserById",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspUsersUserResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspUsersErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "put": {
        "tags": [
          "Users"
        ],
        "summary": "Update user information",
        "description": "Updates an existing user's information. Only provided fields are updated.",
        "operationId": "PublicApi_UpdateUser",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateUserRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspUsersUserResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspUsersErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspUsersErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/auth/tokens": {
      "post": {
        "tags": [
          "Auth"
        ],
        "summary": "Create authentication token",
        "description": "Creates a new authentication token for a user. The token can be used for charging sessions.",
        "operationId": "PublicApi_CreateToken",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateTokenRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAuthTokenResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAuthErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAuthErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "get": {
        "tags": [
          "Auth"
        ],
        "summary": "List tokens",
        "description": "Returns a paginated list of tokens for a user.",
        "operationId": "PublicApi_ListTokens",
        "parameters": [
          {
            "name": "userId",
            "in": "query",
            "description": "User UUID.",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "tokenType",
            "in": "query",
            "description": "Filter by token type.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "valid",
            "in": "query",
            "description": "Filter by validity.",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "page",
            "in": "query",
            "description": "Page number, 1-based. Defaults to 1.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "description": "Number of items per page (1–100). Defaults to 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAuthTokenListResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/auth/tokens/{id}": {
      "get": {
        "tags": [
          "Auth"
        ],
        "summary": "Get token details",
        "description": "Returns detailed information about a specific token.",
        "operationId": "PublicApi_GetToken",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAuthTokenResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAuthErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "delete": {
        "tags": [
          "Auth"
        ],
        "summary": "Invalidate a token",
        "description": "Invalidates (soft-deletes) a token so it can no longer be used for authorization.",
        "operationId": "PublicApi_InvalidateToken",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAuthTokenActionResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAuthErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/auth/driver/register": {
      "post": {
        "tags": [
          "Auth"
        ],
        "summary": "Register a new driver account",
        "operationId": "PublicApi_DriverRegister",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DriverRegisterRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/auth/driver/login": {
      "post": {
        "tags": [
          "Auth"
        ],
        "summary": "Login with email and password",
        "operationId": "PublicApi_DriverLogin",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DriverLoginRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthErrorResponse"
                }
              }
            }
          },
          "429": {
            "description": "Too Many Requests",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/auth/driver/refresh": {
      "post": {
        "tags": [
          "Auth"
        ],
        "summary": "Refresh access token using refresh token",
        "operationId": "PublicApi_DriverRefresh",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DriverRefreshRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthRefreshResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/auth/driver/forgot-password": {
      "post": {
        "tags": [
          "Auth"
        ],
        "summary": "Request a password reset email",
        "operationId": "PublicApi_DriverForgotPassword",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DriverForgotPasswordRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthMessageResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/auth/driver/reset-password": {
      "post": {
        "tags": [
          "Auth"
        ],
        "summary": "Reset password using token from email",
        "operationId": "PublicApi_DriverResetPassword",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DriverResetPasswordRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthMessageResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/auth/driver/me": {
      "get": {
        "tags": [
          "Auth"
        ],
        "summary": "Get authenticated driver's profile",
        "operationId": "PublicApi_DriverMe",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthMeResponse"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspDriverAuthErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/me-key": {
      "get": {
        "tags": [
          "Me Key"
        ],
        "summary": "Describe the authenticated API key (identity, scopes, limits, driver)",
        "description": "Start here. Returns this key's family, environment, visibility, granted scopes and current capabilities, plus rate-limit and idempotency conventions. Use it to verify a key works: it returns content even on a brand-new account, whereas list endpoints correctly return an empty array that is indistinguishable from a bad credential.",
        "operationId": "PublicApi_MeKey",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/KeyContextResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/.well-known/scopes": {
      "get": {
        "tags": [
          ".Well Known"
        ],
        "summary": "Canonical eMSP scope catalog (the OAuth scope vocabulary)",
        "description": "Every eMSP scope and what it grants — the vocabulary behind the `scopes` array on /me-key.",
        "operationId": "PublicApi_ScopeCatalog",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ScopeCatalogResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/networks/{networkId}/branding": {
      "get": {
        "tags": [
          "Networks"
        ],
        "summary": "Public network branding (name, logo, colors) for white-label theming",
        "operationId": "PublicApi_NetworkBranding",
        "parameters": [
          {
            "name": "networkId",
            "in": "path",
            "description": "Network UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspNetworkBrandingResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspNetworkBrandingErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/transactions": {
      "get": {
        "tags": [
          "Transactions"
        ],
        "summary": "List transactions",
        "description": "Returns a paginated list of transactions (CDRs) for the network.",
        "operationId": "PublicApi_ListTransactions",
        "parameters": [
          {
            "name": "page",
            "in": "query",
            "description": "Page number, 1-based. Defaults to 1.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "description": "Number of items per page (1–100). Defaults to 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "from",
            "in": "query",
            "description": "Start of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          },
          {
            "name": "to",
            "in": "query",
            "description": "End of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          },
          {
            "name": "userId",
            "in": "query",
            "description": "User UUID.",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "status",
            "in": "query",
            "description": "Filter the results by status.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsListResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/transactions/{id}": {
      "get": {
        "tags": [
          "Transactions"
        ],
        "summary": "Get transaction details",
        "description": "Returns detailed information about a specific transaction including cost breakdown.",
        "operationId": "PublicApi_GetTransaction",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsDetailResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/invoices": {
      "post": {
        "tags": [
          "Invoices"
        ],
        "summary": "Generate invoice",
        "description": "Generates an invoice for one or more transactions and persists it (the covered transactions are stamped with the invoice number).",
        "operationId": "PublicApi_GenerateInvoice",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GenerateInvoiceRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsInvoiceResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "get": {
        "tags": [
          "Invoices"
        ],
        "summary": "List invoices",
        "description": "Lists generated invoices (one row per invoice number), newest first. Scoped to the caller: a driver sees only their own invoices; an operator key sees its network's.",
        "operationId": "PublicApi_ListInvoices",
        "parameters": [
          {
            "name": "page",
            "in": "query",
            "description": "Page number, 1-based. Defaults to 1.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "description": "Number of items per page (1–100). Defaults to 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/PublicApiInvoiceSummaryDto"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/invoices/{invoiceNumber}": {
      "get": {
        "tags": [
          "Invoices"
        ],
        "summary": "Retrieve invoice",
        "description": "Retrieves a single invoice (with line items + totals) by its invoice number.",
        "operationId": "PublicApi_GetInvoice",
        "parameters": [
          {
            "name": "invoiceNumber",
            "in": "path",
            "description": "Invoice number.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsInvoiceResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/pricing/calculate": {
      "post": {
        "tags": [
          "Pricing"
        ],
        "summary": "Calculate charging cost",
        "description": "Calculates the estimated cost for a charging session based on tariff rates.",
        "operationId": "PublicApi_CalculatePricing",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PricingCalculationRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsPricingResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTransactionsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/analytics/sessions": {
      "get": {
        "tags": [
          "Analytics"
        ],
        "summary": "Get session analytics",
        "description": "Returns session analytics including counts, averages, and time series data.",
        "operationId": "PublicApi_GetSessionAnalytics",
        "parameters": [
          {
            "name": "period",
            "in": "query",
            "description": "Aggregation period for the results, e.g. day, week or month.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "from",
            "in": "query",
            "description": "Start of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          },
          {
            "name": "to",
            "in": "query",
            "description": "End of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsSessionResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/analytics/revenue": {
      "get": {
        "tags": [
          "Analytics"
        ],
        "summary": "Get revenue analytics",
        "description": "Returns revenue analytics including totals, averages, and time series data.",
        "operationId": "PublicApi_GetRevenueAnalytics",
        "parameters": [
          {
            "name": "period",
            "in": "query",
            "description": "Aggregation period for the results, e.g. day, week or month.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "from",
            "in": "query",
            "description": "Start of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          },
          {
            "name": "to",
            "in": "query",
            "description": "End of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsRevenueResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/analytics/energy": {
      "get": {
        "tags": [
          "Analytics"
        ],
        "summary": "Get energy consumption analytics",
        "description": "Returns energy consumption analytics including totals and time series data.",
        "operationId": "PublicApi_GetEnergyAnalytics",
        "parameters": [
          {
            "name": "period",
            "in": "query",
            "description": "Aggregation period for the results, e.g. day, week or month.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "from",
            "in": "query",
            "description": "Start of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          },
          {
            "name": "to",
            "in": "query",
            "description": "End of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsEnergyResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/reports/export": {
      "get": {
        "tags": [
          "Reports"
        ],
        "summary": "Export custom reports",
        "description": "Exports reports in JSON or CSV format. Supported types: daily-sales, by-location, by-user, sessions-summary.",
        "operationId": "PublicApi_ExportReport",
        "parameters": [
          {
            "name": "type",
            "in": "query",
            "description": "Filter the results by type.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "format",
            "in": "query",
            "description": "Response format to export.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "from",
            "in": "query",
            "description": "Start of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          },
          {
            "name": "to",
            "in": "query",
            "description": "End of the time range, inclusive. ISO-8601.",
            "schema": {
              "format": "date-time"
            }
          },
          {
            "name": "locationId",
            "in": "query",
            "description": "Location UUID.",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "userId",
            "in": "query",
            "description": "User UUID.",
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsReportExportResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspAnalyticsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/webhooks": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "summary": "List webhook subscriptions",
        "operationId": "PublicApi_ListWebhooks",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksListResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "post": {
        "tags": [
          "Webhooks"
        ],
        "summary": "Create webhook subscription",
        "operationId": "PublicApi_CreateWebhook",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateWebhookRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksCreatedResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/webhooks/{webhookId}": {
      "patch": {
        "tags": [
          "Webhooks"
        ],
        "summary": "Update webhook subscription",
        "operationId": "PublicApi_UpdateWebhook",
        "parameters": [
          {
            "name": "webhookId",
            "in": "path",
            "description": "Webhook subscription UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateWebhookRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksSubscriptionResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "delete": {
        "tags": [
          "Webhooks"
        ],
        "summary": "Delete webhook subscription",
        "operationId": "PublicApi_DeleteWebhook",
        "parameters": [
          {
            "name": "webhookId",
            "in": "path",
            "description": "Webhook subscription UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/webhooks/{webhookId}/test": {
      "post": {
        "tags": [
          "Webhooks"
        ],
        "summary": "Send test event to webhook",
        "operationId": "PublicApi_TestWebhook",
        "parameters": [
          {
            "name": "webhookId",
            "in": "path",
            "description": "Webhook subscription UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksTestResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/webhooks/{webhookId}/deliveries": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "summary": "List webhook deliveries",
        "operationId": "PublicApi_ListWebhookDeliveries",
        "parameters": [
          {
            "name": "webhookId",
            "in": "path",
            "description": "Webhook subscription UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "page",
            "in": "query",
            "description": "Page number, 1-based. Defaults to 1.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "description": "Number of items per page (1–100). Defaults to 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksDeliveryListResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/webhooks/{webhookId}/deliveries/{deliveryId}": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "summary": "Get webhook delivery detail",
        "operationId": "PublicApi_GetWebhookDelivery",
        "parameters": [
          {
            "name": "webhookId",
            "in": "path",
            "description": "Webhook subscription UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "deliveryId",
            "in": "path",
            "description": "Webhook delivery attempt UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksDeliveryDetailResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/webhooks/{webhookId}/deliveries/{deliveryId}/retry": {
      "post": {
        "tags": [
          "Webhooks"
        ],
        "summary": "Retry a webhook delivery",
        "operationId": "PublicApi_RetryWebhookDelivery",
        "parameters": [
          {
            "name": "webhookId",
            "in": "path",
            "description": "Webhook subscription UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "deliveryId",
            "in": "path",
            "description": "Webhook delivery attempt UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "202": {
            "description": "Accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksRetryResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/webhooks/event-types": {
      "get": {
        "tags": [
          "Webhooks"
        ],
        "summary": "List available webhook event types",
        "operationId": "PublicApi_GetWebhookEventTypes",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspWebhooksEventTypesResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/events/stream": {
      "get": {
        "tags": [
          "Events"
        ],
        "summary": "SSE event stream for real-time updates",
        "operationId": "PublicApi_StreamEvents",
        "parameters": [
          {
            "name": "eventTypes",
            "in": "query",
            "description": "Comma-separated list of event types to subscribe to.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "stationIds",
            "in": "query",
            "description": "Comma-separated list of station UUIDs to filter by.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspEventStreamErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/reservations": {
      "post": {
        "tags": [
          "Reservations"
        ],
        "summary": "Reserve a connector",
        "description": "Holds a connector for the authenticated driver until the expiry time (OCPP ReserveNow).",
        "operationId": "PublicApi_Reserve",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReserveRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsRejectedResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "get": {
        "tags": [
          "Reservations"
        ],
        "summary": "List reservations",
        "operationId": "PublicApi_ListReservations",
        "parameters": [
          {
            "name": "status",
            "in": "query",
            "description": "Filter the results by status.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "page",
            "in": "query",
            "description": "Page number, 1-based. Defaults to 1.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "description": "Number of items per page (1–100). Defaults to 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsListResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/reservations/{id}": {
      "get": {
        "tags": [
          "Reservations"
        ],
        "summary": "Get a reservation",
        "operationId": "PublicApi_GetReservation",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "delete": {
        "tags": [
          "Reservations"
        ],
        "summary": "Cancel a reservation",
        "operationId": "PublicApi_CancelReservation",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspReservationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/locations": {
      "get": {
        "tags": [
          "Locations"
        ],
        "summary": "List locations",
        "operationId": "PublicApi_ListLocations",
        "parameters": [
          {
            "name": "city",
            "in": "query",
            "description": "Filter by city name.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "q",
            "in": "query",
            "description": "Free-text search query.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "page",
            "in": "query",
            "description": "Page number, 1-based. Defaults to 1.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "description": "Number of items per page (1–100). Defaults to 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsListResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/locations/search": {
      "get": {
        "tags": [
          "Locations"
        ],
        "summary": "Find locations near a point",
        "operationId": "PublicApi_SearchLocations",
        "parameters": [
          {
            "name": "lat",
            "in": "query",
            "description": "Latitude of the search centre, decimal degrees.",
            "schema": {
              "type": "object",
              "anyOf": [
                {
                  "type": "number"
                },
                {
                  "enum": [
                    "NaN",
                    "Infinity",
                    "-Infinity"
                  ]
                }
              ],
              "format": "double"
            }
          },
          {
            "name": "lng",
            "in": "query",
            "description": "Longitude of the search centre, decimal degrees.",
            "schema": {
              "type": "object",
              "anyOf": [
                {
                  "type": "number"
                },
                {
                  "enum": [
                    "NaN",
                    "Infinity",
                    "-Infinity"
                  ]
                }
              ],
              "format": "double"
            }
          },
          {
            "name": "radiusKm",
            "in": "query",
            "description": "Search radius from the centre point, in kilometres.",
            "schema": {
              "type": "object",
              "anyOf": [
                {
                  "type": "number"
                },
                {
                  "enum": [
                    "NaN",
                    "Infinity",
                    "-Infinity"
                  ]
                }
              ],
              "format": "double"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "description": "Maximum number of items to return.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsListResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/locations/{id}": {
      "get": {
        "tags": [
          "Locations"
        ],
        "summary": "Get a location",
        "operationId": "PublicApi_GetLocation",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsDetailResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/locations/{id}/chargers": {
      "get": {
        "tags": [
          "Locations"
        ],
        "summary": "List chargers at a location",
        "operationId": "PublicApi_GetLocationChargers",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsChargersResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/locations/{id}/reviews": {
      "get": {
        "tags": [
          "Locations"
        ],
        "summary": "Driver reviews + rating summary for a location",
        "operationId": "PublicApi_GetLocationReviews",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsReviewsResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "post": {
        "tags": [
          "Locations"
        ],
        "summary": "Create or update the driver's review for a location",
        "operationId": "PublicApi_AddLocationReview",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LocationReviewRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsReviewResultResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/locations/{id}/report": {
      "post": {
        "tags": [
          "Locations"
        ],
        "summary": "Report a problem at a location (raises an operator alert)",
        "operationId": "PublicApi_ReportLocationIssue",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LocationIssueReportRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsIssueReceiptResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspLocationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/tariffs": {
      "get": {
        "tags": [
          "Tariffs"
        ],
        "summary": "List available tariffs",
        "operationId": "PublicApi_ListTariffs",
        "parameters": [
          {
            "name": "activeOnly",
            "in": "query",
            "description": "Return only active records. Defaults to false.",
            "schema": {
              "type": "boolean"
            }
          },
          {
            "name": "page",
            "in": "query",
            "description": "Page number, 1-based. Defaults to 1.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "description": "Number of items per page (1–100). Defaults to 50.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTariffsListResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTariffsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/tariffs/{id}": {
      "get": {
        "tags": [
          "Tariffs"
        ],
        "summary": "Get a tariff",
        "operationId": "PublicApi_GetTariff",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTariffsDetailResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspTariffsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/smart-charging/{chargerId}/limit": {
      "get": {
        "tags": [
          "Smart Charging"
        ],
        "summary": "Get the effective charging limit for a connector",
        "operationId": "PublicApi_GetSmartChargingLimit",
        "parameters": [
          {
            "name": "chargerId",
            "in": "path",
            "description": "Charger UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "connector",
            "in": "query",
            "description": "Connector number on the charger, 1-based.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "unit",
            "in": "query",
            "description": "Unit the value is expressed in.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingLimitResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "put": {
        "tags": [
          "Smart Charging"
        ],
        "summary": "Set a max charging speed for a connector",
        "operationId": "PublicApi_SetSmartChargingLimit",
        "parameters": [
          {
            "name": "chargerId",
            "in": "path",
            "description": "Charger UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SmartChargingLimitRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingSetLimitResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "delete": {
        "tags": [
          "Smart Charging"
        ],
        "summary": "Clear the driver-set charging limit on a connector",
        "operationId": "PublicApi_ClearSmartChargingLimit",
        "parameters": [
          {
            "name": "chargerId",
            "in": "path",
            "description": "Charger UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          },
          {
            "name": "connector",
            "in": "query",
            "description": "Connector number on the charger, 1-based.",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingClearLimitResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspSmartChargingErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/remote-control/{chargerId}/unlock": {
      "post": {
        "tags": [
          "Remote Control"
        ],
        "summary": "Unlock a connector",
        "operationId": "PublicApi_RemoteUnlock",
        "parameters": [
          {
            "name": "chargerId",
            "in": "path",
            "description": "Charger UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UnlockRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspRemoteControlUnlockResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspRemoteControlErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspRemoteControlErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/remote-control/{chargerId}/trigger": {
      "post": {
        "tags": [
          "Remote Control"
        ],
        "summary": "Ask the charger to re-send a message",
        "operationId": "PublicApi_RemoteTrigger",
        "parameters": [
          {
            "name": "chargerId",
            "in": "path",
            "description": "Charger UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TriggerRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspRemoteControlTriggerResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspRemoteControlErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspRemoteControlErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspRemoteControlErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/remote-control/{chargerId}/reset": {
      "post": {
        "tags": [
          "Remote Control"
        ],
        "summary": "Reset a charger",
        "operationId": "PublicApi_RemoteReset",
        "parameters": [
          {
            "name": "chargerId",
            "in": "path",
            "description": "Charger UUID.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ResetRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspRemoteControlResetResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspRemoteControlErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspRemoteControlErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/notifications/preferences": {
      "get": {
        "tags": [
          "Notifications"
        ],
        "summary": "Get the driver's notification preferences",
        "operationId": "PublicApi_GetNotificationPreferences",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspNotificationsPreferencesResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspNotificationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "put": {
        "tags": [
          "Notifications"
        ],
        "summary": "Update the driver's notification preferences",
        "operationId": "PublicApi_UpdateNotificationPreferences",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/NotificationPreferencesRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspNotificationsPreferencesResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspNotificationsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/favorites": {
      "get": {
        "tags": [
          "Favorites"
        ],
        "summary": "List the driver's favorites",
        "operationId": "PublicApi_ListFavorites",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspFavoritesFavoriteListResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspFavoritesErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      },
      "post": {
        "tags": [
          "Favorites"
        ],
        "summary": "Save a favorite",
        "operationId": "PublicApi_AddFavorite",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/FavoriteRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspFavoritesFavoriteResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspFavoritesErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspFavoritesErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/favorites/{id}": {
      "delete": {
        "tags": [
          "Favorites"
        ],
        "summary": "Remove a favorite",
        "operationId": "PublicApi_RemoveFavorite",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "204": {
            "description": "No Content"
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspFavoritesErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/push/subscribe": {
      "post": {
        "tags": [
          "Push"
        ],
        "summary": "Register this device's web-push subscription",
        "operationId": "PublicApi_PushSubscribe",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PushSubscribeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPushSubscribeResponse"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPushErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPushErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/push/unsubscribe": {
      "post": {
        "tags": [
          "Push"
        ],
        "summary": "Remove a web-push subscription",
        "operationId": "PublicApi_PushUnsubscribe",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PushUnsubscribeRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "204": {
            "description": "No Content"
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPushErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPushErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/push/test": {
      "post": {
        "tags": [
          "Push"
        ],
        "summary": "Send a test push to the driver's devices",
        "operationId": "PublicApi_PushTest",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPushTestResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPushErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/payments/config": {
      "get": {
        "tags": [
          "Payments"
        ],
        "summary": "Discover how this network handles payment",
        "operationId": "PublicApi_GetPaymentConfig",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsConfigResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/payments/methods": {
      "get": {
        "tags": [
          "Payments"
        ],
        "summary": "List the driver's saved cards (phevnix_managed only)",
        "operationId": "PublicApi_GetPaymentMethods",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsMethodsResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/payments/setup-intent": {
      "post": {
        "tags": [
          "Payments"
        ],
        "summary": "Begin saving a card — returns a SetupIntent client_secret for the app",
        "operationId": "PublicApi_CreateSetupIntent",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsSetupIntentResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          },
          "502": {
            "description": "Bad Gateway",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/payments/setup-checkout": {
      "post": {
        "tags": [
          "Payments"
        ],
        "summary": "Begin saving a card via a Stripe-HOSTED page — returns a URL the driver opens in a browser",
        "operationId": "PublicApi_CreateSetupCheckout",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsSetupCheckoutResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "Conflict",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          },
          "502": {
            "description": "Bad Gateway",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/payments/methods/{id}/default": {
      "post": {
        "tags": [
          "Payments"
        ],
        "summary": "Make a saved card the default",
        "operationId": "PublicApi_SetDefaultPaymentMethod",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          },
          "502": {
            "description": "Bad Gateway",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/payments/methods/{id}": {
      "delete": {
        "tags": [
          "Payments"
        ],
        "summary": "Remove a saved card",
        "operationId": "PublicApi_RemovePaymentMethod",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "description": "The resource identifier.",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          },
          "502": {
            "description": "Bad Gateway",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    },
    "/emsp/v1/payments/checkout": {
      "post": {
        "tags": [
          "Payments"
        ],
        "summary": "Report a session's payment status (managed networks capture automatically at stop)",
        "operationId": "PublicApi_PaymentCheckout",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CheckoutRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsCheckoutResponse"
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/EmspPaymentsErrorResponse"
                }
              }
            }
          }
        },
        "security": [
          {}
        ]
      }
    }
  },
  "components": {
    "schemas": {
      "CheckoutRequest": {
        "type": "object",
        "properties": {
          "sessionId": {
            "type": "string",
            "format": "uuid"
          },
          "amount": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          },
          "currency": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "CreateTokenRequest": {
        "required": [
          "userId"
        ],
        "type": "object",
        "properties": {
          "userId": {
            "type": "string",
            "format": "uuid"
          },
          "tokenType": {
            "maxLength": 16,
            "minLength": 0,
            "type": "string"
          },
          "uid": {
            "maxLength": 36,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "alias": {
            "maxLength": 100,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "expiresAt": {
            "format": "date-time"
          }
        }
      },
      "CreateUserRequest": {
        "required": [
          "email",
          "firstName",
          "lastName"
        ],
        "type": "object",
        "properties": {
          "email": {
            "maxLength": 100,
            "minLength": 0,
            "type": "string"
          },
          "firstName": {
            "maxLength": 50,
            "minLength": 0,
            "type": "string"
          },
          "lastName": {
            "maxLength": 50,
            "minLength": 0,
            "type": "string"
          },
          "phoneNumber": {
            "maxLength": 20,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "address": {
            "maxLength": 200,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "city": {
            "maxLength": 100,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "state": {
            "maxLength": 50,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "postalCode": {
            "maxLength": 20,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "country": {
            "maxLength": 50,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "CreateWebhookRequest": {
        "required": [
          "url",
          "events",
          "description"
        ],
        "type": "object",
        "properties": {
          "url": {
            "type": "string"
          },
          "events": {
            "type": "string"
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "DiscoveryLinks": {
        "type": "object",
        "properties": {
          "scopeCatalog": {
            "type": "string",
            "description": "Path to the scope vocabulary for this family.",
            "example": "/emsp/v1/.well-known/scopes"
          }
        }
      },
      "DriverContext": {
        "type": "object",
        "properties": {
          "authenticated": {
            "type": "boolean",
            "example": false
          },
          "id": {
            "type": [
              "null",
              "string"
            ],
            "description": "The signed-in driver's UUID, when a driver JWT was supplied.",
            "format": "uuid"
          }
        }
      },
      "DriverForgotPasswordRequest": {
        "required": [
          "email"
        ],
        "type": "object",
        "properties": {
          "email": {
            "type": "string"
          }
        }
      },
      "DriverLoginRequest": {
        "required": [
          "email",
          "password"
        ],
        "type": "object",
        "properties": {
          "email": {
            "type": "string"
          },
          "password": {
            "type": "string"
          }
        }
      },
      "DriverRefreshRequest": {
        "required": [
          "refreshToken"
        ],
        "type": "object",
        "properties": {
          "refreshToken": {
            "type": "string"
          }
        }
      },
      "DriverRegisterRequest": {
        "required": [
          "email",
          "password",
          "firstName",
          "lastName"
        ],
        "type": "object",
        "properties": {
          "email": {
            "type": "string"
          },
          "password": {
            "type": "string"
          },
          "firstName": {
            "type": "string"
          },
          "lastName": {
            "type": "string"
          },
          "phone": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "DriverResetPasswordRequest": {
        "required": [
          "token",
          "newPassword"
        ],
        "type": "object",
        "properties": {
          "token": {
            "type": "string"
          },
          "newPassword": {
            "type": "string"
          }
        }
      },
      "EmspAnalyticsCategoryPoint": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "Category name (e.g. a location name).",
            "example": "Isla Verde Mall"
          },
          "value": {
            "type": "number",
            "description": "Aggregated value for this category, in the response currency.",
            "format": "double",
            "example": 842.75
          },
          "percentage": {
            "type": "number",
            "description": "This category's share of the total, as a percentage (0–100).",
            "format": "double",
            "example": 31.4
          }
        }
      },
      "EmspAnalyticsEnergyAnalytics": {
        "type": "object",
        "properties": {
          "totalEnergyKwh": {
            "type": "number",
            "description": "Total energy delivered in the window, in kWh (rounded to 2 dp).",
            "format": "double",
            "example": 34328.1
          },
          "averagePerSessionKwh": {
            "type": "number",
            "description": "Average energy delivered per session, in kWh.",
            "format": "double",
            "example": 18.64
          },
          "peakDayKwh": {
            "type": "number",
            "description": "Energy delivered on the single highest day, in kWh.",
            "format": "double",
            "example": 1640.2
          },
          "peakDayDate": {
            "description": "UTC date of the highest-energy day, or null when there are no sessions.",
            "format": "date-time",
            "example": "2026-06-07T00:00:00Z"
          },
          "growthPercentage": {
            "type": "number",
            "description": "Energy growth vs the previous equal-length window, as a percentage.",
            "format": "double",
            "example": 7.2
          },
          "period": {
            "type": "string",
            "description": "Time-series bucketing requested (day, week, or month).",
            "example": "day"
          },
          "fromDate": {
            "description": "UTC start of the analytics window.",
            "format": "date-time",
            "example": "2026-05-20T00:00:00Z"
          },
          "toDate": {
            "description": "UTC end of the analytics window.",
            "format": "date-time",
            "example": "2026-06-19T00:00:00Z"
          },
          "timeline": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspAnalyticsTimeSeriesPoint"
            },
            "description": "Energy delivered bucketed over the window."
          }
        }
      },
      "EmspAnalyticsEnergyResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspAnalyticsEnergyAnalytics"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspAnalyticsErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. forbidden, bad_request, date_range_too_large).",
            "example": "date_range_too_large"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "The requested date range exceeds the maximum of 366 days."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent/MCP tool branches on.",
            "example": "date_range_too_large"
          },
          "timestamp": {
            "description": "UTC time the error was generated. Present on permission/validation errors; absent on the date-range guard.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "details": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "description": "Optional field-level validation details, keyed by field name."
          }
        }
      },
      "EmspAnalyticsReportExport": {
        "type": "object",
        "properties": {
          "reportType": {
            "type": "string",
            "description": "The report type that was generated (daily-sales, by-location, by-user, sessions-summary).",
            "example": "daily-sales"
          },
          "generatedAt": {
            "description": "UTC time the report was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "fromDate": {
            "description": "UTC start of the report window.",
            "format": "date-time",
            "example": "2026-05-20T00:00:00Z"
          },
          "toDate": {
            "description": "UTC end of the report window.",
            "format": "date-time",
            "example": "2026-06-19T00:00:00Z"
          },
          "format": {
            "type": "string",
            "description": "Export format requested (json or csv).",
            "example": "json"
          },
          "recordCount": {
            "type": "integer",
            "description": "Number of rows in the report.",
            "format": "int32",
            "example": 30
          },
          "data": {
            "description": "The report rows — an array whose row shape depends on reportType (daily-sales, by-location, by-user, or sessions-summary)."
          }
        }
      },
      "EmspAnalyticsReportExportResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspAnalyticsReportExport"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspAnalyticsRevenueAnalytics": {
        "type": "object",
        "properties": {
          "totalRevenue": {
            "type": "number",
            "description": "Total revenue in the window, in the response currency (rounded to 2 dp).",
            "format": "double",
            "example": 26840.5
          },
          "averagePerSession": {
            "type": "number",
            "description": "Average revenue per paid session, in the response currency.",
            "format": "double",
            "example": 14.57
          },
          "currency": {
            "type": "string",
            "description": "ISO 4217 currency code the revenue is expressed in.",
            "example": "USD"
          },
          "growthPercentage": {
            "type": "number",
            "description": "Revenue growth vs the previous equal-length window, as a percentage.",
            "format": "double",
            "example": 9.8
          },
          "period": {
            "type": "string",
            "description": "Time-series bucketing requested (day, week, or month).",
            "example": "day"
          },
          "fromDate": {
            "description": "UTC start of the analytics window.",
            "format": "date-time",
            "example": "2026-05-20T00:00:00Z"
          },
          "toDate": {
            "description": "UTC end of the analytics window.",
            "format": "date-time",
            "example": "2026-06-19T00:00:00Z"
          },
          "timeline": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspAnalyticsTimeSeriesPoint"
            },
            "description": "Revenue bucketed over the window."
          },
          "revenueByLocation": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspAnalyticsCategoryPoint"
            },
            "description": "Top 10 locations by revenue in the window."
          }
        }
      },
      "EmspAnalyticsRevenueResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspAnalyticsRevenueAnalytics"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspAnalyticsSessionAnalytics": {
        "type": "object",
        "properties": {
          "totalSessions": {
            "type": "integer",
            "description": "Total sessions started in the window.",
            "format": "int32",
            "example": 1842
          },
          "completedSessions": {
            "type": "integer",
            "description": "Sessions that completed successfully.",
            "format": "int32",
            "example": 1790
          },
          "failedSessions": {
            "type": "integer",
            "description": "Sessions that failed or errored.",
            "format": "int32",
            "example": 52
          },
          "averageSessionDurationMinutes": {
            "type": "number",
            "description": "Average session duration, in minutes (rounded to 2 dp).",
            "format": "double",
            "example": 47.32
          },
          "averageEnergyPerSessionKwh": {
            "type": "number",
            "description": "Average energy delivered per session, in kWh (rounded to 2 dp).",
            "format": "double",
            "example": 18.64
          },
          "growthPercentage": {
            "type": "number",
            "description": "Session-count growth vs the previous equal-length window, as a percentage.",
            "format": "double",
            "example": 12.5
          },
          "period": {
            "type": "string",
            "description": "Time-series bucketing requested (day, week, or month).",
            "example": "day"
          },
          "fromDate": {
            "description": "UTC start of the analytics window.",
            "format": "date-time",
            "example": "2026-05-20T00:00:00Z"
          },
          "toDate": {
            "description": "UTC end of the analytics window.",
            "format": "date-time",
            "example": "2026-06-19T00:00:00Z"
          },
          "timeline": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspAnalyticsTimeSeriesPoint"
            },
            "description": "Session counts bucketed over the window."
          }
        }
      },
      "EmspAnalyticsSessionResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspAnalyticsSessionAnalytics"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspAnalyticsTimeSeriesPoint": {
        "type": "object",
        "properties": {
          "date": {
            "description": "UTC bucket timestamp for this point (day/week/month start, per the period).",
            "format": "date-time",
            "example": "2026-06-18T00:00:00Z"
          },
          "value": {
            "type": "number",
            "description": "Aggregated value for this bucket (sessions count, revenue, or kWh depending on the series).",
            "format": "double",
            "example": 124.5
          },
          "label": {
            "type": [
              "null",
              "string"
            ],
            "description": "Optional human label for the bucket, or null.",
            "example": "Jun 18"
          }
        }
      },
      "EmspAuthErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. not_found, forbidden, conflict).",
            "example": "not_found"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Token with identifier '7c1e2a44-9b3d-4e6f-8a01-2b3c4d5e6f70' was not found."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent can branch on (defaults to the error slug).",
            "example": "RESOURCE_NOT_FOUND"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "details": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "description": "Optional field-level validation details, keyed by field name."
          }
        }
      },
      "EmspAuthPagination": {
        "type": "object",
        "properties": {
          "totalCount": {
            "type": "integer",
            "description": "Total number of tokens across all pages.",
            "format": "int32",
            "example": 42
          },
          "page": {
            "type": "integer",
            "description": "1-based page index of this result set.",
            "format": "int32",
            "example": 1
          },
          "pageSize": {
            "type": "integer",
            "description": "Items per page (1–100; defaults to 20).",
            "format": "int32",
            "example": 20
          },
          "totalPages": {
            "type": "integer",
            "description": "Total number of pages at the current pageSize.",
            "format": "int32",
            "example": 3
          },
          "hasNextPage": {
            "type": "boolean",
            "description": "True when a page after this one exists.",
            "example": true
          },
          "hasPreviousPage": {
            "type": "boolean",
            "description": "True when a page before this one exists.",
            "example": false
          }
        }
      },
      "EmspAuthTokenActionModel": {
        "type": "object",
        "properties": {
          "tokenId": {
            "type": "string",
            "description": "UUID of the token the action was applied to.",
            "format": "uuid",
            "example": "7c1e2a44-9b3d-4e6f-8a01-2b3c4d5e6f70"
          },
          "action": {
            "type": "string",
            "description": "The action that was performed (e.g. \"invalidate\").",
            "example": "invalidate"
          },
          "success": {
            "type": "boolean",
            "description": "True when the action completed successfully.",
            "example": true
          },
          "message": {
            "type": [
              "null",
              "string"
            ],
            "description": "Human-readable description of the outcome.",
            "example": "Token has been invalidated successfully"
          }
        }
      },
      "EmspAuthTokenActionResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "The action result.",
            "$ref": "#/components/schemas/EmspAuthTokenActionModel"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspAuthTokenListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspAuthTokenModel"
            },
            "description": "The page of tokens."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "pagination": {
            "description": "Page metadata for the result set.",
            "$ref": "#/components/schemas/EmspAuthPagination"
          }
        }
      },
      "EmspAuthTokenModel": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable token UUID. Use it in GET /auth/tokens/{id} and DELETE /auth/tokens/{id}.",
            "format": "uuid",
            "example": "7c1e2a44-9b3d-4e6f-8a01-2b3c4d5e6f70"
          },
          "uid": {
            "type": "string",
            "description": "Token UID — the credential a charger reads (RFID card serial or app-issued identifier). Auto-generated (12-char alphanumeric) when not supplied on create.",
            "example": "A1B2C3D4E5F6"
          },
          "contractId": {
            "type": "string",
            "description": "OCPI-style eMA contract id (COUNTRY-PARTY-UNIQUE), generated per token from the owning network.",
            "example": "US-PHV-A1B2C3D4"
          },
          "tokenType": {
            "type": "string",
            "description": "Token category: RFID, APP_USER, AD_HOC_USER, or OTHER.",
            "example": "APP_USER"
          },
          "alias": {
            "type": [
              "null",
              "string"
            ],
            "description": "Optional human-friendly label for the token.",
            "example": "Maya's app token"
          },
          "valid": {
            "type": "boolean",
            "description": "Whether the token may currently be used to authorize charging. Set to false by DELETE /auth/tokens/{id}.",
            "example": true
          },
          "userId": {
            "type": "string",
            "description": "UUID of the driver (user) this token belongs to.",
            "format": "uuid",
            "example": "1ae38f39-2c4b-4d5e-9f10-3a4b5c6d7e8f"
          },
          "createdAt": {
            "description": "UTC timestamp when the token was created.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "expiresAt": {
            "description": "Optional UTC expiry. Null means the token does not expire.",
            "format": "date-time",
            "example": "2027-06-19T00:00:00Z"
          },
          "lastUsedAt": {
            "description": "UTC timestamp the token was last used to authorize a session, or null if never used.",
            "format": "date-time",
            "example": "2026-06-18T14:05:33Z"
          }
        }
      },
      "EmspAuthTokenResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "The token.",
            "$ref": "#/components/schemas/EmspAuthTokenModel"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspChargersChargerDetail": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable charger UUID.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "uid": {
            "type": "string",
            "description": "OCPP charge-point identity (chargePointId).",
            "example": "CP-IslaVerde-01"
          },
          "evseId": {
            "type": [
              "null",
              "string"
            ],
            "description": "eMI3/OCPI EVSE identifier, if assigned.",
            "example": "PR*PHX*E001234"
          },
          "status": {
            "type": "string",
            "description": "Last OCPP status reported by the station. Cross-check isOnline for liveness.",
            "example": "AVAILABLE"
          },
          "locationId": {
            "type": [
              "null",
              "string"
            ],
            "description": "UUID of the assigned location/site, or null.",
            "format": "uuid",
            "example": "c1a2b3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"
          },
          "locationName": {
            "type": [
              "null",
              "string"
            ],
            "description": "Display name of the assigned location, or null.",
            "example": "Isla Verde Mall"
          },
          "isPublic": {
            "type": "boolean",
            "description": "True if the charger is publicly listed/usable.",
            "example": true
          },
          "maxPowerKw": {
            "type": [
              "null",
              "number"
            ],
            "description": "Rated maximum power of the charger, in kW. Falls back to the strongest connector's rating when the charger-level value is unset.",
            "format": "double",
            "example": 150
          },
          "connectorCount": {
            "type": "integer",
            "description": "Number of active (non-deleted) connectors on this charger.",
            "format": "int32",
            "example": 2
          },
          "lastHeartbeat": {
            "description": "UTC timestamp of the last OCPP heartbeat / StatusNotification.",
            "format": "date-time",
            "example": "2026-06-19T18:42:07Z"
          },
          "isOnline": {
            "type": "boolean",
            "description": "True only if a heartbeat arrived within the last 5 minutes.",
            "example": true
          },
          "lastUpdated": {
            "description": "UTC timestamp the charger record was last updated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:07Z"
          },
          "networkId": {
            "type": [
              "null",
              "string"
            ],
            "description": "UUID of the owning network (operator).",
            "format": "uuid",
            "example": "3f9a1c20-6b7d-4e8f-9a0b-1c2d3e4f5a6b"
          },
          "networkName": {
            "type": [
              "null",
              "string"
            ],
            "description": "Display name of the owning network.",
            "example": "Phevnix PR"
          },
          "serialNumber": {
            "type": [
              "null",
              "string"
            ],
            "description": "Manufacturer hardware serial number, if the station reported one.",
            "example": "SN-A1B2C3D4"
          },
          "manufacturer": {
            "type": [
              "null",
              "string"
            ],
            "description": "Charger manufacturer name, if known.",
            "example": "ABB"
          },
          "model": {
            "type": [
              "null",
              "string"
            ],
            "description": "Charger model name, if known.",
            "example": "Terra 184"
          },
          "firmwareVersion": {
            "type": [
              "null",
              "string"
            ],
            "description": "Firmware version last reported via OCPP BootNotification.",
            "example": "1.5.32"
          },
          "ocppVersion": {
            "type": [
              "null",
              "string"
            ],
            "description": "OCPP protocol the station negotiated (e.g. 1.6 or 2.0.1).",
            "example": "1.6"
          },
          "installationDate": {
            "description": "UTC date the charger was installed/commissioned, if recorded.",
            "format": "date-time",
            "example": "2025-09-01T00:00:00Z"
          },
          "floorLevel": {
            "type": [
              "null",
              "string"
            ],
            "description": "Floor/level the charger sits on (e.g. \"P1\"), if recorded.",
            "example": "P1"
          },
          "physicalReference": {
            "type": [
              "null",
              "string"
            ],
            "description": "Free-text physical reference printed at the bay (e.g. a stall number).",
            "example": "Bay 14"
          },
          "coordinates": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "description": "Geographic position of the charger, if it carries its own coordinates.",
                "$ref": "#/components/schemas/EmspChargersCoordinates"
              }
            ]
          },
          "connectors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspChargersConnectorSummary"
            },
            "description": "The charger's connectors, ordered by connector number."
          }
        }
      },
      "EmspChargersChargerInfo": {
        "type": "object",
        "properties": {
          "chargerUuid": {
            "type": "string",
            "description": "Stable charger UUID.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "chargerUid": {
            "type": "string",
            "description": "OCPP charge-point identity (chargePointId).",
            "example": "CP-IslaVerde-01"
          },
          "chargerName": {
            "type": [
              "null",
              "string"
            ],
            "description": "Display name for the charger (currently mirrors the Uid).",
            "example": "CP-IslaVerde-01"
          },
          "llmLookupId": {
            "type": [
              "null",
              "string"
            ],
            "description": "Short human code printed on the station (e.g. \"SHD54S\") — a driver references the charger by this, including by voice.",
            "example": "SHD54S"
          },
          "status": {
            "type": "string",
            "description": "Last OCPP status reported by the station.",
            "example": "AVAILABLE"
          },
          "isOnline": {
            "type": "boolean",
            "description": "True only if a heartbeat arrived within the last 5 minutes.",
            "example": true
          },
          "locationUuid": {
            "type": "string",
            "description": "UUID of the location/site this charger sits at.",
            "format": "uuid",
            "example": "c1a2b3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"
          },
          "locationName": {
            "type": "string",
            "description": "Display name of the location/site.",
            "example": "Isla Verde Mall"
          },
          "address": {
            "type": [
              "null",
              "string"
            ],
            "description": "Street address of the location.",
            "example": "8169 Calle Marginal"
          },
          "city": {
            "type": [
              "null",
              "string"
            ],
            "description": "City of the location.",
            "example": "Carolina"
          },
          "latitude": {
            "type": [
              "null",
              "number"
            ],
            "description": "Latitude of the location (or charger fallback), in decimal degrees.",
            "format": "double",
            "example": 18.4319
          },
          "longitude": {
            "type": [
              "null",
              "number"
            ],
            "description": "Longitude of the location (or charger fallback), in decimal degrees.",
            "format": "double",
            "example": -66.0617
          },
          "networkUuid": {
            "type": "string",
            "description": "UUID of the owning network (operator).",
            "format": "uuid",
            "example": "3f9a1c20-6b7d-4e8f-9a0b-1c2d3e4f5a6b"
          },
          "networkName": {
            "type": "string",
            "description": "Display name of the owning network.",
            "example": "Phevnix PR"
          },
          "networkLogoUrl": {
            "type": [
              "null",
              "string"
            ],
            "description": "URL of the network's logo, for white-label theming. Null if unset.",
            "example": "https://cdn.phevnix.com/networks/phevnix-pr/logo.svg"
          },
          "networkPrimaryColor": {
            "type": [
              "null",
              "string"
            ],
            "description": "Network primary brand color (hex, e.g. \"#0EA5E9\") for white-label UI. Null if unset.",
            "example": "#0EA5E9"
          },
          "networkSecondaryColor": {
            "type": [
              "null",
              "string"
            ],
            "description": "Network secondary brand color (hex). Null if unset.",
            "example": "#0F172A"
          },
          "currency": {
            "type": "string",
            "description": "ISO 4217 currency code the network prices in.",
            "example": "USD"
          },
          "connectors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspChargersConnectorPricing"
            },
            "description": "The charger's connectors with their applicable pricing."
          }
        }
      },
      "EmspChargersChargerSummary": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable charger UUID. Use it in GET /chargers/{id} and wherever a chargerId is required.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "uid": {
            "type": "string",
            "description": "OCPP charge-point identity — the chargePointId the physical station connects to the CSMS with.",
            "example": "CP-IslaVerde-01"
          },
          "evseId": {
            "type": [
              "null",
              "string"
            ],
            "description": "eMI3/OCPI EVSE identifier for this charger, if assigned (e.g. for roaming).",
            "example": "PR*PHX*E001234"
          },
          "status": {
            "type": "string",
            "description": "Last OCPP status reported by the station (AVAILABLE, CHARGING, FAULTED, UNAVAILABLE, …). Can read stale after a station drops offline — cross-check isOnline for liveness.",
            "example": "AVAILABLE"
          },
          "locationId": {
            "type": [
              "null",
              "string"
            ],
            "description": "UUID of the location/site this charger is assigned to, or null if unassigned.",
            "format": "uuid",
            "example": "c1a2b3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"
          },
          "locationName": {
            "type": [
              "null",
              "string"
            ],
            "description": "Display name of the assigned location, or null.",
            "example": "Isla Verde Mall"
          },
          "isPublic": {
            "type": "boolean",
            "description": "True if the charger is publicly listed/usable; false for private or restricted units.",
            "example": true
          },
          "maxPowerKw": {
            "type": [
              "null",
              "number"
            ],
            "description": "Rated maximum power of the charger, in kW.",
            "format": "double",
            "example": 150
          },
          "connectorCount": {
            "type": "integer",
            "description": "Number of active (non-deleted) connectors on this charger.",
            "format": "int32",
            "example": 2
          },
          "lastHeartbeat": {
            "description": "UTC timestamp of the last OCPP heartbeat / StatusNotification from the station.",
            "format": "date-time",
            "example": "2026-06-19T18:42:07Z"
          },
          "isOnline": {
            "type": "boolean",
            "description": "True only if a heartbeat arrived within the last 5 minutes. Treat !isOnline as unavailable regardless of the status field.",
            "example": true
          },
          "lastUpdated": {
            "description": "UTC timestamp the charger record was last updated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:07Z"
          },
          "networkId": {
            "type": [
              "null",
              "string"
            ],
            "description": "UUID of the network (operator) that owns this charger. Important for the hosted/aggregator eMSP, where a single key spans many networks.",
            "format": "uuid",
            "example": "3f9a1c20-6b7d-4e8f-9a0b-1c2d3e4f5a6b"
          },
          "networkName": {
            "type": [
              "null",
              "string"
            ],
            "description": "Display name of the owning network.",
            "example": "Phevnix PR"
          }
        }
      },
      "EmspChargersConnectorPricing": {
        "type": "object",
        "properties": {
          "connectorUuid": {
            "type": "string",
            "description": "Stable connector UUID.",
            "format": "uuid",
            "example": "9f1c2b30-4d5e-6a7b-8c9d-0e1f2a3b4c5d"
          },
          "connectorIdentifier": {
            "type": "string",
            "description": "Stable connector identifier string.",
            "example": "CP-IslaVerde-01-1"
          },
          "connectorNumber": {
            "type": "integer",
            "description": "Connector number on the charger (1-based).",
            "format": "int32",
            "example": 1
          },
          "standard": {
            "type": "string",
            "description": "Plug standard (e.g. IEC_62196_T2).",
            "example": "IEC_62196_T2"
          },
          "format": {
            "type": "string",
            "description": "Connector format: CABLE or SOCKET.",
            "example": "SOCKET"
          },
          "powerType": {
            "type": "string",
            "description": "Power delivery type (AC_1_PHASE, AC_3_PHASE, DC).",
            "example": "AC_3_PHASE"
          },
          "maxPowerKw": {
            "type": [
              "null",
              "number"
            ],
            "description": "Maximum power this connector can deliver, in kW.",
            "format": "double",
            "example": 22
          },
          "status": {
            "type": "string",
            "description": "Live connector status, or UNKNOWN if never reported.",
            "example": "AVAILABLE"
          },
          "tariffId": {
            "type": [
              "null",
              "string"
            ],
            "description": "OCPI id of the tariff applied to this connector (via the connector→charger→location→network hierarchy), or null if no tariff applies.",
            "example": "TARIFF-STD-AC"
          },
          "tariffName": {
            "type": [
              "null",
              "string"
            ],
            "description": "Display name of the applied tariff.",
            "example": "Standard AC"
          },
          "energyRate": {
            "type": [
              "null",
              "number"
            ],
            "description": "Per-kWh energy rate, in the network currency.",
            "format": "double",
            "example": 0.35
          },
          "timeRate": {
            "type": [
              "null",
              "number"
            ],
            "description": "Per-minute time rate, in the network currency.",
            "format": "double",
            "example": 0
          },
          "sessionFee": {
            "type": [
              "null",
              "number"
            ],
            "description": "Flat per-session fee, in the network currency.",
            "format": "double",
            "example": 0.5
          },
          "idleRate": {
            "type": [
              "null",
              "number"
            ],
            "description": "Per-minute idle fee charged after the grace period, in the network currency.",
            "format": "double",
            "example": 0.4
          },
          "idleFeeEnabled": {
            "type": "boolean",
            "description": "True if idle fees apply for this connector's tariff.",
            "example": true
          },
          "idleGracePeriodMinutes": {
            "type": [
              "null",
              "integer"
            ],
            "description": "Minutes of idle time allowed before idle fees begin.",
            "format": "int32",
            "example": 10
          }
        }
      },
      "EmspChargersConnectorSummary": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable connector UUID. Use it in GET /connectors/{id}/status.",
            "format": "uuid",
            "example": "9f1c2b30-4d5e-6a7b-8c9d-0e1f2a3b4c5d"
          },
          "connectorNumber": {
            "type": "integer",
            "description": "Connector number on the charger (1-based).",
            "format": "int32",
            "example": 1
          },
          "connectorIdentifier": {
            "type": "string",
            "description": "Stable connector identifier string (e.g. the OCPI connector id).",
            "example": "CP-IslaVerde-01-1"
          },
          "status": {
            "type": "string",
            "description": "Live connector status (AVAILABLE, CHARGING, PREPARING, FINISHING, FAULTED, …) or UNKNOWN if never reported. Reads CHARGING when an active session occupies an otherwise-AVAILABLE connector.",
            "example": "AVAILABLE"
          },
          "standard": {
            "type": "string",
            "description": "Plug standard (e.g. IEC_62196_T2, CHADEMO, IEC_62196_T1_COMBO).",
            "example": "IEC_62196_T2"
          },
          "format": {
            "type": "string",
            "description": "Connector format: CABLE (tethered) or SOCKET (untethered).",
            "example": "SOCKET"
          },
          "powerType": {
            "type": "string",
            "description": "Power delivery type (AC_1_PHASE, AC_3_PHASE, DC).",
            "example": "AC_3_PHASE"
          },
          "maxVoltage": {
            "type": "integer",
            "description": "Maximum voltage the connector supports, in volts.",
            "format": "int32",
            "example": 400
          },
          "maxAmperage": {
            "type": "integer",
            "description": "Maximum current the connector supports, in amperes.",
            "format": "int32",
            "example": 32
          },
          "maxElectricPowerWatts": {
            "type": [
              "null",
              "integer"
            ],
            "description": "Maximum power this connector can deliver, in watts.",
            "format": "int32",
            "example": 22000
          },
          "lastUpdated": {
            "description": "UTC timestamp the connector record was last updated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:07Z"
          }
        }
      },
      "EmspChargersCoordinates": {
        "type": "object",
        "properties": {
          "latitude": {
            "type": "number",
            "description": "Latitude in decimal degrees (WGS84).",
            "format": "double",
            "example": 18.4319
          },
          "longitude": {
            "type": "number",
            "description": "Longitude in decimal degrees (WGS84).",
            "format": "double",
            "example": -66.0617
          }
        }
      },
      "EmspChargersDetailResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspChargersChargerDetail"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspChargersErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. not_found, forbidden, bad_request).",
            "example": "not_found"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Charger with identifier '4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b' was not found."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent/MCP tool branches on (e.g. RESOURCE_NOT_FOUND).",
            "example": "RESOURCE_NOT_FOUND"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "details": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "description": "Optional field-level validation details, keyed by field name."
          }
        }
      },
      "EmspChargersInfoResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspChargersChargerInfo"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspChargersListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspChargersChargerSummary"
            },
            "description": "The page of chargers."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "pagination": {
            "$ref": "#/components/schemas/EmspChargersPagination"
          }
        }
      },
      "EmspChargersPagination": {
        "type": "object",
        "properties": {
          "totalCount": {
            "type": "integer",
            "description": "Total number of items across all pages.",
            "format": "int32",
            "example": 137
          },
          "page": {
            "type": "integer",
            "description": "1-based page index of this result set.",
            "format": "int32",
            "example": 1
          },
          "pageSize": {
            "type": "integer",
            "description": "Items requested per page (1–100; defaults to 20).",
            "format": "int32",
            "example": 20
          },
          "totalPages": {
            "type": "integer",
            "description": "Total number of pages at the current pageSize.",
            "format": "int32",
            "example": 7
          },
          "hasNextPage": {
            "type": "boolean",
            "description": "True if there is a page after this one.",
            "example": true
          },
          "hasPreviousPage": {
            "type": "boolean",
            "description": "True if there is a page before this one.",
            "example": false
          }
        }
      },
      "EmspChargersRebootResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspChargersRebootResult"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspChargersRebootResult": {
        "type": "object",
        "properties": {
          "chargerId": {
            "type": "string",
            "description": "UUID of the charger the reset command was sent to.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "status": {
            "type": "string",
            "description": "Command acknowledgement status, e.g. \"Accepted\".",
            "example": "Accepted"
          },
          "message": {
            "type": "string",
            "description": "Human-readable confirmation of the command result.",
            "example": "Soft reset command sent successfully"
          }
        }
      },
      "EmspChargingErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error code (e.g. forbidden, bad_request, not_found, payment_method_required, payment_failed).",
            "example": "payment_method_required"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Add a payment method before starting a session on this network."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent can branch on (defaults to the `error` slug).",
            "example": "payment_method_required"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspChargingStartResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "The start-command result. While the charger has not yet confirmed, sessionId is null and status is PENDING — resolve the real session id by polling the sessions list with the returned correlationId/chargerId.",
            "$ref": "#/components/schemas/StartSessionResponse"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspChargingStopResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "The session as it stands the instant the stop command was accepted (status STOPPING). Final energy/cost arrive asynchronously from the charger's StopTransaction — re-fetch the session for the settled values.",
            "$ref": "#/components/schemas/PublicApiSessionDetailDto"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspConnectorsConnectorStatus": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable connector UUID.",
            "format": "uuid",
            "example": "9f1c2b30-4d5e-6a7b-8c9d-0e1f2a3b4c5d"
          },
          "connectorNumber": {
            "type": "integer",
            "description": "Connector number on the charger (1-based).",
            "format": "int32",
            "example": 1
          },
          "connectorIdentifier": {
            "type": "string",
            "description": "Stable connector identifier string (e.g. the OCPI connector id).",
            "example": "CP-IslaVerde-01-1"
          },
          "status": {
            "type": "string",
            "description": "Live connector status (AVAILABLE, CHARGING, PREPARING, FINISHING, FAULTED, …) or UNKNOWN if never reported.",
            "example": "AVAILABLE"
          },
          "standard": {
            "type": "string",
            "description": "Plug standard (e.g. IEC_62196_T2, CHADEMO, IEC_62196_T1_COMBO).",
            "example": "IEC_62196_T2"
          },
          "format": {
            "type": "string",
            "description": "Connector format: CABLE (tethered) or SOCKET (untethered).",
            "example": "SOCKET"
          },
          "powerType": {
            "type": "string",
            "description": "Power delivery type (AC_1_PHASE, AC_3_PHASE, DC).",
            "example": "AC_3_PHASE"
          },
          "maxVoltage": {
            "type": "integer",
            "description": "Maximum voltage the connector supports, in volts.",
            "format": "int32",
            "example": 400
          },
          "maxAmperage": {
            "type": "integer",
            "description": "Maximum current the connector supports, in amperes.",
            "format": "int32",
            "example": 32
          },
          "maxElectricPowerWatts": {
            "type": [
              "null",
              "integer"
            ],
            "description": "Maximum power this connector can deliver, in watts.",
            "format": "int32",
            "example": 22000
          },
          "lastUpdated": {
            "description": "UTC timestamp the connector record was last updated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:07Z"
          },
          "chargerId": {
            "type": "string",
            "description": "UUID of the charger this connector belongs to.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "chargerUid": {
            "type": "string",
            "description": "OCPP charge-point identity of the owning charger (chargePointId).",
            "example": "CP-IslaVerde-01"
          },
          "locationId": {
            "type": [
              "null",
              "string"
            ],
            "description": "UUID of the location/site the charger is assigned to, or null.",
            "format": "uuid",
            "example": "c1a2b3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"
          },
          "locationName": {
            "type": [
              "null",
              "string"
            ],
            "description": "Display name of the assigned location, or null.",
            "example": "Isla Verde Mall"
          },
          "lastStatusUpdate": {
            "description": "UTC timestamp of the last OCPP StatusNotification for this connector.",
            "format": "date-time",
            "example": "2026-06-19T18:41:55Z"
          },
          "hasRfidReader": {
            "type": "boolean",
            "description": "True if the connector has an RFID reader.",
            "example": true
          },
          "hasDisplay": {
            "type": "boolean",
            "description": "True if the connector has a display.",
            "example": false
          }
        }
      },
      "EmspConnectorsErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. not_found, forbidden).",
            "example": "not_found"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Connector with identifier '9f1c2b30-4d5e-6a7b-8c9d-0e1f2a3b4c5d' was not found."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent/MCP tool branches on (e.g. RESOURCE_NOT_FOUND).",
            "example": "RESOURCE_NOT_FOUND"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "details": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "description": "Optional field-level validation details, keyed by field name."
          }
        }
      },
      "EmspConnectorsStatusResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspConnectorsConnectorStatus"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspDriverAuthDriverSummary": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable driver (user) UUID — the sub the token is bound to.",
            "format": "uuid",
            "example": "1ae38f39-2c4b-4d5e-9f10-3a4b5c6d7e8f"
          },
          "email": {
            "type": "string",
            "description": "Driver's email address.",
            "example": "maya@example.com"
          },
          "firstName": {
            "type": "string",
            "description": "Driver's first name.",
            "example": "Maya"
          },
          "lastName": {
            "type": "string",
            "description": "Driver's last name.",
            "example": "Rivera"
          },
          "tokenUid": {
            "type": [
              "null",
              "string"
            ],
            "description": "UID of the charging token auto-provisioned for the driver, or null if none was issued.",
            "example": "A1B2C3D4E5F6"
          }
        }
      },
      "EmspDriverAuthErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. unauthorized, rate_limited, bad_request, not_found).",
            "example": "unauthorized"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Invalid email or password."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent can branch on (defaults to the error slug).",
            "example": "unauthorized"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "details": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "description": "Optional field-level validation details, keyed by field name."
          }
        }
      },
      "EmspDriverAuthMeModel": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable driver (user) UUID.",
            "format": "uuid",
            "example": "1ae38f39-2c4b-4d5e-9f10-3a4b5c6d7e8f"
          },
          "Email": {
            "type": "string",
            "description": "Driver's email address.",
            "example": "maya@example.com"
          },
          "FirstName": {
            "type": "string",
            "description": "Driver's first name.",
            "example": "Maya"
          },
          "LastName": {
            "type": "string",
            "description": "Driver's last name.",
            "example": "Rivera"
          },
          "PhoneNumber": {
            "type": "string",
            "description": "Driver's phone number.",
            "example": "+17875551234"
          },
          "Address": {
            "type": [
              "null",
              "string"
            ],
            "description": "Street address, or null.",
            "example": "123 Calle Sol"
          },
          "City": {
            "type": [
              "null",
              "string"
            ],
            "description": "City, or null.",
            "example": "San Juan"
          },
          "State": {
            "type": [
              "null",
              "string"
            ],
            "description": "State/region, or null.",
            "example": "PR"
          },
          "PostalCode": {
            "type": [
              "null",
              "string"
            ],
            "description": "Postal code, or null.",
            "example": "00901"
          },
          "Country": {
            "type": [
              "null",
              "string"
            ],
            "description": "Country, or null.",
            "example": "US"
          },
          "CreatedAt": {
            "description": "UTC timestamp when the driver account was created.",
            "format": "date-time",
            "example": "2026-01-15T09:30:00Z"
          },
          "tokens": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspDriverAuthMeToken"
            },
            "description": "The driver's currently valid charging tokens."
          }
        }
      },
      "EmspDriverAuthMeResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "The authenticated driver's profile.",
            "$ref": "#/components/schemas/EmspDriverAuthMeModel"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspDriverAuthMeToken": {
        "type": "object",
        "properties": {
          "TokenUuid": {
            "type": "string",
            "description": "Stable token UUID.",
            "format": "uuid",
            "example": "7c1e2a44-9b3d-4e6f-8a01-2b3c4d5e6f70"
          },
          "Uid": {
            "type": "string",
            "description": "Token UID — the credential a charger reads.",
            "example": "A1B2C3D4E5F6"
          },
          "TokenType": {
            "type": "string",
            "description": "Token category: RFID, APP_USER, AD_HOC_USER, or OTHER.",
            "example": "APP_USER"
          }
        }
      },
      "EmspDriverAuthMessageModel": {
        "type": "object",
        "properties": {
          "message": {
            "type": "string",
            "description": "Human-readable outcome message. For forgot-password it is deliberately generic to prevent email enumeration.",
            "example": "If the email exists, a password reset link has been sent."
          }
        }
      },
      "EmspDriverAuthMessageResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "The outcome message.",
            "$ref": "#/components/schemas/EmspDriverAuthMessageModel"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspDriverAuthRefreshModel": {
        "type": "object",
        "properties": {
          "accessToken": {
            "type": "string",
            "description": "A freshly issued short-lived bearer access token (JWT).",
            "example": "eyJ...<access-token>..."
          },
          "refreshToken": {
            "type": [
              "null",
              "string"
            ],
            "description": "The rotated refresh token, or the same token on a benign within-grace duplicate refresh.",
            "example": "<refresh-token>"
          },
          "expiresIn": {
            "type": "integer",
            "description": "Lifetime of the new access token, in seconds.",
            "format": "int32",
            "example": 3600
          },
          "tokenType": {
            "type": "string",
            "description": "Authorization scheme for the access token — always \"Bearer\".",
            "example": "Bearer"
          }
        }
      },
      "EmspDriverAuthRefreshResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "The refreshed tokens.",
            "$ref": "#/components/schemas/EmspDriverAuthRefreshModel"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspDriverAuthResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "Tokens and driver summary.",
            "$ref": "#/components/schemas/EmspDriverAuthResultModel"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspDriverAuthResultModel": {
        "type": "object",
        "properties": {
          "accessToken": {
            "type": "string",
            "description": "Short-lived bearer access token (JWT). Send it as `Authorization: Bearer <token>` on driver-scoped requests.",
            "example": "eyJ...<access-token>..."
          },
          "refreshToken": {
            "type": [
              "null",
              "string"
            ],
            "description": "Long-lived refresh token. Exchange it at /auth/driver/refresh for a new access token. Store it securely; treat it as a credential.",
            "example": "<refresh-token>"
          },
          "expiresIn": {
            "type": "integer",
            "description": "Lifetime of the access token, in seconds.",
            "format": "int32",
            "example": 3600
          },
          "tokenType": {
            "type": "string",
            "description": "Authorization scheme for the access token — always \"Bearer\".",
            "example": "Bearer"
          },
          "driver": {
            "description": "The authenticated driver's summary.",
            "$ref": "#/components/schemas/EmspDriverAuthDriverSummary"
          }
        }
      },
      "EmspEventStreamErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (unauthorized, events_not_available).",
            "example": "events_not_available"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Real-time event streaming is not available for this key type. Driver-scoped streaming is coming to the eMSP API."
          }
        }
      },
      "EmspFavoritesErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. driver_required, forbidden, not_found, bad_request).",
            "example": "driver_required"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Favorites require driver authentication. Log in via /api/emsp/v1/auth/driver/login."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent can branch on (defaults to the error slug).",
            "example": "driver_required"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "details": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "description": "Optional field-level validation details, keyed by field name."
          }
        }
      },
      "EmspFavoritesFavoriteListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspFavoritesFavoriteModel"
            },
            "description": "The driver's favorites, newest first."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspFavoritesFavoriteModel": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable favorite UUID. Use it in DELETE /favorites/{id}.",
            "format": "uuid",
            "example": "5d4c3b2a-1f0e-4d9c-8b7a-6e5f4d3c2b1a"
          },
          "targetType": {
            "type": "string",
            "description": "What was favorited: \"location\" or \"charger\".",
            "example": "location"
          },
          "targetId": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable UUID of the favorited location or charger. May be null if the target could not be resolved.",
            "format": "uuid",
            "example": "9f1c2b30-4d5e-6a7b-8c9d-0e1f2a3b4c5d"
          },
          "label": {
            "type": [
              "null",
              "string"
            ],
            "description": "Friendly label — the caller-supplied label, falling back to the target's name. May be null.",
            "example": "Home charger"
          },
          "createdAt": {
            "description": "UTC timestamp when the favorite was saved.",
            "format": "date-time",
            "example": "2026-06-18T14:05:33Z"
          }
        }
      },
      "EmspFavoritesFavoriteResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "The saved favorite.",
            "$ref": "#/components/schemas/EmspFavoritesFavoriteModel"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspLocationsCharger": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable charger UUID.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "serialNumber": {
            "type": [
              "null",
              "string"
            ],
            "description": "Manufacturer hardware serial number, if reported.",
            "example": "SN-A1B2C3D4"
          },
          "status": {
            "type": "string",
            "description": "Last OCPP status reported by the charger.",
            "example": "AVAILABLE"
          },
          "lastHeartbeat": {
            "description": "UTC timestamp of the last heartbeat.",
            "format": "date-time",
            "example": "2026-06-19T18:42:07Z"
          },
          "isOnline": {
            "type": "boolean",
            "description": "True only if a heartbeat arrived within the last 5 minutes.",
            "example": true
          },
          "connectorCount": {
            "type": "integer",
            "description": "Number of active connectors on this charger.",
            "format": "int32",
            "example": 2
          }
        }
      },
      "EmspLocationsChargersResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspLocationsCharger"
            },
            "description": "The chargers at this location."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspLocationsDetailResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspLocationsLocationDetail"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspLocationsErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. not_found, forbidden, bad_request, driver_required).",
            "example": "not_found"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Location with identifier 'c1a2b3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d' was not found."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent/MCP tool branches on.",
            "example": "RESOURCE_NOT_FOUND"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "details": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "description": "Optional field-level validation details, keyed by field name."
          }
        }
      },
      "EmspLocationsImage": {
        "type": "object",
        "properties": {
          "url": {
            "type": [
              "null",
              "string"
            ],
            "description": "Full-size image URL.",
            "example": "https://cdn.phevnix.com/locations/isla-verde/1.jpg"
          },
          "thumbnailUrl": {
            "type": [
              "null",
              "string"
            ],
            "description": "Thumbnail image URL.",
            "example": "https://cdn.phevnix.com/locations/isla-verde/1_thumb.jpg"
          },
          "type": {
            "type": [
              "null",
              "string"
            ],
            "description": "Image category/type (OCPI image category).",
            "example": "location"
          },
          "width": {
            "type": "integer",
            "description": "Image width in pixels.",
            "format": "int32",
            "example": 1280
          },
          "height": {
            "type": "integer",
            "description": "Image height in pixels.",
            "format": "int32",
            "example": 720
          }
        }
      },
      "EmspLocationsIssueReceipt": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable UUID of the operator alert raised from this report.",
            "format": "uuid",
            "example": "a1b2c3d4-e5f6-7a8b-9c0d-1e2f3a4b5c6d"
          },
          "status": {
            "type": "string",
            "description": "Receipt status — always \"received\".",
            "example": "received"
          }
        }
      },
      "EmspLocationsIssueReceiptResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspLocationsIssueReceipt"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspLocationsListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspLocationsLocationSummary"
            },
            "description": "The locations (with charger counts and, for /search, distanceKm)."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspLocationsLocationDetail": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable location UUID.",
            "format": "uuid",
            "example": "c1a2b3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"
          },
          "name": {
            "type": "string",
            "description": "Display name of the location/site.",
            "example": "Isla Verde Mall"
          },
          "address": {
            "type": [
              "null",
              "string"
            ],
            "description": "Street address of the location.",
            "example": "8169 Calle Marginal"
          },
          "city": {
            "type": [
              "null",
              "string"
            ],
            "description": "City the location is in.",
            "example": "Carolina"
          },
          "state": {
            "type": [
              "null",
              "string"
            ],
            "description": "State / region the location is in.",
            "example": "PR"
          },
          "country": {
            "type": [
              "null",
              "string"
            ],
            "description": "ISO country code of the location.",
            "example": "US"
          },
          "latitude": {
            "type": [
              "null",
              "number"
            ],
            "description": "Latitude in decimal degrees (WGS84).",
            "format": "double",
            "example": 18.4319
          },
          "longitude": {
            "type": [
              "null",
              "number"
            ],
            "description": "Longitude in decimal degrees (WGS84).",
            "format": "double",
            "example": -66.0617
          },
          "hasParking": {
            "type": "boolean",
            "description": "True if the site offers parking.",
            "example": true
          },
          "hasRestrooms": {
            "type": "boolean",
            "description": "True if the site offers restrooms.",
            "example": true
          },
          "hasWifi": {
            "type": "boolean",
            "description": "True if the site offers WiFi.",
            "example": false
          },
          "phone": {
            "type": [
              "null",
              "string"
            ],
            "description": "Site contact phone number, or null.",
            "example": "+1-787-555-0142"
          },
          "openingHours": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "description": "The location's opening hours. Present only when the location has opening times configured.",
                "$ref": "#/components/schemas/EmspLocationsOpeningHours"
              }
            ]
          },
          "images": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspLocationsImage"
            },
            "description": "Images attached to the location."
          },
          "chargerCount": {
            "type": "integer",
            "description": "Total number of active chargers at this location.",
            "format": "int32",
            "example": 4
          },
          "availableCount": {
            "type": "integer",
            "description": "Number of chargers that are AVAILABLE and online right now.",
            "format": "int32",
            "example": 3
          },
          "ratingAverage": {
            "type": "object",
            "anyOf": [
              {
                "type": "number"
              },
              {
                "enum": [
                  "NaN",
                  "Infinity",
                  "-Infinity"
                ]
              }
            ],
            "description": "Average driver star rating (1–5), rounded to one decimal, or null if there are no reviews.",
            "format": "double",
            "example": 4.6
          },
          "ratingCount": {
            "type": "integer",
            "description": "Number of driver reviews for this location.",
            "format": "int32",
            "example": 28
          }
        }
      },
      "EmspLocationsLocationSummary": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable location UUID. Use it in GET /locations/{id}.",
            "format": "uuid",
            "example": "c1a2b3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d"
          },
          "name": {
            "type": "string",
            "description": "Display name of the location/site.",
            "example": "Isla Verde Mall"
          },
          "address": {
            "type": [
              "null",
              "string"
            ],
            "description": "Street address of the location.",
            "example": "8169 Calle Marginal"
          },
          "city": {
            "type": [
              "null",
              "string"
            ],
            "description": "City the location is in.",
            "example": "Carolina"
          },
          "state": {
            "type": [
              "null",
              "string"
            ],
            "description": "State / region the location is in.",
            "example": "PR"
          },
          "country": {
            "type": [
              "null",
              "string"
            ],
            "description": "ISO country code of the location.",
            "example": "US"
          },
          "latitude": {
            "type": [
              "null",
              "number"
            ],
            "description": "Latitude in decimal degrees (WGS84).",
            "format": "double",
            "example": 18.4319
          },
          "longitude": {
            "type": [
              "null",
              "number"
            ],
            "description": "Longitude in decimal degrees (WGS84).",
            "format": "double",
            "example": -66.0617
          },
          "hasParking": {
            "type": "boolean",
            "description": "True if the site offers parking.",
            "example": true
          },
          "hasRestrooms": {
            "type": "boolean",
            "description": "True if the site offers restrooms.",
            "example": true
          },
          "hasWifi": {
            "type": "boolean",
            "description": "True if the site offers WiFi.",
            "example": false
          },
          "phone": {
            "type": [
              "null",
              "string"
            ],
            "description": "Site contact phone number, or null if not published.",
            "example": "+1-787-555-0142"
          },
          "chargerCount": {
            "type": "integer",
            "description": "Total number of active (non-deleted) chargers at this location.",
            "format": "int32",
            "example": 4
          },
          "availableCount": {
            "type": "integer",
            "description": "Number of chargers that are both AVAILABLE and online (recent heartbeat) right now — powers the green/amber/red map pin.",
            "format": "int32",
            "example": 3
          },
          "maxPowerKw": {
            "type": [
              "null",
              "number"
            ],
            "description": "Highest charger power rating at this location, in kW.",
            "format": "double",
            "example": 150
          },
          "connectorTypes": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Distinct connector standards available at this location — powers connector-type filters."
          },
          "distanceKm": {
            "type": "object",
            "anyOf": [
              {
                "type": "number"
              },
              {
                "enum": [
                  "NaN",
                  "Infinity",
                  "-Infinity"
                ]
              }
            ],
            "description": "Distance from the search point, in kilometres. Present ONLY on geo-search (/locations/search) results.",
            "format": "double",
            "example": 2.137
          }
        }
      },
      "EmspLocationsOpeningHours": {
        "type": "object",
        "properties": {
          "twentyFourSeven": {
            "type": "boolean",
            "description": "True if the location is open 24/7 (the regular schedule is then ignored).",
            "example": false
          },
          "regular": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspLocationsRegularHours"
            },
            "description": "Weekly opening windows, ordered by weekday."
          }
        }
      },
      "EmspLocationsRegularHours": {
        "type": "object",
        "properties": {
          "weekday": {
            "type": "integer",
            "description": "Day of week, 1 = Monday … 7 = Sunday (OCPI convention).",
            "format": "int32",
            "example": 1
          },
          "open": {
            "type": [
              "null",
              "string"
            ],
            "description": "Opening time, HH:mm (24h).",
            "example": "08:00"
          },
          "close": {
            "type": [
              "null",
              "string"
            ],
            "description": "Closing time, HH:mm (24h).",
            "example": "22:00"
          }
        }
      },
      "EmspLocationsReview": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable review UUID.",
            "format": "uuid",
            "example": "7e6d5c4b-3a2b-1c0d-9e8f-7a6b5c4d3e2f"
          },
          "rating": {
            "type": "integer",
            "description": "Star rating, 1–5.",
            "format": "int32",
            "example": 5
          },
          "comment": {
            "type": [
              "null",
              "string"
            ],
            "description": "Free-text review comment, or null.",
            "example": "Fast chargers, easy to find."
          },
          "authorName": {
            "type": [
              "null",
              "string"
            ],
            "description": "Reviewer's first name, or \"Driver\" when unavailable.",
            "example": "Maya"
          },
          "isMine": {
            "type": "boolean",
            "description": "True if this review belongs to the currently authenticated driver.",
            "example": false
          },
          "createdAt": {
            "description": "UTC time the review was created.",
            "format": "date-time",
            "example": "2026-05-02T14:10:00Z"
          },
          "updatedAt": {
            "description": "UTC time the review was last updated.",
            "format": "date-time",
            "example": "2026-05-02T14:10:00Z"
          }
        }
      },
      "EmspLocationsReviewResult": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable review UUID.",
            "format": "uuid",
            "example": "7e6d5c4b-3a2b-1c0d-9e8f-7a6b5c4d3e2f"
          },
          "rating": {
            "type": "integer",
            "description": "Star rating, 1–5.",
            "format": "int32",
            "example": 5
          },
          "comment": {
            "type": [
              "null",
              "string"
            ],
            "description": "Free-text review comment, or null.",
            "example": "Fast chargers, easy to find."
          },
          "createdAt": {
            "description": "UTC time the review was created.",
            "format": "date-time",
            "example": "2026-05-02T14:10:00Z"
          },
          "updatedAt": {
            "description": "UTC time the review was last updated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspLocationsReviewResultResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspLocationsReviewResult"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspLocationsReviewSummary": {
        "type": "object",
        "properties": {
          "average": {
            "type": "object",
            "anyOf": [
              {
                "type": "number"
              },
              {
                "enum": [
                  "NaN",
                  "Infinity",
                  "-Infinity"
                ]
              }
            ],
            "description": "Average star rating (1–5), rounded to one decimal; 0 when there are no reviews.",
            "format": "double",
            "example": 4.6
          },
          "count": {
            "type": "integer",
            "description": "Number of reviews.",
            "format": "int32",
            "example": 28
          }
        }
      },
      "EmspLocationsReviews": {
        "type": "object",
        "properties": {
          "summary": {
            "description": "Aggregate rating summary.",
            "$ref": "#/components/schemas/EmspLocationsReviewSummary"
          },
          "reviews": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspLocationsReview"
            },
            "description": "Up to 50 most-recent reviews."
          }
        }
      },
      "EmspLocationsReviewsResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspLocationsReviews"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspNetworkBranding": {
        "type": "object",
        "properties": {
          "networkId": {
            "type": "string",
            "description": "UUID of the network the branding belongs to (echoes the path parameter).",
            "format": "uuid",
            "example": "3f9a1c20-6b7d-4e8f-9a0b-1c2d3e4f5a6b"
          },
          "name": {
            "type": "string",
            "description": "Public display name of the network (operator).",
            "example": "Phevnix PR"
          },
          "logoUrl": {
            "type": [
              "null",
              "string"
            ],
            "description": "URL of the network's logo, or null if unset.",
            "example": "https://cdn.phevnix.com/networks/phevnix-pr/logo.svg"
          },
          "faviconUrl": {
            "type": [
              "null",
              "string"
            ],
            "description": "URL of the network's favicon, or null if unset.",
            "example": "https://cdn.phevnix.com/networks/phevnix-pr/favicon.ico"
          },
          "logoBackground": {
            "type": "string",
            "description": "Recommended background tone for the logo — always either \"light\" or \"dark\".",
            "example": "light"
          },
          "primaryColor": {
            "type": [
              "null",
              "string"
            ],
            "description": "Primary brand color (hex, e.g. \"#0EA5E9\"), or null if unset.",
            "example": "#0EA5E9"
          },
          "secondaryColor": {
            "type": [
              "null",
              "string"
            ],
            "description": "Secondary brand color (hex), or null if unset.",
            "example": "#0F172A"
          },
          "termsUrl": {
            "type": [
              "null",
              "string"
            ],
            "description": "URL of the network's Terms of Service, or null if unset.",
            "example": "https://phevnix.com/terms"
          },
          "privacyUrl": {
            "type": [
              "null",
              "string"
            ],
            "description": "URL of the network's Privacy Policy, or null if unset.",
            "example": "https://phevnix.com/privacy"
          }
        }
      },
      "EmspNetworkBrandingErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. not_found).",
            "example": "not_found"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "network with identifier '3f9a1c20-6b7d-4e8f-9a0b-1c2d3e4f5a6b' was not found."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent/MCP tool branches on.",
            "example": "RESOURCE_NOT_FOUND"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "details": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "description": "Optional field-level validation details, keyed by field name."
          }
        }
      },
      "EmspNetworkBrandingResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspNetworkBranding"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspNotificationsChannels": {
        "type": "object",
        "properties": {
          "push": {
            "type": "boolean",
            "description": "Whether web/app push notifications are enabled.",
            "example": true
          },
          "email": {
            "type": "boolean",
            "description": "Whether email notifications are enabled.",
            "example": true
          },
          "sms": {
            "type": "boolean",
            "description": "Whether SMS notifications are enabled.",
            "example": false
          }
        }
      },
      "EmspNotificationsContact": {
        "type": "object",
        "properties": {
          "email": {
            "type": [
              "null",
              "string"
            ],
            "description": "Email address notifications are sent to, or null to use the driver's account email.",
            "example": "driver@example.com"
          },
          "phoneNumber": {
            "type": [
              "null",
              "string"
            ],
            "description": "Phone number SMS notifications are sent to (E.164), or null.",
            "example": "+17875551234"
          }
        }
      },
      "EmspNotificationsErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (driver_required, forbidden, not_found).",
            "example": "driver_required"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Notification preferences require driver authentication. Log in via /api/emsp/v1/auth/driver/login."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code (defaults to the error slug when not set explicitly).",
            "example": "driver_required"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspNotificationsEvents": {
        "type": "object",
        "properties": {
          "sessionStarted": {
            "type": "boolean",
            "description": "Notify when a charging session starts.",
            "example": true
          },
          "sessionStopped": {
            "type": "boolean",
            "description": "Notify when a charging session stops.",
            "example": true
          },
          "sessionFailed": {
            "type": "boolean",
            "description": "Notify when a charging session fails to start or is interrupted.",
            "example": true
          },
          "reservationReminder": {
            "type": "boolean",
            "description": "Notify ahead of an upcoming reservation.",
            "example": true
          },
          "payment": {
            "type": "boolean",
            "description": "Notify on payment events (charge captured, payment failed).",
            "example": true
          }
        }
      },
      "EmspNotificationsPreferences": {
        "type": "object",
        "properties": {
          "channels": {
            "description": "Enabled delivery channels.",
            "$ref": "#/components/schemas/EmspNotificationsChannels"
          },
          "events": {
            "description": "Per-event-category opt-ins.",
            "$ref": "#/components/schemas/EmspNotificationsEvents"
          },
          "contact": {
            "description": "Contact details notifications are delivered to.",
            "$ref": "#/components/schemas/EmspNotificationsContact"
          },
          "updatedAt": {
            "description": "UTC time the preferences were last updated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspNotificationsPreferencesResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspNotificationsPreferences"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspPaymentsCard": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stripe PaymentMethod id for the saved card. Use it in /methods/{id}/default and DELETE /methods/{id}.",
            "example": "pm_1AbCdEfGhIjKlMnOpQrStUvW"
          },
          "brand": {
            "type": "string",
            "description": "Card brand (visa, mastercard, amex, …).",
            "example": "visa"
          },
          "last4": {
            "type": "string",
            "description": "Last four digits of the card number.",
            "example": "4242"
          },
          "expMonth": {
            "type": "integer",
            "description": "Card expiry month (1–12).",
            "format": "int64",
            "example": 12
          },
          "expYear": {
            "type": "integer",
            "description": "Card expiry year (four digits).",
            "format": "int64",
            "example": 2029
          },
          "isDefault": {
            "type": "boolean",
            "description": "True if this is the driver's default card for charges on the network.",
            "example": true
          }
        }
      },
      "EmspPaymentsCheckoutResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspPaymentsCheckoutStatus"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspPaymentsCheckoutStatus": {
        "type": "object",
        "properties": {
          "paymentMode": {
            "type": "string",
            "description": "Always 'phevnix_managed' here.",
            "example": "phevnix_managed"
          },
          "sessionId": {
            "type": "string",
            "description": "The charging session UUID this status is for.",
            "format": "uuid",
            "example": "7c6f5e40-1a2b-3c4d-5e6f-7a8b9c0d1e2f"
          },
          "sessionStatus": {
            "type": [
              "null",
              "string"
            ],
            "description": "Current session status (active, completed, …).",
            "example": "completed"
          },
          "paymentStatus": {
            "type": [
              "null",
              "string"
            ],
            "description": "Payment lifecycle: null (no charge yet / free), authorized (pre-auth hold), captured, failed, refunded.",
            "example": "captured"
          },
          "isFree": {
            "type": "boolean",
            "description": "True if the session is free (no charge applies).",
            "example": false
          },
          "total": {
            "type": [
              "null",
              "number"
            ],
            "description": "The session's total amount in the network currency.",
            "format": "double",
            "example": 8.45
          },
          "currency": {
            "type": [
              "null",
              "string"
            ],
            "description": "ISO-4217 currency code for the total.",
            "example": "USD"
          },
          "captured": {
            "type": "boolean",
            "description": "True when the final amount has already been captured (paymentStatus == 'captured').",
            "example": true
          },
          "note": {
            "type": "string",
            "description": "Guidance: capture happens automatically at session stop; no manual checkout is needed.",
            "example": "Capture happens automatically when the session stops; no manual checkout is needed for managed networks. A pre-authorization hold is placed at session start and the final amount is captured on stop."
          }
        }
      },
      "EmspPaymentsConfigResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "Payment configuration for the resolved network. Shape varies by paymentMode (self_managed vs phevnix_managed).",
            "$ref": "#/components/schemas/EmspPaymentsManagedConfig"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspPaymentsErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. driver_required, payments_not_enabled, stripe_error).",
            "example": "payments_not_enabled"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Payments are not enabled for this network."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code (defaults to the error slug when not set explicitly).",
            "example": "payments_not_enabled"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspPaymentsManagedConfig": {
        "type": "object",
        "properties": {
          "paymentMode": {
            "type": "string",
            "description": "Always 'phevnix_managed' here — the operator opted into Phevnix billing rails.",
            "example": "phevnix_managed"
          },
          "phevnixBillingAvailable": {
            "type": "boolean",
            "description": "True only when the network's payment settings are configured and enabled.",
            "example": true
          },
          "provider": {
            "type": "string",
            "description": "Payment provider in use; 'stripe' unless a different provider is configured.",
            "example": "stripe"
          },
          "publishableKey": {
            "type": [
              "null",
              "string"
            ],
            "description": "The PUBLIC (publishable) Stripe key the app uses to initialize Stripe.js. Never a secret/webhook key.",
            "example": "pk_live_51AbCdEfGhIjKlMnOpQrStUvWx"
          },
          "currency": {
            "type": "string",
            "description": "ISO-4217 currency code charges are settled in (falls back to the network's default currency).",
            "example": "USD"
          },
          "methods": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "The payment method types enabled for this network (e.g. card, apple_pay)."
          },
          "preAuthorizationAmount": {
            "type": [
              "null",
              "number"
            ],
            "description": "Amount, in the network currency, held as a pre-authorization at session start. Null if none.",
            "format": "double",
            "example": 25
          },
          "minimumAmount": {
            "type": [
              "null",
              "number"
            ],
            "description": "Minimum chargeable amount for a session, in the network currency. Null if unset.",
            "format": "double",
            "example": 1
          },
          "maximumAmount": {
            "type": [
              "null",
              "number"
            ],
            "description": "Maximum chargeable amount for a session, in the network currency. Null if unset.",
            "format": "double",
            "example": 500
          }
        }
      },
      "EmspPaymentsMethods": {
        "type": "object",
        "properties": {
          "paymentMode": {
            "type": "string",
            "description": "Always 'phevnix_managed' — saved cards only exist for managed networks.",
            "example": "phevnix_managed"
          },
          "methods": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspPaymentsCard"
            },
            "description": "The driver's saved cards."
          }
        }
      },
      "EmspPaymentsMethodsResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspPaymentsMethods"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspPaymentsSetupCheckout": {
        "type": "object",
        "properties": {
          "url": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stripe-hosted card-setup page URL. Open it in a browser; Stripe redirects back to the return URL when done.",
            "example": "https://checkout.stripe.com/c/pay/cs_test_a1B2c3D4e5F6"
          }
        }
      },
      "EmspPaymentsSetupCheckoutResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspPaymentsSetupCheckout"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspPaymentsSetupIntent": {
        "type": "object",
        "properties": {
          "clientSecret": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stripe SetupIntent client_secret — pass to confirmCardSetup() / the Payment Element to save the card.",
            "example": "seti_1AbCdEfGhIjKl_secret_MnOpQrStUvWxYz"
          },
          "publishableKey": {
            "type": [
              "null",
              "string"
            ],
            "description": "The publishable Stripe key to initialize Stripe.js with for this SetupIntent.",
            "example": "pk_live_51AbCdEfGhIjKlMnOpQrStUvWx"
          }
        }
      },
      "EmspPaymentsSetupIntentResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspPaymentsSetupIntent"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspPushErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (driver_required, not_found, bad_request).",
            "example": "driver_required"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Push requires driver authentication. Log in via /api/emsp/v1/auth/driver/login."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code (defaults to the error slug when not set explicitly).",
            "example": "driver_required"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspPushSubscribeResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspPushSubscribeResult"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspPushSubscribeResult": {
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "description": "Always 'subscribed' — the device's web-push subscription is now registered.",
            "example": "subscribed"
          }
        }
      },
      "EmspPushTestResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspPushTestResult"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspPushTestResult": {
        "type": "object",
        "properties": {
          "sent": {
            "type": "integer",
            "description": "Number of devices the test push was successfully delivered to.",
            "format": "int32",
            "example": 2
          },
          "subscriptions": {
            "type": "integer",
            "description": "Total number of registered device subscriptions for the driver (some may have been pruned if gone).",
            "format": "int32",
            "example": 2
          }
        }
      },
      "EmspRemoteControlErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (forbidden, not_found, bad_request).",
            "example": "forbidden"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "You can only remote-control a charger you are actively using."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code (defaults to the error slug when not set explicitly).",
            "example": "forbidden"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspRemoteControlResetResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspRemoteControlResetResult"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response (the command was dispatched; see data.accepted).",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspRemoteControlResetResult": {
        "type": "object",
        "properties": {
          "chargerId": {
            "type": "string",
            "description": "The charger UUID the command was sent to.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "type": {
            "type": "string",
            "description": "The reset type actually issued: Soft (default) or Hard. Driver-authenticated callers are forced to Soft even if they request Hard.",
            "example": "Soft"
          },
          "accepted": {
            "type": "boolean",
            "description": "Whether the charger accepted the command.",
            "example": true
          },
          "reason": {
            "type": [
              "null",
              "string"
            ],
            "description": "Public-facing reason when not accepted, or null on success.",
            "example": "The charger rejected the request."
          },
          "retryable": {
            "type": "boolean",
            "description": "True when the failure was transient and the request can be retried.",
            "example": false
          }
        }
      },
      "EmspRemoteControlTriggerResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspRemoteControlTriggerResult"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response (the command was dispatched; see data.accepted).",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspRemoteControlTriggerResult": {
        "type": "object",
        "properties": {
          "chargerId": {
            "type": "string",
            "description": "The charger UUID the command was sent to.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "message": {
            "type": "string",
            "description": "The OCPP message the charger was asked to re-send (BootNotification, StatusNotification, MeterValues, …).",
            "example": "StatusNotification"
          },
          "accepted": {
            "type": "boolean",
            "description": "Whether the charger accepted the command.",
            "example": true
          },
          "reason": {
            "type": [
              "null",
              "string"
            ],
            "description": "Public-facing reason when not accepted, or null on success.",
            "example": "The charger rejected the request."
          },
          "retryable": {
            "type": "boolean",
            "description": "True when the failure was transient and the request can be retried.",
            "example": false
          }
        }
      },
      "EmspRemoteControlUnlockResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspRemoteControlUnlockResult"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response (the command was dispatched; see data.accepted for the charger's verdict).",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspRemoteControlUnlockResult": {
        "type": "object",
        "properties": {
          "chargerId": {
            "type": "string",
            "description": "The charger UUID the command was sent to.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "connectorNumber": {
            "type": "integer",
            "description": "The connector number that was asked to unlock (defaults to 1).",
            "format": "int32",
            "example": 1
          },
          "accepted": {
            "type": "boolean",
            "description": "Whether the charger accepted the command. False means the charger rejected it or did not respond.",
            "example": true
          },
          "reason": {
            "type": [
              "null",
              "string"
            ],
            "description": "Public-facing reason when not accepted, or null on success.",
            "example": "The charger rejected the request."
          },
          "retryable": {
            "type": "boolean",
            "description": "True when the failure was transient (e.g. charger unreachable) and the request can be retried.",
            "example": false
          }
        }
      },
      "EmspReservationsErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error code (e.g. forbidden, bad_request, not_found).",
            "example": "bad_request"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "This connector already has an active reservation. Cancel it before reserving again."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent can branch on (defaults to the `error` slug).",
            "example": "INVALID_REQUEST"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:45:01Z"
          }
        }
      },
      "EmspReservationsListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ReservationResponse"
            },
            "description": "The matching reservations, most-recent created first (capped at the page size)."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:45:01Z"
          }
        }
      },
      "EmspReservationsRejectedResponse": {
        "type": "object",
        "properties": {
          "success": {
            "type": "boolean",
            "description": "Always false — the charger rejected the reservation.",
            "example": false
          },
          "error": {
            "type": "string",
            "description": "Stable machine-readable error code for a charger-side rejection.",
            "example": "reservation_rejected"
          },
          "message": {
            "type": "string",
            "description": "Human-readable rejection reason from the charger.",
            "example": "The charger rejected the reservation."
          }
        }
      },
      "EmspReservationsResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/ReservationResponse"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:45:01Z"
          }
        }
      },
      "EmspScheduledChargingDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable scheduled-charge UUID. Use it in DELETE /charging/schedule/{id} to cancel.",
            "format": "uuid",
            "example": "7c1f0a23-9b4d-4e5a-8c6f-1d2e3f4a5b6c"
          },
          "chargerId": {
            "type": "string",
            "description": "UUID of the charger the session will be started on at the scheduled time.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "connectorNumber": {
            "type": "integer",
            "description": "Connector number on the charger (1-based) the session will start on.",
            "format": "int32",
            "example": 1
          },
          "scheduledTime": {
            "description": "UTC time at which the background trigger will fire the remote start.",
            "format": "date-time",
            "example": "2026-06-20T06:00:00Z"
          },
          "status": {
            "type": "string",
            "description": "Lifecycle state: Pending (waiting to fire), Fired (start dispatched), Failed, or Cancelled.",
            "example": "Pending"
          },
          "statusReason": {
            "type": [
              "null",
              "string"
            ],
            "description": "Why the schedule reached its current status (e.g. the charger's rejection reason on Failed). Null while Pending or on a clean fire.",
            "example": "Charger did not respond"
          },
          "firedAt": {
            "description": "UTC time the start was actually dispatched, or null if it has not fired yet.",
            "format": "date-time",
            "example": "2026-06-20T06:00:01Z"
          },
          "createdAt": {
            "description": "UTC time the schedule was created.",
            "format": "date-time",
            "example": "2026-06-19T22:14:55Z"
          }
        }
      },
      "EmspScheduledChargingErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error code (e.g. forbidden, bad_request, not_found).",
            "example": "bad_request"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "scheduledTime must be in the future"
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent can branch on (defaults to the `error` slug).",
            "example": "INVALID_REQUEST"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T22:14:55Z"
          }
        }
      },
      "EmspScheduledChargingListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspScheduledChargingDto"
            },
            "description": "The driver's scheduled charges, most-recent scheduledTime first (capped at 100)."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T22:14:55Z"
          }
        }
      },
      "EmspScheduledChargingResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspScheduledChargingDto"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T22:14:55Z"
          }
        }
      },
      "EmspSessionMeterValuesResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PublicApiMeterValueDto"
            },
            "description": "Meter-value samples for the session, oldest first (charging-curve order)."
          },
          "count": {
            "type": "integer",
            "description": "Number of samples returned in this response.",
            "format": "int32",
            "example": 96
          },
          "truncated": {
            "type": "boolean",
            "description": "True when the session has more samples than the requested limit and the curve was cut off.",
            "example": false
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspSessionsDetailResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/PublicApiSessionDetailDto"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspSessionsErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error code (e.g. forbidden, not_found).",
            "example": "not_found"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Session with identifier '…' was not found."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent can branch on (defaults to the `error` slug).",
            "example": "RESOURCE_NOT_FOUND"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspSessionsListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PublicApiSessionDto"
            },
            "description": "The page of charging sessions, most-recent start first."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "pagination": {
            "$ref": "#/components/schemas/EmspSessionsPagination"
          }
        }
      },
      "EmspSessionsPagination": {
        "type": "object",
        "properties": {
          "totalCount": {
            "type": "integer",
            "description": "Total number of sessions matching the filter, across all pages.",
            "format": "int32",
            "example": 248
          },
          "page": {
            "type": "integer",
            "description": "1-based page index of this result set.",
            "format": "int32",
            "example": 1
          },
          "pageSize": {
            "type": "integer",
            "description": "Items per page (1–100; defaults to 20).",
            "format": "int32",
            "example": 20
          },
          "totalPages": {
            "type": "integer",
            "description": "Total number of pages at the current pageSize.",
            "format": "int32",
            "example": 13
          },
          "hasNextPage": {
            "type": "boolean",
            "description": "True when a page after this one exists.",
            "example": true
          },
          "hasPreviousPage": {
            "type": "boolean",
            "description": "True when a page before this one exists.",
            "example": false
          }
        }
      },
      "EmspSmartChargingClearLimitDto": {
        "type": "object",
        "properties": {
          "chargerId": {
            "type": "string",
            "description": "UUID of the charger the limit was cleared on.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "connectorNumber": {
            "type": "integer",
            "description": "Connector number on the charger (1-based) the cleared limit applied to.",
            "format": "int32",
            "example": 1
          },
          "profileId": {
            "type": "integer",
            "description": "The OCPP charging-profile id that was targeted for removal (reserved 90000+connector range).",
            "format": "int32",
            "example": 90001
          },
          "accepted": {
            "type": "boolean",
            "description": "True if the charger accepted the ClearChargingProfile command.",
            "example": true
          },
          "reason": {
            "type": [
              "null",
              "string"
            ],
            "description": "Why the charger rejected the request, or null when accepted.",
            "example": "The charger rejected the request."
          },
          "retryable": {
            "type": "boolean",
            "description": "True when a failed command is worth retrying shortly; false for a definitive rejection.",
            "example": false
          }
        }
      },
      "EmspSmartChargingClearLimitResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspSmartChargingClearLimitDto"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspSmartChargingErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error code (e.g. forbidden, bad_request, not_found).",
            "example": "bad_request"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "limit must be greater than zero."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent can branch on (defaults to the `error` slug).",
            "example": "INVALID_REQUEST"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspSmartChargingLimitDto": {
        "type": "object",
        "properties": {
          "chargerId": {
            "type": "string",
            "description": "UUID of the charger the schedule was queried from.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "connectorNumber": {
            "type": "integer",
            "description": "Connector number on the charger (1-based) the schedule applies to.",
            "format": "int32",
            "example": 1
          },
          "unit": {
            "type": "string",
            "description": "Charging-rate unit of the schedule: A (amps) or W (watts).",
            "example": "A"
          },
          "accepted": {
            "type": "boolean",
            "description": "True if the charger answered the GetCompositeSchedule request successfully.",
            "example": true
          },
          "schedule": {
            "description": "The raw OCPP composite schedule the charger returned (chargingSchedulePeriod entries), or null when the charger reported none. Shape is pass-through from OCPP 1.6."
          }
        }
      },
      "EmspSmartChargingLimitResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspSmartChargingLimitDto"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspSmartChargingSetLimitDto": {
        "type": "object",
        "properties": {
          "chargerId": {
            "type": "string",
            "description": "UUID of the charger the limit was applied to.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "connectorNumber": {
            "type": "integer",
            "description": "Connector number on the charger (1-based) the limit applies to.",
            "format": "int32",
            "example": 1
          },
          "unit": {
            "type": "string",
            "description": "Charging-rate unit of the requested limit: A (amps) or W (watts).",
            "example": "A"
          },
          "limit": {
            "type": "number",
            "description": "The requested maximum charging rate in the given unit. A driver cap only ever reduces the rate — the network's load-balancing ceiling still applies.",
            "format": "double",
            "example": 16
          },
          "profileId": {
            "type": "integer",
            "description": "The OCPP charging-profile id used for this driver cap (reserved 90000+connector range so it is individually clearable).",
            "format": "int32",
            "example": 90001
          },
          "accepted": {
            "type": "boolean",
            "description": "True if the charger accepted the SetChargingProfile command.",
            "example": true
          },
          "reason": {
            "type": [
              "null",
              "string"
            ],
            "description": "Why the charger rejected the request, or null when accepted.",
            "example": "The charger rejected the request."
          },
          "retryable": {
            "type": "boolean",
            "description": "True when a failed command is worth retrying shortly (charger unreachable now but may reconnect); false for a definitive rejection.",
            "example": false
          }
        }
      },
      "EmspSmartChargingSetLimitResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspSmartChargingSetLimitDto"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspTariffsDetailResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspTariffsTariff"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspTariffsErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. not_found, forbidden).",
            "example": "not_found"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Tariff with identifier 'd4c3b2a1-6f5e-4d3c-2b1a-0f9e8d7c6b5a' was not found."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent/MCP tool branches on.",
            "example": "RESOURCE_NOT_FOUND"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "details": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "description": "Optional field-level validation details, keyed by field name."
          }
        }
      },
      "EmspTariffsListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspTariffsTariff"
            },
            "description": "The available tariffs."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspTariffsTariff": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable tariff UUID. Use it in GET /tariffs/{id}.",
            "format": "uuid",
            "example": "d4c3b2a1-6f5e-4d3c-2b1a-0f9e8d7c6b5a"
          },
          "name": {
            "type": [
              "null",
              "string"
            ],
            "description": "Display name of the tariff.",
            "example": "Standard AC"
          },
          "description": {
            "type": [
              "null",
              "string"
            ],
            "description": "Free-text description of the tariff.",
            "example": "Default rate for AC chargers."
          },
          "type": {
            "type": [
              "null",
              "string"
            ],
            "description": "Tariff type/category (e.g. REGULAR, AD_HOC_PAYMENT, PROFILE_GREEN).",
            "example": "REGULAR"
          },
          "currency": {
            "type": [
              "null",
              "string"
            ],
            "description": "ISO 4217 currency code the rates are expressed in.",
            "example": "USD"
          },
          "isFree": {
            "type": "boolean",
            "description": "True if charging under this tariff is free (all rates ignored).",
            "example": false
          },
          "energyRate": {
            "type": [
              "null",
              "number"
            ],
            "description": "Per-kWh energy rate, in the tariff currency.",
            "format": "double",
            "example": 0.35
          },
          "timeRate": {
            "type": [
              "null",
              "number"
            ],
            "description": "Per-minute charging-time rate, in the tariff currency.",
            "format": "double",
            "example": 0
          },
          "idleRate": {
            "type": [
              "null",
              "number"
            ],
            "description": "Per-minute idle fee charged after the grace period, in the tariff currency.",
            "format": "double",
            "example": 0.4
          },
          "sessionFee": {
            "type": [
              "null",
              "number"
            ],
            "description": "Flat per-session fee, in the tariff currency.",
            "format": "double",
            "example": 0.5
          },
          "minimumSessionFee": {
            "type": [
              "null",
              "number"
            ],
            "description": "Minimum total charged for any session under this tariff.",
            "format": "double",
            "example": 1
          },
          "maximumSessionFee": {
            "type": [
              "null",
              "number"
            ],
            "description": "Maximum (capped) total charged for any session under this tariff.",
            "format": "double",
            "example": 50
          },
          "taxRate": {
            "type": [
              "null",
              "number"
            ],
            "description": "Tax rate applied to the session total, as a percentage.",
            "format": "double",
            "example": 11.5
          },
          "effectiveFrom": {
            "description": "UTC timestamp the tariff becomes effective.",
            "format": "date-time",
            "example": "2026-01-01T00:00:00Z"
          },
          "effectiveTo": {
            "description": "UTC timestamp the tariff stops being effective, or null if open-ended.",
            "format": "date-time",
            "example": "2026-12-31T23:59:59Z"
          }
        }
      },
      "EmspTransactionsDetailResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/PublicApiTransactionDetailDto"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspTransactionsErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error code (e.g. forbidden, bad_request, not_found).",
            "example": "not_found"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Transaction with identifier '…' was not found."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent can branch on (defaults to the `error` slug).",
            "example": "RESOURCE_NOT_FOUND"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspTransactionsInvoiceResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/PublicApiInvoiceDto"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspTransactionsListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PublicApiTransactionDto"
            },
            "description": "The page of transactions (charge detail records), most-recent end time first."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "pagination": {
            "$ref": "#/components/schemas/EmspTransactionsPagination"
          }
        }
      },
      "EmspTransactionsPagination": {
        "type": "object",
        "properties": {
          "totalCount": {
            "type": "integer",
            "description": "Total number of transactions (CDRs) matching the filter, across all pages.",
            "format": "int32",
            "example": 412
          },
          "page": {
            "type": "integer",
            "description": "1-based page index of this result set.",
            "format": "int32",
            "example": 1
          },
          "pageSize": {
            "type": "integer",
            "description": "Items per page (1–100; defaults to 20).",
            "format": "int32",
            "example": 20
          },
          "totalPages": {
            "type": "integer",
            "description": "Total number of pages at the current pageSize.",
            "format": "int32",
            "example": 21
          },
          "hasNextPage": {
            "type": "boolean",
            "description": "True when a page after this one exists.",
            "example": true
          },
          "hasPreviousPage": {
            "type": "boolean",
            "description": "True when a page before this one exists.",
            "example": false
          }
        }
      },
      "EmspTransactionsPricingResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/PricingCalculationDto"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspUsersErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (e.g. not_found, forbidden, conflict).",
            "example": "conflict"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "A user with email 'maya@example.com' already exists in this network."
          },
          "code": {
            "type": [
              "null",
              "string"
            ],
            "description": "Stable machine-readable error code an agent can branch on (defaults to the error slug).",
            "example": "RESOURCE_CONFLICT"
          },
          "timestamp": {
            "description": "UTC time the error was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "details": {
            "type": [
              "null",
              "object"
            ],
            "additionalProperties": {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            "description": "Optional field-level validation details, keyed by field name."
          }
        }
      },
      "EmspUsersPagination": {
        "type": "object",
        "properties": {
          "totalCount": {
            "type": "integer",
            "description": "Total number of users across all pages.",
            "format": "int32",
            "example": 137
          },
          "page": {
            "type": "integer",
            "description": "1-based page index of this result set.",
            "format": "int32",
            "example": 1
          },
          "pageSize": {
            "type": "integer",
            "description": "Items per page (1–100; defaults to 20).",
            "format": "int32",
            "example": 20
          },
          "totalPages": {
            "type": "integer",
            "description": "Total number of pages at the current pageSize.",
            "format": "int32",
            "example": 7
          },
          "hasNextPage": {
            "type": "boolean",
            "description": "True when a page after this one exists.",
            "example": true
          },
          "hasPreviousPage": {
            "type": "boolean",
            "description": "True when a page before this one exists.",
            "example": false
          }
        }
      },
      "EmspUsersUserListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspUsersUserModel"
            },
            "description": "The page of users."
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "pagination": {
            "description": "Page metadata for the result set.",
            "$ref": "#/components/schemas/EmspUsersPagination"
          }
        }
      },
      "EmspUsersUserModel": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable user (driver) UUID. Use it in GET/PUT /users/{id}.",
            "format": "uuid",
            "example": "1ae38f39-2c4b-4d5e-9f10-3a4b5c6d7e8f"
          },
          "email": {
            "type": "string",
            "description": "User's email address (unique within a network).",
            "example": "maya@example.com"
          },
          "firstName": {
            "type": "string",
            "description": "User's first name.",
            "example": "Maya"
          },
          "lastName": {
            "type": "string",
            "description": "User's last name.",
            "example": "Rivera"
          },
          "phoneNumber": {
            "type": [
              "null",
              "string"
            ],
            "description": "User's phone number, or null.",
            "example": "+17875551234"
          },
          "address": {
            "type": [
              "null",
              "string"
            ],
            "description": "Street address, or null.",
            "example": "123 Calle Sol"
          },
          "city": {
            "type": [
              "null",
              "string"
            ],
            "description": "City, or null.",
            "example": "San Juan"
          },
          "state": {
            "type": [
              "null",
              "string"
            ],
            "description": "State/region, or null.",
            "example": "PR"
          },
          "postalCode": {
            "type": [
              "null",
              "string"
            ],
            "description": "Postal code, or null.",
            "example": "00901"
          },
          "country": {
            "type": [
              "null",
              "string"
            ],
            "description": "Country, or null.",
            "example": "US"
          },
          "createdAt": {
            "description": "UTC timestamp when the user was created.",
            "format": "date-time",
            "example": "2026-01-15T09:30:00Z"
          },
          "lastUpdated": {
            "description": "UTC timestamp the user was last updated, or null if never updated since creation.",
            "format": "date-time",
            "example": "2026-06-18T14:05:33Z"
          },
          "totalSessions": {
            "type": "integer",
            "description": "Number of charging sessions the user has across the key's accessible networks.",
            "format": "int32",
            "example": 27
          },
          "totalEnergyKwh": {
            "type": "number",
            "description": "Total energy delivered to the user across all sessions, in kWh.",
            "format": "double",
            "example": 412.5
          },
          "totalSpent": {
            "type": "number",
            "description": "Total amount the user has spent across all sessions, in the network currency.",
            "format": "double",
            "example": 186.4
          },
          "currency": {
            "type": "string",
            "description": "ISO-4217 currency code for totalSpent (from the primary network; defaults to USD).",
            "example": "USD"
          }
        }
      },
      "EmspUsersUserResponse": {
        "type": "object",
        "properties": {
          "data": {
            "description": "The user.",
            "$ref": "#/components/schemas/EmspUsersUserModel"
          },
          "success": {
            "type": "boolean",
            "description": "Always true on a 2xx response.",
            "example": true
          },
          "timestamp": {
            "description": "UTC time the response was generated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspWebhooksCreated": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable webhook subscription UUID.",
            "format": "uuid",
            "example": "3a1b2c3d-4e5f-6a7b-8c9d-0e1f2a3b4c5d"
          },
          "url": {
            "type": "string",
            "description": "HTTPS endpoint events are delivered to.",
            "example": "https://example.com/hooks/phevnix"
          },
          "events": {
            "type": "string",
            "description": "Comma-separated subscribed event types, or '*'.",
            "example": "charging.session.started,charging.session.stopped"
          },
          "description": {
            "type": "string",
            "description": "Operator-supplied description.",
            "example": "Billing pipeline hook"
          },
          "hmac_secret": {
            "type": "string",
            "description": "The HMAC signing secret for verifying delivery signatures. Shown ONLY at creation — store it securely; it cannot be retrieved later.",
            "example": "whsec_REDACTED_store_this_value_now"
          },
          "is_active": {
            "type": "boolean",
            "description": "Whether the subscription is active (true on creation).",
            "example": true
          },
          "created_at": {
            "description": "UTC time the subscription was created.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspWebhooksCreatedResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspWebhooksCreated"
          }
        }
      },
      "EmspWebhooksDeliveryDetail": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable delivery UUID.",
            "format": "uuid",
            "example": "6f5e4d3c-2b1a-0e9f-8d7c-6b5a4c3d2e1f"
          },
          "event_type": {
            "type": "string",
            "description": "The event type that triggered this delivery.",
            "example": "charging.session.stopped"
          },
          "payload": {
            "type": "string",
            "description": "The raw JSON payload (as a string) that was POSTed to the destination.",
            "example": "{\"event\":\"charging.session.stopped\",\"sessionId\":\"7c6f5e40-1a2b-3c4d-5e6f-7a8b9c0d1e2f\"}"
          },
          "http_status": {
            "type": [
              "null",
              "integer"
            ],
            "description": "HTTP status code returned by the destination, or null if no response.",
            "format": "int32",
            "example": 200
          },
          "response_body": {
            "type": [
              "null",
              "string"
            ],
            "description": "Response body returned by the destination (truncated), or null.",
            "example": "OK"
          },
          "success": {
            "type": "boolean",
            "description": "True when the delivery reached the Delivered terminal state.",
            "example": true
          },
          "status": {
            "type": "string",
            "description": "Delivery state (Pending, Delivered, Failed, …).",
            "example": "Delivered"
          },
          "attempts": {
            "type": "integer",
            "description": "Number of delivery attempts made so far.",
            "format": "int32",
            "example": 1
          },
          "max_attempts": {
            "type": "integer",
            "description": "Maximum number of delivery attempts before the delivery is abandoned.",
            "format": "int32",
            "example": 5
          },
          "duration_ms": {
            "type": [
              "null",
              "integer"
            ],
            "description": "How long the last delivery attempt took, in milliseconds, or null.",
            "format": "int32",
            "example": 142
          },
          "next_retry_at": {
            "description": "UTC time the next retry is scheduled for, or null if none pending.",
            "format": "date-time",
            "example": "2026-06-19T18:47:09Z"
          },
          "created_at": {
            "description": "UTC time the delivery was created.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "completed_at": {
            "description": "UTC time the delivery reached a terminal state, or null.",
            "format": "date-time",
            "example": "2026-06-19T18:42:11Z"
          }
        }
      },
      "EmspWebhooksDeliveryDetailResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspWebhooksDeliveryDetail"
          }
        }
      },
      "EmspWebhooksDeliveryListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspWebhooksDeliverySummary"
            },
            "description": "The page of webhook deliveries, newest first."
          },
          "pagination": {
            "$ref": "#/components/schemas/EmspWebhooksPagination"
          }
        }
      },
      "EmspWebhooksDeliverySummary": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable delivery UUID. Use it in the /deliveries/{deliveryId} routes.",
            "format": "uuid",
            "example": "6f5e4d3c-2b1a-0e9f-8d7c-6b5a4c3d2e1f"
          },
          "event_type": {
            "type": "string",
            "description": "The event type that triggered this delivery.",
            "example": "charging.session.stopped"
          },
          "http_status": {
            "type": [
              "null",
              "integer"
            ],
            "description": "HTTP status code returned by the destination, or null if no response was received.",
            "format": "int32",
            "example": 200
          },
          "success": {
            "type": "boolean",
            "description": "True when the delivery reached the Delivered terminal state.",
            "example": true
          },
          "status": {
            "type": "string",
            "description": "Delivery state (Pending, Delivered, Failed, …).",
            "example": "Delivered"
          },
          "attempts": {
            "type": "integer",
            "description": "Number of delivery attempts made so far.",
            "format": "int32",
            "example": 1
          },
          "created_at": {
            "description": "UTC time the delivery was created (event enqueued).",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "completed_at": {
            "description": "UTC time the delivery reached a terminal state, or null if still pending.",
            "format": "date-time",
            "example": "2026-06-19T18:42:11Z"
          }
        }
      },
      "EmspWebhooksErrorResponse": {
        "type": "object",
        "properties": {
          "error": {
            "type": "string",
            "description": "Stable machine-readable error slug (forbidden, unauthorized, invalid_url, invalid_events, not_found).",
            "example": "not_found"
          },
          "message": {
            "type": "string",
            "description": "Human-readable explanation of the error.",
            "example": "Webhook subscription not found"
          }
        }
      },
      "EmspWebhooksEventTypesResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "All event types a subscription may subscribe to."
          }
        }
      },
      "EmspWebhooksListResponse": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EmspWebhooksSubscription"
            },
            "description": "The operator's webhook subscriptions."
          }
        }
      },
      "EmspWebhooksPagination": {
        "type": "object",
        "properties": {
          "page": {
            "type": "integer",
            "description": "1-based page index of this result set.",
            "format": "int32",
            "example": 1
          },
          "page_size": {
            "type": "integer",
            "description": "Items requested per page (1–100; defaults to 20).",
            "format": "int32",
            "example": 20
          },
          "total_count": {
            "type": "integer",
            "description": "Total number of deliveries across all pages.",
            "format": "int32",
            "example": 57
          },
          "total_pages": {
            "type": "integer",
            "description": "Total number of pages at the current page_size.",
            "format": "int32",
            "example": 3
          }
        }
      },
      "EmspWebhooksRetryResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspWebhooksRetryResult"
          }
        }
      },
      "EmspWebhooksRetryResult": {
        "type": "object",
        "properties": {
          "delivery_id": {
            "type": "string",
            "description": "The delivery UUID that was re-enqueued.",
            "format": "uuid",
            "example": "6f5e4d3c-2b1a-0e9f-8d7c-6b5a4c3d2e1f"
          },
          "retry_enqueued": {
            "type": "boolean",
            "description": "Always true — the delivery was queued for one immediate re-processing pass.",
            "example": true
          }
        }
      },
      "EmspWebhooksSubscription": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable webhook subscription UUID. Use it in the /webhooks/{webhookId} routes.",
            "format": "uuid",
            "example": "3a1b2c3d-4e5f-6a7b-8c9d-0e1f2a3b4c5d"
          },
          "url": {
            "type": "string",
            "description": "HTTPS endpoint events are delivered to (POST).",
            "example": "https://example.com/hooks/phevnix"
          },
          "events": {
            "type": "string",
            "description": "Comma-separated list of subscribed event types, or '*' for all events.",
            "example": "charging.session.started,charging.session.stopped"
          },
          "description": {
            "type": "string",
            "description": "Operator-supplied description of the subscription.",
            "example": "Billing pipeline hook"
          },
          "is_active": {
            "type": "boolean",
            "description": "Whether the subscription is currently active and receiving deliveries.",
            "example": true
          },
          "consecutive_failures": {
            "type": "integer",
            "description": "Number of consecutive failed deliveries; the subscription auto-disables past a threshold.",
            "format": "int32",
            "example": 0
          },
          "disabled_at": {
            "description": "UTC time the subscription was auto-disabled after repeated failures, or null if active.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "disabled_reason": {
            "type": [
              "null",
              "string"
            ],
            "description": "Why the subscription was disabled, or null if active.",
            "example": "Too many consecutive delivery failures"
          },
          "created_at": {
            "description": "UTC time the subscription was created.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          },
          "updated_at": {
            "description": "UTC time the subscription was last updated.",
            "format": "date-time",
            "example": "2026-06-19T18:42:09Z"
          }
        }
      },
      "EmspWebhooksSubscriptionResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspWebhooksSubscription"
          }
        }
      },
      "EmspWebhooksTestResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/EmspWebhooksTestResult"
          }
        }
      },
      "EmspWebhooksTestResult": {
        "type": "object",
        "properties": {
          "webhook_id": {
            "type": "string",
            "description": "The subscription UUID the test event was enqueued for.",
            "format": "uuid",
            "example": "3a1b2c3d-4e5f-6a7b-8c9d-0e1f2a3b4c5d"
          },
          "test_enqueued": {
            "type": "boolean",
            "description": "Always true — the test delivery was queued for the worker.",
            "example": true
          }
        }
      },
      "FavoriteRequest": {
        "type": "object",
        "properties": {
          "targetType": {
            "type": "string"
          },
          "targetId": {
            "type": "string",
            "format": "uuid"
          },
          "label": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "GenerateInvoiceRequest": {
        "type": "object",
        "properties": {
          "transactionId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "transactionIds": {
            "type": [
              "null",
              "array"
            ],
            "items": {
              "type": "string",
              "format": "uuid"
            }
          }
        }
      },
      "IdempotencyInfo": {
        "type": "object",
        "properties": {
          "supported": {
            "type": "boolean",
            "example": true
          },
          "header": {
            "type": "string",
            "example": "Idempotency-Key"
          },
          "appliesTo": {
            "type": "string",
            "example": "POST/PUT/PATCH/DELETE"
          }
        }
      },
      "KeyContext": {
        "type": "object",
        "properties": {
          "apiVersion": {
            "type": "string",
            "description": "API family and version this key addresses.",
            "example": "emsp/v1"
          },
          "apiFamily": {
            "type": "string",
            "description": "Which API family the key is bound to. A key used on the other family returns 403 wrong_api_family.",
            "example": "emsp"
          },
          "environment": {
            "type": "string",
            "description": "Environment the key belongs to (Production or Test).",
            "example": "Production"
          },
          "keyType": {
            "type": [
              "null",
              "string"
            ],
            "description": "Transport class of the credential, or null when not applicable.",
            "example": "Rest"
          },
          "visibility": {
            "type": "string",
            "description": "Public = publishable (browser-safe, read-only until a driver signs in); Private = secret (server-side).",
            "example": "Public"
          },
          "scopes": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Scopes granted to this key. See GET /{family}/v1/.well-known/scopes for the vocabulary."
          },
          "capabilities": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Higher-level actions this credential can perform right now, given its scopes and whether a driver is signed in."
          },
          "driver": {
            "$ref": "#/components/schemas/DriverContext"
          },
          "accessibleNetworks": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/NetworkRef"
            },
            "description": "Networks this key may operate on. Empty on a brand-new account — that is a success, not a failure."
          },
          "rateLimit": {
            "$ref": "#/components/schemas/RateLimitInfo"
          },
          "idempotency": {
            "$ref": "#/components/schemas/IdempotencyInfo"
          },
          "discovery": {
            "$ref": "#/components/schemas/DiscoveryLinks"
          }
        }
      },
      "KeyContextResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/KeyContext"
          },
          "success": {
            "type": "boolean",
            "example": true
          },
          "timestamp": {
            "format": "date-time",
            "example": "2026-07-26T02:41:09Z"
          }
        }
      },
      "LocationIssueReportRequest": {
        "type": "object",
        "properties": {
          "category": {
            "type": [
              "null",
              "string"
            ]
          },
          "note": {
            "type": [
              "null",
              "string"
            ]
          },
          "chargerId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          }
        }
      },
      "LocationReviewRequest": {
        "type": "object",
        "properties": {
          "rating": {
            "type": "integer",
            "format": "int32"
          },
          "comment": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "NetworkRef": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid",
            "example": "0a9fc2cf-2a7c-40d5-bdd5-27aabecf186e"
          },
          "name": {
            "type": "string",
            "example": "Nova Charge Co"
          }
        }
      },
      "NotificationPreferencesRequest": {
        "type": "object",
        "properties": {
          "pushEnabled": {
            "type": [
              "null",
              "boolean"
            ]
          },
          "emailEnabled": {
            "type": [
              "null",
              "boolean"
            ]
          },
          "smsEnabled": {
            "type": [
              "null",
              "boolean"
            ]
          },
          "notifySessionStarted": {
            "type": [
              "null",
              "boolean"
            ]
          },
          "notifySessionStopped": {
            "type": [
              "null",
              "boolean"
            ]
          },
          "notifySessionFailed": {
            "type": [
              "null",
              "boolean"
            ]
          },
          "notifyReservationReminder": {
            "type": [
              "null",
              "boolean"
            ]
          },
          "notifyPayment": {
            "type": [
              "null",
              "boolean"
            ]
          },
          "email": {
            "type": [
              "null",
              "string"
            ]
          },
          "phoneNumber": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "PricingCalculationDto": {
        "type": "object",
        "properties": {
          "energyCost": {
            "type": "number",
            "format": "double"
          },
          "timeCost": {
            "type": "number",
            "format": "double"
          },
          "sessionFee": {
            "type": "number",
            "format": "double"
          },
          "idleFee": {
            "type": "number",
            "format": "double"
          },
          "subtotal": {
            "type": "number",
            "format": "double"
          },
          "tax": {
            "type": "number",
            "format": "double"
          },
          "total": {
            "type": "number",
            "format": "double"
          },
          "currency": {
            "type": "string"
          },
          "tariffName": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "PricingCalculationRequest": {
        "required": [
          "energyKwh"
        ],
        "type": "object",
        "properties": {
          "tariffId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "chargerId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "connectorId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "energyKwh": {
            "type": "number",
            "format": "double"
          },
          "durationMinutes": {
            "type": "number",
            "format": "double"
          },
          "idleMinutes": {
            "type": "number",
            "format": "double"
          }
        }
      },
      "PublicApiCostBreakdownDto": {
        "type": "object",
        "properties": {
          "energyCost": {
            "type": "number",
            "format": "double"
          },
          "timeCost": {
            "type": "number",
            "format": "double"
          },
          "sessionFee": {
            "type": "number",
            "format": "double"
          },
          "idleFee": {
            "type": "number",
            "format": "double"
          },
          "subtotal": {
            "type": "number",
            "format": "double"
          },
          "tax": {
            "type": "number",
            "format": "double"
          },
          "total": {
            "type": "number",
            "format": "double"
          }
        }
      },
      "PublicApiInvoiceDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "invoiceNumber": {
            "type": "string"
          },
          "issueDate": {
            "format": "date-time"
          },
          "dueDate": {
            "format": "date-time"
          },
          "userId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "userName": {
            "type": [
              "null",
              "string"
            ]
          },
          "userEmail": {
            "type": [
              "null",
              "string"
            ]
          },
          "lineItems": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PublicApiInvoiceLineItemDto"
            }
          },
          "subtotal": {
            "type": "number",
            "format": "double"
          },
          "tax": {
            "type": "number",
            "format": "double"
          },
          "total": {
            "type": "number",
            "format": "double"
          },
          "currency": {
            "type": "string"
          },
          "status": {
            "type": "string"
          }
        }
      },
      "PublicApiInvoiceLineItemDto": {
        "type": "object",
        "properties": {
          "transactionId": {
            "type": "string",
            "format": "uuid"
          },
          "sessionDate": {
            "format": "date-time"
          },
          "locationName": {
            "type": [
              "null",
              "string"
            ]
          },
          "energyKwh": {
            "type": "number",
            "format": "double"
          },
          "amount": {
            "type": "number",
            "format": "double"
          }
        }
      },
      "PublicApiInvoiceSummaryDto": {
        "type": "object",
        "properties": {
          "invoiceNumber": {
            "type": "string"
          },
          "issueDate": {
            "format": "date-time"
          },
          "transactionCount": {
            "type": "integer",
            "format": "int32"
          },
          "total": {
            "type": "number",
            "format": "double"
          },
          "currency": {
            "type": "string"
          }
        }
      },
      "PublicApiMeterValueDto": {
        "type": "object",
        "properties": {
          "timestamp": {
            "description": "UTC time the charger captured this sample.",
            "format": "date-time",
            "example": "2026-06-19T18:21:30Z"
          },
          "meterValue": {
            "type": "number",
            "description": "Cumulative active-energy register at this sample (the raw OCPP Energy.Active.Import.Register value, kWh). Subtract consecutive readings for interval consumption.",
            "format": "double",
            "example": 14.382
          },
          "powerKw": {
            "type": [
              "null",
              "number"
            ],
            "description": "Instantaneous active power draw at this sample, in kW.",
            "format": "double",
            "example": 7.2
          },
          "energyWh": {
            "type": [
              "null",
              "number"
            ],
            "description": "Interval energy delivered since the previous sample, in Wh (when the charger reports it).",
            "format": "double",
            "example": 120
          },
          "currentA": {
            "type": [
              "null",
              "number"
            ],
            "description": "Phase L1 current, in amperes.",
            "format": "double",
            "example": 31.5
          },
          "currentB": {
            "type": [
              "null",
              "number"
            ],
            "description": "Phase L2 current, in amperes (3-phase chargers only).",
            "format": "double"
          },
          "currentC": {
            "type": [
              "null",
              "number"
            ],
            "description": "Phase L3 current, in amperes (3-phase chargers only).",
            "format": "double"
          },
          "voltageA": {
            "type": [
              "null",
              "number"
            ],
            "description": "Phase L1 voltage, in volts.",
            "format": "double",
            "example": 230.1
          },
          "voltageB": {
            "type": [
              "null",
              "number"
            ],
            "description": "Phase L2 voltage, in volts (3-phase chargers only).",
            "format": "double"
          },
          "voltageC": {
            "type": [
              "null",
              "number"
            ],
            "description": "Phase L3 voltage, in volts (3-phase chargers only).",
            "format": "double"
          },
          "stateOfCharge": {
            "type": [
              "null",
              "integer"
            ],
            "description": "Vehicle battery state of charge at this sample, 0–100 (when the EV reports it over OCPP).",
            "format": "int32",
            "example": 64
          },
          "temperature": {
            "type": [
              "null",
              "number"
            ],
            "description": "Connector/charger temperature at this sample, in °C (when reported).",
            "format": "double"
          }
        }
      },
      "PublicApiSessionDetailDto": {
        "type": "object",
        "properties": {
          "authMethod": {
            "type": "string"
          },
          "idTag": {
            "type": [
              "null",
              "string"
            ]
          },
          "startMeterValue": {
            "type": "number",
            "format": "double"
          },
          "endMeterValue": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          },
          "currentMeterValue": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          },
          "startReason": {
            "type": [
              "null",
              "string"
            ]
          },
          "stopReason": {
            "type": [
              "null",
              "string"
            ]
          },
          "idleTimeSeconds": {
            "type": [
              "null",
              "integer"
            ],
            "format": "int32"
          },
          "isInIdleState": {
            "type": "boolean"
          },
          "paymentStatus": {
            "type": [
              "null",
              "string"
            ]
          },
          "costs": {
            "$ref": "#/components/schemas/SessionCostBreakdownDto"
          },
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "status": {
            "type": "string"
          },
          "chargerId": {
            "type": "string",
            "format": "uuid"
          },
          "chargerUid": {
            "type": [
              "null",
              "string"
            ]
          },
          "connectorId": {
            "type": "string",
            "format": "uuid"
          },
          "connectorNumber": {
            "type": "integer",
            "format": "int32"
          },
          "locationId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "locationName": {
            "type": [
              "null",
              "string"
            ]
          },
          "startTime": {
            "format": "date-time"
          },
          "endTime": {
            "format": "date-time"
          },
          "durationSeconds": {
            "type": [
              "null",
              "integer"
            ],
            "format": "int32"
          },
          "energyDeliveredKwh": {
            "type": "number",
            "format": "double"
          },
          "total": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          },
          "currency": {
            "type": "string"
          },
          "maxPowerKw": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          },
          "currentPowerKw": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          },
          "currentSocPercent": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          }
        }
      },
      "PublicApiSessionDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "status": {
            "type": "string"
          },
          "chargerId": {
            "type": "string",
            "format": "uuid"
          },
          "chargerUid": {
            "type": [
              "null",
              "string"
            ]
          },
          "connectorId": {
            "type": "string",
            "format": "uuid"
          },
          "connectorNumber": {
            "type": "integer",
            "format": "int32"
          },
          "locationId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "locationName": {
            "type": [
              "null",
              "string"
            ]
          },
          "startTime": {
            "format": "date-time"
          },
          "endTime": {
            "format": "date-time"
          },
          "durationSeconds": {
            "type": [
              "null",
              "integer"
            ],
            "format": "int32"
          },
          "energyDeliveredKwh": {
            "type": "number",
            "format": "double"
          },
          "total": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          },
          "currency": {
            "type": "string"
          },
          "maxPowerKw": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          },
          "currentPowerKw": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          },
          "currentSocPercent": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          }
        }
      },
      "PublicApiTransactionDetailDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "ocpiId": {
            "type": [
              "null",
              "string"
            ]
          },
          "sessionId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "userId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "startTime": {
            "format": "date-time"
          },
          "endTime": {
            "format": "date-time"
          },
          "totalEnergyKwh": {
            "type": "number",
            "format": "double"
          },
          "totalTimeMinutes": {
            "type": "number",
            "format": "double"
          },
          "currency": {
            "type": "string"
          },
          "paymentStatus": {
            "type": [
              "null",
              "string"
            ]
          },
          "locationId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "locationName": {
            "type": [
              "null",
              "string"
            ]
          },
          "locationAddress": {
            "type": [
              "null",
              "string"
            ]
          },
          "chargerUid": {
            "type": [
              "null",
              "string"
            ]
          },
          "connectorNumber": {
            "type": [
              "null",
              "integer"
            ],
            "format": "int32"
          },
          "costBreakdown": {
            "$ref": "#/components/schemas/PublicApiCostBreakdownDto"
          }
        }
      },
      "PublicApiTransactionDto": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "ocpiId": {
            "type": [
              "null",
              "string"
            ]
          },
          "sessionId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "userId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "startTime": {
            "format": "date-time"
          },
          "endTime": {
            "format": "date-time"
          },
          "totalEnergyKwh": {
            "type": "number",
            "format": "double"
          },
          "amount": {
            "type": "number",
            "format": "double"
          },
          "currency": {
            "type": "string"
          },
          "paymentStatus": {
            "type": [
              "null",
              "string"
            ]
          },
          "locationName": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "PushKeys": {
        "type": "object",
        "properties": {
          "p256dh": {
            "type": [
              "null",
              "string"
            ]
          },
          "auth": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "PushSubscribeRequest": {
        "type": "object",
        "properties": {
          "endpoint": {
            "type": [
              "null",
              "string"
            ]
          },
          "keys": {
            "oneOf": [
              {
                "type": "null"
              },
              {
                "$ref": "#/components/schemas/PushKeys"
              }
            ]
          }
        }
      },
      "PushUnsubscribeRequest": {
        "type": "object",
        "properties": {
          "endpoint": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "RateLimitInfo": {
        "type": "object",
        "properties": {
          "limit": {
            "type": "integer",
            "description": "Requests permitted per window for this key's plan.",
            "format": "int32",
            "example": 120
          },
          "window": {
            "type": "string",
            "example": "1m"
          },
          "header": {
            "type": "string",
            "description": "Response header carrying the remaining allowance.",
            "example": "X-RateLimit-Remaining"
          }
        }
      },
      "RebootChargerRequest": {
        "type": "object",
        "properties": {
          "resetType": {
            "type": "string"
          }
        }
      },
      "ReservationResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Stable reservation UUID. Use it in GET/DELETE /reservations/{id}.",
            "format": "uuid",
            "example": "a3f9c812-6e7b-4d1a-9f0c-2b3e4d5f6a70"
          },
          "chargerId": {
            "type": "string",
            "description": "UUID of the charger holding the reservation.",
            "format": "uuid",
            "example": "4b2e9c10-7d8a-4a6e-9b1f-2c3d4e5f6a7b"
          },
          "chargerName": {
            "type": [
              "null",
              "string"
            ],
            "description": "Display name of the charger (serial number, falling back to the OCPP UID). Null if the charger could not be resolved.",
            "example": "CP-IslaVerde-01"
          },
          "connectorNumber": {
            "type": "integer",
            "description": "Connector number on the charger (1-based) that is reserved.",
            "format": "int32",
            "example": 1
          },
          "status": {
            "type": "string",
            "description": "Reservation lifecycle state: Pending, Accepted (held by the charger), Rejected, Cancelled, or Expired.",
            "example": "Accepted"
          },
          "statusReason": {
            "type": [
              "null",
              "string"
            ],
            "description": "Why the reservation reached its current status (e.g. the charger's rejection reason). Null on a clean Accepted.",
            "example": "Rejected by charger"
          },
          "idTag": {
            "type": "string",
            "description": "Authorization id-tag the reservation is bound to — only this token may start the held session.",
            "example": "DRV-7F3A91C2"
          },
          "expiryDate": {
            "description": "UTC time the hold expires; the connector is released automatically afterwards.",
            "format": "date-time",
            "example": "2026-06-19T19:00:00Z"
          },
          "createdAt": {
            "description": "UTC time the reservation was created.",
            "format": "date-time",
            "example": "2026-06-19T18:45:00Z"
          },
          "cancelledAt": {
            "description": "UTC time the reservation was cancelled, or null if it was never cancelled.",
            "format": "date-time",
            "example": "2026-06-19T18:52:00Z"
          }
        }
      },
      "ReserveRequest": {
        "type": "object",
        "properties": {
          "chargerId": {
            "type": "string",
            "format": "uuid"
          },
          "connectorNumber": {
            "type": "integer",
            "format": "int32"
          },
          "idTag": {
            "type": "string"
          },
          "expiryMinutes": {
            "type": [
              "null",
              "integer"
            ],
            "format": "int32"
          }
        }
      },
      "ResetRequest": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string"
          }
        }
      },
      "ScheduleChargeRequest": {
        "type": "object",
        "properties": {
          "chargerId": {
            "type": "string",
            "format": "uuid"
          },
          "connectorNumber": {
            "type": "integer",
            "format": "int32"
          },
          "idTag": {
            "type": "string"
          },
          "scheduledTime": {
            "format": "date-time"
          }
        }
      },
      "ScopeCatalogData": {
        "type": "object",
        "properties": {
          "apiFamily": {
            "type": "string",
            "example": "emsp"
          },
          "scopes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ScopeDescription"
            }
          },
          "notes": {
            "type": "string"
          }
        }
      },
      "ScopeCatalogResponse": {
        "type": "object",
        "properties": {
          "data": {
            "$ref": "#/components/schemas/ScopeCatalogData"
          },
          "success": {
            "type": "boolean",
            "example": true
          },
          "timestamp": {
            "format": "date-time"
          }
        }
      },
      "ScopeDescription": {
        "type": "object",
        "properties": {
          "scope": {
            "type": "string",
            "example": "read:locations"
          },
          "description": {
            "type": "string",
            "example": "Browse charging locations and geo-search"
          }
        }
      },
      "SessionCostBreakdownDto": {
        "type": "object",
        "properties": {
          "subtotal": {
            "type": "number",
            "format": "double"
          },
          "taxes": {
            "type": "number",
            "format": "double"
          },
          "sessionFees": {
            "type": "number",
            "format": "double"
          },
          "idleFees": {
            "type": "number",
            "format": "double"
          },
          "timeFees": {
            "type": "number",
            "format": "double"
          },
          "total": {
            "type": [
              "null",
              "number"
            ],
            "format": "double"
          },
          "currency": {
            "type": "string"
          }
        }
      },
      "SmartChargingLimitRequest": {
        "type": "object",
        "properties": {
          "connectorNumber": {
            "type": "integer",
            "format": "int32"
          },
          "unit": {
            "type": "string"
          },
          "limit": {
            "type": "number",
            "format": "double"
          }
        }
      },
      "StartSessionRequest": {
        "required": [
          "chargerId",
          "connectorNumber",
          "idTag"
        ],
        "type": "object",
        "properties": {
          "chargerId": {
            "type": "string",
            "format": "uuid"
          },
          "connectorNumber": {
            "type": "integer",
            "format": "int32"
          },
          "idTag": {
            "maxLength": 36,
            "minLength": 1,
            "type": "string"
          }
        }
      },
      "StartSessionResponse": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid"
          },
          "sessionId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "correlationId": {
            "type": [
              "null",
              "string"
            ],
            "format": "uuid"
          },
          "status": {
            "type": "string"
          },
          "chargerId": {
            "type": "string",
            "format": "uuid"
          },
          "connectorNumber": {
            "type": "integer",
            "format": "int32"
          },
          "startTime": {
            "format": "date-time"
          },
          "message": {
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "StopSessionRequest": {
        "required": [
          "sessionId"
        ],
        "type": "object",
        "properties": {
          "sessionId": {
            "type": "string",
            "format": "uuid"
          }
        }
      },
      "TriggerRequest": {
        "type": "object",
        "properties": {
          "message": {
            "type": "string"
          },
          "connectorNumber": {
            "type": [
              "null",
              "integer"
            ],
            "format": "int32"
          }
        }
      },
      "UnlockRequest": {
        "type": "object",
        "properties": {
          "connectorNumber": {
            "type": "integer",
            "format": "int32"
          }
        }
      },
      "UpdateUserRequest": {
        "type": "object",
        "properties": {
          "email": {
            "maxLength": 100,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "firstName": {
            "maxLength": 50,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "lastName": {
            "maxLength": 50,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "phoneNumber": {
            "maxLength": 20,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "address": {
            "maxLength": 200,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "city": {
            "maxLength": 100,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "state": {
            "maxLength": 50,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "postalCode": {
            "maxLength": 20,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          },
          "country": {
            "maxLength": 50,
            "minLength": 0,
            "type": [
              "null",
              "string"
            ]
          }
        }
      },
      "UpdateWebhookRequest": {
        "required": [
          "url",
          "events",
          "description",
          "isActive"
        ],
        "type": "object",
        "properties": {
          "url": {
            "type": [
              "null",
              "string"
            ]
          },
          "events": {
            "type": [
              "null",
              "array"
            ],
            "items": {
              "type": "string"
            }
          },
          "description": {
            "type": [
              "null",
              "string"
            ]
          },
          "isActive": {
            "type": [
              "null",
              "boolean"
            ]
          }
        }
      }
    },
    "securitySchemes": {
      "ApiKey": {
        "type": "apiKey",
        "description": "ProRanked public API key. Send it in the X-API-Key header on every request to the eMSP (/emsp/v1) and CPMS (/cpms/v1) APIs.",
        "name": "X-API-Key",
        "in": "header"
      },
      "Bearer": {
        "type": "http",
        "description": "Driver access token (JWT) obtained from /emsp/v1/auth/driver/login. Required IN ADDITION to the X-API-Key on eMSP write operations that act on a driver's own resources.",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      },
      "CpmsOperatorOAuth": {
        "type": "http",
        "description": "Operator OAuth (ProRanked Connect \"Shape 2\") — for backend-less CPMS SPAs. Sign the operator in at id.proranked.com (authorization_code + PKCE), then send the resulting role-scoped token as 'Authorization: Bearer <token>' (or 'DPoP <token>' if sender-constrained) on /cpms/v1 requests. An alternative to X-API-Key — no server-held secret required. See the OAuth guide for the full flow.",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      },
      "OCPIToken": {
        "type": "apiKey",
        "description": "OCPI Token Authorization header. Enter the token WITH the 'Token ' prefix.\r\nExample: Token test-token-1234567890abcdef1234567890abcdef1234567890abcdef1234567890\r\n\r\nTest tokens from seed data:\r\n- US Test EMSP: Token test-token-1234567890abcdef1234567890abcdef1234567890abcdef1234567890\r\n- EU EMSP: Token emsp-token-abcdef1234567890abcdef1234567890abcdef1234567890abcdef123456",
        "name": "Authorization",
        "in": "header"
      }
    }
  },
  "tags": [
    {
      "name": ".Well Known"
    },
    {
      "name": "Analytics"
    },
    {
      "name": "Auth"
    },
    {
      "name": "Chargers"
    },
    {
      "name": "Charging"
    },
    {
      "name": "Connectors"
    },
    {
      "name": "Events"
    },
    {
      "name": "Favorites"
    },
    {
      "name": "Invoices"
    },
    {
      "name": "Locations"
    },
    {
      "name": "Me Key"
    },
    {
      "name": "Networks"
    },
    {
      "name": "Notifications"
    },
    {
      "name": "Payments"
    },
    {
      "name": "Pricing"
    },
    {
      "name": "Push"
    },
    {
      "name": "Remote Control"
    },
    {
      "name": "Reports"
    },
    {
      "name": "Reservations"
    },
    {
      "name": "Smart Charging"
    },
    {
      "name": "Tariffs"
    },
    {
      "name": "Transactions"
    },
    {
      "name": "Users"
    },
    {
      "name": "Wallet"
    },
    {
      "name": "Webhooks"
    }
  ]
}
