{
  "openapi": "3.1.0",
  "info": {
    "title": "headless.bid Platform API",
    "version": "1.0.0-sandbox",
    "description": "Human Platform reads for the official CLI and hosted MCP. The OAuth grant selects one exact Workspace and Environment. This API cannot issue a Ledgero service credential or execute an auction intervention."
  },
  "servers": [
    {
      "url": "https://api.sandbox.headless.bid",
      "description": "Sandbox only"
    }
  ],
  "tags": [
    {
      "name": "Context"
    },
    {
      "name": "Inventory"
    },
    {
      "name": "Usage"
    },
    {
      "name": "Export"
    },
    {
      "name": "Lifecycle"
    },
    {
      "name": "Audit"
    }
  ],
  "paths": {
    "/v1/user": {
      "delete": {
        "operationId": "deleteCurrentUser",
        "summary": "Delete the authenticated User globally after recent authentication",
        "tags": [
          "Lifecycle"
        ],
        "security": [
          {
            "platformOAuth": [
              "platform:write"
            ]
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "confirmation"
                ],
                "properties": {
                  "confirmation": {
                    "type": "string",
                    "const": "DELETE MY ACCOUNT"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Durable deletion accepted; every session and grant will be revoked before PII removal.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "userDeletion",
                    "correlationId"
                  ],
                  "properties": {
                    "userDeletion": {
                      "type": "object",
                      "required": [
                        "operationId",
                        "status",
                        "webSessionsRevoked",
                        "webTransactionsInvalidated",
                        "replayedFromBackup",
                        "errorCode",
                        "requestedAt",
                        "completedAt"
                      ],
                      "properties": {
                        "operationId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "requested",
                            "ledger_recorded",
                            "access_revoked",
                            "complete"
                          ]
                        },
                        "webSessionsRevoked": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "webTransactionsInvalidated": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "replayedFromBackup": {
                          "type": "boolean"
                        },
                        "errorCode": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "ledger_unavailable",
                                "web_revoke_unavailable",
                                "pseudonymization_failed"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "requestedAt": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "completedAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/oauth/session-context": {
      "get": {
        "operationId": "getPlatformSessionContext",
        "summary": "Resolve the live context selected by the bearer",
        "security": [
          {
            "platformOAuth": [
              "platform:read"
            ]
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Successful exact-context Platform response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "userId",
                    "workspaceId",
                    "environmentId",
                    "environmentKind",
                    "surface",
                    "correlationId"
                  ],
                  "properties": {
                    "userId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128,
                      "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                    },
                    "workspaceId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128,
                      "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                    },
                    "environmentId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128,
                      "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                    },
                    "environmentKind": {
                      "type": "string",
                      "enum": [
                        "sandbox",
                        "production"
                      ]
                    },
                    "surface": {
                      "type": "string",
                      "enum": [
                        "web",
                        "cli",
                        "mcp"
                      ]
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/workspace-contexts": {
      "get": {
        "operationId": "listPlatformWorkspaceContexts",
        "summary": "List active contexts for the authenticated User",
        "security": [
          {
            "platformOAuth": [
              "platform:read"
            ]
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Successful exact-context Platform response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "contexts",
                    "correlationId"
                  ],
                  "properties": {
                    "contexts": {
                      "type": "array",
                      "maxItems": 100,
                      "items": {
                        "type": "object",
                        "required": [
                          "workspaceId",
                          "workspaceSlug",
                          "workspaceName",
                          "environmentId",
                          "environmentKind",
                          "role"
                        ],
                        "properties": {
                          "workspaceId": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 128,
                            "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                          },
                          "workspaceSlug": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 128,
                            "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                          },
                          "workspaceName": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 128
                          },
                          "environmentId": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 128,
                            "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                          },
                          "environmentKind": {
                            "type": "string",
                            "enum": [
                              "sandbox",
                              "production"
                            ]
                          },
                          "role": {
                            "type": "string",
                            "enum": [
                              "owner",
                              "admin",
                              "developer",
                              "viewer"
                            ]
                          }
                        },
                        "additionalProperties": false
                      }
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/usage": {
      "get": {
        "operationId": "getPlatformUsage",
        "summary": "Reconcile one retained Environment usage window",
        "security": [
          {
            "platformOAuth": [
              "platform:read"
            ]
          }
        ],
        "parameters": [
          {
            "in": "query",
            "name": "fromDay",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "in": "query",
            "name": "throughDay",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful exact-context Platform response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "usageVersion",
                    "classification",
                    "source",
                    "reconciliation",
                    "retentionDays",
                    "missingDays",
                    "fromDay",
                    "throughDay",
                    "items",
                    "correlationId"
                  ],
                  "properties": {
                    "usageVersion": {
                      "type": "string",
                      "const": "1.0"
                    },
                    "classification": {
                      "type": "string",
                      "const": "estimated_not_billing"
                    },
                    "source": {
                      "type": "string",
                      "const": "platform_projection"
                    },
                    "reconciliation": {
                      "type": "object",
                      "required": [
                        "basis",
                        "maximumAbsoluteError"
                      ],
                      "properties": {
                        "basis": {
                          "type": "string",
                          "const": "exact_at_source_watermark"
                        },
                        "maximumAbsoluteError": {
                          "type": "integer",
                          "const": 0
                        }
                      },
                      "additionalProperties": false
                    },
                    "retentionDays": {
                      "type": "integer",
                      "const": 90
                    },
                    "missingDays": {
                      "type": "string",
                      "const": "unknown"
                    },
                    "fromDay": {
                      "type": "string",
                      "format": "date"
                    },
                    "throughDay": {
                      "type": "string",
                      "format": "date"
                    },
                    "items": {
                      "type": "array",
                      "maxItems": 90,
                      "items": {
                        "type": "object",
                        "required": [
                          "internalSchemaVersion",
                          "environmentId",
                          "environmentKind",
                          "usageDay",
                          "revision",
                          "sourceWatermark",
                          "computedAt",
                          "final",
                          "lotsProvisioned",
                          "commandsAccepted",
                          "commandsRejected",
                          "sessionMinutes",
                          "deliveryAttempts",
                          "archiveBytes"
                        ],
                        "properties": {
                          "internalSchemaVersion": {
                            "type": "string",
                            "const": "platform-usage-projection-v1"
                          },
                          "environmentId": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 128,
                            "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                          },
                          "environmentKind": {
                            "type": "string",
                            "enum": [
                              "sandbox",
                              "production"
                            ]
                          },
                          "usageDay": {
                            "type": "string",
                            "format": "date"
                          },
                          "revision": {
                            "type": "integer",
                            "minimum": 1
                          },
                          "sourceWatermark": {
                            "type": "integer",
                            "minimum": 0
                          },
                          "computedAt": {
                            "type": "integer",
                            "minimum": 0
                          },
                          "final": {
                            "type": "boolean"
                          },
                          "lotsProvisioned": {
                            "type": "integer",
                            "minimum": 0
                          },
                          "commandsAccepted": {
                            "type": "integer",
                            "minimum": 0
                          },
                          "commandsRejected": {
                            "type": "integer",
                            "minimum": 0
                          },
                          "sessionMinutes": {
                            "type": "integer",
                            "minimum": 0
                          },
                          "deliveryAttempts": {
                            "type": "integer",
                            "minimum": 0
                          },
                          "archiveBytes": {
                            "type": "integer",
                            "minimum": 0
                          }
                        },
                        "additionalProperties": false
                      }
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/workspace-export": {
      "get": {
        "operationId": "getLatestWorkspaceExport",
        "summary": "Read the latest export operation for the active Workspace",
        "security": [
          {
            "platformOAuth": [
              "platform:read"
            ]
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Successful exact-context Platform response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "workspaceExport",
                    "correlationId"
                  ],
                  "properties": {
                    "workspaceExport": {
                      "anyOf": [
                        {
                          "type": "object",
                          "required": [
                            "operationId",
                            "workspaceId",
                            "status",
                            "requestedAt",
                            "completedAt",
                            "artifactExpiresAt",
                            "artifactDigest",
                            "artifactBytes",
                            "errorCode",
                            "manifest"
                          ],
                          "properties": {
                            "operationId": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 128,
                              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                            },
                            "workspaceId": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 128,
                              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                            },
                            "status": {
                              "type": "string",
                              "enum": [
                                "requested",
                                "building",
                                "ready",
                                "failed",
                                "expired"
                              ]
                            },
                            "requestedAt": {
                              "type": "integer",
                              "minimum": 0
                            },
                            "completedAt": {
                              "anyOf": [
                                {
                                  "type": "integer",
                                  "minimum": 0
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "artifactExpiresAt": {
                              "anyOf": [
                                {
                                  "type": "integer",
                                  "minimum": 0
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "artifactDigest": {
                              "anyOf": [
                                {
                                  "type": "string",
                                  "pattern": "^sha256:[a-f0-9]{64}$"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "artifactBytes": {
                              "anyOf": [
                                {
                                  "type": "integer",
                                  "minimum": 0
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "errorCode": {
                              "anyOf": [
                                {
                                  "type": "string"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "manifest": {
                              "anyOf": [
                                {
                                  "type": "object"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "additionalProperties": false
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "requestWorkspaceExport",
        "summary": "Request an asynchronous privacy-bounded Workspace export",
        "tags": [
          "Export"
        ],
        "security": [
          {
            "platformOAuth": [
              "platform:write"
            ]
          }
        ],
        "responses": {
          "202": {
            "description": "The durable export operation was accepted.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "workspaceExport",
                    "correlationId"
                  ],
                  "properties": {
                    "workspaceExport": {
                      "type": "object",
                      "required": [
                        "operationId",
                        "workspaceId",
                        "status",
                        "requestedAt",
                        "completedAt",
                        "artifactExpiresAt",
                        "artifactDigest",
                        "artifactBytes",
                        "errorCode",
                        "manifest"
                      ],
                      "properties": {
                        "operationId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "workspaceId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "requested",
                            "building",
                            "ready",
                            "failed",
                            "expired"
                          ]
                        },
                        "requestedAt": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "completedAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "artifactExpiresAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "artifactDigest": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^sha256:[a-f0-9]{64}$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "artifactBytes": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "errorCode": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "manifest": {
                          "anyOf": [
                            {
                              "type": "object"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/workspace-export/{operationId}": {
      "get": {
        "operationId": "getWorkspaceExport",
        "summary": "Read one export operation owned by the active Workspace",
        "security": [
          {
            "platformOAuth": [
              "platform:read"
            ]
          }
        ],
        "parameters": [
          {
            "in": "path",
            "name": "operationId",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128,
              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful exact-context Platform response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "workspaceExport",
                    "correlationId"
                  ],
                  "properties": {
                    "workspaceExport": {
                      "type": "object",
                      "required": [
                        "operationId",
                        "workspaceId",
                        "status",
                        "requestedAt",
                        "completedAt",
                        "artifactExpiresAt",
                        "artifactDigest",
                        "artifactBytes",
                        "errorCode",
                        "manifest"
                      ],
                      "properties": {
                        "operationId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "workspaceId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "requested",
                            "building",
                            "ready",
                            "failed",
                            "expired"
                          ]
                        },
                        "requestedAt": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "completedAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "artifactExpiresAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "artifactDigest": {
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^sha256:[a-f0-9]{64}$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "artifactBytes": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "errorCode": {
                          "anyOf": [
                            {
                              "type": "string"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "manifest": {
                          "anyOf": [
                            {
                              "type": "object"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/workspace-export/{operationId}/download-grant": {
      "post": {
        "operationId": "issueWorkspaceExportDownloadGrant",
        "summary": "Issue a recent-auth download grant bounded to 24 hours",
        "tags": [
          "Export"
        ],
        "security": [
          {
            "platformOAuth": [
              "platform:write"
            ]
          }
        ],
        "parameters": [
          {
            "in": "path",
            "name": "operationId",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128,
              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "An opaque temporary grant was issued once.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "downloadGrant",
                    "correlationId"
                  ],
                  "properties": {
                    "downloadGrant": {
                      "type": "object",
                      "required": [
                        "grant",
                        "expiresAt"
                      ],
                      "properties": {
                        "grant": {
                          "type": "string",
                          "minLength": 43,
                          "maxLength": 43
                        },
                        "expiresAt": {
                          "type": "integer",
                          "minimum": 0
                        }
                      },
                      "additionalProperties": false
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/workspace-export/{operationId}/download": {
      "post": {
        "operationId": "downloadWorkspaceExport",
        "summary": "Download and checksum-verify one staged export artifact",
        "tags": [
          "Export"
        ],
        "security": [
          {
            "platformOAuth": [
              "platform:write"
            ]
          }
        ],
        "parameters": [
          {
            "in": "path",
            "name": "operationId",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128,
              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "grant"
                ],
                "properties": {
                  "grant": {
                    "type": "string",
                    "minLength": 43,
                    "maxLength": 43
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Canonical Workspace export JSON artifact.",
            "headers": {
              "X-Export-Digest": {
                "schema": {
                  "type": "string",
                  "pattern": "^sha256:[a-f0-9]{64}$"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "type": "string",
                  "format": "binary"
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/workspace-closure": {
      "get": {
        "operationId": "getLatestWorkspaceClosure",
        "summary": "Read the latest durable closure operation for this Workspace",
        "security": [
          {
            "platformOAuth": [
              "platform:read"
            ]
          }
        ],
        "parameters": [],
        "responses": {
          "200": {
            "description": "Successful exact-context Platform response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "workspaceClosure",
                    "correlationId"
                  ],
                  "properties": {
                    "workspaceClosure": {
                      "anyOf": [
                        {
                          "type": "object",
                          "required": [
                            "operationId",
                            "workspaceId",
                            "status",
                            "notBefore",
                            "blockerCode",
                            "exportOperationId",
                            "exportWaiverCode",
                            "webSessionsRevoked",
                            "deletionCheckpoints",
                            "environments",
                            "legalHolds",
                            "retainedClasses",
                            "requestedAt",
                            "completedAt",
                            "cancelledAt"
                          ],
                          "properties": {
                            "operationId": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 128,
                              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                            },
                            "workspaceId": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 128,
                              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                            },
                            "status": {
                              "type": "string",
                              "enum": [
                                "closure_requested",
                                "draining",
                                "integrations_revoked",
                                "deleting",
                                "closed",
                                "cancelled"
                              ]
                            },
                            "notBefore": {
                              "type": "integer",
                              "minimum": 0
                            },
                            "blockerCode": {
                              "anyOf": [
                                {
                                  "type": "string",
                                  "enum": [
                                    "blocked_live_work",
                                    "blocked_delivery",
                                    "blocked_retention",
                                    "dependency_unavailable"
                                  ]
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "exportOperationId": {
                              "anyOf": [
                                {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128,
                                  "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "exportWaiverCode": {
                              "anyOf": [
                                {
                                  "type": "string",
                                  "const": "declined_by_owner"
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "webSessionsRevoked": {
                              "type": "integer",
                              "minimum": 0
                            },
                            "deletionCheckpoints": {
                              "type": "array",
                              "maxItems": 7,
                              "items": {
                                "type": "object",
                                "required": [
                                  "dataClass",
                                  "status",
                                  "deletedRows"
                                ],
                                "properties": {
                                  "dataClass": {
                                    "type": "string",
                                    "enum": [
                                      "operator_connections",
                                      "production_applications",
                                      "workspace_invitations",
                                      "usage_projections",
                                      "memberships",
                                      "environment_configuration",
                                      "workspace_profile"
                                    ]
                                  },
                                  "status": {
                                    "type": "string",
                                    "enum": [
                                      "pending",
                                      "complete",
                                      "held"
                                    ]
                                  },
                                  "deletedRows": {
                                    "type": "integer",
                                    "minimum": 0
                                  }
                                },
                                "additionalProperties": false
                              }
                            },
                            "environments": {
                              "type": "array",
                              "maxItems": 2,
                              "items": {
                                "type": "object",
                                "required": [
                                  "environmentId",
                                  "environmentKind",
                                  "readiness",
                                  "barrierApplied",
                                  "integrationsRevoked",
                                  "ciphertextDestroyed"
                                ],
                                "properties": {
                                  "environmentId": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 128,
                                    "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                                  },
                                  "environmentKind": {
                                    "type": "string",
                                    "enum": [
                                      "sandbox",
                                      "production"
                                    ]
                                  },
                                  "readiness": {
                                    "anyOf": [
                                      {
                                        "type": "object",
                                        "required": [
                                          "nonTerminalLots",
                                          "unarchivedTerminalLots",
                                          "pendingDeliveries",
                                          "pendingCleanupTickets",
                                          "activeServiceCredentials",
                                          "activeIssuers",
                                          "activeWebhooks",
                                          "retainedEvidenceRecords"
                                        ],
                                        "properties": {
                                          "nonTerminalLots": {
                                            "type": "integer",
                                            "minimum": 0
                                          },
                                          "unarchivedTerminalLots": {
                                            "type": "integer",
                                            "minimum": 0
                                          },
                                          "pendingDeliveries": {
                                            "type": "integer",
                                            "minimum": 0
                                          },
                                          "pendingCleanupTickets": {
                                            "type": "integer",
                                            "minimum": 0
                                          },
                                          "activeServiceCredentials": {
                                            "type": "integer",
                                            "minimum": 0
                                          },
                                          "activeIssuers": {
                                            "type": "integer",
                                            "minimum": 0
                                          },
                                          "activeWebhooks": {
                                            "type": "integer",
                                            "minimum": 0
                                          },
                                          "retainedEvidenceRecords": {
                                            "type": "integer",
                                            "minimum": 0
                                          }
                                        },
                                        "additionalProperties": false
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "barrierApplied": {
                                    "type": "boolean"
                                  },
                                  "integrationsRevoked": {
                                    "type": "boolean"
                                  },
                                  "ciphertextDestroyed": {
                                    "type": "boolean"
                                  }
                                },
                                "additionalProperties": false
                              }
                            },
                            "legalHolds": {
                              "type": "array",
                              "maxItems": 100,
                              "items": {
                                "type": "object",
                                "required": [
                                  "holdId",
                                  "dataClass",
                                  "scope",
                                  "approvedBy",
                                  "reviewAt",
                                  "expiresAt"
                                ],
                                "properties": {
                                  "holdId": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 128,
                                    "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                                  },
                                  "dataClass": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 128
                                  },
                                  "scope": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 512
                                  },
                                  "approvedBy": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 128,
                                    "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                                  },
                                  "reviewAt": {
                                    "type": "integer",
                                    "minimum": 0
                                  },
                                  "expiresAt": {
                                    "type": "integer",
                                    "minimum": 0
                                  }
                                },
                                "additionalProperties": false
                              }
                            },
                            "retainedClasses": {
                              "type": "array",
                              "maxItems": 16,
                              "items": {
                                "type": "object",
                                "required": [
                                  "dataClass",
                                  "reason",
                                  "access",
                                  "policy"
                                ],
                                "properties": {
                                  "dataClass": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 128
                                  },
                                  "reason": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 512
                                  },
                                  "access": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 256
                                  },
                                  "policy": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 256
                                  }
                                },
                                "additionalProperties": false
                              }
                            },
                            "requestedAt": {
                              "type": "integer",
                              "minimum": 0
                            },
                            "completedAt": {
                              "anyOf": [
                                {
                                  "type": "integer",
                                  "minimum": 0
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "cancelledAt": {
                              "anyOf": [
                                {
                                  "type": "integer",
                                  "minimum": 0
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            }
                          },
                          "additionalProperties": false
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      },
      "post": {
        "operationId": "requestWorkspaceClosure",
        "summary": "Request Workspace closure with a seven-day reversible barrier",
        "tags": [
          "Lifecycle"
        ],
        "security": [
          {
            "platformOAuth": [
              "platform:write"
            ]
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "confirmation"
                ],
                "properties": {
                  "confirmation": {
                    "type": "string",
                    "minLength": 7,
                    "maxLength": 134
                  },
                  "exportOperationId": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                  },
                  "exportWaiverCode": {
                    "type": "string",
                    "const": "declined_by_owner"
                  }
                },
                "oneOf": [
                  {
                    "required": [
                      "exportOperationId"
                    ]
                  },
                  {
                    "required": [
                      "exportWaiverCode"
                    ]
                  }
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "The durable closure operation was accepted.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "workspaceClosure",
                    "correlationId"
                  ],
                  "properties": {
                    "workspaceClosure": {
                      "type": "object",
                      "required": [
                        "operationId",
                        "workspaceId",
                        "status",
                        "notBefore",
                        "blockerCode",
                        "exportOperationId",
                        "exportWaiverCode",
                        "webSessionsRevoked",
                        "deletionCheckpoints",
                        "environments",
                        "legalHolds",
                        "retainedClasses",
                        "requestedAt",
                        "completedAt",
                        "cancelledAt"
                      ],
                      "properties": {
                        "operationId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "workspaceId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "closure_requested",
                            "draining",
                            "integrations_revoked",
                            "deleting",
                            "closed",
                            "cancelled"
                          ]
                        },
                        "notBefore": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "blockerCode": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "blocked_live_work",
                                "blocked_delivery",
                                "blocked_retention",
                                "dependency_unavailable"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "exportOperationId": {
                          "anyOf": [
                            {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 128,
                              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "exportWaiverCode": {
                          "anyOf": [
                            {
                              "type": "string",
                              "const": "declined_by_owner"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "webSessionsRevoked": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "deletionCheckpoints": {
                          "type": "array",
                          "maxItems": 7,
                          "items": {
                            "type": "object",
                            "required": [
                              "dataClass",
                              "status",
                              "deletedRows"
                            ],
                            "properties": {
                              "dataClass": {
                                "type": "string",
                                "enum": [
                                  "operator_connections",
                                  "production_applications",
                                  "workspace_invitations",
                                  "usage_projections",
                                  "memberships",
                                  "environment_configuration",
                                  "workspace_profile"
                                ]
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "pending",
                                  "complete",
                                  "held"
                                ]
                              },
                              "deletedRows": {
                                "type": "integer",
                                "minimum": 0
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "environments": {
                          "type": "array",
                          "maxItems": 2,
                          "items": {
                            "type": "object",
                            "required": [
                              "environmentId",
                              "environmentKind",
                              "readiness",
                              "barrierApplied",
                              "integrationsRevoked",
                              "ciphertextDestroyed"
                            ],
                            "properties": {
                              "environmentId": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128,
                                "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                              },
                              "environmentKind": {
                                "type": "string",
                                "enum": [
                                  "sandbox",
                                  "production"
                                ]
                              },
                              "readiness": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "required": [
                                      "nonTerminalLots",
                                      "unarchivedTerminalLots",
                                      "pendingDeliveries",
                                      "pendingCleanupTickets",
                                      "activeServiceCredentials",
                                      "activeIssuers",
                                      "activeWebhooks",
                                      "retainedEvidenceRecords"
                                    ],
                                    "properties": {
                                      "nonTerminalLots": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "unarchivedTerminalLots": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "pendingDeliveries": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "pendingCleanupTickets": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "activeServiceCredentials": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "activeIssuers": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "activeWebhooks": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "retainedEvidenceRecords": {
                                        "type": "integer",
                                        "minimum": 0
                                      }
                                    },
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "barrierApplied": {
                                "type": "boolean"
                              },
                              "integrationsRevoked": {
                                "type": "boolean"
                              },
                              "ciphertextDestroyed": {
                                "type": "boolean"
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "legalHolds": {
                          "type": "array",
                          "maxItems": 100,
                          "items": {
                            "type": "object",
                            "required": [
                              "holdId",
                              "dataClass",
                              "scope",
                              "approvedBy",
                              "reviewAt",
                              "expiresAt"
                            ],
                            "properties": {
                              "holdId": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128,
                                "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                              },
                              "dataClass": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128
                              },
                              "scope": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 512
                              },
                              "approvedBy": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128,
                                "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                              },
                              "reviewAt": {
                                "type": "integer",
                                "minimum": 0
                              },
                              "expiresAt": {
                                "type": "integer",
                                "minimum": 0
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "retainedClasses": {
                          "type": "array",
                          "maxItems": 16,
                          "items": {
                            "type": "object",
                            "required": [
                              "dataClass",
                              "reason",
                              "access",
                              "policy"
                            ],
                            "properties": {
                              "dataClass": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128
                              },
                              "reason": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 512
                              },
                              "access": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 256
                              },
                              "policy": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 256
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "requestedAt": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "completedAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "cancelledAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/workspace-closure/{operationId}": {
      "get": {
        "operationId": "getWorkspaceClosure",
        "summary": "Read one durable closure operation",
        "security": [
          {
            "platformOAuth": [
              "platform:read"
            ]
          }
        ],
        "parameters": [
          {
            "in": "path",
            "name": "operationId",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128,
              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful exact-context Platform response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "workspaceClosure",
                    "correlationId"
                  ],
                  "properties": {
                    "workspaceClosure": {
                      "type": "object",
                      "required": [
                        "operationId",
                        "workspaceId",
                        "status",
                        "notBefore",
                        "blockerCode",
                        "exportOperationId",
                        "exportWaiverCode",
                        "webSessionsRevoked",
                        "deletionCheckpoints",
                        "environments",
                        "legalHolds",
                        "retainedClasses",
                        "requestedAt",
                        "completedAt",
                        "cancelledAt"
                      ],
                      "properties": {
                        "operationId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "workspaceId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "closure_requested",
                            "draining",
                            "integrations_revoked",
                            "deleting",
                            "closed",
                            "cancelled"
                          ]
                        },
                        "notBefore": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "blockerCode": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "blocked_live_work",
                                "blocked_delivery",
                                "blocked_retention",
                                "dependency_unavailable"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "exportOperationId": {
                          "anyOf": [
                            {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 128,
                              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "exportWaiverCode": {
                          "anyOf": [
                            {
                              "type": "string",
                              "const": "declined_by_owner"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "webSessionsRevoked": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "deletionCheckpoints": {
                          "type": "array",
                          "maxItems": 7,
                          "items": {
                            "type": "object",
                            "required": [
                              "dataClass",
                              "status",
                              "deletedRows"
                            ],
                            "properties": {
                              "dataClass": {
                                "type": "string",
                                "enum": [
                                  "operator_connections",
                                  "production_applications",
                                  "workspace_invitations",
                                  "usage_projections",
                                  "memberships",
                                  "environment_configuration",
                                  "workspace_profile"
                                ]
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "pending",
                                  "complete",
                                  "held"
                                ]
                              },
                              "deletedRows": {
                                "type": "integer",
                                "minimum": 0
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "environments": {
                          "type": "array",
                          "maxItems": 2,
                          "items": {
                            "type": "object",
                            "required": [
                              "environmentId",
                              "environmentKind",
                              "readiness",
                              "barrierApplied",
                              "integrationsRevoked",
                              "ciphertextDestroyed"
                            ],
                            "properties": {
                              "environmentId": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128,
                                "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                              },
                              "environmentKind": {
                                "type": "string",
                                "enum": [
                                  "sandbox",
                                  "production"
                                ]
                              },
                              "readiness": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "required": [
                                      "nonTerminalLots",
                                      "unarchivedTerminalLots",
                                      "pendingDeliveries",
                                      "pendingCleanupTickets",
                                      "activeServiceCredentials",
                                      "activeIssuers",
                                      "activeWebhooks",
                                      "retainedEvidenceRecords"
                                    ],
                                    "properties": {
                                      "nonTerminalLots": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "unarchivedTerminalLots": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "pendingDeliveries": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "pendingCleanupTickets": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "activeServiceCredentials": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "activeIssuers": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "activeWebhooks": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "retainedEvidenceRecords": {
                                        "type": "integer",
                                        "minimum": 0
                                      }
                                    },
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "barrierApplied": {
                                "type": "boolean"
                              },
                              "integrationsRevoked": {
                                "type": "boolean"
                              },
                              "ciphertextDestroyed": {
                                "type": "boolean"
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "legalHolds": {
                          "type": "array",
                          "maxItems": 100,
                          "items": {
                            "type": "object",
                            "required": [
                              "holdId",
                              "dataClass",
                              "scope",
                              "approvedBy",
                              "reviewAt",
                              "expiresAt"
                            ],
                            "properties": {
                              "holdId": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128,
                                "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                              },
                              "dataClass": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128
                              },
                              "scope": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 512
                              },
                              "approvedBy": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128,
                                "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                              },
                              "reviewAt": {
                                "type": "integer",
                                "minimum": 0
                              },
                              "expiresAt": {
                                "type": "integer",
                                "minimum": 0
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "retainedClasses": {
                          "type": "array",
                          "maxItems": 16,
                          "items": {
                            "type": "object",
                            "required": [
                              "dataClass",
                              "reason",
                              "access",
                              "policy"
                            ],
                            "properties": {
                              "dataClass": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128
                              },
                              "reason": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 512
                              },
                              "access": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 256
                              },
                              "policy": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 256
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "requestedAt": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "completedAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "cancelledAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/workspace-closure/{operationId}/cancel": {
      "post": {
        "operationId": "cancelWorkspaceClosure",
        "summary": "Cancel closure before its irreversible boundary",
        "tags": [
          "Lifecycle"
        ],
        "security": [
          {
            "platformOAuth": [
              "platform:write"
            ]
          }
        ],
        "parameters": [
          {
            "in": "path",
            "name": "operationId",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128,
              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "The exact prior Workspace and Environment state was restored.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "workspaceClosure",
                    "correlationId"
                  ],
                  "properties": {
                    "workspaceClosure": {
                      "type": "object",
                      "required": [
                        "operationId",
                        "workspaceId",
                        "status",
                        "notBefore",
                        "blockerCode",
                        "exportOperationId",
                        "exportWaiverCode",
                        "webSessionsRevoked",
                        "deletionCheckpoints",
                        "environments",
                        "legalHolds",
                        "retainedClasses",
                        "requestedAt",
                        "completedAt",
                        "cancelledAt"
                      ],
                      "properties": {
                        "operationId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "workspaceId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "closure_requested",
                            "draining",
                            "integrations_revoked",
                            "deleting",
                            "closed",
                            "cancelled"
                          ]
                        },
                        "notBefore": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "blockerCode": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "blocked_live_work",
                                "blocked_delivery",
                                "blocked_retention",
                                "dependency_unavailable"
                              ]
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "exportOperationId": {
                          "anyOf": [
                            {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 128,
                              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "exportWaiverCode": {
                          "anyOf": [
                            {
                              "type": "string",
                              "const": "declined_by_owner"
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "webSessionsRevoked": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "deletionCheckpoints": {
                          "type": "array",
                          "maxItems": 7,
                          "items": {
                            "type": "object",
                            "required": [
                              "dataClass",
                              "status",
                              "deletedRows"
                            ],
                            "properties": {
                              "dataClass": {
                                "type": "string",
                                "enum": [
                                  "operator_connections",
                                  "production_applications",
                                  "workspace_invitations",
                                  "usage_projections",
                                  "memberships",
                                  "environment_configuration",
                                  "workspace_profile"
                                ]
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "pending",
                                  "complete",
                                  "held"
                                ]
                              },
                              "deletedRows": {
                                "type": "integer",
                                "minimum": 0
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "environments": {
                          "type": "array",
                          "maxItems": 2,
                          "items": {
                            "type": "object",
                            "required": [
                              "environmentId",
                              "environmentKind",
                              "readiness",
                              "barrierApplied",
                              "integrationsRevoked",
                              "ciphertextDestroyed"
                            ],
                            "properties": {
                              "environmentId": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128,
                                "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                              },
                              "environmentKind": {
                                "type": "string",
                                "enum": [
                                  "sandbox",
                                  "production"
                                ]
                              },
                              "readiness": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "required": [
                                      "nonTerminalLots",
                                      "unarchivedTerminalLots",
                                      "pendingDeliveries",
                                      "pendingCleanupTickets",
                                      "activeServiceCredentials",
                                      "activeIssuers",
                                      "activeWebhooks",
                                      "retainedEvidenceRecords"
                                    ],
                                    "properties": {
                                      "nonTerminalLots": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "unarchivedTerminalLots": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "pendingDeliveries": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "pendingCleanupTickets": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "activeServiceCredentials": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "activeIssuers": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "activeWebhooks": {
                                        "type": "integer",
                                        "minimum": 0
                                      },
                                      "retainedEvidenceRecords": {
                                        "type": "integer",
                                        "minimum": 0
                                      }
                                    },
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "barrierApplied": {
                                "type": "boolean"
                              },
                              "integrationsRevoked": {
                                "type": "boolean"
                              },
                              "ciphertextDestroyed": {
                                "type": "boolean"
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "legalHolds": {
                          "type": "array",
                          "maxItems": 100,
                          "items": {
                            "type": "object",
                            "required": [
                              "holdId",
                              "dataClass",
                              "scope",
                              "approvedBy",
                              "reviewAt",
                              "expiresAt"
                            ],
                            "properties": {
                              "holdId": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128,
                                "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                              },
                              "dataClass": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128
                              },
                              "scope": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 512
                              },
                              "approvedBy": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128,
                                "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
                              },
                              "reviewAt": {
                                "type": "integer",
                                "minimum": 0
                              },
                              "expiresAt": {
                                "type": "integer",
                                "minimum": 0
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "retainedClasses": {
                          "type": "array",
                          "maxItems": 16,
                          "items": {
                            "type": "object",
                            "required": [
                              "dataClass",
                              "reason",
                              "access",
                              "policy"
                            ],
                            "properties": {
                              "dataClass": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 128
                              },
                              "reason": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 512
                              },
                              "access": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 256
                              },
                              "policy": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 256
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "requestedAt": {
                          "type": "integer",
                          "minimum": 0
                        },
                        "completedAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "cancelledAt": {
                          "anyOf": [
                            {
                              "type": "integer",
                              "minimum": 0
                            },
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "additionalProperties": false
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/administrative/{kind}": {
      "get": {
        "operationId": "listPlatformAdministrativeResources",
        "summary": "Read one bounded page from the selected Environment",
        "security": [
          {
            "platformOAuth": [
              "platform:read"
            ]
          }
        ],
        "parameters": [
          {
            "in": "path",
            "name": "kind",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "auction",
                "lot",
                "service_credential",
                "issuer",
                "webhook_endpoint",
                "delivery_attention",
                "intervention",
                "evidence",
                "ceiling",
                "usage_projection"
              ]
            }
          },
          {
            "in": "query",
            "name": "limit",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 50
            }
          },
          {
            "in": "query",
            "name": "cursor",
            "schema": {
              "type": "string",
              "minLength": 16,
              "maxLength": 512,
              "pattern": "^[A-Za-z0-9_-]+$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful exact-context Platform response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "freshness",
                    "source",
                    "engine",
                    "correlationId"
                  ],
                  "properties": {
                    "freshness": {
                      "type": "string",
                      "const": "fresh"
                    },
                    "source": {
                      "type": "string",
                      "const": "engine"
                    },
                    "engine": {
                      "type": "object",
                      "description": "Validated Ledgero AdministrativeReadPage for the selected kind."
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/lots/{lotId}/snapshot": {
      "get": {
        "operationId": "getPlatformLotSnapshot",
        "summary": "Read the authoritative sanitized lot snapshot",
        "security": [
          {
            "platformOAuth": [
              "platform:read"
            ]
          }
        ],
        "parameters": [
          {
            "in": "path",
            "name": "lotId",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128,
              "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]*$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful exact-context Platform response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "freshness",
                    "source",
                    "engine",
                    "correlationId"
                  ],
                  "properties": {
                    "freshness": {
                      "type": "string",
                      "const": "authoritative"
                    },
                    "source": {
                      "type": "string",
                      "const": "engine"
                    },
                    "engine": {
                      "type": "object",
                      "description": "Validated Ledgero LotAdministrativeSnapshot."
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    },
    "/v1/platform-audit": {
      "get": {
        "operationId": "listPlatformAudit",
        "summary": "Read a bounded audit page from the selected context",
        "security": [
          {
            "platformOAuth": [
              "platform:read"
            ]
          }
        ],
        "parameters": [
          {
            "in": "query",
            "name": "limit",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 50
            }
          },
          {
            "in": "query",
            "name": "beforeSequence",
            "schema": {
              "type": "integer",
              "minimum": 1
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful exact-context Platform response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "items",
                    "nextBeforeSequence",
                    "correlationId"
                  ],
                  "properties": {
                    "items": {
                      "type": "array",
                      "maxItems": 100,
                      "items": {
                        "type": "object"
                      }
                    },
                    "nextBeforeSequence": {
                      "anyOf": [
                        {
                          "type": "integer",
                          "minimum": 1
                        },
                        {
                          "type": "null"
                        }
                      ]
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Platform request failed with HTTP 400.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Platform request failed with HTTP 401.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "403": {
            "description": "Platform request failed with HTTP 403.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "404": {
            "description": "Platform request failed with HTTP 404.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "409": {
            "description": "Platform request failed with HTTP 409.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "429": {
            "description": "Platform request failed with HTTP 429.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          },
          "503": {
            "description": "Platform request failed with HTTP 503.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "error",
                    "correlationId"
                  ],
                  "properties": {
                    "error": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "retryable": {
                      "type": "boolean"
                    },
                    "correlationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    },
                    "engineCorrelationId": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "additionalProperties": false
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "platformOAuth": {
        "type": "oauth2",
        "description": "Authorization code + S256. CLI and MCP are public clients; no client secret is accepted from them.",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://oauth.sandbox.headless.bid/authorize",
            "tokenUrl": "https://oauth.sandbox.headless.bid/oauth/token",
            "scopes": {
              "platform:read": "Read the exact consented Platform context.",
              "platform:write": "Web/CLI ceiling; does not grant Ledgero economic authority.",
              "platform:prepare": "MCP ceiling for Web handoff; cannot confirm or execute."
            }
          }
        }
      }
    }
  },
  "x-headless-authority": {
    "cli": "read plus browser handoff",
    "mcp": "read plus browser handoff",
    "interventionExecution": false
  }
}
