{
  "openapi": "3.1.0",
  "info": {
    "title": "Akua API",
    "version": "1.0.0",
    "description": "Manage installs and their asynchronous operations. Authenticate with a session bearer token and select a Workspace using Akua-Context.",
    "contact": {
      "name": "Akua API support",
      "email": "support@akua.dev",
      "url": "https://docs.akua.dev/"
    }
  },
  "paths": {
    "/operations/{id}": {
      "get": {
        "tags": [
          "operations"
        ],
        "operationId": "operations.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 2,
              "maxLength": 192,
              "description": "Operation ID, `op_<id>`.",
              "examples": [
                "op_j572abc..."
              ]
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Operation details",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Returns the operation, answered by the resource that owns it. Visibility follows the owning resource. Clients poll this endpoint while `done` is false; when `done` flips true, `response` may carry the typed result (`SUCCEEDED`) and `error.message` carries a failure reason when available. Prefer `POST /v1/operations/{id}:wait` for sync \"wait until done\" semantics - it long-polls server-side instead of asking the client to tight-poll.\n\nThe owning resource answers directly, so the answer is never behind the Operation projection that `GET /v1/operations` reads. Terminal outcomes remain immutable.",
        "summary": "Get operation details",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/operations/{id}:wait": {
      "post": {
        "tags": [
          "operations"
        ],
        "operationId": "operations.wait",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 2,
              "maxLength": 192,
              "description": "Operation ID, `op_<id>`.",
              "examples": [
                "op_j572abc..."
              ]
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "timeout",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Max seconds to wait for the operation to reach a terminal state. Default 30, max 60.",
              "minimum": 1,
              "maximum": 60
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Operation in its latest known state (terminal or still running on timeout)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Long-polls server-side until the operation reaches a terminal state (`SUCCEEDED`, `FAILED`, `CANCELLED`) or the timeout elapses. Returns the latest `Operation` either way - check `done` to distinguish.\n\nThe owning resource answers with a bounded server-side wait; visibility follows it. A wait timeout returns the latest snapshot and does not cancel execution. Terminal outcomes remain immutable.",
        "summary": "Wait for an operation to reach a terminal state",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/operations/{id}:cancel": {
      "post": {
        "tags": [
          "operations"
        ],
        "operationId": "operations.cancel",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 2,
              "maxLength": 192,
              "description": "Operation ID, `op_<id>`.",
              "examples": [
                "op_j572abc..."
              ]
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "description": "Optional optimistic concurrency token for clients that track the latest operation revision.",
              "examples": [
                "WzQ1Njc="
              ],
              "minLength": 1,
              "maxLength": 64
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Cancellation requested; operation transition is in progress",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Requests cancellation of an in-flight operation. Cancellation is asynchronous: successful requests return the current operation envelope while the owning resource settles into a terminal result. Replaying the request with the same Idempotency-Key is supported. If the operation has already reached a terminal state, cancellation is rejected with 409 Conflict (code 7006) because it conflicts with the current state.\n\nAn accepted request has no fixed cancellation-completion deadline. Keep following GET or WAIT until the Operation is terminal; a WAIT timeout does not stop cancellation. Cancelling an Install update restores and confirms the last successful version before reporting CANCELLED; if restoration cannot be confirmed, the Operation and Install fail with rollback-unconfirmed. Cancelling Install creation deletes the Install: it first settles active writes and removes its Route and workload, then destroys its secrets and releases admission. CANCELLED is reported only after that cleanup completes. This can exceed three minutes: workload-removal acknowledgement alone allows a fifteen-minute grace period, and unavailable external services can delay required cleanup further. A deletion cannot be cancelled.",
        "summary": "Request operation cancellation",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/installs": {
      "post": {
        "tags": [
          "installs"
        ],
        "operationId": "installs.create",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Install intent accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Creates an installation of a Package version. Akua processes the installation in the background and returns an Operation envelope to poll for progress. Native Install references are available after durable acceptance without waiting for a catalog projection. Retry the same intent with the same Idempotency-Key to retrieve its original Operation.",
        "summary": "Create install",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateInstallBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "installs"
        ],
        "operationId": "installs.list",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Installs list",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InstallList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Lists installs in the current workspace, newest first.",
        "summary": "List installs",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/installs/{id}": {
      "delete": {
        "tags": [
          "installs"
        ],
        "operationId": "installs.delete",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Install ID",
              "examples": [
                "inst_j572abc123def456"
              ],
              "minLength": 1,
              "maxLength": 55
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          },
          {
            "name": "force",
            "in": "query",
            "schema": {
              "type": "boolean",
              "description": "Remove Akua-side state even if the Cluster cannot acknowledge workload removal. The Operation records any unconfirmed removal; unreachable workloads may remain on the Cluster.",
              "default": false
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Delete workflow started",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Deletes an Install and cleans up its Route, Placement, secrets and admission asynchronously. Supersedes an active update and waits for it to settle before cleanup. With force, removes Akua-side inventory without requiring a Ready node or a surviving Cluster and records unconfirmed workload removal in Operation steps. Retry deletion to recover the same Operation, including after completion.",
        "summary": "Delete install",
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "installs"
        ],
        "operationId": "installs.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Install ID",
              "examples": [
                "inst_j572abc123def456"
              ],
              "minLength": 1,
              "maxLength": 55
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Install details",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Install"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Returns current install metadata.",
        "summary": "Get install details",
        "x-platform-visibility": "PUBLIC"
      },
      "patch": {
        "tags": [
          "installs"
        ],
        "operationId": "installs.update",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 55
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Required caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": true
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Install update accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The idempotency key was already used for a different request. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Updates the Package version and/or inputs of one existing Install (AIP-134). Returns a long-running Operation. The Install identity, Route, namespace and volumes are retained. Concurrent updates conflict; deletion supersedes an update. Cancel the Operation to restore the last successful version; cancellation completes only after restoration is confirmed, otherwise the Install fails with rollback-unconfirmed. Retry the same intent and Idempotency-Key to recover its Operation even with the original If-Match. Other update failures retain the existing resources and a specific condition; no fleet update is performed.",
        "summary": "Update install",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateInstallBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/installs/{id}/inputs": {
      "get": {
        "tags": [
          "installs"
        ],
        "operationId": "installs.getInputs",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 55
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Non-secret persisted Install inputs",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InstallInputs"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Returns original non-secret configure inputs from the Install owner for recovery. Requires install.installs.get in the Install Workspace and access to the pinned Package schema. Does not read the vault or return secret values or references. Returns 422 instead of inputs when the schema no longer matches the original pin or its secrecy cannot be established safely, including indirect or applicator schemas.",
        "summary": "Get install inputs",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/organizations/{id}:getIamPolicy": {
      "get": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.getIamPolicy",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Organization ID, `org_<id>`."
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Policy",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Policy"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Bindings attached to the Organization; they apply to every Workspace in it. Members are the people bound here.",
        "summary": "Get an Organization policy",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/organizations/{id}:setIamPolicy": {
      "post": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.setIamPolicy",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Organization ID, `org_<id>`."
            },
            "required": true
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Policy",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Policy"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Replaces all bindings when `If-Match` is the current etag; removing a member removes their access. Only an owner adds or removes `roles/owner`, and the last owner stays (422). Requests in its Workspaces see the change within 30 seconds.",
        "summary": "Set an Organization policy",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetOrganizationIamPolicyRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/organizations": {
      "post": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.create",
        "parameters": [
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Organization created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Organization"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "409": {
            "description": "The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiIdempotencyConflict"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Creates an Organization. The authenticated person becomes its `roles/owner`. Retry with the same Idempotency-Key to receive the same Organization.",
        "summary": "Create organization",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OrganizationCreateRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.list",
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512,
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Organizations",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrganizationList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Lists the Organizations the caller holds a role in.",
        "summary": "List organizations",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/organizations/{id}": {
      "get": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Organization ID, `org_<id>`."
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Organization",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Organization"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Returns an Organization the caller holds a role in.",
        "summary": "Get organization",
        "x-platform-visibility": "PUBLIC"
      },
      "delete": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.delete",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Organization ID, `org_<id>`."
            },
            "required": true
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Organization deleted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Organization"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Soft-deletes an Organization (AIP-164): its invitations and policy are erased at once and it reads as `deleted` until `purge_at`. Refused with 409 while a Workspace remains in it.",
        "summary": "Delete organization",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/organizations/{id}/invitations": {
      "post": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.createInvitation",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Organization ID, `org_<id>`."
            },
            "required": true
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Invitation created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrganizationInvitation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Invites a person by email. Only the person who signs in with that verified email can accept it before `expire_at`, at `/v1/organizations/{id}/invitations/{invitation_id}:accept`. One pending invitation per email (409).",
        "summary": "Invite to organization",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OrganizationInvitationCreateRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.listInvitations",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Organization ID, `org_<id>`."
            },
            "required": true
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512,
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Invitations",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrganizationInvitationList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Lists an Organization's invitations.",
        "summary": "List organization invitations",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/organizations/{id}/invitations/{invitationId}:revoke": {
      "post": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.revokeInvitation",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Organization ID, `org_<id>`."
            },
            "required": true
          },
          {
            "name": "invitationId",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 55,
              "description": "Invitation ID, `orgi_<id>`."
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Invitation revoked",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrganizationInvitation"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiConflict"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Revokes a pending invitation. Revoking a revoked invitation answers it unchanged.",
        "summary": "Revoke organization invitation",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/organization_invitations": {
      "get": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.listMyInvitations",
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512,
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Pending invitations",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrganizationInvitationList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Lists the pending invitations sent to the verified email of the signed-in person.",
        "summary": "List my invitations",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/organizations/{id}/invitations/{invitationId}:accept": {
      "post": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.acceptInvitation",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Organization ID, `org_<id>`."
            },
            "required": true
          },
          {
            "name": "invitationId",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 55,
              "description": "Invitation ID, `orgi_<id>`."
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Invitation accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrganizationInvitation"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiConflict"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Accepts an invitation sent to the caller's verified email: the caller gets the invited role on the Organization. Accepting an accepted invitation answers it unchanged.",
        "summary": "Accept organization invitation",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/organizations/{id}/invitations/{invitationId}:decline": {
      "post": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.declineInvitation",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Organization ID, `org_<id>`."
            },
            "required": true
          },
          {
            "name": "invitationId",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 55,
              "description": "Invitation ID, `orgi_<id>`."
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Invitation declined",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrganizationInvitation"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiConflict"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Declines an invitation sent to the caller's verified email.",
        "summary": "Decline organization invitation",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/organization_invitations/accept": {
      "post": {
        "tags": [
          "Organizations"
        ],
        "operationId": "organizations.acceptInvitationToken",
        "parameters": [],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Invitation accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrganizationInvitation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiConflict"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Accepts the invitation whose emailed link carried `token`, for the signed-in person with the invited verified email.",
        "summary": "Accept organization invitation by link",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OrganizationInvitationTokenRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/billing_accounts": {
      "post": {
        "tags": [
          "Billing accounts"
        ],
        "operationId": "billingAccounts.create",
        "parameters": [
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Required caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "BillingAccount",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingAccount"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiIdempotencyConflict"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Starts `PENDING` with a card payment method and binds the caller as `roles/billing.admin` on the new account.",
        "summary": "Create a billing account",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateBillingAccountRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "Billing accounts"
        ],
        "operationId": "billingAccounts.list",
        "parameters": [
          {
            "name": "organization",
            "in": "query",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512
            },
            "required": false
          },
          {
            "name": "state",
            "in": "query",
            "schema": {
              "type": "string",
              "enum": [
                "PENDING",
                "ACTIVE",
                "CLOSED"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "BillingAccountList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingAccountList"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "The accounts the caller may read, optionally of one Organization. From the catalog projection; a change shows up within seconds.",
        "summary": "List billing accounts",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/billing_accounts/{billing_account}": {
      "get": {
        "tags": [
          "Billing accounts"
        ],
        "operationId": "billingAccounts.get",
        "parameters": [
          {
            "name": "billing_account",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "BillingAccount",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingAccount"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Always current.",
        "summary": "Get a billing account",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/billing_accounts/{billing_account}:startPaymentSetup": {
      "post": {
        "tags": [
          "Billing accounts"
        ],
        "operationId": "billingAccounts.startPaymentSetup",
        "parameters": [
          {
            "name": "billing_account",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54
            },
            "required": true
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "PaymentSetupSession",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PaymentSetupSession"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Returns a Stripe embedded Checkout session in setup mode for this account. Cards only: Apple Pay, Google Pay and Link are not offered. The card is verified, not charged. The account becomes `ACTIVE` when Stripe reports the setup complete; on an `ACTIVE` card account the new card replaces the old one. Limited per account; an invoice account answers 409.",
        "summary": "Start adding a card",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/billing_accounts/{billing_account}:close": {
      "post": {
        "tags": [
          "Billing accounts"
        ],
        "operationId": "billingAccounts.close",
        "parameters": [
          {
            "name": "billing_account",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54
            },
            "required": true
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "BillingAccount",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BillingAccount"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Final: a closed account cannot be reopened; create a new one. Linked Workspaces keep their resources but cannot create billed ones; link another account to continue.",
        "summary": "Close a billing account",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CloseBillingAccountRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/billing_accounts/{billing_account}:getIamPolicy": {
      "get": {
        "tags": [
          "Billing accounts"
        ],
        "operationId": "billingAccounts.getIamPolicy",
        "parameters": [
          {
            "name": "billing_account",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Policy",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Policy"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Bindings on the account. Organization bindings apply in addition.",
        "summary": "Get a billing account policy",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/billing_accounts/{billing_account}:setIamPolicy": {
      "post": {
        "tags": [
          "Billing accounts"
        ],
        "operationId": "billingAccounts.setIamPolicy",
        "parameters": [
          {
            "name": "billing_account",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54
            },
            "required": true
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Policy",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Policy"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Replaces all bindings; only `roles/billing.*` are grantable here.",
        "summary": "Set a billing account policy",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetIamPolicyRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/billing_accounts/{billing_account}:testIamPermissions": {
      "post": {
        "tags": [
          "Billing accounts"
        ],
        "operationId": "billingAccounts.testIamPermissions",
        "parameters": [
          {
            "name": "billing_account",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "TestIamPermissionsResponse",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TestIamPermissionsResponse"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Which of the permissions the caller holds on the account. Needs no permission itself.",
        "summary": "Test billing account permissions",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TestIamPermissionsRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/workspaces/{id}/billing_info": {
      "get": {
        "tags": [
          "Billing accounts"
        ],
        "operationId": "workspaces.getBillingInfo",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "WorkspaceBillingInfo",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorkspaceBillingInfo"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "The linked account and whether billing is enabled.",
        "summary": "Get Workspace billing",
        "x-platform-visibility": "PUBLIC"
      },
      "put": {
        "tags": [
          "Billing accounts"
        ],
        "operationId": "workspaces.updateBillingInfo",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53
            },
            "required": true
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "WorkspaceBillingInfo",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorkspaceBillingInfo"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Needs `billing.associations.create` on the account too. The account must be in the Workspace Organization and not `CLOSED`; a `PENDING` account may be linked and enables billing once it is `ACTIVE`.",
        "summary": "Link a billing account",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateWorkspaceBillingInfoRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/workspaces": {
      "get": {
        "tags": [
          "workspaces"
        ],
        "operationId": "workspaces.list",
        "parameters": [
          {
            "name": "organization",
            "in": "query",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 54,
              "description": "Filter by owning organization. Requires membership."
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Workspace list",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorkspaceList"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          }
        },
        "description": "Returns workspaces visible within the authenticated request scope. An unscoped user credential sees all of its workspaces; a workspace-scoped request sees only that workspace.",
        "summary": "List workspaces",
        "x-platform-visibility": "PUBLIC"
      },
      "post": {
        "tags": [
          "workspaces"
        ],
        "operationId": "workspaces.create",
        "parameters": [
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Workspace created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Workspace"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Creates a workspace in the named Organization; you must be an owner or admin of it and become the workspace owner. An Idempotency-Key is scoped to that user. Reusing it with the same request returns the existing Workspace in its current state; a different request returns 409/7015. Keys do not expire; replay remains available until the Workspace is permanently deleted.",
        "summary": "Create workspace",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "organization": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 54,
                    "description": "The Organization the Workspace is created in (its parent). Required: the server picks none. You must be an owner or admin of it. Clients may default it, as the dashboard does from its current Organization and the CLI from its configuration."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100,
                    "pattern": "^(?=.*\\S)[^\\p{Cc}\\p{Zl}\\p{Zp}]+$"
                  },
                  "slug": {
                    "type": "string",
                    "minLength": 3,
                    "maxLength": 39
                  }
                },
                "required": [
                  "organization",
                  "name"
                ],
                "additionalProperties": false
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/workspaces/{id}": {
      "get": {
        "tags": [
          "workspaces"
        ],
        "operationId": "workspaces.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Workspace ID",
              "minLength": 1,
              "maxLength": 53
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Workspace details",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Workspace"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          }
        },
        "description": "Returns the details of a workspace.",
        "summary": "Get workspace",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/regions": {
      "get": {
        "tags": [
          "regions"
        ],
        "operationId": "regions.list",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "List of regions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RegionList"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          }
        },
        "description": "Returns all regions belonging to the workspace specified in the workspace context.",
        "summary": "List regions in workspace",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/products": {
      "get": {
        "tags": [
          "products"
        ],
        "operationId": "products.list",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "List of products",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProductResourceList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          }
        },
        "description": "Returns the Products of the Akua-Context Workspace a page at a time, in a stable order; pass `next_cursor` as `cursor` for the next page.",
        "summary": "List products in workspace",
        "x-platform-visibility": "PUBLIC"
      },
      "post": {
        "tags": [
          "products"
        ],
        "operationId": "products.create",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Product created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProductResource"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiConflict"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          }
        },
        "description": "Creates a Product in the Akua-Context Workspace from a published version of one of its Packages. Offers sell the Product at exactly that version. Retry with the same Idempotency-Key to receive the same Product.",
        "summary": "Create product",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateProductRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/products/{id}": {
      "get": {
        "tags": [
          "products"
        ],
        "operationId": "products.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Product ID",
              "examples": [
                "prod_j572abc..."
              ],
              "minLength": 1,
              "maxLength": 55
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Product details",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProductResource"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          }
        },
        "description": "Returns a Product of a Workspace you belong to, with its pinned Package version.",
        "summary": "Get product details",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/products/{id}:archive": {
      "post": {
        "tags": [
          "products"
        ],
        "operationId": "products.archive",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Product ID",
              "examples": [
                "prod_j572abc..."
              ],
              "minLength": 1,
              "maxLength": 55
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Product archived",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProductResource"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiPreconditionFailed"
                }
              }
            }
          }
        },
        "description": "Archives the Product: no new Offers are made for it. Existing Offers and Installs are unaffected. Send the etag you read as If-Match; an archived Product answers unchanged.",
        "summary": "Archive product",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/offers": {
      "get": {
        "tags": [
          "offers"
        ],
        "operationId": "offers.list",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          },
          {
            "name": "product_id",
            "in": "query",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 55
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "List of offers",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OfferSummaryList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          }
        },
        "description": "Returns the Offers of the Akua-Context Workspace, optionally of one Product, a page at a time in a stable order; pass `next_cursor` as `cursor` for the next page.",
        "summary": "List offers in workspace",
        "x-platform-visibility": "PUBLIC"
      },
      "post": {
        "tags": [
          "offers"
        ],
        "operationId": "offers.create",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Offer created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OfferResource"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiConflict"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          }
        },
        "description": "Creates an Offer for an active Product of the Akua-Context Workspace: its pinned Package version, at no charge, for an audience and a number of customer Workspaces. Share `url`; a customer who redeems it gets access to the Package version with the locked values. Retry with the same Idempotency-Key to receive the same Offer.",
        "summary": "Create offer",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateOfferRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/offers/{id}": {
      "get": {
        "tags": [
          "offers"
        ],
        "operationId": "offers.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Offer ID",
              "examples": [
                "offer_j572abc..."
              ],
              "minLength": 1,
              "maxLength": 56
            },
            "required": true
          },
          {
            "name": "view",
            "in": "query",
            "schema": {
              "type": "string",
              "enum": [
                "public",
                "basic",
                "full"
              ],
              "description": "`public` is what anyone with the link sees, also without a session (only for an Offer open to anyone signed in); `basic` (the default when signed in) is what a customer the Offer is for may see; `full` is for members of the seller Workspace. Without a session the answer is `public`."
            },
            "required": false
          }
        ],
        "security": [
          {},
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Offer details",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OfferViewResource"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          }
        },
        "description": "Returns an Offer. Without a session, an Offer open to anyone signed in shows its public view; an email-restricted one answers 401 until you sign in. A customer it is for sees the basic view while it can be redeemed; archived or expired Offers answer 410 to them. Members of the seller Workspace may read the full view.",
        "summary": "Get offer details",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/offers:resolve": {
      "get": {
        "tags": [
          "offers"
        ],
        "operationId": "offers.resolve",
        "parameters": [
          {
            "name": "short_hash",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Offer short hash from the customer link `/i/<short_hash>`",
              "pattern": "^[0-9A-Za-z]{8}$"
            },
            "required": true
          }
        ],
        "security": [
          {},
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Offer resolved",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OfferResolution"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          }
        },
        "description": "Answers the ID of the Offer a customer link names (AIP-122 alias), when the caller may see it: without a session only for an Offer open to anyone signed in. Read it with Get offer.",
        "summary": "Resolve offer by short hash",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/offers/{id}:archive": {
      "post": {
        "tags": [
          "offers"
        ],
        "operationId": "offers.archive",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Offer ID",
              "examples": [
                "offer_j572abc..."
              ],
              "minLength": 1,
              "maxLength": 56
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Offer archived",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OfferResource"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiPreconditionFailed"
                }
              }
            }
          }
        },
        "description": "Archives the Offer: nobody can redeem it any more. Redemptions already made keep their access. Send the etag you read as If-Match; an archived Offer answers unchanged.",
        "summary": "Archive offer",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/order_drafts": {
      "post": {
        "tags": [
          "Order Drafts"
        ],
        "operationId": "orderDrafts.create",
        "parameters": [
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Order draft created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrderDraft"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Starts redeeming an Offer for the signed-in customer, from its ID or the short hash of its link. Any draft field may be set now or later, in any order. The answer lists what is still `missing` and the `problems` to fix. Retrying with the same Idempotency-Key answers the same draft.",
        "summary": "Create order draft",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateOrderDraftBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/order_drafts/{id}": {
      "get": {
        "tags": [
          "Order Drafts"
        ],
        "operationId": "orderDrafts.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Order draft ID",
              "examples": [
                "odft_j572abc..."
              ],
              "minLength": 1,
              "maxLength": 55
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Order draft, with what is missing and wrong now",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrderDraft"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          }
        },
        "description": "Returns the customer's own order draft. `missing` and `problems` are computed from the Offer, the Workspace and the Cluster at the time of the request.",
        "summary": "Get order draft",
        "x-platform-visibility": "PUBLIC"
      },
      "patch": {
        "tags": [
          "Order Drafts"
        ],
        "operationId": "orderDrafts.update",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Order draft ID",
              "examples": [
                "odft_j572abc..."
              ],
              "minLength": 1,
              "maxLength": 55
            },
            "required": true
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Order draft updated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrderDraft"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Sets the fields present in the body and keeps the others; the fields can be set in any order. Only a `draft` before `expires_at` changes (410 after). A new Workspace is created at once.",
        "summary": "Update order draft",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateOrderDraftBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/order_drafts/{id}:redeem": {
      "post": {
        "tags": [
          "Order Drafts"
        ],
        "operationId": "orderDrafts.redeem",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Order draft ID",
              "examples": [
                "odft_j572abc..."
              ],
              "minLength": 1,
              "maxLength": 55
            },
            "required": true
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Offer redeemed and Install started",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrderDraft"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Checks the draft and the sensitive values together (422 names what is missing or wrong, and nothing changes), then redeems the Offer into the Workspace and creates the Install with the Offer's pinned Package version. The answer is `installing` with `install_id` and `operation_id`. A retry resumes the same redemption and Install whatever its Idempotency-Key; resend the sensitive values with it (an Install already created keeps the ones it was created with).",
        "summary": "Redeem order draft",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RedeemOrderDraftBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/order_drafts/{id}:cancel": {
      "post": {
        "tags": [
          "Order Drafts"
        ],
        "operationId": "orderDrafts.cancel",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Order draft ID",
              "examples": [
                "odft_j572abc..."
              ],
              "minLength": 1,
              "maxLength": 55
            },
            "required": true
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Order draft cancelled",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OrderDraft"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          }
        },
        "description": "Ends a `draft`. Once `:redeem` started the draft cannot be cancelled (409), because the redemption may already be spent. Cancelling a cancelled draft answers it unchanged.",
        "summary": "Cancel order draft",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/packages": {
      "post": {
        "tags": [
          "packages"
        ],
        "operationId": "packages.create",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Package created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PackageResource"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiConflict"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Creates a private Package in the Akua-Context Workspace, hosted at Akua or imported from an external OCI repository. It holds no versions yet; publish each with Create package version. Retry with the same Idempotency-Key to receive the same Package.",
        "summary": "Create package",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePackageRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/packages/{id}": {
      "get": {
        "tags": [
          "packages"
        ],
        "operationId": "packages.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 54
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Package details",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PackageResource"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          }
        },
        "description": "Returns a Package of a Workspace you belong to, with its versions. With Akua-Context, also returns a Package granted to that Workspace and all its published versions, including versions published after redemption.",
        "summary": "Get package details",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/packages/{id}/versions": {
      "post": {
        "tags": [
          "packages"
        ],
        "operationId": "packages.createVersion",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Package ID",
              "examples": [
                "pkg_j572abc123def456"
              ],
              "minLength": 1,
              "maxLength": 54
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Package version publication accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiConflict"
                }
              }
            }
          }
        },
        "description": "Publishes one version from the private hosted repository or external OCI source, verifies its digest and records its format, input schema and defaults. Push hosted archive bytes before calling this action. Poll the returned Operation until it is done. A version number is published once; retry with the same Idempotency-Key to receive the same Operation.",
        "summary": "Create package version",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePackageVersionRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/packages/{id}/versions/{version_id}/inputs": {
      "get": {
        "tags": [
          "packages"
        ],
        "operationId": "packages.getVersionInputs",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 54
            },
            "required": true
          },
          {
            "name": "version_id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 55
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Package version input schema",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PackageVersionInputs"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          }
        },
        "description": "Returns the version input schema used by the install wizard, typically generated JSON Schema.",
        "summary": "Get package version input schema",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/packages/{id}/grants": {
      "get": {
        "tags": [
          "packages"
        ],
        "operationId": "packages.listGrants",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Package ID",
              "examples": [
                "pkg_j572abc123def456"
              ],
              "minLength": 1,
              "maxLength": 54
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512,
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Grants per page (1-100, default 50)",
              "default": 50,
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Grants, newest first",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PackageGrantList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          }
        },
        "description": "Lists the customer Workspaces that hold a grant to your Package, newest grant first: each Workspace ID, the version it redeemed, the Offer and redemption time that granted it, and when. Use the Workspace ID to revoke a grant. Requires package.grants.list in the Package's Workspace.",
        "summary": "List package grants",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/packages/{id}/grants/{workspace_id}": {
      "delete": {
        "tags": [
          "packages"
        ],
        "operationId": "packages.revokeGrant",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "description": "Package ID",
              "examples": [
                "pkg_j572abc123def456"
              ],
              "minLength": 1,
              "maxLength": 54
            },
            "required": true
          },
          {
            "name": "workspace_id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 2,
              "maxLength": 53,
              "description": "The customer Workspace that holds the grant.",
              "examples": [
                "ws_9177x8shcx0niswcn"
              ]
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "204": {
            "description": "Grant revoked"
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          }
        },
        "description": "Ends a customer Workspace's access to your Package, which an Offer redemption granted. From then on the Workspace can no longer read, resolve or install any version of it, and redeeming the same Offer again grants nothing. Installs already running keep running unchanged and remain the customer's to delete; they can no longer be updated or have their inputs read. Another Offer for the Package that the Workspace redeems later grants access again; archive the Offers it should not redeem. Retry with the same Idempotency-Key to receive the same answer; a Workspace without a grant answers 404.",
        "summary": "Revoke package grant",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/api_tokens": {
      "get": {
        "tags": [
          "API Tokens"
        ],
        "operationId": "apiTokens.list",
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Your API tokens, newest first",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTokenList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          }
        },
        "description": "Returns metadata for your own API tokens. Full token values are never shown after creation.",
        "summary": "List API tokens",
        "x-platform-visibility": "PUBLIC"
      },
      "post": {
        "tags": [
          "API Tokens"
        ],
        "operationId": "apiTokens.create",
        "parameters": [],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Token created. The `token` field is shown only once.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreatedApiToken"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          }
        },
        "description": "Creates an API token that acts as you, optionally limited to one Workspace and to a ceiling of IAM roles. Requires a signed-in session; an API token cannot create another. The full plaintext token is returned once and never shown again - store it securely.",
        "summary": "Create an API token",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateApiTokenRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/api_tokens/{id}": {
      "get": {
        "tags": [
          "API Tokens"
        ],
        "operationId": "apiTokens.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "API token ID.",
              "examples": [
                "tok_3k9x2mfq8a1b7c4d5e6f"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Token metadata",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiToken"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          }
        },
        "description": "Returns the metadata of one of your API tokens.",
        "summary": "Get an API token",
        "x-platform-visibility": "PUBLIC"
      },
      "delete": {
        "tags": [
          "API Tokens"
        ],
        "operationId": "apiTokens.revoke",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "API token ID.",
              "examples": [
                "tok_3k9x2mfq8a1b7c4d5e6f"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "204": {
            "description": "Token revoked"
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          }
        },
        "description": "Revokes one of your API tokens. It stops authenticating requests immediately.",
        "summary": "Revoke an API token",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/feedback": {
      "post": {
        "tags": [
          "Feedback"
        ],
        "operationId": "feedback.create",
        "parameters": [],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "The message reached the Akua team. The receipt shows what was sent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FeedbackReceipt"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Sends a message to the Akua team. It is attributed to the person the credential belongs to, never to a user named in the request. The message is delivered to a private team channel with your user ID, your account email and the `User-Agent` of your client (for the Akua CLI: its version, your operating system and architecture, and the Bun version); nothing else is attached. Each person may send a few messages per minute.",
        "summary": "Send feedback to the Akua team",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateFeedbackRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/registry/upstreams": {
      "post": {
        "tags": [
          "Registry"
        ],
        "operationId": "registry.createUpstream",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "upstream_id",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/UpstreamId"
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Upstream created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Upstream"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "summary": "Connect an image registry",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateUpstream"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "Registry"
        ],
        "operationId": "registry.listUpstreams",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 128
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Upstream"
                      }
                    },
                    "has_more": {
                      "type": "boolean"
                    },
                    "next_cursor": {
                      "anyOf": [
                        {
                          "type": "string"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "data",
                    "has_more",
                    "next_cursor"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "summary": "List Upstreams",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/registry/upstreams/{upstream}": {
      "get": {
        "tags": [
          "Registry"
        ],
        "operationId": "registry.getUpstream",
        "parameters": [
          {
            "name": "upstream",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/UpstreamId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Upstream",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Upstream"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "summary": "Get an Upstream",
        "x-platform-visibility": "PUBLIC"
      },
      "delete": {
        "tags": [
          "Registry"
        ],
        "operationId": "registry.deleteUpstream",
        "parameters": [
          {
            "name": "upstream",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/UpstreamId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Upstream",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Upstream"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "summary": "Delete an Upstream",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/registry/upstreams/{upstream}:test": {
      "post": {
        "tags": [
          "Registry"
        ],
        "operationId": "registry.testUpstream",
        "parameters": [
          {
            "name": "upstream",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/UpstreamId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "ResolvedImage",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResolvedImage"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "summary": "Test an Upstream pull",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/registry/upstreams/{upstream}:resolveImage": {
      "post": {
        "tags": [
          "Registry"
        ],
        "operationId": "registry.resolveImage",
        "parameters": [
          {
            "name": "upstream",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/UpstreamId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "ResolvedImage",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResolvedImage"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "summary": "Resolve an image to its Akua path",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "image": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 1024
                  }
                },
                "required": [
                  "image"
                ],
                "additionalProperties": false
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/registry/images:check": {
      "post": {
        "tags": [
          "Registry"
        ],
        "operationId": "registry.checkImages",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "images": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "image": {
                            "type": "string"
                          },
                          "state": {
                            "type": "string",
                            "enum": [
                              "public",
                              "resolved",
                              "failed"
                            ]
                          },
                          "digest": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "message": {
                            "anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "required": [
                          "image",
                          "state",
                          "digest",
                          "message"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "images"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "summary": "Check images before publishing",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "images": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 1024
                    },
                    "maxItems": 256
                  }
                },
                "required": [
                  "images"
                ],
                "additionalProperties": false
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/workspaces/{id}/services": {
      "get": {
        "tags": [
          "Workspace services"
        ],
        "operationId": "workspaces.listServices",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "WorkspaceServiceList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorkspaceServiceList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Every product service with its state and what keeps it from creating resources now. Existing resources keep working.",
        "summary": "List Workspace services",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/connections": {
      "get": {
        "tags": [
          "Vault connections"
        ],
        "operationId": "connections.list",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "VaultConnectionList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VaultConnectionList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "No credentials.",
        "summary": "List connections",
        "x-platform-visibility": "PUBLIC"
      },
      "post": {
        "tags": [
          "Vault connections"
        ],
        "operationId": "connections.create",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "VaultConnection",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VaultConnection"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "`PENDING_CONSENT` until a key is set with `:setCredential` or OAuth consent completes.",
        "summary": "Create a connection",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateVaultConnectionRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/connections/{connection}": {
      "get": {
        "tags": [
          "Vault connections"
        ],
        "operationId": "connections.get",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "connection",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/ConnectionId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "VaultConnection",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VaultConnection"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "No credentials.",
        "summary": "Get a connection",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/connections/{connection}:setCredential": {
      "post": {
        "tags": [
          "Vault connections"
        ],
        "operationId": "connections.setCredential",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "connection",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/ConnectionId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "VaultConnection",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VaultConnection"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Stores the key in the vault, verified with the provider first. It is only ever injected into requests, never returned.",
        "summary": "Set a connection credential",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetConnectionCredentialRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/connections/{connection}:revoke": {
      "post": {
        "tags": [
          "Vault connections"
        ],
        "operationId": "connections.revoke",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "connection",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/ConnectionId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "VaultConnection",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VaultConnection"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Denies use at once.",
        "summary": "Revoke a connection",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/connections/{connection}:getIamPolicy": {
      "get": {
        "tags": [
          "Vault connections"
        ],
        "operationId": "connections.getIamPolicy",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "connection",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/ConnectionId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Policy",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Policy"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "The bindings attached to this connection.",
        "summary": "Get a connection policy",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/connections/{connection}:setIamPolicy": {
      "post": {
        "tags": [
          "Vault connections"
        ],
        "operationId": "connections.setIamPolicy",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "connection",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/ConnectionId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Policy",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Policy"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Replaces the bindings attached to this connection.",
        "summary": "Set a connection policy",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetIamPolicyRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/connections/{connection}:testIamPermissions": {
      "post": {
        "tags": [
          "Vault connections"
        ],
        "operationId": "connections.testIamPermissions",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "connection",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/ConnectionId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "TestIamPermissionsResponse",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TestIamPermissionsResponse"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Returns the requested permissions the caller holds.",
        "summary": "Test connection permissions",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TestIamPermissionsRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}/join_info": {
      "get": {
        "tags": [
          "clusterJoin"
        ],
        "operationId": "clusters.getJoinInfo",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          }
        ],
        "security": [],
        "responses": {
          "200": {
            "description": "Public worker bootstrap discovery",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClusterJoinInfo"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Unauthenticated TLS discovery for join.sh. Returns only the public CA certificate, Kubernetes API endpoint, controller version and the image credential provider digests. No credentials, private keys or Workspace metadata. Unavailable for attached, unready or deleted Clusters.",
        "summary": "Get public Cluster join information",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}:reportJoinBootstrap": {
      "post": {
        "tags": [
          "joinBootstrap"
        ],
        "operationId": "clusters.reportJoinBootstrap",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          }
        ],
        "security": [
          {
            "JoinBootstrapBearer": []
          }
        ],
        "responses": {
          "200": {
            "description": "<No Content>"
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Guest-only diagnostic, authenticated by the active unexpired bootstrap token for this Cluster. Records only a fixed bootstrap step, reason and exit code in API logs. Does not enroll a Node or change Cluster readiness. Never send command output or credentials in the body.",
        "summary": "Report a customer-server join failure",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/JoinBootstrapReport"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters": {
      "get": {
        "tags": [
          "clusters"
        ],
        "operationId": "clusters.list",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Clusters, newest first",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClusterList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Lists the Clusters of the selected Workspace, newest first.",
        "summary": "List Clusters",
        "x-platform-visibility": "PUBLIC"
      },
      "post": {
        "tags": [
          "clusters"
        ],
        "operationId": "clusters.create",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Cluster creation accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Creates a hosted Cluster in a Region or attaches an existing one, and returns the creation Operation. It succeeds once the Cluster is ready. For an attached Cluster, issue the agent install command next. Retry with the same Idempotency-Key to get the same Cluster and Operation.",
        "summary": "Create a Cluster",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ClusterCreateBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}": {
      "get": {
        "tags": [
          "clusters"
        ],
        "operationId": "clusters.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "The Cluster",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Cluster"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "summary": "Get a Cluster",
        "x-platform-visibility": "PUBLIC"
      },
      "delete": {
        "tags": [
          "clusters"
        ],
        "operationId": "clusters.delete",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          },
          {
            "name": "force",
            "in": "query",
            "schema": {
              "type": "boolean",
              "description": "Delete remaining Installs and app Placements before completing Cluster deletion.",
              "default": false
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Cluster deletion accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Removes what Akua placed on the Cluster and the Cluster itself. Refused with 409 while Installs remain unless force=true explicitly requests cascading deletion. A repeated delete returns the same Operation.",
        "summary": "Delete a Cluster",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}/connector_install": {
      "post": {
        "tags": [
          "clusters"
        ],
        "operationId": "clusters.issueConnectorInstall",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "ClusterConnector install command",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClusterConnectorInstall"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Connected Clusters: a Helm command that installs or repairs the ClusterConnector with the access you grant. Each call invalidates the previous command.",
        "summary": "Issue the ClusterConnector install command",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "access": {
                    "$ref": "#/components/schemas/ClusterAccess"
                  }
                },
                "required": [
                  "access"
                ],
                "additionalProperties": false
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}/join_tokens": {
      "post": {
        "tags": [
          "clusters"
        ],
        "operationId": "clusters.createJoinToken",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Join token and its join command",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClusterJoinCommand"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Hosted Clusters: a token and the command that joins a server as a node. The command is returned only here.",
        "summary": "Create a join token",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "ttl_seconds": {
                    "type": "integer",
                    "description": "Lifetime of the token in seconds. A token is for one server: 15 minutes after its first use it expires, whatever is left of this lifetime.",
                    "minimum": 60,
                    "maximum": 86400
                  }
                },
                "required": [
                  "ttl_seconds"
                ],
                "additionalProperties": false
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "clusters"
        ],
        "operationId": "clusters.listJoinTokens",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Join tokens, newest first",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClusterJoinTokenList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "summary": "List join tokens",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}/capabilities": {
      "get": {
        "tags": [
          "clusters"
        ],
        "operationId": "clusters.listCapabilities",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "The Cluster’s capabilities",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClusterAddonList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "The platform-owned components of the Cluster (tunnel connector, private ingress gateway, storage, metrics) with the release each runs.",
        "summary": "List capabilities",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}/join_tokens/{token_id}": {
      "delete": {
        "tags": [
          "clusters"
        ],
        "operationId": "clusters.revokeJoinToken",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "token_id",
            "in": "path",
            "schema": {
              "type": "string",
              "pattern": "^[a-z0-9]{6}$"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Join token revocation accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Revocation invalidates the join token generation on acceptance. Kubernetes may cache a successful authentication for at most 10 seconds, so a just-revoked token can still join within that window; subsequent authentication is refused even if old credential material remains. The Operation confirms invalidation and credential cleanup. Existing Nodes stay; remove them with nodes.remove. Idempotent; retry a failed revocation with a new idempotency key.",
        "summary": "Revoke a join token",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}/node_pools": {
      "get": {
        "tags": [
          "Node pools"
        ],
        "operationId": "nodePools.list",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Node pools, by ID",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NodePoolList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "summary": "List node pools",
        "x-platform-visibility": "PUBLIC"
      },
      "post": {
        "tags": [
          "Node pools"
        ],
        "operationId": "nodePools.create",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "node_pool_id",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/NodePoolId"
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Node pool creation accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Hosted Clusters. Creates `node_count` Machines of `machine_type` in the Cluster’s Region, each joined as a node, and returns the creation Operation; it succeeds once every node is ready. Machine creation needs an active billing account; the first `cx23` of a person is the free trial. An unknown machine type or location is refused here (400, 422). Billing, quota and provider refusals fail the Operation instead: `error.reason` is `billing-required`, `quota-exceeded`, `service-disabled` or `provider-refused`, and `error.message` says what to do. Adding one Akua server is a pool of size 1.",
        "summary": "Create a node pool",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateNodePoolBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}/node_pools/{node_pool_id}": {
      "get": {
        "tags": [
          "Node pools"
        ],
        "operationId": "nodePools.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "node_pool_id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/NodePoolId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "The node pool",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NodePool"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "summary": "Get a node pool",
        "x-platform-visibility": "PUBLIC"
      },
      "delete": {
        "tags": [
          "Node pools"
        ],
        "operationId": "nodePools.delete",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "node_pool_id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/NodePoolId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Node pool deletion accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Drains its nodes (PodDisruptionBudgets honoured, bounded), removes them and deletes their Machines. A repeated delete returns the same Operation.",
        "summary": "Delete a node pool",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}/node_pools/{node_pool_id}:setSize": {
      "post": {
        "tags": [
          "Node pools"
        ],
        "operationId": "nodePools.setSize",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "node_pool_id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/NodePoolId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Size change accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Adds Machines or drains and deletes nodes, newest first, until the pool has `node_count` nodes.",
        "summary": "Resize a node pool",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetNodePoolSizeBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}/nodes": {
      "get": {
        "tags": [
          "Nodes"
        ],
        "operationId": "nodes.list",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          },
          {
            "name": "node_pool_id",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/NodePoolId"
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Nodes, by name",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NodeList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "summary": "List nodes",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/clusters/{id}/nodes/{name}": {
      "get": {
        "tags": [
          "Nodes"
        ],
        "operationId": "nodes.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "name",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 253,
              "pattern": "^[a-z0-9](?:[-a-z0-9.]*[a-z0-9])?$"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "The node",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Node"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "summary": "Get a node",
        "x-platform-visibility": "PUBLIC"
      },
      "delete": {
        "tags": [
          "Nodes"
        ],
        "operationId": "nodes.remove",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54,
              "description": "Cluster ID"
            },
            "required": true
          },
          {
            "name": "name",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 253,
              "pattern": "^[a-z0-9](?:[-a-z0-9.]*[a-z0-9])?$"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Node removal accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "500": {
            "description": "The server failed to handle the request.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiInternalServerError"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "A joined server: cordons and drains the node (PodDisruptionBudgets honoured, bounded), then removes it from the Cluster; the server is left running. A node pool’s node answers 422: resize its pool instead.",
        "summary": "Remove a node",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/machines/{id}:reportBootstrap": {
      "post": {
        "tags": [
          "machineBootstrap"
        ],
        "operationId": "machineBootstrap.reportBootstrap",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54
            },
            "required": true
          }
        ],
        "security": [
          {
            "MachineBootstrapBearer": []
          }
        ],
        "responses": {
          "200": {
            "description": "<No Content>"
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          }
        },
        "description": "Guest-only bootstrap progress. Authenticate with the per-Machine bootstrap bearer from user data, not a session. Authority expires after one hour or the first joined/failed report. Send only a safe step description, never environment, tokens or command output. Messages are truncated and unrecognized descriptions omitted.",
        "summary": "Report machine bootstrap",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MachineBootstrapReport"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/machines/{id}": {
      "get": {
        "tags": [
          "machines"
        ],
        "operationId": "machines.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string",
              "minLength": 3,
              "maxLength": 54
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Machine details",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Machine"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          }
        },
        "description": "Returns a machine by ID.",
        "summary": "Get machine",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/machines": {
      "get": {
        "tags": [
          "machines"
        ],
        "operationId": "machines.list",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          },
          {
            "name": "state",
            "in": "query",
            "schema": {
              "type": "string",
              "enum": [
                "PROVISIONING",
                "RUNNING",
                "SUSPENDING",
                "SUSPENDED",
                "RESTORING",
                "EXPIRED",
                "DELETING",
                "FAILED"
              ],
              "description": "Machine lifecycle state."
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Machine list",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MachineList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          }
        },
        "description": "Lists the Machines of the Workspace, including those its node pools created (`created_by`).",
        "summary": "List machines",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.create",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Sandbox creation started",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Creates a Workspace sandbox and returns an Operation; the sandbox is `PROVISIONING` until the Operation finishes and `ACTIVE` afterwards. The caller gets the `manage` permission. With `source.type: \"sandbox\"` the new sandbox is a copy of that sandbox from its latest snapshot; the source must be `SUSPENDED`. Retrying with the same Idempotency-Key returns the same Operation.",
        "summary": "Create a sandbox",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateSandboxBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.list",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512,
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          },
          {
            "name": "state",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/SandboxState"
            },
            "required": false
          },
          {
            "name": "opencode",
            "in": "query",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 100,
              "description": "Only sandboxes this OpenCode Server (`oc_...`) has a grant on."
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Sandboxes visible through the caller’s own grant or a grant to every current Workspace member, newest first.",
        "summary": "List sandboxes",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}": {
      "get": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Sandbox",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Sandbox"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "One sandbox the caller has a grant on.",
        "summary": "Get a sandbox",
        "x-platform-visibility": "PUBLIC"
      },
      "patch": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.update",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Sandbox",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Sandbox"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Changes name, size, network policy, idle timeout or labels. Requires `manage`. A new idle timeout applies from the next activity.",
        "summary": "Update a sandbox",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateSandboxBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "delete": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.delete",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Sandbox deletion started",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Deletes the sandbox, its files, running processes and command history, and returns an Operation. Requires `manage`. OpenCode sessions that used the sandbox keep their history; their next tool call that needs it gets an error saying the sandbox no longer exists. A new delete is not supported yet because the sandbox's quota cannot be released safely and answers 422; idle and orphan cleanup continue.",
        "summary": "Delete a sandbox",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:suspend": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.suspend",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Sandbox suspend started",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Snapshots the whole sandbox, including its files and the memory of running processes, and stops it, returning an Operation. A suspended sandbox costs only storage. Requires `manage`. While suspended, commands, file operations and terminals are unavailable until it is resumed. Sandboxes also suspend themselves after `idle_timeout_seconds` without activity.",
        "summary": "Suspend a sandbox",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:resume": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.resume",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Sandbox resume started",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Restores a suspended sandbox from its snapshot, with files and the processes that were running, and returns an Operation. Requires `manage`, `run_commands` or `files`. Network connections that were open at suspend time are closed.",
        "summary": "Resume a sandbox",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:fork": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.fork",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Sandbox fork started",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Creates a new sandbox from this sandbox’s latest snapshot and returns the new sandbox’s creation Operation. The source must be `SUSPENDED`; it cannot be resumed or deleted until the copy has been taken. Requires `files` on the source; the caller gets `manage` on the copy, which keeps the source’s size, network policy, idle timeout and environment.",
        "summary": "Fork a sandbox",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ForkSandboxBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}/commands": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.runCommand",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Command started",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxCommand"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Starts a command and returns it. With `wait: true` the response comes when the command finished, for at most 60 seconds, and includes its output. Requires `run_commands`. Environment: the sandbox's `env`, then the request's. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Run a command",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RunSandboxCommandBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.listCommands",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512,
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          },
          {
            "name": "state",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/SandboxCommandState"
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxCommandList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxCommandList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Commands run in the sandbox, newest first. Works in every sandbox state. Requires `run_commands`.",
        "summary": "List commands",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}/commands/{command_id}": {
      "get": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.getCommand",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "command_id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxCommandId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxCommand",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxCommand"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "One command with its state and exit code. Requires `run_commands`.",
        "summary": "Get a command",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}/commands/{command_id}/logs:stream": {
      "get": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.streamCommandLogs",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "command_id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxCommandId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "offset",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "description": "Resume from this output byte offset. Default 0.",
              "default": 0
            },
            "required": false
          },
          {
            "name": "follow",
            "in": "query",
            "schema": {
              "type": "boolean",
              "description": "Keep the stream open until the command finished. Default true.",
              "default": true
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/x-ndjson": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                },
                "x-effect-stream": {
                  "encoding": "uint8array"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Newline-delimited JSON `SandboxCommandLogRecord` values (`{ stream, data, offset }`) in output order. Reconnect with `?offset=` to continue where a stream broke off. Requires `run_commands`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Stream command output",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}/commands/{command_id}:cancel": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.cancelCommand",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "command_id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxCommandId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxCommand",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxCommand"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Stops a running command (SIGTERM, then SIGKILL after 5 seconds) and returns it. A finished command is returned unchanged. Requires `run_commands`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Cancel a command",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}/commands/{command_id}:writeStdin": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.writeCommandStdin",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "command_id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxCommandId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "204": {
            "description": "<No Content>"
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Writes text to the standard input of a command started with `stdin: true`. Requires `run_commands`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Write command input",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WriteSandboxStdinBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:readFile": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.readFile",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/octet-stream": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                },
                "x-effect-stream": {
                  "encoding": "uint8array"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "The raw bytes of one file, streamed. Files over 100 MiB answer 422; read them in parts with a command. Requires `files`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Read a file",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SandboxPathBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:writeFile": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.writeFile",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "path",
            "in": "query",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 4096,
              "pattern": "^\\/[^\\0]*$",
              "description": "Absolute path inside the sandbox.",
              "examples": [
                "/workspace/README.md"
              ]
            },
            "required": true
          },
          {
            "name": "create_parents",
            "in": "query",
            "schema": {
              "type": "boolean",
              "description": "Create missing directories. Default true."
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxFileInfo",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxFileInfo"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Replaces one file with the raw request body (`application/octet-stream`, at most 100 MiB) and returns its new metadata. The body is streamed to the sandbox, never buffered whole. Requires `files`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Write a file",
        "requestBody": {
          "content": {
            "application/octet-stream": {
              "schema": {
                "type": "string",
                "format": "binary"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:writeFiles": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.writeFiles",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxFileInfos",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxFileInfos"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Writes a batch of small files (UTF-8 text or base64) in one request of at most 4 MiB, for example a set of agent edits. Files are written in order; a failure stops the batch and earlier files stay written. Requires `files`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Write several files",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/WriteSandboxFilesBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:listFiles": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.listFiles",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxFileList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxFileList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Entries of a directory sorted by path, optionally recursive, paged with `cursor`. Symbolic links are listed, not followed. Requires `files`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "List files",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ListSandboxFilesBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:statFile": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.statFile",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxFileInfo",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxFileInfo"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Type, size, mode and modification time of one path, without following a final symbolic link. Requires `files`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Get file metadata",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SandboxPathBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:removeFiles": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.removeFiles",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "204": {
            "description": "<No Content>"
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Removes files, and directories when `recursive` is true. Missing paths are ignored. Requires `files`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Remove files",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RemoveSandboxFilesBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:moveFile": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.moveFile",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxFileInfo",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxFileInfo"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Moves or renames a file or directory and returns the destination's metadata. An existing destination answers 409 unless `overwrite` is true. Requires `files`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Move a file",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MoveSandboxFileBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}:makeDirectory": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.makeDirectory",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxFileInfo",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxFileInfo"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Creates a directory, with missing parents unless `parents` is false. An existing directory is returned unchanged. Requires `files`. Commands and file operations need an `ACTIVE` sandbox; on any other state they answer 409.",
        "summary": "Make a directory",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MakeSandboxDirectoryBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}/access": {
      "post": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.grantAccess",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Access granted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxAccessGrant"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Gives a Workspace member, an OpenCode Server, or every current Workspace member permissions on the sandbox. For subject_type workspace, subject_id may be omitted and must match this Workspace if supplied. One grant per subject; change permissions by deleting and granting again. Requires `manage`.",
        "summary": "Grant access to a sandbox",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateSandboxAccessGrantBody"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.listAccess",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512,
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SandboxAccessGrantList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SandboxAccessGrantList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Who may use the sandbox and how. Requires any grant on the sandbox.",
        "summary": "List access grants",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/sandboxes/{id}/access/{grant_id}": {
      "delete": {
        "tags": [
          "Sandboxes"
        ],
        "operationId": "sandboxes.revokeAccess",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxId"
            },
            "required": true
          },
          {
            "name": "grant_id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SandboxAccessGrantId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "204": {
            "description": "<No Content>"
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The Workspace or owner sandbox quota has been reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "502": {
            "description": "An upstream provider failed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiExternalServiceError"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Removes one grant. Requires `manage`. A sandbox nobody has access to anymore is deleted after 7 days.",
        "summary": "Revoke access to a sandbox",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/opencodes": {
      "post": {
        "tags": [
          "OpenCode Servers"
        ],
        "operationId": "opencodes.create",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "OpenCode Server created",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpenCodeServer"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Creates a hosted OpenCode Server in the workspace with a random id. OpenCode's own settings (models, providers, agents) are managed in OpenCode itself; this resource holds the platform guardrails around it. With an `Idempotency-Key`, a retry of the same request returns the server it created; the same key on a different request answers 409.",
        "summary": "Create an OpenCode Server",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateOpenCodeServer"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "get": {
        "tags": [
          "OpenCode Servers"
        ],
        "operationId": "opencodes.list",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "description": "Pagination cursor from a previous response's `next_cursor`."
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "description": "Items per page (1-100, default 50)",
              "default": 50,
              "examples": [
                50
              ],
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "OpenCode Server list",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpenCodeServerList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Lists the workspace's OpenCode Servers, oldest first, deleted servers excluded. The default server is created on first use.",
        "summary": "List OpenCode Servers",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/opencodes/{id}": {
      "get": {
        "tags": [
          "OpenCode Servers"
        ],
        "operationId": "opencodes.get",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/OpenCodeServerId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "OpenCode Server",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpenCodeServer"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Returns one OpenCode Server of the workspace.",
        "summary": "Get an OpenCode Server",
        "x-platform-visibility": "PUBLIC"
      },
      "patch": {
        "tags": [
          "OpenCode Servers"
        ],
        "operationId": "opencodes.update",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/OpenCodeServerId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "OpenCode Server updated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpenCodeServer"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Changes the name, labels and guardrails of a server that is not deleted. Requires `If-Match` with the server's `etag`.",
        "summary": "Update an OpenCode Server",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateOpenCodeServer"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "delete": {
        "tags": [
          "OpenCode Servers"
        ],
        "operationId": "opencodes.delete",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/OpenCodeServerId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Delete accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Starts an operation that stops the server for good: protocol traffic is refused, its stored data is erased, and the platform's grants for it are revoked. The workspace's default server cannot be deleted. Deletion is not supported yet because the server's own Vault cannot be cleaned up safely: a new delete answers 422.",
        "summary": "Delete an OpenCode Server",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/opencodes/{id}:suspend": {
      "post": {
        "tags": [
          "OpenCode Servers"
        ],
        "operationId": "opencodes.suspend",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/OpenCodeServerId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Suspend accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Starts an operation after which the server refuses OpenCode protocol traffic. Its data is kept.",
        "summary": "Suspend an OpenCode Server",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/opencodes/{id}:resume": {
      "post": {
        "tags": [
          "OpenCode Servers"
        ],
        "operationId": "opencodes.resume",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/OpenCodeServerId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "202": {
            "description": "Resume accepted",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Operation"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          },
          "504": {
            "description": "An upstream provider did not answer in time.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGatewayTimeout"
                }
              }
            }
          }
        },
        "description": "Starts an operation that lets a suspended server serve OpenCode protocol traffic again.",
        "summary": "Resume an OpenCode Server",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/opencodes/{id}:createClientToken": {
      "post": {
        "tags": [
          "OpenCode Servers"
        ],
        "operationId": "opencodes.createClientToken",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/OpenCodeServerId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "OpenCodeClientToken",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/OpenCodeClientToken"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Creates a one-time link that signs the browser in to the OpenCode Server's own web UI. The link expires after about a minute. Requires a workspace user; the server must belong to the workspace and be active.",
        "summary": "Sign in to an OpenCode Server's web UI",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults": {
      "get": {
        "tags": [
          "vaults"
        ],
        "operationId": "vaults.list",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "VaultList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VaultList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "The default vault first.",
        "summary": "List vaults",
        "x-platform-visibility": "PUBLIC"
      },
      "post": {
        "tags": [
          "vaults"
        ],
        "operationId": "vaults.create",
        "parameters": [
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "vault_id",
            "in": "query",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Vault",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vault"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Creates the vault `vault_id` (AIP-133), for example one per end customer of a reseller. `default` exists already. Unless a policy is set later, Workspace admins administer it and members manage its secrets without reading them.",
        "summary": "Create a vault",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateVaultRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}": {
      "get": {
        "tags": [
          "vaults"
        ],
        "operationId": "vaults.get",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Vault",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vault"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Metadata only.",
        "summary": "Get a vault",
        "x-platform-visibility": "PUBLIC"
      },
      "patch": {
        "tags": [
          "vaults"
        ],
        "operationId": "vaults.update",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Vault",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Vault"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Display name, labels and annotations.",
        "summary": "Update a vault",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateVaultRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "delete": {
        "tags": [
          "vaults"
        ],
        "operationId": "vaults.delete",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "204": {
            "description": "<No Content>"
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Erases the vault's key and every value in it at once; connections stop working immediately. Erasure removes every command receipt. A repeated DELETE of a named vault that is still absent returns 404, even with the same Idempotency-Key. If the vault has been recreated, the retry acts on the new vault and can erase its new values. For conditional retries, send If-Match with the last observed etag: a different current etag returns 409. Etags are revision-based and may repeat after recreation, so they do not identify a vault incarnation. A deleted `default` vault comes back empty on next use; a repeated DELETE without If-Match materializes and deletes an empty vault, returning 204.",
        "summary": "Delete a vault",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}:getIamPolicy": {
      "get": {
        "tags": [
          "vaults"
        ],
        "operationId": "vaults.getIamPolicy",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Policy",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Policy"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Bindings on the vault. Workspace roles apply in addition.",
        "summary": "Get a vault policy",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}:setIamPolicy": {
      "post": {
        "tags": [
          "vaults"
        ],
        "operationId": "vaults.setIamPolicy",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Policy",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Policy"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Replaces all bindings.",
        "summary": "Set a vault policy",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetIamPolicyRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/audit_events": {
      "get": {
        "tags": [
          "vaults"
        ],
        "operationId": "vaults.listAuditEvents",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "VaultAuditEventList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VaultAuditEventList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Every access and change, allowed or denied, newest first. Never contains a value.",
        "summary": "List vault audit events",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/secrets": {
      "get": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.list",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SecretList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SecretList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Metadata only.",
        "summary": "List secrets",
        "x-platform-visibility": "PUBLIC"
      },
      "post": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.create",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "Secret",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Secret"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Optionally with its first version.",
        "summary": "Create a secret",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateSecretRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/secrets/{secret}": {
      "get": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.get",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "secret",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SecretId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Secret",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Secret"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Metadata only.",
        "summary": "Get a secret",
        "x-platform-visibility": "PUBLIC"
      },
      "patch": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.update",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "secret",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SecretId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "Secret",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Secret"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Labels.",
        "summary": "Update a secret",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateSecretRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      },
      "delete": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.delete",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "secret",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SecretId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "204": {
            "description": "<No Content>"
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Destroys every version at once.",
        "summary": "Delete a secret",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/secrets/{secret}:addVersion": {
      "post": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.addVersion",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "secret",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SecretId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "201": {
            "description": "SecretVersion",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SecretVersion"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "The value is never echoed.",
        "summary": "Add a secret version",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AddSecretVersionRequest"
              }
            }
          },
          "required": true
        },
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/secrets/{secret}/versions": {
      "get": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.listVersions",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "secret",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SecretId"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "cursor",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 512
            },
            "required": false
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SecretVersionList",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SecretVersionList"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Metadata only.",
        "summary": "List versions",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/secrets/{secret}/versions/{version}": {
      "get": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.getVersion",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "secret",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SecretId"
            },
            "required": true
          },
          {
            "name": "version",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VersionSelector"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SecretVersion",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SecretVersion"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Metadata only.",
        "summary": "Get a version",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/secrets/{secret}/versions/{version}:enable": {
      "post": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.enableVersion",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "secret",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SecretId"
            },
            "required": true
          },
          {
            "name": "version",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VersionSelector"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SecretVersion",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SecretVersion"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Reversible.",
        "summary": "Enable a version",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/secrets/{secret}/versions/{version}:disable": {
      "post": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.disableVersion",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "secret",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SecretId"
            },
            "required": true
          },
          {
            "name": "version",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VersionSelector"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SecretVersion",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SecretVersion"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "`:access` fails while disabled.",
        "summary": "Disable a version",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/secrets/{secret}/versions/{version}:destroy": {
      "post": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.destroyVersion",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "secret",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SecretId"
            },
            "required": true
          },
          {
            "name": "version",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VersionSelector"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          },
          {
            "name": "idempotency-key",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 64,
              "description": "Optional caller-supplied idempotency key. Any non-empty key up to 64 characters is accepted. Endpoint-specific documentation describes how the key is used.",
              "examples": [
                "create-prod-2026-05-07"
              ]
            },
            "required": false
          },
          {
            "name": "if-match",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 256,
              "description": "The `etag` of the resource version the client last read. Required on writes when the resource exposes an `etag` field. Mismatch returns 409 `ABORTED` with the current etag in the error metadata.",
              "examples": [
                "42"
              ]
            },
            "required": true
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "SecretVersion",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SecretVersion"
                }
              }
            }
          },
          "400": {
            "description": "The request is malformed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiBadRequest"
                }
              }
            }
          },
          "401": {
            "description": "Missing, invalid or expired credential.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnauthorized"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent. | The resource changed since the etag the client sent; the current etag is in the metadata. | The idempotency key was already used for a different request.",
            "content": {
              "application/json": {
                "schema": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/ApiConflict"
                    },
                    {
                      "$ref": "#/components/schemas/ApiPreconditionFailed"
                    },
                    {
                      "$ref": "#/components/schemas/ApiIdempotencyConflict"
                    }
                  ]
                }
              }
            }
          },
          "422": {
            "description": "The request is well-formed but cannot be processed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiUnprocessable"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Erases the value for good.",
        "summary": "Destroy a version",
        "x-platform-visibility": "PUBLIC"
      }
    },
    "/vaults/{vault}/secrets/{secret}/versions/{version}:access": {
      "post": {
        "tags": [
          "vaultSecrets"
        ],
        "operationId": "secrets.accessVersion",
        "parameters": [
          {
            "name": "vault",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VaultId"
            },
            "required": true
          },
          {
            "name": "secret",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/SecretId"
            },
            "required": true
          },
          {
            "name": "version",
            "in": "path",
            "schema": {
              "$ref": "#/components/schemas/VersionSelector"
            },
            "required": true
          },
          {
            "name": "akua-context",
            "in": "header",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 53,
              "description": "Optional workspace/scope context for the request. Carries a single workspace wire id (`ws_…`) today. Only needed for broad tokens - a workspace-owned token implies its workspace.",
              "examples": [
                "ws_j572abc123def4"
              ]
            },
            "required": false
          }
        ],
        "security": [
          {
            "BearerAuth": []
          }
        ],
        "responses": {
          "200": {
            "description": "AccessSecretVersionResponse",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AccessSecretVersionResponse"
                }
              }
            }
          },
          "403": {
            "description": "The credential may not act in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiForbidden"
                }
              }
            }
          },
          "404": {
            "description": "The resource was not found in this workspace.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiNotFound"
                }
              }
            }
          },
          "409": {
            "description": "The request conflicts with existing resource state or immutable intent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiConflict"
                }
              }
            }
          },
          "410": {
            "description": "The resource is permanently unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiGone"
                }
              }
            }
          },
          "429": {
            "description": "The caller is over a rate budget, or a resource it adds to is at its limit (resource exhausted).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTooManyRequests"
                }
              }
            }
          },
          "503": {
            "description": "The service is temporarily unavailable.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiServiceUnavailable"
                }
              }
            }
          }
        },
        "description": "Returns the value. Needs `vault.versions.access`: Workspace admins and owners have it on every vault of their Workspace, including the vaults an Install or Offer created for the values they entered; Akua services hold it only where a vault binds them. Every call is audited. POST so that no cache, prefetcher or access log keeps the response.",
        "summary": "Access a secret version",
        "x-platform-visibility": "PUBLIC"
      }
    }
  },
  "components": {
    "schemas": {
      "ApiServiceUnavailable": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "ServiceUnavailable"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "ApiErrorEntry": {
        "type": "object",
        "properties": {
          "code": {
            "type": "integer",
            "minimum": -9007199254740991,
            "maximum": 9007199254740991,
            "description": "Machine-readable error code",
            "examples": [
              7002
            ]
          },
          "message": {
            "type": "string",
            "description": "Human-readable error message",
            "examples": [
              "Resource not found"
            ]
          },
          "path": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Field path that caused the error, when applicable",
            "examples": [
              [
                "body",
                "name"
              ]
            ]
          },
          "metadata": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          }
        },
        "required": [
          "code",
          "message"
        ],
        "additionalProperties": false
      },
      "ApiTooManyRequests": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "TooManyRequests"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "ApiGone": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "Gone"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "ApiConflict": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "Conflict"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "ApiNotFound": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "NotFound"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "ApiForbidden": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "Forbidden"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "AccessSecretVersionResponse": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The resolved version, also when `latest` was asked for."
          },
          "payload": {
            "type": "string"
          }
        },
        "required": [
          "name",
          "payload"
        ],
        "additionalProperties": false
      },
      "VersionSelector": {
        "type": "string",
        "pattern": "^(latest|[1-9][0-9]{0,8})$",
        "title": "VersionSelector",
        "description": "A version number or `latest`",
        "examples": [
          "latest",
          "3"
        ]
      },
      "SecretId": {
        "type": "string",
        "pattern": "^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$",
        "title": "SecretId",
        "description": "A secret id, unique in its vault",
        "examples": [
          "db-password"
        ]
      },
      "VaultId": {
        "type": "string",
        "pattern": "^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$",
        "title": "VaultId",
        "description": "A vault id chosen by its creator, unique in the Workspace. `default` is the Workspace vault.",
        "examples": [
          "default"
        ]
      },
      "ApiIdempotencyConflict": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "IdempotencyConflict"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "ApiPreconditionFailed": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "PreconditionFailed"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "number",
                    "enum": [
                      7006
                    ]
                  },
                  "message": {
                    "type": "string"
                  },
                  "metadata": {
                    "type": "object",
                    "properties": {
                      "current_etag": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "current_etag"
                    ],
                    "allOf": [
                      {
                        "type": "object",
                        "additionalProperties": {
                          "type": "string"
                        }
                      }
                    ]
                  }
                },
                "required": [
                  "code",
                  "message",
                  "metadata"
                ],
                "additionalProperties": false
              }
            ],
            "maxItems": 1,
            "minItems": 1
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "ApiUnauthorized": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "Unauthorized"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "ApiBadRequest": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "Validation"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "ApiUnprocessable": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "Unprocessable"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "SecretVersion": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "Resource name `vaults/{vault}/secrets/{secret}/versions/{version}`."
          },
          "version": {
            "type": "integer"
          },
          "state": {
            "type": "string",
            "enum": [
              "ENABLED",
              "DISABLED",
              "DESTROYED"
            ]
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Unix timestamp (seconds)"
          },
          "destroyed_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "description": "Unix timestamp (seconds)"
              },
              {
                "type": "null"
              }
            ]
          },
          "etag": {
            "type": "string",
            "maxLength": 64,
            "description": "Pass as `If-Match` on writes. OUTPUT_ONLY."
          }
        },
        "required": [
          "name",
          "version",
          "state",
          "created_at",
          "destroyed_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "SecretVersionList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SecretVersion"
            },
            "maxItems": 100
          },
          "has_more": {
            "type": "boolean"
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "AddSecretVersionRequest": {
        "type": "object",
        "properties": {
          "payload": {
            "type": "string"
          }
        },
        "required": [
          "payload"
        ],
        "additionalProperties": false
      },
      "Secret": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "Resource name `vaults/{vault}/secrets/{secret}`.",
            "examples": [
              "vaults/default/secrets/db-password"
            ]
          },
          "vault_id": {
            "$ref": "#/components/schemas/VaultId"
          },
          "secret_id": {
            "$ref": "#/components/schemas/SecretId"
          },
          "labels": {
            "type": "object",
            "patternProperties": {
              "^[a-z][a-z0-9_-]{0,62}$": {
                "type": "string",
                "maxLength": 63
              }
            },
            "additionalProperties": false,
            "maxProperties": 64
          },
          "latest_version": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ]
          },
          "version_count": {
            "type": "integer"
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Unix timestamp (seconds)"
          },
          "updated_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Unix timestamp (seconds)"
          },
          "etag": {
            "type": "string",
            "maxLength": 64,
            "description": "Pass as `If-Match` on writes. OUTPUT_ONLY."
          }
        },
        "required": [
          "name",
          "vault_id",
          "secret_id",
          "labels",
          "latest_version",
          "version_count",
          "created_at",
          "updated_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "UpdateSecretRequest": {
        "type": "object",
        "properties": {
          "labels": {
            "type": "object",
            "patternProperties": {
              "^[a-z][a-z0-9_-]{0,62}$": {
                "type": "string",
                "maxLength": 63
              }
            },
            "additionalProperties": false,
            "maxProperties": 64
          }
        },
        "required": [
          "labels"
        ],
        "additionalProperties": false
      },
      "CreateSecretRequest": {
        "type": "object",
        "properties": {
          "secret_id": {
            "$ref": "#/components/schemas/SecretId"
          },
          "labels": {
            "type": "object",
            "patternProperties": {
              "^[a-z][a-z0-9_-]{0,62}$": {
                "type": "string",
                "maxLength": 63
              }
            },
            "additionalProperties": false,
            "maxProperties": 64
          },
          "payload": {
            "type": "string"
          }
        },
        "required": [
          "secret_id"
        ],
        "additionalProperties": false
      },
      "SecretList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Secret"
            },
            "maxItems": 100
          },
          "has_more": {
            "type": "boolean"
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "VaultAuditEventList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/VaultAuditEvent"
            },
            "maxItems": 100
          },
          "has_more": {
            "type": "boolean"
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "VaultAuditEvent": {
        "type": "object",
        "properties": {
          "sequence": {
            "type": "integer"
          },
          "time": {
            "type": "integer",
            "minimum": 0,
            "description": "Unix timestamp (seconds)"
          },
          "method": {
            "type": "string",
            "maxLength": 64,
            "examples": [
              "AccessSecretVersion"
            ]
          },
          "resource": {
            "type": "string",
            "maxLength": 256
          },
          "principal": {
            "$ref": "#/components/schemas/Member"
          },
          "act": {
            "type": "object",
            "properties": {
              "sub": {
                "anyOf": [
                  {
                    "$ref": "#/components/schemas/Principal"
                  },
                  {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 256
                  }
                ]
              },
              "act": {
                "type": "object",
                "properties": {
                  "sub": {
                    "anyOf": [
                      {
                        "$ref": "#/components/schemas/Principal"
                      },
                      {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 256
                      }
                    ]
                  },
                  "act": {
                    "type": "object",
                    "properties": {
                      "sub": {
                        "anyOf": [
                          {
                            "$ref": "#/components/schemas/Principal"
                          },
                          {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 256
                          }
                        ]
                      },
                      "act": {
                        "type": "object",
                        "properties": {
                          "sub": {
                            "anyOf": [
                              {
                                "$ref": "#/components/schemas/Principal"
                              },
                              {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 256
                              }
                            ]
                          }
                        },
                        "required": [
                          "sub"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "required": [
                      "sub"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "sub"
                ],
                "additionalProperties": false
              }
            },
            "required": [
              "sub"
            ],
            "additionalProperties": false
          },
          "execution": {
            "$ref": "#/components/schemas/ExecutionContext"
          },
          "via": {
            "type": "string",
            "maxLength": 200,
            "description": "The service or workload that presented the call."
          },
          "decision": {
            "type": "string",
            "enum": [
              "ALLOWED",
              "DENIED"
            ]
          },
          "reason": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 128
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "sequence",
          "time",
          "method",
          "resource",
          "principal",
          "via",
          "decision",
          "reason"
        ],
        "additionalProperties": false
      },
      "ExecutionContext": {
        "type": "object",
        "properties": {
          "session_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 256
          },
          "agent": {
            "type": "string",
            "minLength": 1,
            "maxLength": 256
          }
        },
        "required": [
          "session_id"
        ],
        "additionalProperties": false
      },
      "Principal": {
        "anyOf": [
          {
            "type": "string",
            "pattern": "^service:[\\s\\S]*?$"
          },
          {
            "type": "string",
            "pattern": "^workload:[\\s\\S]*?\\/[\\s\\S]*?$"
          },
          {
            "type": "string",
            "pattern": "^workforce:[\\s\\S]*?\\/[\\s\\S]*?$"
          }
        ]
      },
      "Member": {
        "type": "string",
        "pattern": "^(user:[^\\s]{1,64}|service:[a-z][a-z0-9-]{0,62}|(?:workload|workforce):[a-z][a-z0-9-]{0,62}\\/[A-Za-z0-9_-]{1,128})$",
        "title": "Member",
        "description": "A person (`user:<id>`), service agent (`service:<name>`), workload (`workload:<pool>/<id>`) or workforce identity (`workforce:<pool>/<subject>`)",
        "examples": [
          "user:usr_j572abc",
          "service:placement"
        ]
      },
      "Policy": {
        "type": "object",
        "properties": {
          "bindings": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Binding"
            },
            "maxItems": 100
          },
          "etag": {
            "type": "string",
            "maxLength": 64,
            "description": "Pass as `If-Match` on `setIamPolicy`. OUTPUT_ONLY."
          }
        },
        "required": [
          "bindings",
          "etag"
        ],
        "additionalProperties": false
      },
      "Binding": {
        "type": "object",
        "properties": {
          "role": {
            "$ref": "#/components/schemas/RoleName"
          },
          "members": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/Member"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/Member"
            },
            "maxItems": 64
          },
          "condition": {
            "$ref": "#/components/schemas/BindingCondition"
          }
        },
        "required": [
          "role",
          "members"
        ],
        "additionalProperties": false
      },
      "BindingCondition": {
        "type": "object",
        "properties": {
          "title": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          },
          "description": {
            "type": "string",
            "maxLength": 512
          },
          "expires_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "operations": {
            "type": "array",
            "prefixItems": [
              {
                "type": "string",
                "pattern": "^[a-z][a-z0-9]*(?:[._-][a-z0-9]+)*$",
                "maxLength": 96
              }
            ],
            "minItems": 1,
            "items": {
              "type": "string",
              "pattern": "^[a-z][a-z0-9]*(?:[._-][a-z0-9]+)*$",
              "maxLength": 96
            },
            "maxItems": 100
          }
        },
        "required": [
          "title"
        ],
        "additionalProperties": false
      },
      "RoleName": {
        "type": "string",
        "pattern": "^roles\\/(owner|admin|member|viewer|[a-z][a-z0-9-]{0,62}\\.[a-z][A-Za-z]{0,62})$",
        "title": "RoleName",
        "description": "A basic role `roles/<name>` or a predefined role `roles/<service>.<role>`",
        "examples": [
          "roles/admin",
          "roles/vault.secretAccessor"
        ]
      },
      "SetIamPolicyRequest": {
        "type": "object",
        "properties": {
          "bindings": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Binding"
            },
            "maxItems": 100
          }
        },
        "required": [
          "bindings"
        ],
        "additionalProperties": false
      },
      "Vault": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "Resource name `vaults/{vault}`.",
            "examples": [
              "vaults/default"
            ]
          },
          "vault_id": {
            "$ref": "#/components/schemas/VaultId"
          },
          "workspace_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 53
          },
          "display_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          },
          "labels": {
            "type": "object",
            "patternProperties": {
              "^[a-z][a-z0-9_-]{0,62}$": {
                "type": "string",
                "maxLength": 63
              }
            },
            "additionalProperties": false,
            "maxProperties": 64
          },
          "annotations": {
            "type": "object",
            "patternProperties": {
              "^([a-z0-9.-]{1,253}\\/)?[A-Za-z0-9_.-]{1,63}$": {
                "type": "string",
                "maxLength": 1024
              }
            },
            "additionalProperties": false,
            "maxProperties": 32,
            "description": "Opaque key-value data for clients (AIP-148)."
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Unix timestamp (seconds)"
          },
          "updated_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Unix timestamp (seconds)"
          },
          "etag": {
            "type": "string",
            "maxLength": 64,
            "description": "Pass as `If-Match` on writes. OUTPUT_ONLY."
          }
        },
        "required": [
          "name",
          "vault_id",
          "workspace_id",
          "display_name",
          "labels",
          "annotations",
          "created_at",
          "updated_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "UpdateVaultRequest": {
        "type": "object",
        "properties": {
          "display_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          },
          "labels": {
            "type": "object",
            "patternProperties": {
              "^[a-z][a-z0-9_-]{0,62}$": {
                "type": "string",
                "maxLength": 63
              }
            },
            "additionalProperties": false,
            "maxProperties": 64
          },
          "annotations": {
            "type": "object",
            "patternProperties": {
              "^([a-z0-9.-]{1,253}\\/)?[A-Za-z0-9_.-]{1,63}$": {
                "type": "string",
                "maxLength": 1024
              }
            },
            "additionalProperties": false,
            "maxProperties": 32,
            "description": "Opaque key-value data for clients (AIP-148)."
          }
        },
        "additionalProperties": false
      },
      "CreateVaultRequest": {
        "type": "object",
        "properties": {
          "display_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          },
          "labels": {
            "type": "object",
            "patternProperties": {
              "^[a-z][a-z0-9_-]{0,62}$": {
                "type": "string",
                "maxLength": 63
              }
            },
            "additionalProperties": false,
            "maxProperties": 64
          },
          "annotations": {
            "type": "object",
            "patternProperties": {
              "^([a-z0-9.-]{1,253}\\/)?[A-Za-z0-9_.-]{1,63}$": {
                "type": "string",
                "maxLength": 1024
              }
            },
            "additionalProperties": false,
            "maxProperties": 32,
            "description": "Opaque key-value data for clients (AIP-148)."
          }
        },
        "additionalProperties": false
      },
      "VaultList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Vault"
            },
            "maxItems": 100
          },
          "has_more": {
            "type": "boolean"
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "OpenCodeClientToken": {
        "type": "object",
        "properties": {
          "url": {
            "type": "string",
            "description": "The web UI address with a one-time client token in its fragment (`#ct=...`). Open it in a browser, or set it as an iframe's source; the token is exchanged for a session of that server and never reaches a server log."
          },
          "expires_at": {
            "type": "integer",
            "description": "When the token expires unused, in Unix seconds. Tokens live about a minute."
          }
        },
        "required": [
          "url",
          "expires_at"
        ],
        "additionalProperties": false
      },
      "OpenCodeServerId": {
        "type": "string",
        "pattern": "^oc_[a-z0-9]{1,64}$",
        "title": "OpenCode Server id",
        "description": "OpenCode Server id (`oc_...`).",
        "examples": [
          "oc_j572abc123def456"
        ]
      },
      "ApiGatewayTimeout": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "GatewayTimeout"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "Operation": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 192
          },
          "workspace_id": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              {
                "type": "null"
              }
            ]
          },
          "organization_id": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              {
                "type": "null"
              }
            ]
          },
          "owner_type": {
            "type": "string",
            "enum": [
              "install",
              "repository_change_request",
              "repository",
              "workspace",
              "machine",
              "cluster",
              "node_pool",
              "package",
              "sandbox",
              "opencode"
            ],
            "description": "Domain entity collection the operation acts on."
          },
          "owner_id": {
            "type": "string",
            "description": "Prefixed ID of the entity this operation acts on. Prefix matches `owner_type` (`ws_`, `mch_`, `clu_`, `pkg_`, `inst_`, `rcr_`, `repo_`, `sbx_`, `oc_`); a node pool is `clu_<id>/node_pools/<node pool id>`."
          },
          "parent_operation_id": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 2,
                "maxLength": 192
              },
              {
                "type": "null"
              }
            ],
            "description": "ID of the chained parent operation, when present."
          },
          "state": {
            "type": "string",
            "enum": [
              "RUNNING",
              "SUCCEEDED",
              "FAILED",
              "CANCELLED"
            ],
            "description": "Lifecycle state. Past-participle terminal states per AIP-216."
          },
          "done": {
            "type": "boolean",
            "description": "True iff state is a terminal value."
          },
          "html_url": {
            "type": "string",
            "description": "Deep link to the dashboard view of this operation's owning resource when available, otherwise the operation detail page.",
            "format": "uri",
            "examples": [
              "https://akua.dev/installs/inst_j572abc123def456?tab=operations"
            ],
            "maxLength": 2048
          },
          "metadata": {
            "$ref": "#/components/schemas/OperationMetadata"
          },
          "response": {
            "$ref": "#/components/schemas/OperationResponse"
          },
          "error": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "integer"
                  },
                  "message": {
                    "type": "string"
                  },
                  "reason": {
                    "type": "string",
                    "description": "Why it failed, stable for clients to branch on. Node pool and Machine creates use `billing-required`, `quota-exceeded`, `service-disabled`, `capacity-unavailable`, `provider-refused`, `provider-unavailable` and `abandoned`; most Operations omit it.",
                    "examples": [
                      "billing-required"
                    ]
                  },
                  "violations": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/OperationViolation"
                    },
                    "description": "Each precondition that failed, like `google.rpc.PreconditionFailure`. A Package version that fails with `image-unresolvable` lists every image it could not resolve."
                  }
                },
                "required": [
                  "message"
                ],
                "additionalProperties": false
              },
              {
                "type": "null"
              }
            ],
            "description": "Populated when `state` is `FAILED` or `CANCELLED`."
          },
          "last_error": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "message": {
                    "type": "string"
                  },
                  "step_name": {
                    "type": "string"
                  }
                },
                "required": [
                  "message"
                ],
                "additionalProperties": false
              },
              {
                "type": "null"
              }
            ],
            "description": "Latest error from any failed step. Populated even mid-flight; cleared when the step succeeds on retry."
          },
          "started_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "completed_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "Unix timestamp (seconds)"
          },
          "steps": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OperationStep"
            }
          }
        },
        "required": [
          "id",
          "workspace_id",
          "organization_id",
          "owner_type",
          "owner_id",
          "parent_operation_id",
          "state",
          "done",
          "html_url",
          "metadata",
          "response",
          "error",
          "last_error",
          "started_at",
          "completed_at"
        ],
        "additionalProperties": false
      },
      "OperationStep": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "User-visible milestone name."
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "running",
              "completed",
              "failed",
              "skipped"
            ],
            "description": "Step lifecycle state."
          },
          "execution_type": {
            "type": "string",
            "enum": [
              "system",
              "user",
              "approval",
              "skipped"
            ],
            "description": "Step execution kind. `user`/`approval` mean the workflow is blocked on a human action. Internal bookkeeping steps are filtered from public responses."
          },
          "started_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "completed_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "Unix timestamp (seconds)"
          },
          "error_message": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "retryable": {
            "type": "boolean"
          },
          "skippable": {
            "type": "boolean"
          }
        },
        "required": [
          "name",
          "status",
          "execution_type",
          "started_at",
          "completed_at",
          "error_message",
          "retryable",
          "skippable"
        ],
        "additionalProperties": false
      },
      "OperationViolation": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "The kind of violation, stable for clients to branch on.",
            "examples": [
              "image-unresolvable"
            ]
          },
          "subject": {
            "type": "string",
            "description": "What failed it, for `image-unresolvable` the image reference.",
            "examples": [
              "pkg.akua.dev/ws_xxx/images/ghcr-acme/web:1.2.3"
            ]
          },
          "description": {
            "type": "string",
            "description": "Why it failed, safe to show."
          }
        },
        "required": [
          "type",
          "subject",
          "description"
        ],
        "additionalProperties": false
      },
      "OperationResponse": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.join_token.revoke"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "token_id": {
                "type": "string",
                "pattern": "^[a-z0-9]{6}$"
              }
            },
            "required": [
              "type",
              "cluster_id",
              "token_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "machine.create"
                ]
              },
              "machine_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "provider_id": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "machine_id",
              "provider_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "machine.delete"
                ]
              },
              "machine_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "machine_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "machine.suspend"
                ]
              },
              "machine_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "suspension_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "machine_id",
              "suspension_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "machine.resume"
                ]
              },
              "machine_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "machine_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.delete"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "cluster_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.create"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "cluster_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.node.remove"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "node_name": {
                "type": "string",
                "minLength": 1,
                "maxLength": 253
              }
            },
            "required": [
              "type",
              "cluster_id",
              "node_name"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "node_pool.create",
                  "node_pool.set_size",
                  "node_pool.delete"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "node_pool_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 40
              }
            },
            "required": [
              "type",
              "cluster_id",
              "node_pool_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.suspend"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "cluster_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.resume"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "cluster_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.capabilities.refresh"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "cluster_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.capability.ensure"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "capability": {
                "type": "string",
                "minLength": 1
              }
            },
            "required": [
              "type",
              "cluster_id",
              "capability"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.worker_bootstrap.revoke"
                ]
              },
              "note": {
                "type": "string"
              }
            },
            "required": [
              "type"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "install.create"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "argo_app_name": {
                "type": "string"
              },
              "argo_app_namespace": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "install_id",
              "argo_app_name",
              "argo_app_namespace"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "install.create"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "sandbox_skipped": {
                "type": "boolean",
                "enum": [
                  true
                ]
              }
            },
            "required": [
              "type",
              "install_id",
              "sandbox_skipped"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "install.render"
                ]
              },
              "install_render_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "repository_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "commit_sha": {
                "type": "string"
              },
              "render_hash": {
                "type": "string"
              },
              "skipped": {
                "type": "boolean"
              }
            },
            "required": [
              "type",
              "install_render_id",
              "repository_id",
              "render_hash",
              "skipped"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "install.delete"
                ]
              },
              "argo_app_deleted": {
                "type": "boolean"
              },
              "repo_purged": {
                "type": "boolean"
              }
            },
            "required": [
              "type",
              "argo_app_deleted",
              "repo_purged"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "preview_hostname.bind_pinned"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "preview_hostname_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "hostname": {
                "type": "string",
                "minLength": 1,
                "maxLength": 253
              }
            },
            "required": [
              "type",
              "install_id",
              "preview_hostname_id",
              "hostname"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "preview_hostname.bind_floating"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "preview_hostname_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "hostname": {
                "type": "string",
                "minLength": 1,
                "maxLength": 253
              }
            },
            "required": [
              "type",
              "install_id",
              "preview_hostname_id",
              "hostname"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "preview_hostname.delete"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "preview_hostname_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "hostname": {
                "type": "string",
                "minLength": 1,
                "maxLength": 253
              }
            },
            "required": [
              "type",
              "install_id",
              "preview_hostname_id",
              "hostname"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "workspace.delete"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              }
            },
            "required": [
              "type",
              "workspace_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "workspace.subscription.cancel"
                ]
              },
              "subscription_id": {
                "type": "string"
              },
              "cancel_at": {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              }
            },
            "required": [
              "type",
              "subscription_id",
              "cancel_at"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "workspace.subdomain.set_name"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "workspace_subdomain_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "fqdn": {
                "type": "string",
                "minLength": 1,
                "maxLength": 253
              }
            },
            "required": [
              "type",
              "workspace_id",
              "workspace_subdomain_id",
              "fqdn"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "custom_domain.create"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "custom_domain_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "hostname": {
                "type": "string",
                "minLength": 1,
                "maxLength": 253
              }
            },
            "required": [
              "type",
              "workspace_id",
              "custom_domain_id",
              "hostname"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "custom_domain.update"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "custom_domain_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "hostname": {
                "type": "string",
                "minLength": 1,
                "maxLength": 253
              }
            },
            "required": [
              "type",
              "workspace_id",
              "custom_domain_id",
              "hostname"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "custom_domain.delete"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "custom_domain_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "hostname": {
                "type": "string",
                "minLength": 1,
                "maxLength": 253
              }
            },
            "required": [
              "type",
              "workspace_id",
              "custom_domain_id",
              "hostname"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cloudflare.private_origin_route.prepare"
                ]
              },
              "origin_route_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "origin_route_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cloudflare.private_origin_route.release"
                ]
              },
              "route_intent_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "route_intent_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "package.create"
                ]
              },
              "package_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "package_version_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "repository_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "type",
              "package_id",
              "package_version_id",
              "repository_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "package.version.publish_hosted"
                ]
              },
              "package_version_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "type",
              "package_version_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "package.version.publish_local_chart"
                ]
              },
              "package_version_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "type",
              "package_version_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "package.version.publish"
                ]
              },
              "package_version_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "artifact_digest": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "package_version_id",
              "artifact_digest"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository_change_request.create"
                ]
              },
              "repository_change_request_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "fork_repository_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "expires_at": {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              }
            },
            "required": [
              "type",
              "repository_change_request_id",
              "fork_repository_id",
              "expires_at"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository_change_request.accept"
                ]
              },
              "merged_at": {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              },
              "triggered_install_render": {
                "type": "boolean"
              }
            },
            "required": [
              "type",
              "merged_at",
              "triggered_install_render"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository_change_request.reject"
                ]
              },
              "rejected_at": {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              }
            },
            "required": [
              "type",
              "rejected_at"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository_change_request.withdraw"
                ]
              },
              "withdrawn_at": {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              }
            },
            "required": [
              "type",
              "withdrawn_at"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository_change_request.expire"
                ]
              },
              "expired": {
                "type": "boolean"
              }
            },
            "required": [
              "type",
              "expired"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "opencode.suspend"
                ]
              },
              "opencode_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 70
              },
              "state": {
                "type": "string",
                "enum": [
                  "SUSPENDED"
                ]
              }
            },
            "required": [
              "type",
              "opencode_id",
              "state"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "opencode.resume"
                ]
              },
              "opencode_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 70
              },
              "state": {
                "type": "string",
                "enum": [
                  "ACTIVE"
                ]
              }
            },
            "required": [
              "type",
              "opencode_id",
              "state"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "opencode.delete"
                ]
              },
              "opencode_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 70
              },
              "state": {
                "type": "string",
                "enum": [
                  "DELETED"
                ]
              }
            },
            "required": [
              "type",
              "opencode_id",
              "state"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository.delete"
                ]
              },
              "purged_at": {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              }
            },
            "required": [
              "type",
              "purged_at"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "sandbox.create"
                ]
              },
              "sandbox_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "sandbox_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "sandbox.suspend"
                ]
              },
              "sandbox_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "sandbox_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "sandbox.resume"
                ]
              },
              "sandbox_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "sandbox_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "sandbox.delete"
                ]
              },
              "sandbox_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "sandbox_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "connect.vault.delete"
                ]
              },
              "vault_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "vault_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "connect.connection.revoke"
                ]
              },
              "connection_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "type",
              "connection_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "null"
          }
        ],
        "description": "Populated only when `done && state === \"SUCCEEDED\"`. Discriminated by `type`."
      },
      "OperationMetadata": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.join_token.revoke"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "token_id": {
                "type": "string",
                "pattern": "^[a-z0-9]{6}$"
              }
            },
            "required": [
              "type",
              "workspace_id",
              "cluster_id",
              "token_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "machine.create"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "compute_config_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "instance_type": {
                "type": "string"
              },
              "managed": {
                "type": "boolean"
              },
              "request_fingerprint": {
                "type": "string",
                "minLength": 1
              }
            },
            "required": [
              "type",
              "workspace_id",
              "instance_type",
              "managed",
              "request_fingerprint"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "machine.delete"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "machine_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "request_fingerprint": {
                "type": "string",
                "minLength": 1
              }
            },
            "required": [
              "type",
              "workspace_id",
              "machine_id",
              "request_fingerprint"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "machine.suspend"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "machine_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "request_fingerprint": {
                "type": "string",
                "minLength": 1
              }
            },
            "required": [
              "type",
              "workspace_id",
              "machine_id",
              "request_fingerprint"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "machine.resume"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "machine_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "request_fingerprint": {
                "type": "string",
                "minLength": 1
              }
            },
            "required": [
              "type",
              "workspace_id",
              "machine_id",
              "request_fingerprint"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.delete"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "cluster_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.create"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "cluster_id": {
                "type": "string",
                "description": "ID of the new cluster. Set once the cluster record exists, before provisioning finishes.",
                "minLength": 1,
                "maxLength": 54
              },
              "name": {
                "type": "string"
              },
              "kind": {
                "type": "string",
                "enum": [
                  "hosted",
                  "attached"
                ]
              },
              "region_id": {
                "anyOf": [
                  {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 54
                  },
                  {
                    "type": "null"
                  }
                ],
                "description": "The Region of a hosted Cluster; null for an attached one."
              }
            },
            "required": [
              "type",
              "workspace_id",
              "name",
              "kind",
              "region_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "node_pool.create",
                  "node_pool.set_size",
                  "node_pool.delete"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "node_pool_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 40
              },
              "node_count": {
                "anyOf": [
                  {
                    "type": "integer"
                  },
                  {
                    "type": "null"
                  }
                ],
                "description": "The size the Operation moves the pool to; null for a deletion."
              }
            },
            "required": [
              "type",
              "workspace_id",
              "cluster_id",
              "node_pool_id",
              "node_count"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.node.remove"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "node_name": {
                "type": "string",
                "minLength": 1,
                "maxLength": 253
              }
            },
            "required": [
              "type",
              "workspace_id",
              "cluster_id",
              "node_name"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.suspend"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "cluster_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.resume"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "cluster_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.capabilities.refresh"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "cluster_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.capability.ensure"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "capability": {
                "type": "string",
                "minLength": 1
              }
            },
            "required": [
              "type",
              "cluster_id",
              "capability"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cluster.worker_bootstrap.revoke"
                ]
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "worker_bootstrap_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "cluster_id",
              "worker_bootstrap_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "install.create"
                ]
              },
              "idempotency_key": {
                "type": "string"
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "product_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "type",
              "idempotency_key",
              "workspace_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "install.render"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "trigger_commit_sha": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "install_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "install.delete"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "type",
              "install_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "install.update"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "type",
              "install_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "preview_hostname.bind_pinned"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "render_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "protocol": {
                "type": "string",
                "enum": [
                  "http",
                  "websocket",
                  "grpc"
                ]
              },
              "routing_mode": {
                "type": "string",
                "enum": [
                  "through_dispatcher",
                  "bypass_dispatcher"
                ]
              },
              "idempotency_key": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "install_id",
              "render_id",
              "protocol",
              "routing_mode",
              "idempotency_key"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "preview_hostname.bind_floating"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "track": {
                "type": "string",
                "minLength": 1,
                "maxLength": 100
              },
              "render_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "protocol": {
                "type": "string",
                "enum": [
                  "http",
                  "websocket",
                  "grpc"
                ]
              },
              "routing_mode": {
                "type": "string",
                "enum": [
                  "through_dispatcher",
                  "bypass_dispatcher"
                ]
              },
              "idempotency_key": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "install_id",
              "track",
              "render_id",
              "protocol",
              "routing_mode",
              "idempotency_key"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "preview_hostname.delete"
                ]
              },
              "install_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "preview_hostname_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "if_match": {
                "type": "string"
              },
              "idempotency_key": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "install_id",
              "preview_hostname_id",
              "if_match",
              "idempotency_key"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "workspace.delete"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              }
            },
            "required": [
              "type",
              "workspace_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "workspace.subscription.cancel"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "mode": {
                "type": "string",
                "enum": [
                  "period_end"
                ]
              }
            },
            "required": [
              "type",
              "workspace_id",
              "mode"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "workspace.subdomain.set_name"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "name": {
                "type": "string",
                "minLength": 1,
                "maxLength": 63
              },
              "idempotency_key": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "workspace_id",
              "name",
              "idempotency_key"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "custom_domain.create"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "hostname": {
                "type": "string",
                "minLength": 1,
                "maxLength": 253
              },
              "target": {
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "enum": [
                          "install"
                        ]
                      },
                      "install_id": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 55
                      }
                    },
                    "required": [
                      "kind",
                      "install_id"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "enum": [
                          "cluster"
                        ]
                      },
                      "cluster_id": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 54
                      }
                    },
                    "required": [
                      "kind",
                      "cluster_id"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "enum": [
                          "external"
                        ]
                      },
                      "endpoint": {
                        "type": "string",
                        "format": "uri"
                      },
                      "mtls_secret_id": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 54
                      }
                    },
                    "required": [
                      "kind",
                      "endpoint"
                    ],
                    "additionalProperties": false
                  }
                ]
              },
              "protocol": {
                "type": "string",
                "enum": [
                  "http",
                  "websocket",
                  "grpc"
                ]
              },
              "routing_mode": {
                "type": "string",
                "enum": [
                  "through_dispatcher",
                  "bypass_dispatcher"
                ]
              },
              "idempotency_key": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "workspace_id",
              "hostname",
              "target",
              "protocol",
              "routing_mode",
              "idempotency_key"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "custom_domain.update"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "custom_domain_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "target": {
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "enum": [
                          "install"
                        ]
                      },
                      "install_id": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 55
                      }
                    },
                    "required": [
                      "kind",
                      "install_id"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "enum": [
                          "cluster"
                        ]
                      },
                      "cluster_id": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 54
                      }
                    },
                    "required": [
                      "kind",
                      "cluster_id"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "enum": [
                          "external"
                        ]
                      },
                      "endpoint": {
                        "type": "string",
                        "format": "uri"
                      },
                      "mtls_secret_id": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 54
                      }
                    },
                    "required": [
                      "kind",
                      "endpoint"
                    ],
                    "additionalProperties": false
                  }
                ]
              },
              "protocol": {
                "type": "string",
                "enum": [
                  "http",
                  "websocket",
                  "grpc"
                ]
              },
              "routing_mode": {
                "type": "string",
                "enum": [
                  "through_dispatcher",
                  "bypass_dispatcher"
                ]
              },
              "if_match": {
                "type": "string"
              },
              "idempotency_key": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "workspace_id",
              "custom_domain_id",
              "if_match",
              "idempotency_key"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "custom_domain.delete"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "custom_domain_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "if_match": {
                "type": "string"
              },
              "idempotency_key": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "workspace_id",
              "custom_domain_id",
              "if_match",
              "idempotency_key"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cloudflare.private_origin_route.prepare"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "cluster_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "route_intent_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "workspace_id",
              "cluster_id",
              "route_intent_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "cloudflare.private_origin_route.release"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "route_intent_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "workspace_id",
              "route_intent_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "package.create"
                ]
              },
              "idempotency_key": {
                "type": "string"
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "name": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "idempotency_key",
              "workspace_id",
              "name"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "package.version.publish_hosted"
                ]
              },
              "idempotency_key": {
                "type": "string"
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "package_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "request_fingerprint": {
                "type": "string",
                "minLength": 1
              }
            },
            "required": [
              "type",
              "idempotency_key",
              "workspace_id",
              "package_id",
              "request_fingerprint"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "package.version.publish_local_chart"
                ]
              },
              "idempotency_key": {
                "type": "string"
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "package_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "idempotency_key",
              "workspace_id",
              "package_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "package.version.publish"
                ]
              },
              "idempotency_key": {
                "type": "string"
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "package_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "version": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128
              }
            },
            "required": [
              "type",
              "idempotency_key",
              "workspace_id",
              "package_id",
              "version"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository_change_request.create"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "parent_repository_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "created_by_kind": {
                "type": "string",
                "enum": [
                  "agent",
                  "wizard",
                  "user"
                ]
              }
            },
            "required": [
              "type",
              "workspace_id",
              "parent_repository_id",
              "created_by_kind"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository_change_request.accept"
                ]
              },
              "repository_change_request_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "user_id": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "repository_change_request_id",
              "user_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository_change_request.reject"
                ]
              },
              "repository_change_request_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "user_id": {
                "type": "string"
              },
              "reason": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "repository_change_request_id",
              "user_id",
              "reason"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository_change_request.withdraw"
                ]
              },
              "repository_change_request_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "user_id": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "repository_change_request_id",
              "user_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository_change_request.expire"
                ]
              },
              "repository_change_request_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "repository_change_request_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "opencode.suspend"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "opencode_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 70
              },
              "idempotency_key": {
                "type": "string"
              },
              "reason": {
                "type": "string",
                "enum": [
                  "manual",
                  "workspace_deleted"
                ]
              }
            },
            "required": [
              "type",
              "workspace_id",
              "opencode_id",
              "idempotency_key"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "opencode.resume"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "opencode_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 70
              },
              "idempotency_key": {
                "type": "string"
              },
              "reason": {
                "type": "string",
                "enum": [
                  "manual",
                  "workspace_deleted"
                ]
              }
            },
            "required": [
              "type",
              "workspace_id",
              "opencode_id",
              "idempotency_key"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "opencode.delete"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "opencode_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 70
              },
              "idempotency_key": {
                "type": "string"
              },
              "reason": {
                "type": "string",
                "enum": [
                  "manual",
                  "workspace_deleted"
                ]
              }
            },
            "required": [
              "type",
              "workspace_id",
              "opencode_id",
              "idempotency_key"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "repository.delete"
                ]
              },
              "repository_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "type",
              "repository_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "sandbox.create"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "sandbox_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "source_sandbox_id": {
                "type": "string",
                "description": "Set when the sandbox is a fork of another sandbox.",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "workspace_id",
              "sandbox_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "sandbox.suspend"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "sandbox_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "reason": {
                "type": "string",
                "enum": [
                  "manual",
                  "idle"
                ],
                "description": "`idle`: the sandbox suspended itself after its idle timeout."
              }
            },
            "required": [
              "type",
              "workspace_id",
              "sandbox_id",
              "reason"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "sandbox.resume"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "sandbox_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "workspace_id",
              "sandbox_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "sandbox.delete"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "sandbox_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "reason": {
                "type": "string",
                "enum": [
                  "manual",
                  "orphaned",
                  "workspace_deleted"
                ],
                "description": "`orphaned`: nobody had access to the sandbox for 7 days. `workspace_deleted`: its workspace is being deleted."
              }
            },
            "required": [
              "type",
              "workspace_id",
              "sandbox_id",
              "reason"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "connect.vault.delete"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "vault_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              }
            },
            "required": [
              "type",
              "workspace_id",
              "vault_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "connect.connection.revoke"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              },
              "vault_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "connection_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "type",
              "workspace_id",
              "vault_id",
              "connection_id"
            ],
            "additionalProperties": false
          }
        ]
      },
      "OpenCodeServer": {
        "type": "object",
        "properties": {
          "id": {
            "$ref": "#/components/schemas/OpenCodeServerId"
          },
          "workspace_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 53
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Display name."
          },
          "hostname": {
            "type": "string",
            "pattern": "^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?$",
            "description": "DNS label chosen for the server's browser UI; unique across the platform. Created from the name plus a short random suffix when not given. The UI is served at `web_url` until chosen hostnames are routed.",
            "examples": [
              "acme-agents"
            ]
          },
          "labels": {
            "type": "object",
            "propertyNames": {
              "type": "string",
              "minLength": 1,
              "maxLength": 63
            },
            "additionalProperties": {
              "type": "string",
              "maxLength": 63
            },
            "maxProperties": 32,
            "description": "Free-form string labels: up to 32 keys of up to 63 characters."
          },
          "state": {
            "$ref": "#/components/schemas/OpenCodeServerState"
          },
          "default": {
            "type": "boolean",
            "description": "True for the Workspace's default server, which exists as soon as the Workspace uses OpenCode and cannot be deleted."
          },
          "budget": {
            "$ref": "#/components/schemas/OpenCodeBudget"
          },
          "features": {
            "$ref": "#/components/schemas/OpenCodeFeatures"
          },
          "vault_id": {
            "$ref": "#/components/schemas/VaultId_2"
          },
          "web_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Where people open the server's web UI: `https://oc-<key>.akua.run/`, a browser origin of its own, derived from the server id. `null` when this deployment hosts no OpenCode Servers."
          },
          "server_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "The long form of the server's address, `https://<api host>/v1/opencodes/{id}/`: OpenCode's protocol under `api/`, its web UI at the base. `null` when this deployment hosts no OpenCode Servers."
          },
          "short_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "The short form, `https://<site host>/{id}/`: protocol requests only, always with an explicit token. `null` when this deployment has none."
          },
          "created_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "updated_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "etag": {
            "type": "string",
            "description": "Send as `If-Match` on `PATCH`."
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "hostname",
          "labels",
          "state",
          "default",
          "budget",
          "features",
          "vault_id",
          "web_url",
          "server_url",
          "short_url",
          "created_at",
          "updated_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "VaultId_2": {
        "type": "string",
        "description": "The Vault of the server's third-party credentials: the one named at creation, or the Vault created for this server."
      },
      "OpenCodeFeatures": {
        "type": "object",
        "properties": {
          "worktrees": {
            "type": "boolean",
            "description": "OpenCode worktree creation in the web UI."
          },
          "terminal": {
            "type": "boolean",
            "description": "OpenCode terminals in the web UI."
          }
        },
        "required": [
          "worktrees",
          "terminal"
        ],
        "additionalProperties": false,
        "description": "Web UI feature toggles. Everything else in OpenCode's UI stays on."
      },
      "OpenCodeBudget": {
        "type": "object",
        "properties": {
          "monthly_limit": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "description": "Monthly limit in metered usage units. The unit and its pricing are not defined yet; the value is stored and returned, not enforced. `null`: no limit."
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "monthly_limit"
        ],
        "additionalProperties": false
      },
      "OpenCodeServerState": {
        "type": "string",
        "enum": [
          "ACTIVE",
          "SUSPENDING",
          "SUSPENDED",
          "RESUMING",
          "DELETING",
          "DELETED"
        ],
        "description": "`ACTIVE`: serves OpenCode protocol traffic. `SUSPENDED`: the gateway refuses protocol traffic until it is resumed. `DELETED`: terminal; the id stays reserved. `SUSPENDING`, `RESUMING` and `DELETING`: a requested change is in progress; its Operation finishes when the server reached the new state. A deletion always finishes."
      },
      "UpdateOpenCodeServer": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Display name."
          },
          "hostname": {
            "type": "string",
            "pattern": "^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?$",
            "description": "DNS label chosen for the server's browser UI; unique across the platform. Created from the name plus a short random suffix when not given. The UI is served at `web_url` until chosen hostnames are routed.",
            "examples": [
              "acme-agents"
            ]
          },
          "labels": {
            "type": "object",
            "propertyNames": {
              "type": "string",
              "minLength": 1,
              "maxLength": 63
            },
            "additionalProperties": {
              "type": "string",
              "maxLength": 63
            },
            "maxProperties": 32,
            "description": "Free-form string labels: up to 32 keys of up to 63 characters."
          },
          "budget": {
            "$ref": "#/components/schemas/OpenCodeBudget"
          },
          "features": {
            "type": "object",
            "properties": {
              "worktrees": {
                "type": "boolean",
                "description": "OpenCode worktree creation in the web UI."
              },
              "terminal": {
                "type": "boolean",
                "description": "OpenCode terminals in the web UI."
              }
            },
            "additionalProperties": false
          }
        },
        "additionalProperties": false,
        "description": "Fields left out stay as they are. `labels` replaces the whole map; `features` changes only the toggles named."
      },
      "OpenCodeServerList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OpenCodeServer"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "CreateOpenCodeServer": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Display name."
          },
          "hostname": {
            "type": "string",
            "pattern": "^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?$",
            "description": "DNS label chosen for the server's browser UI; unique across the platform. Created from the name plus a short random suffix when not given. The UI is served at `web_url` until chosen hostnames are routed.",
            "examples": [
              "acme-agents"
            ]
          },
          "labels": {
            "type": "object",
            "propertyNames": {
              "type": "string",
              "minLength": 1,
              "maxLength": 63
            },
            "additionalProperties": {
              "type": "string",
              "maxLength": 63
            },
            "maxProperties": 32,
            "description": "Free-form string labels: up to 32 keys of up to 63 characters."
          },
          "budget": {
            "$ref": "#/components/schemas/OpenCodeBudget"
          },
          "features": {
            "$ref": "#/components/schemas/OpenCodeFeatures"
          },
          "vault_id": {
            "$ref": "#/components/schemas/VaultId_1"
          }
        },
        "required": [
          "name"
        ],
        "additionalProperties": false
      },
      "VaultId_1": {
        "type": "string",
        "description": "An existing Vault of this Workspace that you may use. The server does not own it. Left out, a new Vault is created for this server."
      },
      "ApiExternalServiceError": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "ExternalServiceError"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/ApiErrorEntry"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/ApiErrorEntry"
            }
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "SandboxAccessGrantId": {
        "type": "string",
        "pattern": "^sbxg_[A-Za-z0-9]{1,64}$",
        "title": "Sandbox access grant id",
        "description": "Sandbox access grant id (`sbxg_...`).",
        "examples": [
          "sbxg_j572abc123def456"
        ]
      },
      "SandboxId": {
        "type": "string",
        "pattern": "^sbx_[A-Za-z0-9]{1,64}$",
        "title": "Sandbox id",
        "description": "Sandbox id (`sbx_...`).",
        "examples": [
          "sbx_j572abc123def456"
        ]
      },
      "SandboxAccessGrantList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SandboxAccessGrant"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "SandboxAccessGrant": {
        "type": "object",
        "properties": {
          "id": {
            "$ref": "#/components/schemas/SandboxAccessGrantId"
          },
          "sandbox_id": {
            "$ref": "#/components/schemas/SandboxId"
          },
          "subject_type": {
            "type": "string",
            "enum": [
              "user",
              "opencode",
              "workspace"
            ],
            "description": "A Workspace member, an OpenCode Server, or every current member of this sandbox's Workspace."
          },
          "subject_id": {
            "type": "string"
          },
          "permissions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SandboxPermission"
            }
          },
          "created_by": {
            "$ref": "#/components/schemas/SandboxActor"
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Grant time (Unix seconds)."
          }
        },
        "required": [
          "id",
          "sandbox_id",
          "subject_type",
          "subject_id",
          "permissions",
          "created_by",
          "created_at"
        ],
        "additionalProperties": false
      },
      "SandboxActor": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "user",
              "opencode"
            ],
            "description": "`user`: a workspace member. `opencode`: an OpenCode Server (`oc_...`)."
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          }
        },
        "required": [
          "type",
          "id"
        ],
        "additionalProperties": false
      },
      "SandboxPermission": {
        "type": "string",
        "enum": [
          "run_commands",
          "files",
          "terminal",
          "previews",
          "manage"
        ],
        "description": "`run_commands`: commands. `files`: files. `terminal`: terminals. `previews`: reserved; sandboxes have no previews. `manage`: all permissions, lifecycle, settings and access grants."
      },
      "CreateSandboxAccessGrantBody": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "subject_type": {
                "type": "string",
                "enum": [
                  "user",
                  "opencode"
                ],
                "description": "`user`: a workspace member. `opencode`: an OpenCode Server (`oc_...`)."
              },
              "subject_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 100
              },
              "permissions": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/SandboxPermission"
                },
                "minItems": 1,
                "maxItems": 5
              }
            },
            "required": [
              "subject_type",
              "subject_id",
              "permissions"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "subject_type": {
                "type": "string",
                "enum": [
                  "workspace"
                ]
              },
              "subject_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 100,
                "description": "This sandbox's Workspace id. May be omitted; another Workspace is never accepted."
              },
              "permissions": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/SandboxPermission"
                },
                "minItems": 1,
                "maxItems": 5
              }
            },
            "required": [
              "subject_type",
              "permissions"
            ],
            "additionalProperties": false
          }
        ]
      },
      "SandboxFileInfo": {
        "type": "object",
        "properties": {
          "path": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "enum": [
              "file",
              "directory",
              "symlink",
              "other"
            ]
          },
          "size": {
            "type": "integer",
            "minimum": 0
          },
          "mode": {
            "type": "string",
            "description": "Permission bits in octal.",
            "examples": [
              "0644"
            ]
          },
          "modified_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Last modification (Unix seconds)."
          }
        },
        "required": [
          "path",
          "type",
          "size",
          "mode",
          "modified_at"
        ],
        "additionalProperties": false
      },
      "MakeSandboxDirectoryBody": {
        "type": "object",
        "properties": {
          "path": {
            "type": "string",
            "minLength": 1,
            "maxLength": 4096,
            "pattern": "^\\/[^\\0]*$",
            "description": "Absolute path inside the sandbox.",
            "examples": [
              "/workspace/README.md"
            ]
          },
          "parents": {
            "type": "boolean",
            "default": true
          }
        },
        "required": [
          "path"
        ],
        "additionalProperties": false
      },
      "MoveSandboxFileBody": {
        "type": "object",
        "properties": {
          "from": {
            "type": "string",
            "minLength": 1,
            "maxLength": 4096,
            "pattern": "^\\/[^\\0]*$",
            "description": "Absolute path inside the sandbox.",
            "examples": [
              "/workspace/README.md"
            ]
          },
          "to": {
            "type": "string",
            "minLength": 1,
            "maxLength": 4096,
            "pattern": "^\\/[^\\0]*$",
            "description": "Absolute path inside the sandbox.",
            "examples": [
              "/workspace/README.md"
            ]
          },
          "overwrite": {
            "type": "boolean",
            "default": false
          }
        },
        "required": [
          "from",
          "to"
        ],
        "additionalProperties": false
      },
      "RemoveSandboxFilesBody": {
        "type": "object",
        "properties": {
          "paths": {
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 4096,
              "pattern": "^\\/[^\\0]*$",
              "description": "Absolute path inside the sandbox.",
              "examples": [
                "/workspace/README.md"
              ]
            },
            "minItems": 1,
            "maxItems": 100
          },
          "recursive": {
            "type": "boolean",
            "default": false
          }
        },
        "required": [
          "paths"
        ],
        "additionalProperties": false
      },
      "SandboxPathBody": {
        "type": "object",
        "properties": {
          "path": {
            "type": "string",
            "minLength": 1,
            "maxLength": 4096,
            "pattern": "^\\/[^\\0]*$",
            "description": "Absolute path inside the sandbox.",
            "examples": [
              "/workspace/README.md"
            ]
          }
        },
        "required": [
          "path"
        ],
        "additionalProperties": false
      },
      "SandboxFileList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SandboxFileInfo"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "ListSandboxFilesBody": {
        "type": "object",
        "properties": {
          "path": {
            "type": "string",
            "minLength": 1,
            "maxLength": 4096,
            "pattern": "^\\/[^\\0]*$",
            "description": "Absolute path inside the sandbox.",
            "examples": [
              "/workspace/README.md"
            ]
          },
          "recursive": {
            "type": "boolean",
            "default": false
          },
          "limit": {
            "type": "integer",
            "minimum": 1,
            "maximum": 1000,
            "default": 200
          },
          "cursor": {
            "type": "string",
            "maxLength": 4096
          }
        },
        "required": [
          "path"
        ],
        "additionalProperties": false
      },
      "SandboxFileInfos": {
        "type": "object",
        "properties": {
          "files": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SandboxFileInfo"
            }
          }
        },
        "required": [
          "files"
        ],
        "additionalProperties": false
      },
      "WriteSandboxFilesBody": {
        "type": "object",
        "properties": {
          "files": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "path": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 4096,
                  "pattern": "^\\/[^\\0]*$",
                  "description": "Absolute path inside the sandbox.",
                  "examples": [
                    "/workspace/README.md"
                  ]
                },
                "content": {
                  "type": "string"
                },
                "encoding": {
                  "type": "string",
                  "enum": [
                    "utf8",
                    "base64"
                  ],
                  "default": "utf8"
                }
              },
              "required": [
                "path",
                "content"
              ],
              "additionalProperties": false
            },
            "minItems": 1,
            "maxItems": 1000
          },
          "create_parents": {
            "type": "boolean",
            "default": true
          }
        },
        "required": [
          "files"
        ],
        "additionalProperties": false
      },
      "SandboxCommandId": {
        "type": "string",
        "pattern": "^cmd_[A-Za-z0-9]{1,64}$",
        "title": "Sandbox command id",
        "description": "Sandbox command id (`cmd_...`).",
        "examples": [
          "cmd_j572abc123def456"
        ]
      },
      "WriteSandboxStdinBody": {
        "type": "object",
        "properties": {
          "data": {
            "type": "string",
            "maxLength": 1048576,
            "description": "Text to write."
          },
          "close": {
            "type": "boolean",
            "description": "Close standard input afterwards.",
            "default": false
          }
        },
        "required": [
          "data"
        ],
        "additionalProperties": false
      },
      "SandboxCommand": {
        "type": "object",
        "properties": {
          "id": {
            "$ref": "#/components/schemas/SandboxCommandId"
          },
          "sandbox_id": {
            "$ref": "#/components/schemas/SandboxId"
          },
          "argv": {
            "anyOf": [
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              {
                "type": "null"
              }
            ]
          },
          "shell": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "cwd": {
            "type": "string"
          },
          "timeout_seconds": {
            "type": "integer"
          },
          "state": {
            "$ref": "#/components/schemas/SandboxCommandState"
          },
          "exit_code": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "description": "Set once the command finished."
          },
          "created_by": {
            "$ref": "#/components/schemas/SandboxActor"
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Start time (Unix seconds)."
          },
          "finished_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "description": "Finish time (Unix seconds)."
              },
              {
                "type": "null"
              }
            ]
          },
          "output": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/SandboxCommandOutput"
              },
              {
                "type": "null"
              }
            ],
            "description": "Captured output, only on the response to a `wait: true` request that finished in time; `null` elsewhere."
          }
        },
        "required": [
          "id",
          "sandbox_id",
          "argv",
          "shell",
          "cwd",
          "timeout_seconds",
          "state",
          "exit_code",
          "created_by",
          "created_at",
          "finished_at",
          "output"
        ],
        "additionalProperties": false
      },
      "SandboxCommandOutput": {
        "type": "object",
        "properties": {
          "stdout": {
            "type": "string"
          },
          "stderr": {
            "type": "string"
          },
          "truncated": {
            "type": "boolean",
            "description": "True when the output is longer than the 64 KiB returned here; read it all with `logs:stream`."
          }
        },
        "required": [
          "stdout",
          "stderr",
          "truncated"
        ],
        "additionalProperties": false
      },
      "SandboxCommandState": {
        "type": "string",
        "enum": [
          "RUNNING",
          "SUCCEEDED",
          "FAILED",
          "CANCELLED"
        ],
        "description": "`SUCCEEDED`: exited with code 0. `FAILED`: exited with another code, was killed, or hit its timeout (exit code 124)."
      },
      "SandboxCommandList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SandboxCommand"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "RunSandboxCommandBody": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "argv": {
                "type": "array",
                "items": {
                  "type": "string",
                  "maxLength": 16384
                },
                "minItems": 1,
                "maxItems": 256,
                "description": "Program and arguments, run without a shell."
              },
              "cwd": {
                "type": "string",
                "minLength": 1,
                "maxLength": 4096,
                "pattern": "^\\/[^\\0]*$",
                "description": "Absolute path inside the sandbox.",
                "default": "/workspace",
                "examples": [
                  "/workspace/README.md"
                ]
              },
              "env": {
                "$ref": "#/components/schemas/SandboxEnv"
              },
              "timeout_seconds": {
                "type": "integer",
                "minimum": 1,
                "maximum": 86400,
                "description": "Seconds before the command is killed. Default 600.",
                "default": 600
              },
              "wait": {
                "type": "boolean",
                "description": "Return when the command finished, for at most 60 seconds, with its output. Otherwise return as soon as it started.",
                "default": false
              },
              "stdin": {
                "type": "boolean",
                "description": "Keep standard input open for `:writeStdin`. Default false (empty input).",
                "default": false
              }
            },
            "required": [
              "argv"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "shell": {
                "type": "string",
                "minLength": 1,
                "maxLength": 16384,
                "description": "A `bash -lc` command line."
              },
              "cwd": {
                "type": "string",
                "minLength": 1,
                "maxLength": 4096,
                "pattern": "^\\/[^\\0]*$",
                "description": "Absolute path inside the sandbox.",
                "default": "/workspace",
                "examples": [
                  "/workspace/README.md"
                ]
              },
              "env": {
                "$ref": "#/components/schemas/SandboxEnv"
              },
              "timeout_seconds": {
                "type": "integer",
                "minimum": 1,
                "maximum": 86400,
                "description": "Seconds before the command is killed. Default 600.",
                "default": 600
              },
              "wait": {
                "type": "boolean",
                "description": "Return when the command finished, for at most 60 seconds, with its output. Otherwise return as soon as it started.",
                "default": false
              },
              "stdin": {
                "type": "boolean",
                "description": "Keep standard input open for `:writeStdin`. Default false (empty input).",
                "default": false
              }
            },
            "required": [
              "shell"
            ],
            "additionalProperties": false
          }
        ]
      },
      "SandboxEnv": {
        "type": "object",
        "additionalProperties": {
          "type": "string",
          "maxLength": 4096
        }
      },
      "ForkSandboxBody": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Display name.",
            "examples": [
              "checkout-service"
            ]
          },
          "labels": {
            "$ref": "#/components/schemas/SandboxLabels"
          }
        },
        "required": [
          "name"
        ],
        "additionalProperties": false
      },
      "SandboxLabels": {
        "type": "object",
        "additionalProperties": {
          "type": "string",
          "maxLength": 256
        }
      },
      "Sandbox": {
        "type": "object",
        "properties": {
          "id": {
            "$ref": "#/components/schemas/SandboxId"
          },
          "workspace_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 53
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Display name.",
            "examples": [
              "checkout-service"
            ]
          },
          "state": {
            "$ref": "#/components/schemas/SandboxState"
          },
          "size": {
            "$ref": "#/components/schemas/SandboxSize"
          },
          "source": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/SandboxSource"
              },
              {
                "type": "null"
              }
            ],
            "description": "`null` for a sandbox created empty."
          },
          "network_policy": {
            "$ref": "#/components/schemas/SandboxNetworkPolicy"
          },
          "idle_timeout_seconds": {
            "type": "integer",
            "minimum": 300,
            "maximum": 86400,
            "description": "Seconds without API activity after which the sandbox suspends itself. Commands that are still running keep it awake. 300 to 86400; default 600.",
            "default": 600,
            "examples": [
              600
            ]
          },
          "env": {
            "$ref": "#/components/schemas/SandboxEnv"
          },
          "labels": {
            "$ref": "#/components/schemas/SandboxLabels"
          },
          "created_by": {
            "$ref": "#/components/schemas/SandboxActor"
          },
          "usage": {
            "$ref": "#/components/schemas/SandboxUsage"
          },
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Condition"
            },
            "maxItems": 32,
            "description": "What needs attention now; empty when nothing does. Reasons:\n- `create-failed` (error): the sandbox could not be created; it is `FAILED` and can only be deleted.\n- `suspend-failed` (warning): the last suspend failed; the sandbox stays `ACTIVE`.\n- `resume-failed` (warning): the last resume failed; the sandbox stays `SUSPENDED`."
          },
          "last_active_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "description": "Last API activity (Unix seconds)."
              },
              {
                "type": "null"
              }
            ]
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Creation time (Unix seconds)."
          },
          "updated_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Last change (Unix seconds)."
          },
          "etag": {
            "type": "string",
            "description": "Opaque version token. Send it as `If-Match` on writes."
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "state",
          "size",
          "source",
          "network_policy",
          "idle_timeout_seconds",
          "env",
          "labels",
          "created_by",
          "usage",
          "conditions",
          "last_active_at",
          "created_at",
          "updated_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "Condition": {
        "type": "object",
        "properties": {
          "reason": {
            "type": "string",
            "maxLength": 64,
            "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$",
            "description": "Kebab-case reason; the resource documents the reasons it reports.",
            "examples": [
              "agent-offline"
            ]
          },
          "severity": {
            "type": "string",
            "enum": [
              "error",
              "warning",
              "info"
            ],
            "description": "`error`: the resource failed; the condition says why. `warning`: it is limited or held until the person acts or it recovers. `info`: worth knowing, nothing to do."
          },
          "message": {
            "type": "string",
            "maxLength": 512,
            "description": "Safe to show the person as is."
          },
          "remedy": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/FailureRemedy"
              },
              {
                "type": "null"
              }
            ],
            "description": "What the person can do; null when nothing they do helps."
          },
          "last_transition_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Unix timestamp (seconds) when this condition last changed."
          }
        },
        "required": [
          "reason",
          "severity",
          "message",
          "remedy",
          "last_transition_at"
        ],
        "additionalProperties": false
      },
      "FailureRemedy": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "free-capacity"
                ]
              },
              "metric": {
                "type": "string",
                "enum": [
                  "kaas/clusters",
                  "compute/machines",
                  "compute/cpu",
                  "compute/memory",
                  "compute/machines_concurrency",
                  "compute/managed_vm_trial",
                  "agents/turns_concurrency",
                  "agents/sandboxes",
                  "agents/sandboxes_running",
                  "agents/retained_filesystem_lifetime",
                  "codemode/executions",
                  "api/secrets_access",
                  "api/secrets_write",
                  "domain_routing/preview_hostnames",
                  "domain_routing/custom_domains",
                  "source_control/repositories"
                ]
              },
              "limit": {
                "type": "integer"
              },
              "usage": {
                "type": "integer"
              },
              "hint": {
                "type": "string",
                "maxLength": 256
              }
            },
            "required": [
              "kind",
              "metric",
              "limit",
              "usage",
              "hint"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "upgrade-plan"
                ]
              },
              "metric": {
                "type": "string",
                "enum": [
                  "kaas/clusters",
                  "compute/machines",
                  "compute/cpu",
                  "compute/memory",
                  "compute/machines_concurrency",
                  "compute/managed_vm_trial",
                  "agents/turns_concurrency",
                  "agents/sandboxes",
                  "agents/sandboxes_running",
                  "agents/retained_filesystem_lifetime",
                  "codemode/executions",
                  "api/secrets_access",
                  "api/secrets_write",
                  "domain_routing/preview_hostnames",
                  "domain_routing/custom_domains",
                  "source_control/repositories"
                ]
              }
            },
            "required": [
              "kind",
              "metric"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "grant-access"
                ]
              },
              "namespace": {
                "anyOf": [
                  {
                    "type": "string",
                    "maxLength": 63
                  },
                  {
                    "type": "null"
                  }
                ]
              },
              "permissions": {
                "type": "array",
                "prefixItems": [
                  {
                    "type": "string",
                    "maxLength": 256
                  }
                ],
                "minItems": 1,
                "items": {
                  "type": "string",
                  "maxLength": 256
                },
                "maxItems": 64
              }
            },
            "required": [
              "kind",
              "namespace",
              "permissions"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "reconnect"
                ]
              },
              "what": {
                "type": "string",
                "enum": [
                  "cluster-agent",
                  "connection"
                ]
              }
            },
            "required": [
              "kind",
              "what"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "add-machine"
                ]
              }
            },
            "required": [
              "kind"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "add-billing"
                ]
              }
            },
            "required": [
              "kind"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "change-input"
                ]
              },
              "path": {
                "type": "array",
                "items": {
                  "type": "string",
                  "maxLength": 128
                },
                "maxItems": 32
              }
            },
            "required": [
              "kind",
              "path"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "retry"
                ]
              },
              "after_seconds": {
                "anyOf": [
                  {
                    "type": "integer"
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "required": [
              "kind",
              "after_seconds"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "run-agent-install"
                ],
                "description": "Run the command from `POST /v1/clusters/{id}/connector_install` again; it re-applies the ClusterConnector and its updater at one release."
              }
            },
            "required": [
              "kind"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "customer-upgrade"
                ],
                "description": "The change needs rights the agent was not granted. Run `command` (a `helm upgrade`, no secret) with an identity that holds `permissions`, or grant them to the agent."
              },
              "permissions": {
                "type": "array",
                "prefixItems": [
                  {
                    "type": "string",
                    "maxLength": 256
                  }
                ],
                "minItems": 1,
                "items": {
                  "type": "string",
                  "maxLength": 256
                },
                "maxItems": 64
              },
              "command": {
                "type": "string",
                "minLength": 1,
                "maxLength": 8192
              }
            },
            "required": [
              "kind",
              "permissions",
              "command"
            ],
            "additionalProperties": false
          }
        ]
      },
      "SandboxUsage": {
        "type": "object",
        "properties": {
          "active_seconds": {
            "type": "integer",
            "minimum": 0,
            "description": "Seconds the sandbox has spent `ACTIVE`, including the current active period."
          },
          "cpu_seconds": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "CPU seconds used. `null` until CPU accounting is available."
          },
          "egress_bytes": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "Bytes sent to the network. `null` until network accounting is available."
          },
          "ingress_bytes": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "Bytes received from the network. `null` until network accounting is available."
          }
        },
        "required": [
          "active_seconds",
          "cpu_seconds",
          "egress_bytes",
          "ingress_bytes"
        ],
        "additionalProperties": false
      },
      "SandboxNetworkPolicy": {
        "type": "object",
        "properties": {
          "mode": {
            "type": "string",
            "enum": [
              "allow_all"
            ]
          }
        },
        "required": [
          "mode"
        ],
        "additionalProperties": false,
        "description": "Outbound network access. `allow_all` means public internet only: HTTP on TCP port 80, TLS on TCP port 443 (including HTTPS), and public DNS. Private, link-local, cluster-internal and execution-cluster node addresses are blocked. Cluster DNS names and other ports or protocols are unavailable."
      },
      "SandboxSource": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "sandbox"
            ]
          },
          "sandbox_id": {
            "$ref": "#/components/schemas/SandboxId"
          }
        },
        "required": [
          "type",
          "sandbox_id"
        ],
        "additionalProperties": false,
        "description": "Where the sandbox content comes from. `sandbox`: a copy of another sandbox from its latest snapshot (a fork). Repository, snapshot and template sources are added as new `type` values."
      },
      "SandboxSize": {
        "type": "string",
        "enum": [
          "standard"
        ],
        "description": "Compute size. `standard` is the only size today; larger sizes are added as new values."
      },
      "SandboxState": {
        "type": "string",
        "enum": [
          "PROVISIONING",
          "ACTIVE",
          "SUSPENDING",
          "SUSPENDED",
          "RESUMING",
          "DELETING",
          "FAILED"
        ],
        "description": "`ACTIVE` sandboxes run commands and file operations. `SUSPENDED` sandboxes keep their files and cost only storage. `-ING` states are in flight; `FAILED` sandboxes can only be deleted."
      },
      "UpdateSandboxBody": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Display name.",
            "examples": [
              "checkout-service"
            ]
          },
          "size": {
            "$ref": "#/components/schemas/SandboxSize"
          },
          "network_policy": {
            "$ref": "#/components/schemas/SandboxNetworkPolicy"
          },
          "idle_timeout_seconds": {
            "type": "integer",
            "minimum": 300,
            "maximum": 86400,
            "description": "Seconds without API activity after which the sandbox suspends itself. Commands that are still running keep it awake. 300 to 86400; default 600.",
            "default": 600,
            "examples": [
              600
            ]
          },
          "labels": {
            "$ref": "#/components/schemas/SandboxLabels"
          }
        },
        "additionalProperties": false
      },
      "SandboxList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Sandbox"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "CreateSandboxBody": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Display name.",
            "examples": [
              "checkout-service"
            ]
          },
          "size": {
            "$ref": "#/components/schemas/SandboxSize"
          },
          "source": {
            "$ref": "#/components/schemas/SandboxSource"
          },
          "network_policy": {
            "$ref": "#/components/schemas/SandboxNetworkPolicy"
          },
          "idle_timeout_seconds": {
            "type": "integer",
            "minimum": 300,
            "maximum": 86400,
            "description": "Seconds without API activity after which the sandbox suspends itself. Commands that are still running keep it awake. 300 to 86400; default 600.",
            "default": 600,
            "examples": [
              600
            ]
          },
          "env": {
            "$ref": "#/components/schemas/SandboxEnv"
          },
          "labels": {
            "$ref": "#/components/schemas/SandboxLabels"
          },
          "sharing": {
            "type": "string",
            "enum": [
              "private",
              "workspace"
            ],
            "description": "Explicit creation is private by default. `workspace` grants access to every current Workspace member.",
            "default": "private"
          },
          "sharing_permissions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/SandboxPermission"
            },
            "minItems": 1,
            "maxItems": 5,
            "description": "Workspace-sharing permissions; defaults to run_commands and files. manage stays with the owner unless explicitly included."
          }
        },
        "required": [
          "name"
        ],
        "additionalProperties": false
      },
      "MachineList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Machine"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "Machine": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "workspace_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 53
          },
          "region_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "location": {
            "type": "string",
            "maxLength": 32
          },
          "machine_type": {
            "$ref": "#/components/schemas/MachineType"
          },
          "image": {
            "$ref": "#/components/schemas/MachineImage"
          },
          "labels": {
            "$ref": "#/components/schemas/MachineLabels"
          },
          "name": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 120
              },
              {
                "type": "null"
              }
            ]
          },
          "provider_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "The server at its provider (`hcloud://<server id>`); null until the provider created it.",
            "examples": [
              "hcloud://1234"
            ]
          },
          "ipv4": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "ipv6": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "state": {
            "type": "string",
            "enum": [
              "PROVISIONING",
              "RUNNING",
              "SUSPENDING",
              "SUSPENDED",
              "RESTORING",
              "EXPIRED",
              "DELETING",
              "FAILED"
            ],
            "description": "Machine lifecycle state."
          },
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Condition"
            },
            "maxItems": 32,
            "description": "What needs attention now; empty when nothing does. Reasons:\n- `bootstrap-progress` (info): the latest guest-reported stage and report time. If progress stalls, this remains the last observation, not a readiness claim.\n- `bootstrap-failed` (error): guest bootstrap failed at the named step with its exit code. Provider state may remain RUNNING; no automatic replacement occurs.\n- `trial-ended` (warning): the free trial is over and the Machine is `SUSPENDED`; upgrade to Pro while its snapshot is retained to restore it. Remedy `upgrade-plan`.\n- `trial-data-expired` (warning): the snapshot expired or was deleted. No server can be restored from it; a Pro upgrade still succeeds.\n- `RESTORING` waits for the replacement server to run and, for a pool Machine, its node to join; only then is the snapshot removed.\n- When `state` is `FAILED`, one error whose reason says why: `capacity-unavailable`, `provider-refused`, `provider-unavailable` or `abandoned`. Its server and capacity were already released."
          },
          "trial": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "pauses_at": {
                    "anyOf": [
                      {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991,
                        "description": "Unix timestamp (seconds)"
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "When the free trial Machine pauses; null until it runs."
                  }
                },
                "required": [
                  "pauses_at"
                ],
                "additionalProperties": false
              },
              {
                "type": "null"
              }
            ]
          },
          "created_by": {
            "anyOf": [
              {
                "type": "string",
                "pattern": "^service:[\\s\\S]*?$"
              },
              {
                "type": "null"
              }
            ],
            "description": "The service that created it (`service:cluster` for a node pool), which also deletes it; null when a person did."
          },
          "operation_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 192,
            "description": "The latest Operation: the create, or the deletion."
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "updated_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "etag": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "region_id",
          "location",
          "machine_type",
          "image",
          "labels",
          "name",
          "provider_id",
          "ipv4",
          "ipv6",
          "state",
          "conditions",
          "trial",
          "created_by",
          "operation_id",
          "created_at",
          "updated_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "MachineLabels": {
        "type": "object",
        "patternProperties": {
          "^[a-z][a-z0-9_-]{0,62}$": {
            "type": "string",
            "pattern": "^[a-z0-9_-]{0,63}$"
          }
        },
        "additionalProperties": false,
        "maxProperties": 32,
        "examples": [
          {
            "team": "web"
          }
        ]
      },
      "MachineImage": {
        "anyOf": [
          {
            "type": "string",
            "enum": [
              "ubuntu-24.04"
            ]
          }
        ]
      },
      "MachineType": {
        "type": "string",
        "pattern": "^[a-z][a-z0-9-]{0,31}$",
        "examples": [
          "cx23"
        ]
      },
      "MachineBootstrapReport": {
        "type": "object",
        "properties": {
          "stage": {
            "type": "string",
            "enum": [
              "started",
              "hostname-set",
              "k0s-downloaded",
              "provider-configured",
              "k0s-installed",
              "worker-started",
              "joined",
              "failed"
            ]
          },
          "exit_code": {
            "type": "integer",
            "minimum": 0,
            "maximum": 255
          },
          "message": {
            "type": "string",
            "maxLength": 8192,
            "description": "Optional secret-free step: hostname, download-k0s, configure-provider-id, download-image-credential-provider, verify-image-credential-provider, install-worker, or start-worker. A provider download that kept failing may add its last curl result as `download-image-credential-provider: curl exit <code>, HTTP <status>`. Other text is omitted rather than exposed as guest output. Retained descriptions are bounded to 2 KiB."
          }
        },
        "required": [
          "stage"
        ],
        "additionalProperties": false
      },
      "ApiInternalServerError": {
        "type": "object",
        "properties": {
          "_tag": {
            "type": "string",
            "enum": [
              "InternalServerError"
            ]
          },
          "success": {
            "type": "boolean",
            "enum": [
              false
            ]
          },
          "errors": {
            "type": "array",
            "prefixItems": [
              {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "number",
                    "enum": [
                      7009
                    ]
                  },
                  "message": {
                    "type": "string",
                    "enum": [
                      "Internal server error"
                    ]
                  }
                },
                "required": [
                  "code",
                  "message"
                ],
                "additionalProperties": false
              }
            ],
            "maxItems": 1,
            "minItems": 1
          },
          "result": {
            "type": "object",
            "additionalProperties": false
          }
        },
        "required": [
          "_tag",
          "success",
          "errors",
          "result"
        ],
        "additionalProperties": false
      },
      "Node": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 253,
            "pattern": "^[a-z0-9](?:[-a-z0-9.]*[a-z0-9])?$"
          },
          "cluster_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "source": {
            "$ref": "#/components/schemas/NodeSource"
          },
          "state": {
            "type": "string",
            "enum": [
              "provisioning",
              "restoring",
              "ready",
              "draining",
              "deleted"
            ],
            "description": "`provisioning`: its Machine is being created or its server is joining.\n`ready`: joined; Kubernetes readiness is `ready` and `conditions`.\n`draining`: cordoned and evicting Pods before it is removed.\n`deleted`: removed from the Cluster."
          },
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Condition"
            },
            "maxItems": 32,
            "description": "What needs attention now; empty when nothing does. Reasons:\n- `not-ready` (warning): Kubernetes reports the node not ready.\n- `join-timeout` (error): the server started but never joined; its Machine was deleted.\n- `drain-timeout` (warning): Pods did not leave within the drain bound; the node was removed anyway.\n- `trial-ended` (warning): the node’s free trial Machine was paused. Remedy `add-billing`.\n- `capacity-unavailable`, `provider-refused`, `provider-unavailable` (error): its Machine could not be created; forwarded from the Machine."
          },
          "ready": {
            "type": "boolean",
            "description": "Kubernetes `Ready`; false until the node joined."
          },
          "provider_id": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 256
              },
              {
                "type": "null"
              }
            ],
            "description": "The node's `spec.providerID`; null without a cloud controller."
          },
          "labels": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            }
          },
          "kubelet_version": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 64
              },
              {
                "type": "null"
              }
            ]
          },
          "created_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Unix timestamp (seconds)"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "name",
          "cluster_id",
          "source",
          "state",
          "conditions",
          "ready",
          "provider_id",
          "labels",
          "kubelet_version",
          "created_at"
        ],
        "additionalProperties": false
      },
      "NodeSource": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "node_pool"
                ]
              },
              "node_pool_id": {
                "$ref": "#/components/schemas/NodePoolId"
              },
              "machine_id": {
                "type": "string",
                "minLength": 3,
                "maxLength": 54
              }
            },
            "required": [
              "kind",
              "node_pool_id",
              "machine_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "joined"
                ],
                "description": "Your own server, joined with a join token. Removing it drains it and removes it from the Cluster; the server itself is untouched."
              }
            },
            "required": [
              "kind"
            ],
            "additionalProperties": false
          }
        ]
      },
      "NodePoolId": {
        "type": "string",
        "pattern": "^[a-z](?:[-a-z0-9]{0,38}[a-z0-9])?$",
        "description": "A DNS label of at most 40 characters, unique in the Cluster. Every node of the pool carries it as the label `akua.dev/node-pool`.",
        "examples": [
          "default"
        ]
      },
      "NodeList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Node"
            },
            "maxItems": 500
          },
          "has_more": {
            "type": "boolean"
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "SetNodePoolSizeBody": {
        "type": "object",
        "properties": {
          "node_count": {
            "type": "integer",
            "minimum": 0,
            "maximum": 10,
            "description": "Number of nodes the pool keeps, 0 to 10 at launch."
          }
        },
        "required": [
          "node_count"
        ],
        "additionalProperties": false
      },
      "NodePool": {
        "type": "object",
        "properties": {
          "id": {
            "$ref": "#/components/schemas/NodePoolId"
          },
          "cluster_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "workspace_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 53
          },
          "html_url": {
            "type": "string",
            "allOf": [
              {
                "maxLength": 2048,
                "format": "uri"
              }
            ]
          },
          "machine_type": {
            "$ref": "#/components/schemas/MachineType"
          },
          "locations": {
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^[a-z][a-z0-9-]{1,31}$"
            },
            "maxItems": 1,
            "description": "Where the pool places its Machines in the Cluster’s Region; empty lets Akua choose. One location at launch."
          },
          "image": {
            "$ref": "#/components/schemas/NodeImage"
          },
          "labels": {
            "$ref": "#/components/schemas/NodeLabels"
          },
          "node_count": {
            "type": "integer",
            "minimum": 0,
            "maximum": 10,
            "description": "Number of nodes the pool keeps, 0 to 10 at launch."
          },
          "ready_nodes": {
            "type": "integer",
            "minimum": 0
          },
          "state": {
            "type": "string",
            "enum": [
              "provisioning",
              "ready",
              "resizing",
              "degraded",
              "failed",
              "deleting",
              "deleted"
            ],
            "description": "`provisioning`: its first nodes are being created and joined.\n`ready`: every node is ready.\n`resizing`: nodes are being added or removed after a size change.\n`degraded`: some nodes are not ready or could not be created; see `conditions`.\n`failed`: no node could be created; see `conditions`.\n`deleting`: its nodes are drained and their Machines deleted."
          },
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Condition"
            },
            "maxItems": 32,
            "description": "What needs attention now; empty when nothing does. Reasons:\n- `billing-required` (error or warning): the Workspace has no active billing account, so no Machine was created. Remedy `add-billing`.\n- `quota-exceeded` (error or warning): the Workspace or your trial has no Machine capacity left. Remedy `free-capacity` or `upgrade-plan`.\n- `capacity-unavailable`, `provider-refused`, `provider-unavailable` (error or warning): a Machine of the pool could not be created; the message names the node. Forwarded from the Machine.\n- `join-timeout` (warning): a server started but its node never became ready; its Machine was deleted.\n- `nodes-not-ready` (warning): Kubernetes reports nodes of the pool not ready; the message names them.\n- `trial-ended` (warning): the free trial Machine of a node was paused and its node removed. Remedy `add-billing`, then set the size again.\n- `machine-deleted` (warning): a node’s Machine was deleted outside the pool; the node is gone and the pool is smaller than `node_count`.\n- `drain-timeout` (warning): Pods did not leave a removed node within the drain bound; it was removed anyway.\n- `abandoned` (error): the create request ended before it recorded its Machines; what it created was deleted.\nAn error holds while `state` is `failed`; the same reason is a warning when other nodes run."
          },
          "operation_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 192,
            "description": "The latest Operation: the create, a size change, or the deletion."
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "updated_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "etag": {
            "type": "string",
            "maxLength": 64
          }
        },
        "required": [
          "id",
          "cluster_id",
          "workspace_id",
          "html_url",
          "machine_type",
          "locations",
          "image",
          "labels",
          "node_count",
          "ready_nodes",
          "state",
          "conditions",
          "operation_id",
          "created_at",
          "updated_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "NodeLabels": {
        "type": "object",
        "propertyNames": {
          "type": "string",
          "maxLength": 317,
          "pattern": "^(?:[a-z0-9](?:[-a-z0-9.]{0,251}[a-z0-9])?\\/)?[A-Za-z0-9](?:[-A-Za-z0-9_.]{0,61}[A-Za-z0-9])?$"
        },
        "additionalProperties": {
          "type": "string",
          "pattern": "^(?:[A-Za-z0-9](?:[-A-Za-z0-9_.]{0,61}[A-Za-z0-9])?)?$"
        },
        "maxProperties": 32,
        "examples": [
          {
            "workload-class": "web"
          }
        ]
      },
      "NodeImage": {
        "anyOf": [
          {
            "type": "string",
            "enum": [
              "ubuntu-24.04"
            ]
          }
        ]
      },
      "CreateNodePoolBody": {
        "type": "object",
        "properties": {
          "machine_type": {
            "$ref": "#/components/schemas/MachineType_1"
          },
          "node_count": {
            "type": "integer",
            "minimum": 0,
            "maximum": 10,
            "description": "Number of nodes the pool keeps, 0 to 10 at launch."
          },
          "locations": {
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^[a-z][a-z0-9-]{1,31}$"
            },
            "maxItems": 1,
            "description": "Where the pool places its Machines in the Cluster’s Region; empty lets Akua choose. One location at launch."
          },
          "image": {
            "$ref": "#/components/schemas/NodeImage_1"
          },
          "labels": {
            "$ref": "#/components/schemas/NodeLabels"
          }
        },
        "required": [
          "machine_type",
          "node_count"
        ],
        "additionalProperties": false
      },
      "NodeImage_1": {
        "anyOf": [
          {
            "type": "string",
            "enum": [
              "ubuntu-24.04"
            ]
          }
        ],
        "default": "ubuntu-24.04"
      },
      "MachineType_1": {
        "type": "string",
        "pattern": "^[a-z][a-z0-9-]{0,31}$",
        "description": "Server type Akua orders for each node, in the Cluster’s Region. The free trial covers one `cx23`.",
        "examples": [
          "cx23"
        ]
      },
      "NodePoolList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/NodePool"
            },
            "maxItems": 100
          },
          "has_more": {
            "type": "boolean"
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "ClusterJoinTokenList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ClusterJoinToken"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "ClusterJoinToken": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^[a-z0-9]{6}$"
          },
          "state": {
            "type": "string",
            "enum": [
              "active",
              "revoked",
              "expired"
            ]
          },
          "expires_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "created_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "used_at": {
            "anyOf": [
              {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "When the token was first used to join a server; it then expires 15 minutes later (`expires_at`). Null while it is unused, and for the tokens of a node pool. OUTPUT_ONLY."
          }
        },
        "required": [
          "id",
          "state",
          "expires_at",
          "created_at",
          "used_at"
        ],
        "additionalProperties": false
      },
      "ClusterAddonList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ClusterAddon"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "ClusterAddon": {
        "type": "object",
        "properties": {
          "name": {
            "$ref": "#/components/schemas/ClusterAddonName"
          },
          "cluster_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "kind": {
            "type": "string",
            "enum": [
              "capability",
              "addon"
            ],
            "description": "`capability`: platform-owned; you never install or remove it. `addon`: installed by you (not offered yet)."
          },
          "location": {
            "type": "string",
            "enum": [
              "in-cluster",
              "control-plane"
            ],
            "description": "Where its Placement is applied from: by the connector inside the Cluster, or by the connector beside the hosted control plane. Changing it is a delete and a create, never a silent move."
          },
          "desired": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ClusterAddonRevision"
              },
              {
                "type": "null"
              }
            ],
            "description": "What the ring wants it to run, recorded when the install is accepted and when an update starts; null once the add-on is being deleted."
          },
          "applied": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ClusterAddonRevision"
              },
              {
                "type": "null"
              }
            ],
            "description": "What runs now."
          },
          "last_known_good": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ClusterAddonRevision"
              },
              {
                "type": "null"
              }
            ],
            "description": "The last release that reached Current; what a rollback restores."
          },
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ClusterAddonCondition"
            }
          }
        },
        "required": [
          "name",
          "cluster_id",
          "kind",
          "location",
          "desired",
          "applied",
          "last_known_good",
          "conditions"
        ],
        "additionalProperties": false
      },
      "ClusterAddonCondition": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "Available",
              "Progressing",
              "Degraded"
            ]
          },
          "status": {
            "type": "boolean"
          },
          "reason": {
            "type": "string",
            "enum": [
              "Applied",
              "NotApplied",
              "Installing",
              "Updating",
              "WaitingForNodes",
              "Deleting",
              "Deleted",
              "Settled",
              "UpdateRolledBack",
              "ApplyFailed",
              "Unauthorized",
              "Healthy"
            ],
            "description": "Fixed reasons per type.\n- `Available`: `Applied`, or `NotApplied`, `Deleting`, `Deleted`.\n- `Progressing`: `Installing`, `Updating` or `Deleting` while a change runs, `WaitingForNodes` while an accepted release waits for the first Ready node to be health-checked, else `Settled`.\n- `Degraded`: `UpdateRolledBack` (the last update failed its health gate and was rolled back), `ApplyFailed` (the install or the rollback did not become healthy) or `Unauthorized` (the cluster API refuses the credential or the rights of the connector that applies it; nothing it applies changes until they are restored), else `Healthy`."
          },
          "message": {
            "type": "string",
            "maxLength": 512
          },
          "last_transition_at": {
            "anyOf": [
              {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "When the failure or rollback was recorded; null otherwise."
          }
        },
        "required": [
          "type",
          "status",
          "reason",
          "message",
          "last_transition_at"
        ],
        "additionalProperties": false
      },
      "ClusterAddonRevision": {
        "type": "object",
        "properties": {
          "version": {
            "type": "string",
            "maxLength": 64
          },
          "package_digest": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$",
            "description": "SHA-256 over the component, version and every pinned image digest of the release, or its Package digest."
          },
          "config_hash": {
            "type": "string",
            "pattern": "^[a-f0-9]{64}$",
            "description": "SHA-256 over the render inputs other than the package: Cluster, Origin, ring and location."
          }
        },
        "required": [
          "version",
          "package_digest",
          "config_hash"
        ],
        "additionalProperties": false
      },
      "ClusterAddonName": {
        "type": "string",
        "enum": [
          "tunnel-connector",
          "private-ingress-gateway",
          "local-path-storage",
          "metrics-server",
          "cni",
          "incluster-api-proxy",
          "cluster-connector",
          "gateway-api-crds"
        ],
        "description": "`cni`, `incluster-api-proxy`, `cluster-connector` and `gateway-api-crds` run on hosted Clusters only, applied from beside the control plane. `gateway-api-crds` serves the Gateway API standard-channel CRDs, so an Install can expose its web service with an HTTPRoute."
      },
      "ClusterJoinCommand": {
        "type": "object",
        "properties": {
          "token": {
            "$ref": "#/components/schemas/ClusterJoinToken"
          },
          "command": {
            "type": "string",
            "minLength": 1,
            "maxLength": 512,
            "description": "Sensitive short join.sh command with the Cluster ID and Kubernetes bootstrap token. Returned only here."
          },
          "expires_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          }
        },
        "required": [
          "token",
          "command",
          "expires_at"
        ],
        "additionalProperties": false
      },
      "ClusterConnectorInstall": {
        "type": "object",
        "properties": {
          "command": {
            "type": "string",
            "description": "Sensitive `helm upgrade --install` command with a single-use enrollment code. Returned only here; issuing a new one invalidates the previous code."
          },
          "chart": {
            "type": "object",
            "properties": {
              "repository": {
                "type": "string"
              },
              "version": {
                "type": "string"
              }
            },
            "required": [
              "repository",
              "version"
            ],
            "additionalProperties": false
          },
          "expires_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          }
        },
        "required": [
          "command",
          "chart",
          "expires_at"
        ],
        "additionalProperties": false
      },
      "ClusterAccess": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "cluster"
                ]
              }
            },
            "required": [
              "kind"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "namespaces"
                ]
              },
              "namespaces": {
                "type": "array",
                "prefixItems": [
                  {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 63
                  }
                ],
                "minItems": 1,
                "items": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 63
                },
                "maxItems": 256
              }
            },
            "required": [
              "kind",
              "namespaces"
            ],
            "additionalProperties": false
          }
        ]
      },
      "Cluster": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "html_url": {
            "type": "string",
            "allOf": [
              {
                "maxLength": 2048,
                "format": "uri"
              }
            ]
          },
          "workspace_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 53
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 63,
            "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
            "description": "A DNS label, unique in the Workspace.",
            "examples": [
              "shop"
            ]
          },
          "kind": {
            "type": "string",
            "enum": [
              "hosted",
              "attached"
            ]
          },
          "region_id": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 3,
                "maxLength": 54
              },
              {
                "type": "null"
              }
            ],
            "description": "The Region of a hosted Cluster; null for an attached one."
          },
          "state": {
            "type": "string",
            "enum": [
              "provisioning",
              "awaiting_node",
              "awaiting_agent",
              "configuring",
              "ready",
              "degraded",
              "disconnected",
              "failed",
              "deleting",
              "deleted"
            ],
            "description": "`provisioning`: the hosted control plane starts. `awaiting_node`: join a server with a join token. `awaiting_agent`: install the agent (attached) or wait for it. `configuring`: the baseline is placed. `disconnected`: the agent stopped calling; workloads keep running."
          },
          "capabilities": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "https_ingress",
                "persistent_volumes",
                "resource_metrics"
              ]
            }
          },
          "storage_classes": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ClusterStorageClass"
            },
            "description": "The StorageClasses Akua runs here and an Install can use, from its healthy storage capabilities. OUTPUT_ONLY. No class is the cluster default: an Install names one on every volume, the one asked for or the one Akua picks."
          },
          "ready_nodes": {
            "type": "integer",
            "minimum": 0
          },
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Condition"
            },
            "maxItems": 32,
            "description": "What needs attention now; empty when nothing does. Reasons:\n- `agent-enrollment-conflict` (error): the Kubernetes UID is already bound to another Cluster. Delete the previous Cluster in its owning instance, wait for completed deletion, then run this Cluster’s install command again. Deleting the local identity Secret alone does not release that binding.\n- `node-bootstrap-unconfirmed` (info): the first node and in-cluster agent are not confirmed. Names each Machine latest guest-reported stage when available; otherwise no report has arrived. A RUNNING Machine does not establish guest bootstrap success.\n- `bootstrap-failed` (error): a Machine guest reported bootstrap failure, with its safe step and exit code.\n- `agent-offline` (warning): the agent is not connected; workloads keep running and nothing new rolls out until it reconnects.\n- `updater-behind` (warning): the updater has run another release than the agent for 30 minutes, so no agent release is offered. Remedy `run-agent-install` on an attached Cluster; none on a hosted one, whose agent and updater Akua re-applies.\n- `needs-customer-upgrade` (warning): the offered agent release changes objects outside the access you granted, so it was not applied. Remedy `customer-upgrade` names the missing permissions and the `helm upgrade` command.\n- `bundle-too-large` (warning): the offered agent release is too large to deliver or to keep as a rollback copy, so it was not applied.\n- `update-rolled-back`, `baseline-degraded` (warning): a capability release failed its health gate and was rolled back, or a capability is not healthy; see the Cluster’s capabilities. A list shows `baseline-degraded` from the Cluster state only; `update-rolled-back` appears when the Cluster is read on its own.\n- When `state` is `failed`, one error whose reason says why: `control-plane-unready`, `enrollment-expired`, `agent-unsupported`, `baseline-failed`, `baseline-rollback-failed`, `cleanup-unconfirmed`, `node-removal-failed` or `agent-bundle-failed`."
          },
          "operation_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 192,
            "description": "The latest Operation: the create, or the deletion once requested."
          },
          "connector": {
            "$ref": "#/components/schemas/ClusterConnector"
          },
          "created_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "etag": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "html_url",
          "workspace_id",
          "name",
          "kind",
          "region_id",
          "state",
          "capabilities",
          "ready_nodes",
          "conditions",
          "operation_id",
          "connector",
          "created_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "ClusterConnector": {
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "connected",
              "offline",
              "revoked"
            ],
            "description": "`pending`: installed or enrolled, no contact yet."
          },
          "version": {
            "type": "string",
            "description": "The release it runs."
          },
          "last_seen_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          }
        },
        "required": [
          "status"
        ],
        "additionalProperties": false
      },
      "ClusterStorageClass": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 253,
            "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?(?:\\.[a-z0-9](?:[-a-z0-9]*[a-z0-9])?)*$",
            "description": "A Kubernetes StorageClass name.",
            "examples": [
              "local-path"
            ]
          },
          "attachment": {
            "type": "string",
            "enum": [
              "node_local",
              "network"
            ],
            "description": "`node_local`: the volume lives on the disk of the node its first Pod ran on, fastest and fixed to that node. `network`: the volume attaches over the network and follows its Pod to another node."
          }
        },
        "required": [
          "name",
          "attachment"
        ],
        "additionalProperties": false
      },
      "ClusterCreateBody": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "hosted"
                ],
                "description": "Akua runs the control plane in the Region; you join your own servers."
              },
              "name": {
                "type": "string",
                "minLength": 1,
                "maxLength": 63,
                "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                "description": "A DNS label, unique in the Workspace.",
                "examples": [
                  "shop"
                ]
              },
              "region_id": {
                "type": "string",
                "minLength": 3,
                "maxLength": 54
              }
            },
            "required": [
              "kind",
              "name",
              "region_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "attached"
                ],
                "description": "An existing Kubernetes cluster that runs the Akua cluster agent."
              },
              "name": {
                "type": "string",
                "minLength": 1,
                "maxLength": 63,
                "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?$",
                "description": "A DNS label, unique in the Workspace.",
                "examples": [
                  "shop"
                ]
              },
              "access": {
                "$ref": "#/components/schemas/ClusterAccess"
              }
            },
            "required": [
              "kind",
              "name",
              "access"
            ],
            "additionalProperties": false
          }
        ]
      },
      "ClusterList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Cluster"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "JoinBootstrapReport": {
        "type": "object",
        "properties": {
          "step": {
            "type": "string",
            "enum": [
              "validate-input",
              "discover-cluster",
              "install-k0s",
              "download-image-credential-provider",
              "verify-image-credential-provider",
              "stop-incomplete-worker",
              "write-bootstrap-config",
              "encode-worker-token",
              "install-worker",
              "start-worker",
              "await-bootstrap"
            ]
          },
          "reason": {
            "type": "string",
            "enum": [
              "command-failed",
              "unavailable",
              "invalid-discovery",
              "provider-install-failed",
              "integrity-failed",
              "bootstrap-timeout"
            ]
          },
          "exit_code": {
            "type": "integer",
            "minimum": 1,
            "maximum": 255
          }
        },
        "required": [
          "step",
          "reason",
          "exit_code"
        ],
        "additionalProperties": false
      },
      "ClusterJoinInfo": {
        "type": "object",
        "properties": {
          "ca_certificate": {
            "type": "string",
            "minLength": 1,
            "maxLength": 32768,
            "description": "Base64-encoded public PEM CA certificate. Never a private key."
          },
          "api_endpoint": {
            "type": "string",
            "maxLength": 512
          },
          "k0s_version": {
            "type": "string",
            "maxLength": 64
          },
          "image_credential_provider": {
            "type": "object",
            "properties": {
              "repository": {
                "type": "string",
                "maxLength": 255,
                "description": "OCI repository (`<registry host>/<path>`) whose blobs hold the provider."
              },
              "amd64": {
                "type": "string",
                "description": "Blob digest of the linux/amd64 layer."
              },
              "arm64": {
                "type": "string",
                "description": "Blob digest of the linux/arm64 layer."
              }
            },
            "required": [
              "repository",
              "amd64",
              "arm64"
            ],
            "additionalProperties": false,
            "description": "The kubelet image credential provider a joining server installs, so its Pods pull private Akua images with their own ServiceAccount token. join.sh downloads the layer of its architecture by digest and refuses it unless its SHA-256 matches."
          }
        },
        "required": [
          "ca_certificate",
          "api_endpoint",
          "k0s_version",
          "image_credential_provider"
        ],
        "additionalProperties": false
      },
      "TestIamPermissionsResponse": {
        "type": "object",
        "properties": {
          "permissions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PermissionName"
            },
            "maxItems": 100
          }
        },
        "required": [
          "permissions"
        ],
        "additionalProperties": false
      },
      "PermissionName": {
        "type": "string",
        "pattern": "^[a-z][a-z0-9-]{0,62}\\.[a-z][a-z0-9-]{0,62}\\.[a-z][a-z0-9-]{0,62}$",
        "title": "PermissionName",
        "description": "A permission `service.resource.verb`",
        "examples": [
          "vault.versions.access"
        ]
      },
      "ConnectionId": {
        "type": "string",
        "pattern": "^conn_[^\\s/]{1,64}$",
        "title": "ConnectionId",
        "description": "A connection id",
        "examples": [
          "conn_j572abc123def456"
        ]
      },
      "TestIamPermissionsRequest": {
        "type": "object",
        "properties": {
          "permissions": {
            "type": "array",
            "prefixItems": [
              {
                "$ref": "#/components/schemas/PermissionName"
              }
            ],
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/PermissionName"
            },
            "maxItems": 100
          }
        },
        "required": [
          "permissions"
        ],
        "additionalProperties": false
      },
      "VaultConnection": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "Resource name `vaults/{vault}/connections/{connection}`."
          },
          "id": {
            "$ref": "#/components/schemas/ConnectionId"
          },
          "connector": {
            "$ref": "#/components/schemas/ConnectorSlug"
          },
          "display_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          },
          "owner": {
            "$ref": "#/components/schemas/ConnectionOwner"
          },
          "state": {
            "$ref": "#/components/schemas/ConnectionState"
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Unix timestamp (seconds)"
          },
          "etag": {
            "type": "string",
            "maxLength": 64,
            "description": "Pass as `If-Match` on writes. OUTPUT_ONLY."
          }
        },
        "required": [
          "name",
          "id",
          "connector",
          "display_name",
          "owner",
          "state",
          "created_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "ConnectionState": {
        "type": "string",
        "enum": [
          "PENDING_CONSENT",
          "CONNECTED",
          "REAUTH_REQUIRED",
          "REVOKING",
          "REVOKED",
          "ERROR"
        ]
      },
      "ConnectionOwner": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "workspace"
                ]
              }
            },
            "required": [
              "type"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user"
                ]
              },
              "user_id": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "user_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "external_user"
                ]
              },
              "external_user_id": {
                "type": "string"
              }
            },
            "required": [
              "type",
              "external_user_id"
            ],
            "additionalProperties": false
          }
        ],
        "description": "Who owns the connection: the Workspace (a shared account), one user (their own account) or an end customer user in a reseller vault."
      },
      "ConnectorSlug": {
        "type": "string",
        "pattern": "^[a-z0-9][a-z0-9_-]{0,63}$",
        "title": "ConnectorSlug",
        "description": "A connector's stable slug.",
        "examples": [
          "akua"
        ]
      },
      "SetConnectionCredentialRequest": {
        "type": "object",
        "properties": {
          "fields": {
            "type": "object",
            "patternProperties": {
              "^[A-Z][A-Z0-9_]{0,62}$": {
                "type": "string",
                "minLength": 1,
                "maxLength": 8192
              }
            },
            "additionalProperties": false,
            "minProperties": 1,
            "maxProperties": 8
          }
        },
        "required": [
          "fields"
        ],
        "additionalProperties": false
      },
      "CreateVaultConnectionRequest": {
        "type": "object",
        "properties": {
          "connector": {
            "$ref": "#/components/schemas/ConnectorSlug"
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          },
          "owner": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "workspace"
                    ]
                  }
                },
                "required": [
                  "type"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user"
                    ]
                  }
                },
                "required": [
                  "type"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "external_user"
                    ]
                  },
                  "external_user_id": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  }
                },
                "required": [
                  "type",
                  "external_user_id"
                ],
                "additionalProperties": false
              }
            ],
            "description": "Defaults to the calling user. A user owner is always the authenticated caller, never a client-supplied id."
          },
          "auth_method": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "description": "Declared connector authentication method. Defaults to api_token. Akua delegated uses the verified signed-in person without a stored credential."
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "connector"
        ],
        "additionalProperties": false
      },
      "VaultConnectionList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/VaultConnection"
            },
            "maxItems": 100
          },
          "has_more": {
            "type": "boolean"
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "WorkspaceServiceList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/WorkspaceService"
            },
            "maxItems": 64
          }
        },
        "required": [
          "data"
        ],
        "additionalProperties": false
      },
      "WorkspaceService": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "examples": [
              "workspaces/ws_j572abc/services/machine"
            ]
          },
          "service": {
            "type": "string",
            "enum": [
              "platform-api",
              "domain-dispatcher",
              "organization",
              "workspace",
              "platform",
              "region",
              "admission",
              "billing",
              "package",
              "registry",
              "product",
              "offer",
              "order-draft",
              "install",
              "placement",
              "cluster",
              "machine",
              "routing",
              "repository",
              "vault",
              "connection",
              "agents",
              "sandbox",
              "opencode-server",
              "identity",
              "convex",
              "access-proxy",
              "instance",
              "development-publisher"
            ]
          },
          "state": {
            "type": "string",
            "enum": [
              "ENABLED",
              "DISABLED"
            ]
          },
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Condition"
            },
            "maxItems": 32,
            "description": "Problems and notable facts that hold now, beside `state`; empty when there are none. See each reason in the resource description."
          }
        },
        "required": [
          "name",
          "service",
          "state",
          "conditions"
        ],
        "additionalProperties": false
      },
      "QuotaAdjustment": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "Resource name `{container}/quotaAdjustments/{id}`; the id is unique in its container.",
            "examples": [
              "workspaces/ws_j572abc/quotaAdjustments/more-clusters"
            ]
          },
          "container": {
            "$ref": "#/components/schemas/QuotaContainerName"
          },
          "metric": {
            "type": "string",
            "examples": [
              "kaas/clusters"
            ]
          },
          "preferred_limit": {
            "type": "integer",
            "minimum": 0
          },
          "granted_limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ]
          },
          "state": {
            "type": "string",
            "enum": [
              "PENDING",
              "APPLIED",
              "REJECTED",
              "EXPIRED"
            ]
          },
          "justification": {
            "type": "string",
            "minLength": 1,
            "maxLength": 1024
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Unix timestamp (seconds)"
              },
              {
                "type": "null"
              }
            ]
          },
          "requested_by": {
            "type": "string"
          },
          "decided_by": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "updated_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "etag": {
            "type": "string",
            "maxLength": 64
          }
        },
        "required": [
          "name",
          "container",
          "metric",
          "preferred_limit",
          "granted_limit",
          "state",
          "justification",
          "expires_at",
          "requested_by",
          "decided_by",
          "created_at",
          "updated_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "QuotaContainerName": {
        "type": "string",
        "pattern": "^(users\\/[^\\s/]{1,64}|paymentInstruments\\/[A-Za-z0-9]{1,64}|workspaces\\/ws_[A-Za-z0-9]+|regions\\/reg_[A-Za-z0-9]+)$",
        "title": "QuotaContainerName",
        "examples": [
          "workspaces/ws_j572abc"
        ]
      },
      "QuotaAdjustmentId": {
        "type": "string",
        "pattern": "^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$",
        "title": "QuotaAdjustmentId",
        "examples": [
          "ws-j572-clusters"
        ]
      },
      "DecideQuotaAdjustmentRequest": {
        "type": "object",
        "properties": {
          "reason": {
            "type": "string",
            "minLength": 1,
            "maxLength": 1024
          }
        },
        "required": [
          "reason"
        ],
        "additionalProperties": false
      },
      "CreateQuotaAdjustmentRequest": {
        "type": "object",
        "properties": {
          "container": {
            "$ref": "#/components/schemas/QuotaContainerName"
          },
          "metric": {
            "type": "string",
            "examples": [
              "kaas/clusters"
            ]
          },
          "preferred_limit": {
            "type": "integer",
            "minimum": 0
          },
          "justification": {
            "type": "string",
            "minLength": 1,
            "maxLength": 1024
          },
          "expires_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          }
        },
        "required": [
          "container",
          "metric",
          "preferred_limit",
          "justification"
        ],
        "additionalProperties": false
      },
      "QuotaAdjustmentList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/QuotaAdjustment"
            },
            "maxItems": 100
          },
          "has_more": {
            "type": "boolean"
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "ResolvedImage": {
        "type": "object",
        "properties": {
          "image": {
            "type": "string"
          },
          "digest": {
            "type": "string"
          }
        },
        "required": [
          "image",
          "digest"
        ],
        "additionalProperties": false
      },
      "UpstreamId": {
        "type": "string",
        "description": "a lowercase resource id (AIP-122)"
      },
      "Upstream": {
        "type": "object",
        "properties": {
          "upstream_id": {
            "$ref": "#/components/schemas/UpstreamId"
          },
          "workspace_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 53
          },
          "host": {
            "$ref": "#/components/schemas/RegistryHost"
          },
          "path": {
            "type": "string",
            "maxLength": 255
          },
          "username": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255
          },
          "secret": {
            "type": "string"
          },
          "image_prefix": {
            "type": "string"
          },
          "test_image": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "created_at": {
            "type": "number"
          },
          "etag": {
            "type": "string"
          }
        },
        "required": [
          "upstream_id",
          "workspace_id",
          "host",
          "path",
          "username",
          "secret",
          "image_prefix",
          "test_image",
          "created_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "RegistryHost": {
        "type": "string",
        "maxLength": 259,
        "description": "Public HTTPS OCI registry DNS hostname, optionally with a port. No scheme, IP literal, userinfo, private suffix or Akua-served hostname."
      },
      "CreateUpstream": {
        "type": "object",
        "properties": {
          "host": {
            "$ref": "#/components/schemas/RegistryHost"
          },
          "path": {
            "type": "string",
            "maxLength": 255
          },
          "username": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255
          },
          "secret": {
            "type": "string"
          },
          "test_image": {
            "type": "string",
            "maxLength": 1024
          },
          "skip_test": {
            "type": "boolean"
          }
        },
        "required": [
          "host",
          "path",
          "username",
          "secret"
        ],
        "additionalProperties": false
      },
      "FeedbackReceipt": {
        "type": "object",
        "properties": {
          "message": {
            "type": "string",
            "description": "The message as delivered, without leading or trailing whitespace. The team channel shows it with @ and mention forms made inert."
          },
          "user_id": {
            "type": "string",
            "description": "The user the message is attributed to: the person the credential belongs to."
          },
          "email": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "The account email sent with the message, or null if the credential has none."
          },
          "client": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "The client identification sent with the message: the `User-Agent` header, at most 200 characters, or null if the request had none.",
            "examples": [
              "akua-cli/0.13.9 (darwin; arm64) bun/1.4.4"
            ]
          }
        },
        "required": [
          "message",
          "user_id",
          "email",
          "client"
        ],
        "additionalProperties": false
      },
      "CreateFeedbackRequest": {
        "type": "object",
        "properties": {
          "message": {
            "type": "string",
            "description": "What happened, or what you would like to see. The Akua team reads it in a private channel together with your user ID, the email of your account and the `User-Agent` of the client you sent it with (for the Akua CLI: its version, your operating system and architecture).",
            "examples": [
              "akua clusters list is slow for workspaces with many clusters"
            ],
            "minLength": 1,
            "maxLength": 1500
          }
        },
        "required": [
          "message"
        ],
        "additionalProperties": false
      },
      "ApiToken": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54,
            "description": "API token ID.",
            "examples": [
              "tok_3k9x2mfq8a1b7c4d5e6f"
            ]
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "examples": [
              "My CLI token"
            ]
          },
          "prefix": {
            "type": "string",
            "description": "The first 12 characters of the token, for recognizing it. Never the secret.",
            "examples": [
              "sk_akua_a3B2"
            ]
          },
          "workspace_id": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 2,
                "maxLength": 53,
                "examples": [
                  "ws_j572abc123def4"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "The only Workspace the token may act in. Omitted or null: every Workspace the person may use."
          },
          "roles": {
            "anyOf": [
              {
                "type": "array",
                "prefixItems": [
                  {
                    "$ref": "#/components/schemas/RoleName"
                  }
                ],
                "minItems": 1,
                "items": {
                  "$ref": "#/components/schemas/RoleName"
                },
                "maxItems": 16,
                "examples": [
                  [
                    "roles/viewer"
                  ]
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "A ceiling of IAM roles: the token may do only what one of these roles includes, and only what the person may. Omitted or null: the rights of the person."
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Unix timestamp (seconds)"
          },
          "last_used_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "Unix timestamp (seconds) of last use, or null if never used"
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "Unix timestamp (seconds) when the token expires, or null if never"
          }
        },
        "required": [
          "id",
          "name",
          "prefix",
          "workspace_id",
          "roles",
          "created_at",
          "last_used_at",
          "expires_at"
        ],
        "additionalProperties": false
      },
      "CreatedApiToken": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54,
            "description": "API token ID.",
            "examples": [
              "tok_3k9x2mfq8a1b7c4d5e6f"
            ]
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "examples": [
              "My CLI token"
            ]
          },
          "prefix": {
            "type": "string",
            "description": "The first 12 characters of the token, for recognizing it. Never the secret.",
            "examples": [
              "sk_akua_a3B2"
            ]
          },
          "workspace_id": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 2,
                "maxLength": 53,
                "examples": [
                  "ws_j572abc123def4"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "The only Workspace the token may act in. Omitted or null: every Workspace the person may use."
          },
          "roles": {
            "anyOf": [
              {
                "type": "array",
                "prefixItems": [
                  {
                    "$ref": "#/components/schemas/RoleName"
                  }
                ],
                "minItems": 1,
                "items": {
                  "$ref": "#/components/schemas/RoleName"
                },
                "maxItems": 16,
                "examples": [
                  [
                    "roles/viewer"
                  ]
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "A ceiling of IAM roles: the token may do only what one of these roles includes, and only what the person may. Omitted or null: the rights of the person."
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "description": "Unix timestamp (seconds)"
          },
          "last_used_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "Unix timestamp (seconds) of last use, or null if never used"
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "Unix timestamp (seconds) when the token expires, or null if never"
          },
          "token": {
            "type": "string",
            "description": "The full token. This is shown only once - store it securely.",
            "examples": [
              "sk_akua_a3B2c4D5e6F7g8H9i0J1k2L3m4N5o6P73jZRME"
            ]
          }
        },
        "required": [
          "id",
          "name",
          "prefix",
          "workspace_id",
          "roles",
          "created_at",
          "last_used_at",
          "expires_at",
          "token"
        ],
        "additionalProperties": false
      },
      "CreateApiTokenRequest": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "Human-readable name for the token",
            "examples": [
              "My CLI token"
            ],
            "minLength": 1,
            "maxLength": 100
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "Unix timestamp (seconds) when the token expires. Omit or pass null for no expiry.",
            "examples": [
              1742169600
            ]
          },
          "workspace_id": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 2,
                "maxLength": 53,
                "examples": [
                  "ws_j572abc123def4"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "The only Workspace the token may act in. Omitted or null: every Workspace the person may use."
          },
          "roles": {
            "anyOf": [
              {
                "type": "array",
                "prefixItems": [
                  {
                    "$ref": "#/components/schemas/RoleName"
                  }
                ],
                "minItems": 1,
                "items": {
                  "$ref": "#/components/schemas/RoleName"
                },
                "maxItems": 16,
                "examples": [
                  [
                    "roles/viewer"
                  ]
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "A ceiling of IAM roles: the token may do only what one of these roles includes, and only what the person may. Omitted or null: the rights of the person."
          }
        },
        "required": [
          "name"
        ],
        "additionalProperties": false
      },
      "ApiTokenList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ApiToken"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "PackageGrantList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PackageGrant"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more grants exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "PackageGrant": {
        "type": "object",
        "properties": {
          "workspace_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 53,
            "description": "The customer Workspace that holds the grant.",
            "examples": [
              "ws_9177x8shcx0niswcn"
            ]
          },
          "version": {
            "type": "string",
            "minLength": 1,
            "maxLength": 128,
            "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*)(?:\\.(?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*))*))?(?:\\+([0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*))?$",
            "description": "The version the customer redeemed. The grant covers every published version of the Package."
          },
          "offer_id": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 4,
                "maxLength": 56
              },
              {
                "type": "null"
              }
            ],
            "description": "The Offer whose redemption granted access, or null for a grant made before Akua recorded it."
          },
          "redeemed_at": {
            "anyOf": [
              {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "When the customer redeemed the Offer (Unix seconds), or null like offer_id."
          },
          "granted_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          }
        },
        "required": [
          "workspace_id",
          "version",
          "offer_id",
          "redeemed_at",
          "granted_at"
        ],
        "additionalProperties": false
      },
      "PackageVersionInputs": {
        "type": "object"
      },
      "CreatePackageVersionRequest": {
        "type": "object",
        "properties": {
          "version": {
            "type": "string",
            "minLength": 1,
            "maxLength": 128,
            "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*)(?:\\.(?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*))*))?(?:\\+([0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*))?$",
            "description": "The version tag to publish from the hosted Package repository or external OCI source.",
            "examples": [
              "1.2.3"
            ]
          }
        },
        "required": [
          "version"
        ],
        "additionalProperties": false
      },
      "PackageResource": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "html_url": {
            "type": "string",
            "description": "Absolute dashboard URL for this resource. OUTPUT_ONLY.",
            "format": "uri",
            "maxLength": 2048
          },
          "workspace_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 53
          },
          "name": {
            "type": "string"
          },
          "source": {
            "$ref": "#/components/schemas/PackageSource"
          },
          "versions": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "version": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 128,
                  "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*)(?:\\.(?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*))*))?(?:\\+([0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*))?$"
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "publishing",
                    "published",
                    "failed"
                  ]
                }
              },
              "required": [
                "version",
                "status"
              ],
              "additionalProperties": false
            },
            "description": "Every version created for the Package, newest first."
          },
          "etag": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "html_url",
          "workspace_id",
          "name",
          "source",
          "versions",
          "etag"
        ],
        "additionalProperties": false
      },
      "PackageSource": {
        "anyOf": [
          {
            "$ref": "#/components/schemas/PackageHostedSource"
          },
          {
            "$ref": "#/components/schemas/PackageOciSource"
          }
        ]
      },
      "PackageOciSource": {
        "type": "object",
        "properties": {
          "kind": {
            "type": "string",
            "enum": [
              "oci"
            ]
          },
          "repository": {
            "type": "string",
            "description": "Public OCI repository that holds the chart, without the chart name. Akua pulls each version anonymously.",
            "examples": [
              "oci://ghcr.io/acme/charts"
            ],
            "minLength": 7,
            "maxLength": 2048,
            "pattern": "^oci:\\/\\/[^\\s]+$"
          },
          "chart": {
            "type": "string",
            "examples": [
              "web"
            ],
            "minLength": 1,
            "maxLength": 253
          }
        },
        "required": [
          "kind",
          "repository",
          "chart"
        ],
        "additionalProperties": false
      },
      "PackageHostedSource": {
        "type": "object",
        "properties": {
          "kind": {
            "type": "string",
            "enum": [
              "hosted"
            ]
          },
          "chart": {
            "type": "string",
            "minLength": 1,
            "maxLength": 253,
            "pattern": "^[a-z0-9]+(?:[._-][a-z0-9]+)*$"
          }
        },
        "required": [
          "kind",
          "chart"
        ],
        "additionalProperties": false
      },
      "CreatePackageRequest": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          },
          "source": {
            "$ref": "#/components/schemas/PackageSource"
          }
        },
        "required": [
          "name",
          "source"
        ],
        "additionalProperties": false
      },
      "OrderDraft": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Order draft ID",
            "examples": [
              "odft_j572abc..."
            ],
            "minLength": 1,
            "maxLength": 55
          },
          "offer_id": {
            "type": "string",
            "description": "The Offer this draft redeems"
          },
          "status": {
            "$ref": "#/components/schemas/OrderDraftStatus"
          },
          "workspace_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "cluster_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "values": {
            "type": "object",
            "description": "The customer's configuration values, without the Offer's values and without sensitive values."
          },
          "missing": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrderDraftMissing"
            }
          },
          "problems": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrderDraftProblem"
            }
          },
          "install_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "operation_id": {
            "anyOf": [
              {
                "type": "string",
                "description": "The Install's create Operation; poll /v1/operations"
              },
              {
                "type": "null"
              }
            ]
          },
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Condition"
            },
            "maxItems": 32,
            "description": "What needs attention now; empty when nothing does. Reasons:\n- `install-failed` (error): the Offer was redeemed but the Install could not be created; the draft is `failed`."
          },
          "redeemed_at": {
            "anyOf": [
              {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ]
          },
          "created_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "updated_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "expires_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "allOf": [
              {
                "minimum": 0,
                "description": "After this time a `draft` can no longer change or redeem."
              }
            ]
          },
          "etag": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "offer_id",
          "status",
          "workspace_id",
          "cluster_id",
          "values",
          "missing",
          "problems",
          "install_id",
          "operation_id",
          "conditions",
          "redeemed_at",
          "created_at",
          "updated_at",
          "expires_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "OrderDraftProblem": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "offer"
                ]
              },
              "reason": {
                "type": "string",
                "enum": [
                  "not_found",
                  "not_for_you",
                  "unavailable",
                  "exhausted"
                ]
              },
              "message": {
                "type": "string",
                "description": "Why, for the customer to read"
              }
            },
            "required": [
              "kind",
              "reason",
              "message"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "workspace"
                ]
              },
              "workspace_id": {
                "type": "string"
              },
              "reason": {
                "type": "string",
                "enum": [
                  "not_allowed",
                  "deleting"
                ]
              },
              "message": {
                "type": "string",
                "description": "Why, for the customer to read"
              }
            },
            "required": [
              "kind",
              "workspace_id",
              "reason",
              "message"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "cluster"
                ]
              },
              "cluster_id": {
                "type": "string"
              },
              "reason": {
                "type": "string",
                "enum": [
                  "not_found",
                  "other_workspace",
                  "not_ready",
                  "namespaces_not_allowed"
                ]
              },
              "message": {
                "type": "string",
                "description": "Why, for the customer to read"
              }
            },
            "required": [
              "kind",
              "cluster_id",
              "reason",
              "message"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "value"
                ]
              },
              "pointer": {
                "type": "string",
                "description": "JSON pointer into the configuration values, such as `/auth/password`",
                "examples": [
                  "/replicas"
                ],
                "minLength": 1,
                "maxLength": 512
              },
              "reason": {
                "type": "string",
                "enum": [
                  "invalid",
                  "locked"
                ]
              },
              "message": {
                "type": "string",
                "description": "Why, for the customer to read"
              }
            },
            "required": [
              "kind",
              "pointer",
              "reason",
              "message"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "expired"
                ]
              },
              "message": {
                "type": "string",
                "description": "Why, for the customer to read"
              }
            },
            "required": [
              "kind",
              "message"
            ],
            "additionalProperties": false
          }
        ],
        "description": "Something wrong now; `:redeem` refuses while any is present."
      },
      "OrderDraftMissing": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "workspace"
                ]
              }
            },
            "required": [
              "kind"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "cluster"
                ]
              }
            },
            "required": [
              "kind"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "value"
                ]
              },
              "pointer": {
                "type": "string",
                "description": "JSON pointer into the configuration values, such as `/auth/password`",
                "examples": [
                  "/replicas"
                ],
                "minLength": 1,
                "maxLength": 512
              },
              "sensitive": {
                "type": "boolean",
                "description": "A sensitive value is sent only with `:redeem` and never stored on the draft; it stays missing until then."
              }
            },
            "required": [
              "kind",
              "pointer",
              "sensitive"
            ],
            "additionalProperties": false
          }
        ],
        "description": "Something `:redeem` still needs."
      },
      "OrderDraftStatus": {
        "type": "string",
        "enum": [
          "draft",
          "redeeming",
          "installing",
          "cancelled",
          "failed"
        ],
        "description": "`draft`: editable. `redeeming`: fields frozen while the Offer is redeemed and the Install created; `:redeem` again resumes it. `installing`: the Install exists (`install_id`, `operation_id`). `failed`: the Offer redeemed but the Install could not be created (condition `install-failed`). `cancelled`: ended by the customer."
      },
      "RedeemOrderDraftBody": {
        "type": "object",
        "properties": {
          "sensitive_values": {
            "type": "object",
            "description": "The sensitive configuration values, as a values object holding only those fields. They go to the Install and its vault and are never stored on the draft."
          }
        },
        "additionalProperties": false
      },
      "UpdateOrderDraftBody": {
        "type": "object",
        "properties": {
          "workspace": {
            "$ref": "#/components/schemas/OrderDraftWorkspace"
          },
          "cluster_id": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              {
                "type": "null"
              }
            ],
            "description": "A Cluster in the Workspace; `null` clears it. To use a new hosted Cluster, create it (and its server) through /v1/clusters first."
          },
          "values": {
            "type": "object",
            "description": "Replaces the configuration values as a whole. Sensitive fields (`x-ui.sensitive`) are refused here; send them with `:redeem`."
          }
        },
        "additionalProperties": false
      },
      "OrderDraftWorkspace": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "existing"
                ]
              },
              "workspace_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 53
              }
            },
            "required": [
              "kind",
              "workspace_id"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "new"
                ]
              },
              "name": {
                "type": "string",
                "minLength": 1,
                "maxLength": 100,
                "pattern": "^(?=.*\\S)[^\\p{Cc}\\p{Zl}\\p{Zp}]+$"
              },
              "organization": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54,
                "description": "The Organization the new Workspace is created in; the customer must be its owner or admin. There is no default."
              }
            },
            "required": [
              "kind",
              "name",
              "organization"
            ],
            "additionalProperties": false
          }
        ],
        "description": "An existing Workspace of the customer, or a new one in a named Organization of the customer, created at once and owned by the customer. Setting the same new name again on this draft answers the same Workspace."
      },
      "CreateOrderDraftBody": {
        "type": "object",
        "properties": {
          "offer": {
            "type": "string",
            "description": "The Offer ID (`offer_...`) or the 8-character short hash from the Offer link",
            "examples": [
              "offer_j572abc...",
              "aB3dE5fG"
            ],
            "minLength": 1,
            "maxLength": 56
          },
          "workspace": {
            "$ref": "#/components/schemas/OrderDraftWorkspace"
          },
          "cluster_id": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              {
                "type": "null"
              }
            ],
            "description": "A Cluster in the Workspace; `null` clears it. To use a new hosted Cluster, create it (and its server) through /v1/clusters first."
          },
          "values": {
            "type": "object",
            "description": "Replaces the configuration values as a whole. Sensitive fields (`x-ui.sensitive`) are refused here; send them with `:redeem`."
          }
        },
        "required": [
          "offer"
        ],
        "additionalProperties": false
      },
      "OfferResource": {
        "type": "object",
        "properties": {
          "view": {
            "type": "string",
            "enum": [
              "full"
            ]
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 56
          },
          "short_hash": {
            "type": "string",
            "description": "The 8-character code of the customer link `/i/<short_hash>`",
            "examples": [
              "aB3xK9pQ"
            ]
          },
          "url": {
            "type": "string",
            "description": "The link the seller shares with customers.",
            "format": "uri",
            "maxLength": 2048
          },
          "html_url": {
            "type": "string",
            "description": "Absolute dashboard URL for this resource. OUTPUT_ONLY.",
            "format": "uri",
            "maxLength": 2048
          },
          "workspace_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 53
          },
          "product_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 55
          },
          "package": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "version": {
                "type": "string"
              },
              "version_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "id",
              "version",
              "version_id"
            ],
            "additionalProperties": false,
            "description": "The Package version the Offer installs."
          },
          "terms": {
            "$ref": "#/components/schemas/OfferTerms"
          },
          "audience": {
            "$ref": "#/components/schemas/OfferAudience"
          },
          "field_values": {
            "type": "object",
            "additionalProperties": {
              "$ref": "#/components/schemas/OfferFieldValueView"
            }
          },
          "max_redemptions": {
            "type": "integer"
          },
          "redemption_count": {
            "type": "integer",
            "minimum": 0
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "archived"
            ]
          },
          "created_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "etag": {
            "type": "string"
          }
        },
        "required": [
          "view",
          "id",
          "short_hash",
          "url",
          "html_url",
          "workspace_id",
          "product_id",
          "package",
          "terms",
          "audience",
          "field_values",
          "max_redemptions",
          "redemption_count",
          "expires_at",
          "status",
          "created_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "OfferFieldValueView": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "value": {},
              "locked": {
                "type": "boolean"
              }
            },
            "required": [
              "value",
              "locked"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "sensitive": {
                "type": "boolean",
                "enum": [
                  true
                ]
              },
              "locked": {
                "type": "boolean",
                "enum": [
                  true
                ]
              },
              "secret_version": {
                "type": "string",
                "description": "The pinned version in the Offer's vault that holds the value."
              }
            },
            "required": [
              "sensitive",
              "locked",
              "secret_version"
            ],
            "additionalProperties": false
          }
        ]
      },
      "OfferAudience": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "anyone-signed-in"
                ]
              }
            },
            "required": [
              "kind"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "emails"
                ]
              },
              "emails": {
                "type": "array",
                "items": {
                  "type": "string",
                  "format": "email",
                  "maxLength": 254,
                  "pattern": "^[^\\s@]+@[^\\s@]+$"
                },
                "minItems": 1,
                "maxItems": 500
              }
            },
            "required": [
              "kind",
              "emails"
            ],
            "additionalProperties": false
          }
        ],
        "description": "Who may redeem: anyone signed in with the link, or only people whose verified email is listed."
      },
      "OfferTerms": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "no-charge"
                ]
              }
            },
            "required": [
              "kind"
            ],
            "additionalProperties": false
          }
        ],
        "description": "What the customer pays: nothing, for now."
      },
      "OfferResolution": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The Offer the short hash names",
            "minLength": 1,
            "maxLength": 56
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "OfferViewResource": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/OfferResource"
          },
          {
            "$ref": "#/components/schemas/OfferBasicResource"
          },
          {
            "$ref": "#/components/schemas/OfferPublicResource"
          }
        ]
      },
      "OfferPublicResource": {
        "type": "object",
        "properties": {
          "view": {
            "type": "string",
            "enum": [
              "public"
            ]
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 56
          },
          "short_hash": {
            "type": "string",
            "description": "The 8-character code of the customer link `/i/<short_hash>`",
            "examples": [
              "aB3xK9pQ"
            ]
          },
          "terms": {
            "$ref": "#/components/schemas/OfferTerms"
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "archived"
            ]
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ]
          },
          "product": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "description": {
                "anyOf": [
                  {
                    "type": "string"
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "required": [
              "name",
              "description"
            ],
            "additionalProperties": false,
            "description": "The Product as named when the Offer was made."
          },
          "seller": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              }
            },
            "required": [
              "name"
            ],
            "additionalProperties": false,
            "description": "The seller Workspace as named when the Offer was made."
          },
          "package": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "version": {
                "type": "string"
              }
            },
            "required": [
              "name",
              "version"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "view",
          "id",
          "short_hash",
          "terms",
          "status",
          "expires_at",
          "product",
          "seller",
          "package"
        ],
        "additionalProperties": false
      },
      "OfferBasicResource": {
        "type": "object",
        "properties": {
          "view": {
            "type": "string",
            "enum": [
              "basic"
            ]
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 56
          },
          "short_hash": {
            "type": "string",
            "description": "The 8-character code of the customer link `/i/<short_hash>`",
            "examples": [
              "aB3xK9pQ"
            ]
          },
          "product_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 55
          },
          "package": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "version": {
                "type": "string"
              },
              "version_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              },
              "name": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "version",
              "version_id",
              "name"
            ],
            "additionalProperties": false
          },
          "product": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "description": {
                "anyOf": [
                  {
                    "type": "string"
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "required": [
              "name",
              "description"
            ],
            "additionalProperties": false,
            "description": "The Product as named when the Offer was made."
          },
          "seller": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              }
            },
            "required": [
              "name"
            ],
            "additionalProperties": false,
            "description": "The seller Workspace as named when the Offer was made."
          },
          "terms": {
            "$ref": "#/components/schemas/OfferTerms"
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "archived"
            ]
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ]
          },
          "input_schema": {
            "type": "object",
            "description": "The Package version's values schema, for the configure form."
          },
          "defaults": {
            "type": "object",
            "description": "The seller's prefilled and locked values, as one values object."
          },
          "locked_keys": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "JSON pointers of the inputs the seller locked. A locked sensitive input is listed here without a value."
          }
        },
        "required": [
          "view",
          "id",
          "short_hash",
          "product_id",
          "package",
          "product",
          "seller",
          "terms",
          "status",
          "expires_at",
          "input_schema",
          "defaults",
          "locked_keys"
        ],
        "additionalProperties": false
      },
      "CreateOfferRequest": {
        "type": "object",
        "properties": {
          "product_id": {
            "type": "string",
            "description": "An active Product of the Akua-Context Workspace; the Offer installs its Package version.",
            "minLength": 1,
            "maxLength": 55
          },
          "terms": {
            "$ref": "#/components/schemas/OfferTerms"
          },
          "audience": {
            "$ref": "#/components/schemas/OfferAudience"
          },
          "field_values": {
            "type": "object",
            "propertyNames": {
              "type": "string",
              "description": "JSON pointer to an input of the values schema",
              "examples": [
                "/auth/password"
              ],
              "maxLength": 512,
              "pattern": "^(?:\\/[^/]*)+$"
            },
            "additionalProperties": {
              "type": "object",
              "properties": {
                "value": {},
                "locked": {
                  "type": "boolean",
                  "description": "The customer cannot change a locked value; it is granted with the Package."
                }
              },
              "required": [
                "value",
                "locked"
              ],
              "additionalProperties": false
            },
            "description": "Prefilled and locked inputs, by JSON pointer into the version's values schema. An input marked sensitive (`x-ui.sensitive`) must be a locked string; Akua keeps it in the Offer's own vault and never shows it again."
          },
          "max_redemptions": {
            "type": "integer",
            "description": "How many customer Workspaces may redeem the Offer.",
            "minimum": 1,
            "maximum": 1000
          },
          "expires_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds) after which nobody can redeem.",
            "exclusiveMinimum": 0
          }
        },
        "required": [
          "product_id",
          "terms",
          "audience",
          "max_redemptions"
        ],
        "additionalProperties": false
      },
      "OfferSummaryList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OfferSummaryResource"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "OfferSummaryResource": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 4,
            "maxLength": 56
          },
          "short_hash": {
            "type": "string",
            "description": "The 8-character code of the customer link `/i/<short_hash>`",
            "examples": [
              "aB3xK9pQ"
            ]
          },
          "url": {
            "type": "string",
            "description": "The link the seller shares with customers.",
            "format": "uri",
            "maxLength": 2048
          },
          "html_url": {
            "type": "string",
            "description": "Absolute dashboard URL for this resource. OUTPUT_ONLY.",
            "format": "uri",
            "maxLength": 2048
          },
          "workspace_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 53
          },
          "product_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 55
          },
          "product_name": {
            "type": "string"
          },
          "package": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "version": {
                "type": "string"
              },
              "version_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "id",
              "version",
              "version_id"
            ],
            "additionalProperties": false,
            "description": "The Package version the Offer installs."
          },
          "audience": {
            "$ref": "#/components/schemas/OfferAudience"
          },
          "max_redemptions": {
            "type": "integer"
          },
          "redemption_count": {
            "type": "integer",
            "minimum": 0
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "integer",
                "description": "Unix timestamp (seconds)",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "archived"
            ]
          },
          "created_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "etag": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "short_hash",
          "url",
          "html_url",
          "workspace_id",
          "product_id",
          "product_name",
          "package",
          "audience",
          "max_redemptions",
          "redemption_count",
          "expires_at",
          "status",
          "created_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "ProductResource": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "examples": [
              "prod_j572abc123def456"
            ],
            "minLength": 1,
            "maxLength": 55
          },
          "html_url": {
            "type": "string",
            "description": "Absolute dashboard URL for this resource. OUTPUT_ONLY.",
            "format": "uri",
            "maxLength": 2048
          },
          "workspace_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 53
          },
          "name": {
            "type": "string"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "support_email": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "package": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 54
              },
              "version": {
                "type": "string"
              },
              "version_id": {
                "type": "string",
                "minLength": 1,
                "maxLength": 55
              }
            },
            "required": [
              "id",
              "version",
              "version_id"
            ],
            "additionalProperties": false,
            "description": "The Package version the Product is pinned to."
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "archived"
            ]
          },
          "created_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "etag": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "html_url",
          "workspace_id",
          "name",
          "description",
          "support_email",
          "package",
          "status",
          "created_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "CreateProductRequest": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "examples": [
              "PostgreSQL Managed"
            ],
            "minLength": 2,
            "maxLength": 64
          },
          "package_id": {
            "type": "string",
            "description": "A Package of the Akua-Context Workspace.",
            "examples": [
              "pkg_j572abc123def456"
            ],
            "minLength": 1,
            "maxLength": 54
          },
          "package_version": {
            "type": "string",
            "examples": [
              "1.2.3"
            ],
            "minLength": 1,
            "maxLength": 128,
            "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*)(?:\\.(?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*))*))?(?:\\+([0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*))?$",
            "description": "The published Package version the Product offers. Offers made for the Product install exactly this version."
          },
          "description": {
            "type": "string",
            "maxLength": 500
          },
          "support_email": {
            "type": "string",
            "description": "Shown to customers on Offer pages when they need help.",
            "format": "email",
            "maxLength": 254,
            "pattern": "^[^\\s@]+@[^\\s@]+$"
          }
        },
        "required": [
          "name",
          "package_id",
          "package_version"
        ],
        "additionalProperties": false
      },
      "ProductResourceList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ProductResource"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "RegionList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Region"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "Region": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 54
          },
          "name": {
            "type": "string",
            "examples": [
              "us-east-1"
            ]
          },
          "icon": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Icon URL"
          },
          "workspace_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 53
          },
          "created_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "updated_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds) of the last change",
            "minimum": 0
          },
          "etag": {
            "type": "string",
            "description": "Opaque version token. Send it as `If-Match` when updating or deleting."
          }
        },
        "required": [
          "id",
          "name",
          "icon",
          "workspace_id",
          "created_at",
          "updated_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "Workspace": {
        "type": "object",
        "properties": {
          "organization_id": {
            "type": "string",
            "minLength": 1,
            "maxLength": 54,
            "description": "ID of the organization that owns this workspace."
          },
          "id": {
            "type": "string",
            "description": "Workspace ID",
            "examples": [
              "ws_j572abc123def4"
            ],
            "minLength": 1,
            "maxLength": 53
          },
          "name": {
            "type": "string",
            "description": "Display name",
            "examples": [
              "Acme Research"
            ]
          },
          "slug": {
            "type": "string",
            "description": "URL-safe workspace slug"
          },
          "plan": {
            "type": "object",
            "properties": {
              "tier": {
                "type": "string"
              },
              "billed_by": {
                "type": "string",
                "enum": [
                  "platform",
                  "seller"
                ]
              }
            },
            "required": [
              "tier",
              "billed_by"
            ],
            "additionalProperties": false
          },
          "workspace_class": {
            "type": "string",
            "enum": [
              "standard",
              "platform",
              "sandbox"
            ]
          },
          "lifecycle": {
            "$ref": "#/components/schemas/WorkspaceLifecycle"
          },
          "created_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "updated_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "etag": {
            "type": "string"
          }
        },
        "required": [
          "organization_id",
          "id",
          "name",
          "slug",
          "plan",
          "workspace_class",
          "lifecycle",
          "created_at",
          "updated_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "WorkspaceLifecycle": {
        "type": "object",
        "properties": {
          "state": {
            "type": "string",
            "enum": [
              "ACTIVE",
              "DELETING",
              "PURGED"
            ],
            "description": "Lifecycle state of the workspace. `DELETING` means deletion was accepted and the workspace is retained until `purge_at`."
          },
          "deletion_phase": {
            "anyOf": [
              {
                "type": "string",
                "enum": [
                  "ACCEPTED",
                  "RUNNING",
                  "SUCCEEDED",
                  "FAILED"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "Progress of the accepted deletion request, or null when no deletion has been recorded."
          },
          "deleted_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "When deletion was accepted, or null."
          },
          "purge_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0
              },
              {
                "type": "null"
              }
            ],
            "description": "Scheduled retention expiry that #955 owns as the purge executor, or null."
          }
        },
        "required": [
          "state",
          "deletion_phase",
          "deleted_at",
          "purge_at"
        ],
        "additionalProperties": false
      },
      "WorkspaceList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Workspace"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "WorkspaceBillingInfo": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "examples": [
              "workspaces/ws_j572abc/billingInfo"
            ]
          },
          "workspace_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 53
          },
          "billing_account": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/BillingAccountName"
              },
              {
                "type": "null"
              }
            ]
          },
          "billing_enabled": {
            "type": "boolean"
          }
        },
        "required": [
          "name",
          "workspace_id",
          "billing_account",
          "billing_enabled"
        ],
        "additionalProperties": false
      },
      "BillingAccountName": {
        "type": "string",
        "pattern": "^billingAccounts\\/bac_[A-Za-z0-9]+$",
        "title": "BillingAccountName",
        "examples": [
          "billingAccounts/bac_4kQ9mXr2Tz7Lw1"
        ]
      },
      "UpdateWorkspaceBillingInfoRequest": {
        "type": "object",
        "properties": {
          "billing_account": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/BillingAccountName"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "billing_account"
        ],
        "additionalProperties": false
      },
      "OutOfBandPayment": {
        "type": "object",
        "properties": {
          "invoice_id": {
            "$ref": "#/components/schemas/StripeInvoiceId"
          },
          "reference": {
            "type": "string",
            "minLength": 1,
            "maxLength": 256
          },
          "amount_paid": {
            "type": "integer",
            "minimum": 0,
            "description": "In the currency minor unit, as Stripe reports it after the payment."
          },
          "recorded_by": {
            "type": "string",
            "maxLength": 128
          },
          "recorded_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          }
        },
        "required": [
          "invoice_id",
          "reference",
          "amount_paid",
          "recorded_by",
          "recorded_at"
        ],
        "additionalProperties": false
      },
      "StripeInvoiceId": {
        "type": "string",
        "pattern": "^in_[A-Za-z0-9]{1,250}$"
      },
      "PayOutOfBandRequest": {
        "type": "object",
        "properties": {
          "reference": {
            "type": "string",
            "minLength": 1,
            "maxLength": 256
          },
          "justification": {
            "type": "string",
            "minLength": 1,
            "maxLength": 1024
          }
        },
        "required": [
          "reference",
          "justification"
        ],
        "additionalProperties": false
      },
      "BillingAccount": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "name": {
            "$ref": "#/components/schemas/BillingAccountName"
          },
          "organization_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "display_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          },
          "state": {
            "type": "string",
            "enum": [
              "PENDING",
              "ACTIVE",
              "CLOSED"
            ]
          },
          "payment_method": {
            "$ref": "#/components/schemas/BillingPaymentMethod"
          },
          "currency_code": {
            "type": "string",
            "enum": [
              "EUR"
            ]
          },
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Condition"
            },
            "maxItems": 32,
            "description": "Problems and notable facts that hold now, beside `state`; empty when there are none. See each reason in the resource description."
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "updated_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "closed_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Unix timestamp (seconds)"
              },
              {
                "type": "null"
              }
            ]
          },
          "etag": {
            "type": "string",
            "maxLength": 64
          }
        },
        "required": [
          "id",
          "name",
          "organization_id",
          "display_name",
          "state",
          "payment_method",
          "currency_code",
          "conditions",
          "created_at",
          "updated_at",
          "closed_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "BillingPaymentMethod": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "card"
                ]
              },
              "card": {
                "anyOf": [
                  {
                    "$ref": "#/components/schemas/PaymentCard"
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "required": [
              "type",
              "card"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "invoice"
                ]
              },
              "invoice_email": {
                "type": "string",
                "maxLength": 254
              }
            },
            "required": [
              "type",
              "invoice_email"
            ],
            "additionalProperties": false
          }
        ]
      },
      "PaymentCard": {
        "type": "object",
        "properties": {
          "brand": {
            "type": "string",
            "maxLength": 32,
            "examples": [
              "visa"
            ]
          },
          "last4": {
            "type": "string",
            "pattern": "^[0-9]{4}$"
          },
          "exp_month": {
            "type": "integer",
            "minimum": 1,
            "maximum": 12
          },
          "exp_year": {
            "type": "integer",
            "minimum": 2000,
            "maximum": 2199
          },
          "verified_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          }
        },
        "required": [
          "brand",
          "last4",
          "exp_month",
          "exp_year",
          "verified_at"
        ],
        "additionalProperties": false
      },
      "EnableInvoicingRequest": {
        "type": "object",
        "properties": {
          "invoice_email": {
            "type": "string",
            "maxLength": 254
          },
          "justification": {
            "type": "string",
            "minLength": 1,
            "maxLength": 1024
          }
        },
        "required": [
          "invoice_email",
          "justification"
        ],
        "additionalProperties": false
      },
      "CloseBillingAccountRequest": {
        "type": "object",
        "properties": {
          "reason": {
            "type": "string",
            "minLength": 1,
            "maxLength": 512
          }
        },
        "additionalProperties": false
      },
      "PaymentSetupSession": {
        "type": "object",
        "properties": {
          "client_secret": {
            "type": "string",
            "minLength": 1,
            "maxLength": 512
          },
          "ui_mode": {
            "type": "string",
            "enum": [
              "embedded_page"
            ]
          },
          "publishable_key": {
            "type": "string",
            "pattern": "^pk_(live|test)_[A-Za-z0-9]+$"
          },
          "expires_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          }
        },
        "required": [
          "client_secret",
          "ui_mode",
          "publishable_key",
          "expires_at"
        ],
        "additionalProperties": false
      },
      "BillingAccountList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BillingAccount"
            },
            "maxItems": 100
          },
          "has_more": {
            "type": "boolean"
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "CreateBillingAccountRequest": {
        "type": "object",
        "properties": {
          "organization": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "display_name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          }
        },
        "required": [
          "organization",
          "display_name"
        ],
        "additionalProperties": false
      },
      "OrganizationInvitation": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 55,
            "description": "Invitation ID, `orgi_<id>`."
          },
          "organization_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54,
            "description": "Organization ID, `org_<id>`."
          },
          "email": {
            "type": "string",
            "maxLength": 254,
            "allOf": [
              {
                "pattern": "^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$",
                "format": "email",
                "examples": [
                  "ada@example.com"
                ]
              }
            ]
          },
          "role": {
            "type": "string",
            "enum": [
              "roles/member",
              "roles/admin",
              "roles/owner"
            ],
            "description": "Only an owner may invite an owner. `roles/viewer` is granted through `:setIamPolicy`."
          },
          "state": {
            "type": "string",
            "enum": [
              "pending",
              "accepted",
              "declined",
              "revoked",
              "expired"
            ]
          },
          "expire_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "When a pending invitation becomes `expired`."
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "updated_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          }
        },
        "required": [
          "id",
          "organization_id",
          "email",
          "role",
          "state",
          "expire_at",
          "created_at",
          "updated_at"
        ],
        "additionalProperties": false
      },
      "OrganizationInvitationTokenRequest": {
        "type": "object",
        "properties": {
          "token": {
            "type": "string",
            "format": "password",
            "minLength": 32,
            "maxLength": 512
          }
        },
        "required": [
          "token"
        ],
        "additionalProperties": false
      },
      "OrganizationInvitationList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/OrganizationInvitation"
            },
            "maxItems": 100
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "OrganizationInvitationCreateRequest": {
        "type": "object",
        "properties": {
          "email": {
            "type": "string",
            "maxLength": 254,
            "allOf": [
              {
                "pattern": "^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$",
                "format": "email",
                "examples": [
                  "ada@example.com"
                ]
              }
            ]
          },
          "role": {
            "type": "string",
            "enum": [
              "roles/member",
              "roles/admin",
              "roles/owner"
            ],
            "description": "Only an owner may invite an owner. `roles/viewer` is granted through `:setIamPolicy`."
          }
        },
        "required": [
          "email",
          "role"
        ],
        "additionalProperties": false
      },
      "Organization": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54,
            "description": "Organization ID, `org_<id>`."
          },
          "name": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "maxLength": 50,
                "pattern": "^(?=.*\\S)[^\\p{Cc}\\p{Zl}\\p{Zp}]+$",
                "examples": [
                  "Code Zero"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "Null once the Organization is deleted: delete erases it at once."
          },
          "state": {
            "type": "string",
            "enum": [
              "active",
              "deleted"
            ],
            "description": "`deleted`: soft-deleted until `purge_at`; afterwards the Organization is not found."
          },
          "created_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "updated_at": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Unix timestamp (seconds)"
          },
          "deleted_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Unix timestamp (seconds)"
              },
              {
                "type": "null"
              }
            ]
          },
          "purge_at": {
            "anyOf": [
              {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Unix timestamp (seconds)"
              },
              {
                "type": "null"
              }
            ]
          },
          "etag": {
            "type": "string",
            "maxLength": 64,
            "description": "Pass as `If-Match` to delete only this version. OUTPUT_ONLY."
          }
        },
        "required": [
          "id",
          "name",
          "state",
          "created_at",
          "updated_at",
          "deleted_at",
          "purge_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "OrganizationList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Organization"
            },
            "maxItems": 100
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 512
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "OrganizationCreateRequest": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 50,
            "pattern": "^(?=.*\\S)[^\\p{Cc}\\p{Zl}\\p{Zp}]+$",
            "examples": [
              "Code Zero"
            ]
          }
        },
        "required": [
          "name"
        ],
        "additionalProperties": false
      },
      "SetOrganizationIamPolicyRequest": {
        "type": "object",
        "properties": {
          "bindings": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Binding"
            },
            "maxItems": 100
          }
        },
        "required": [
          "bindings"
        ],
        "additionalProperties": false
      },
      "InstallList": {
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Install"
            }
          },
          "has_more": {
            "type": "boolean",
            "description": "True if more items exist after this page."
          },
          "next_cursor": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "Opaque cursor for the next page, or null if no more pages."
          }
        },
        "required": [
          "data",
          "has_more",
          "next_cursor"
        ],
        "additionalProperties": false
      },
      "Install": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 55
          },
          "html_url": {
            "type": "string",
            "description": "Absolute dashboard URL for this resource. OUTPUT_ONLY.",
            "format": "uri",
            "examples": [
              "https://akua.dev/installs/inst_j572abc123def456"
            ],
            "maxLength": 2048
          },
          "workspace_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 53
          },
          "cluster_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "package_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "package_version": {
            "type": "string",
            "minLength": 1,
            "maxLength": 128
          },
          "state": {
            "type": "string",
            "enum": [
              "pending",
              "rendering",
              "syncing",
              "unknown",
              "healthy",
              "degraded",
              "failed",
              "deleted"
            ],
            "description": "Install lifecycle state from the control plane perspective."
          },
          "conditions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Condition"
            },
            "maxItems": 32,
            "description": "What needs attention now; empty when nothing does. Reasons:\n- `missing-permissions` (warning): the Cluster agent lacks permissions for what this Install applies, because the grant was narrowed or never covered its namespace. Remedy `grant-access` names them; the Install resumes by itself once they are granted.\n- When `state` is `failed`, one error whose reason says why: `render-failed`, `placement-failed`, `route-failed`, `endpoint-unreachable`, `agent-offline`, `agent-unsupported`, `abandoned` or `storage-class-unavailable`.\n- `storage-class-unavailable` (error): the Package claims volumes, the Cluster offers no StorageClass and the person who installed may not add one. A Workspace admin (`cluster.addons.create`) installs again and Akua adds local-path, or remedy `change-input` names `storage_class`: install again naming a class the Cluster has."
          },
          "operation_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 192
          },
          "reconciling": {
            "type": "boolean"
          },
          "url": {
            "anyOf": [
              {
                "type": "string",
                "allOf": [
                  {
                    "maxLength": 2048,
                    "format": "uri"
                  }
                ]
              },
              {
                "type": "null"
              }
            ]
          },
          "storage_class": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "maxLength": 253,
                "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?(?:\\.[a-z0-9](?:[-a-z0-9]*[a-z0-9])?)*$",
                "description": "A Kubernetes StorageClass name.",
                "examples": [
                  "local-path"
                ]
              },
              {
                "type": "null"
              }
            ],
            "description": "The StorageClass every volume of the Install names: once ready, the one asked for or the one Akua picked from the Cluster (`storage_classes`); null when the Package claims no volume. OUTPUT_ONLY."
          },
          "created_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "updated_at": {
            "type": "integer",
            "description": "Unix timestamp (seconds)",
            "minimum": 0
          },
          "etag": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "html_url",
          "workspace_id",
          "cluster_id",
          "package_id",
          "package_version",
          "state",
          "conditions",
          "operation_id",
          "reconciling",
          "url",
          "created_at",
          "updated_at",
          "etag"
        ],
        "additionalProperties": false
      },
      "UpdateInstallBody": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "update_mask": {
                "type": "string",
                "enum": [
                  "package_version"
                ]
              },
              "package_version": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128,
                "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*)(?:\\.(?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*))*))?(?:\\+([0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*))?$"
              },
              "inputs": {
                "type": "object"
              }
            },
            "required": [
              "update_mask",
              "package_version"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "update_mask": {
                "type": "string",
                "enum": [
                  "inputs"
                ]
              },
              "package_version": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128,
                "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*)(?:\\.(?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*))*))?(?:\\+([0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*))?$"
              },
              "inputs": {
                "type": "object"
              }
            },
            "required": [
              "update_mask",
              "inputs"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "update_mask": {
                "type": "string",
                "enum": [
                  "package_version,inputs",
                  "inputs,package_version",
                  "*"
                ]
              },
              "package_version": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128,
                "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*)(?:\\.(?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*))*))?(?:\\+([0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*))?$"
              },
              "inputs": {
                "type": "object"
              }
            },
            "required": [
              "update_mask",
              "package_version",
              "inputs"
            ],
            "additionalProperties": false
          }
        ],
        "description": "Update one Install in place. The mask selects package_version and/or inputs; inputs replaces the configure inputs object ({} resets to version defaults). Fields outside the mask are ignored. * replaces both mutable fields. Omitted inputs retain the existing inputs and secret references."
      },
      "InstallInputs": {
        "type": "object",
        "properties": {
          "install_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 55
          },
          "workspace_id": {
            "type": "string",
            "minLength": 2,
            "maxLength": 53
          },
          "package_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "package_version": {
            "type": "string",
            "minLength": 1,
            "maxLength": 128,
            "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*)(?:\\.(?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*))*))?(?:\\+([0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*))?$"
          },
          "package_version_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 55
          },
          "cluster_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "inputs": {
            "type": "object",
            "description": "Persisted non-secret user inputs. Fields marked sensitive by the pinned Package schema are excluded. Secrets remain write-only and must be entered again. Empty when no original inputs were retained."
          }
        },
        "required": [
          "install_id",
          "workspace_id",
          "package_id",
          "package_version",
          "package_version_id",
          "cluster_id",
          "inputs"
        ],
        "additionalProperties": false
      },
      "CreateInstallBody": {
        "type": "object",
        "properties": {
          "package_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "package_version_pin": {
            "$ref": "#/components/schemas/InstallPackageVersionPin"
          },
          "cluster_id": {
            "type": "string",
            "minLength": 3,
            "maxLength": 54
          },
          "initial_values": {
            "type": "object"
          },
          "storage_class": {
            "type": "string",
            "minLength": 1,
            "maxLength": 253,
            "pattern": "^[a-z0-9](?:[-a-z0-9]*[a-z0-9])?(?:\\.[a-z0-9](?:[-a-z0-9]*[a-z0-9])?)*$",
            "description": "The StorageClass every volume the Package renders names. Omit it and Akua picks one the Cluster offers (`storage_classes`): its only one, else a network-attached one before a node-local one, then by name. On a Cluster with none, Akua adds local-path when you hold `cluster.addons.create`; otherwise an Install with volumes fails `storage-class-unavailable`.",
            "examples": [
              "local-path"
            ]
          }
        },
        "required": [
          "package_id",
          "package_version_pin",
          "cluster_id"
        ],
        "additionalProperties": false,
        "description": "Install a Package version, identified by `package_id` and `package_version_pin`."
      },
      "InstallPackageVersionPin": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "latest"
                ]
              }
            },
            "required": [
              "kind"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "pinned"
                ]
              },
              "version": {
                "type": "string",
                "examples": [
                  "1.2.3"
                ],
                "minLength": 1,
                "maxLength": 128,
                "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*)(?:\\.(?:0|[1-9]\\d*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*))*))?(?:\\+([0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*))?$"
              }
            },
            "required": [
              "kind",
              "version"
            ],
            "additionalProperties": false
          }
        ]
      }
    },
    "securitySchemes": {
      "BearerAuth": {
        "description": "Bearer token for the authenticated caller.",
        "type": "http",
        "scheme": "bearer"
      },
      "JoinBootstrapBearer": {
        "type": "http",
        "scheme": "bearer"
      },
      "MachineBootstrapBearer": {
        "type": "http",
        "scheme": "bearer"
      }
    }
  },
  "security": [],
  "tags": [
    {
      "name": "operations"
    },
    {
      "name": "installs"
    },
    {
      "name": "Organizations"
    },
    {
      "name": "Billing accounts"
    },
    {
      "name": "workspaces"
    },
    {
      "name": "regions"
    },
    {
      "name": "products"
    },
    {
      "name": "offers"
    },
    {
      "name": "Order Drafts"
    },
    {
      "name": "packages"
    },
    {
      "name": "API Tokens"
    },
    {
      "name": "Feedback"
    },
    {
      "name": "Registry",
      "description": "Connect image registry Upstreams and resolve private images. Guide: https://docs.akua.dev/private-images"
    },
    {
      "name": "Quota adjustments"
    },
    {
      "name": "Workspace services"
    },
    {
      "name": "Vault connections"
    },
    {
      "name": "clusterJoin"
    },
    {
      "name": "joinBootstrap"
    },
    {
      "name": "clusters"
    },
    {
      "name": "Node pools"
    },
    {
      "name": "Nodes"
    },
    {
      "name": "machineBootstrap"
    },
    {
      "name": "machines"
    },
    {
      "name": "Sandboxes"
    },
    {
      "name": "OpenCode Servers"
    },
    {
      "name": "vaults"
    },
    {
      "name": "vaultSecrets"
    }
  ],
  "servers": [
    {
      "url": "https://api.akua.dev/v1"
    }
  ]
}
