{"openapi":"3.1.0","info":{"title":"Synapsor Cloud Control Plane API","version":"v1","description":"Hosted single-node Synapsor Cloud V2 controlled-beta control-plane contract."},"servers":[{"url":"https://synapsor.ai"}],"x-synapsor-control-plane-version":"v1","x-synapsor-product-version":"v2-controlled-beta","x-synapsor-version-note":"The /v1 path prefix is the stable API namespace for the Synapsor Cloud V2 controlled-beta product.","x-synapsor-deployment-version":"ec175d80","paths":{"/v1/control/openapi.json":{"get":{"operationId":"getControlOpenapi","summary":"Return this OpenAPI contract.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[]}},"/v1/control/health":{"get":{"operationId":"getControlHealth","summary":"Return lightweight control-plane health.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[]},"head":{"operationId":"headControlHealth","summary":"Return lightweight control-plane health headers.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[]}},"/v1/control/status":{"get":{"operationId":"getControlStatus","summary":"Return scoped hosted status and diagnostics.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/status-page":{"get":{"operationId":"getPublicStatusPage","summary":"Return public-safe service status and public incident summaries without customer identifiers.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[]}},"/v1/control/seed":{"get":{"operationId":"getSeedProjects","summary":"Seed demo projects.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]},"post":{"operationId":"postSeedProjects","summary":"Seed demo projects.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/quota-check":{"get":{"operationId":"getQuotaCheck","summary":"Check plan quota headroom from query usage values.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/projects":{"get":{"operationId":"listProjects","summary":"List visible projects.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":500},"description":"Maximum items to return. Responses include next_cursor when another page is available."},{"name":"cursor","in":"query","required":false,"schema":{"type":"string"},"description":"Opaque cursor returned by a previous list response."},{"name":"include_archived","in":"query","required":false,"schema":{"type":"boolean"}}]},"post":{"operationId":"createProject","summary":"Create a project.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/projects/{project_id}/archive":{"post":{"operationId":"archiveProject","summary":"Archive a project and revoke active project API keys.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/projects/{project_id}/delete":{"post":{"operationId":"deleteProject","summary":"Delete a project, cascade-delete hosted databases, and revoke active project API keys.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/projects/{project_id}/spend-cap":{"post":{"operationId":"setProjectSpendCap","summary":"Set a project spend cap and warning threshold.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/projects/{project_id}/usage/reset":{"post":{"operationId":"resetProjectUsageCounters","summary":"Admin-only reset for capability invocation and embedding-call counters.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/accounts":{"get":{"operationId":"listAccounts","summary":"List visible accounts.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":500},"description":"Maximum items to return. Responses include next_cursor when another page is available."},{"name":"cursor","in":"query","required":false,"schema":{"type":"string"},"description":"Opaque cursor returned by a previous list response."},{"name":"search","in":"query","required":false,"schema":{"type":"string"},"description":"Operator-only keyword or exact email search across accounts and related project/database billing records."}]},"post":{"operationId":"createAccount","summary":"Create an account.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/accounts/{account_id}/delete":{"post":{"operationId":"deleteAccount","summary":"Admin-only account deletion with cascaded hosted resource cleanup.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/invites":{"get":{"operationId":"listInvites","summary":"List controlled-beta invites.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]},"post":{"operationId":"createInvite","summary":"Create a controlled-beta invite.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/invites/index/backfill":{"post":{"operationId":"backfillInviteIndex","summary":"Backfill the bounded invite listing index.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/audit-events/index/backfill":{"post":{"operationId":"backfillAuditEventIndex","summary":"Backfill the bounded audit-event listing index.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/usage-events/index/backfill":{"post":{"operationId":"backfillUsageEventIndex","summary":"Backfill the bounded usage-event listing index.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/invites/accept":{"post":{"operationId":"acceptInvite","summary":"Accept a controlled-beta invite.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/sessions":{"post":{"operationId":"createAccountSession","summary":"Create a developer account session with email and password.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/password-reset/request":{"post":{"operationId":"requestPasswordReset","summary":"Request a throttled password-reset email.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/password-reset/confirm":{"post":{"operationId":"confirmPasswordReset","summary":"Confirm a password reset token and create a new session.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/signup-requests":{"get":{"operationId":"listSignupRequests","summary":"List public signup requests.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]},"post":{"operationId":"createSignupRequest","summary":"Request hosted Synapsor access.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/signup-requests/index/backfill":{"post":{"operationId":"backfillSignupRequestIndex","summary":"Backfill the bounded signup request listing index.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/signup-requests/{request_id}/approve":{"post":{"operationId":"approveSignupRequest","summary":"Approve a signup request, create an invite, and optionally send the invite email.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/signup-requests/{request_id}/close":{"post":{"operationId":"closeSignupRequest","summary":"Close or reject a signup request.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"request_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/operator/sessions":{"post":{"operationId":"createOperatorSession","summary":"Create an HttpOnly operator session from configured admin credentials. Hardened environments can require TOTP, recovery code, or passkey MFA plus an audited reason, ticket, scope, and expiry.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/operator/sessions/revoke":{"post":{"operationId":"revokeOperatorSession","summary":"Admin-only revocation of a named operator session for support-access cleanup and evidence drills.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/operator/webauthn/register/options":{"post":{"operationId":"createOperatorWebAuthnRegistrationOptions","summary":"Create passkey/security-key registration options for an authenticated operator session.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/operator/webauthn/register/verify":{"post":{"operationId":"verifyOperatorWebAuthnRegistration","summary":"Verify a passkey/security-key registration response and store the operator credential.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/operator/webauthn/authenticate/options":{"post":{"operationId":"createOperatorWebAuthnAuthenticationOptions","summary":"Create passkey/security-key authentication options after validating operator username and password.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/operator/access-review":{"get":{"operationId":"exportOperatorAccessReview","summary":"Admin-only export of recent operator sessions, support-access fields, break-glass flags, MFA metadata, and operator-session audit events.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":500},"description":"Maximum items to return. Responses include next_cursor when another page is available."}]}},"/v1/control/sessions/self":{"get":{"operationId":"getOwnSession","summary":"Return the current session context.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/sessions/revoke":{"post":{"operationId":"revokeSession","summary":"Revoke the current or named session.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/projects/index/backfill":{"post":{"operationId":"backfillProjectIndex","summary":"Admin-only maintenance operation that backfills the queryable project index used by compact status/list paths.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/databases/index/backfill":{"post":{"operationId":"backfillDatabaseIndex","summary":"Admin-only maintenance operation that backfills the queryable database index used by compact status/list paths.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/api-keys":{"get":{"operationId":"listApiKeys","summary":"List visible API keys.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"}}]},"post":{"operationId":"createApiKey","summary":"Create an API key and return the raw token once. Production environments can require expires_at.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateApiKeyRequest"}}}}}},"/v1/control/api-keys/revoke":{"post":{"operationId":"revokeApiKey","summary":"Revoke an API key.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/api-keys/rotate":{"post":{"operationId":"rotateApiKey","summary":"Create a replacement API key with the same scope by default, return the new raw token once, and revoke the old key.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RotateApiKeyRequest"}}}}}},"/v1/control/auth/validate":{"post":{"operationId":"validateApiKey","summary":"Validate a gateway bearer token.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[]}},"/v1/control/external-sources":{"get":{"operationId":"listExternalSources","summary":"List visible external Postgres or MySQL sources. live_read is the current public connector path; cdc_mirror is preview/dev-test only.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"}}]},"post":{"operationId":"createExternalSource","summary":"Create an external Postgres or MySQL source and store its connection secret by reference. live_read is the default; cdc_mirror is preview/dev-test only and requires explicit acknowledgement.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/test-connection":{"post":{"operationId":"testExternalSourceConnection","summary":"Test an unsaved Postgres or MySQL connection from Synapsor Cloud without storing credentials. The response returns redacted metadata only.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}":{"get":{"operationId":"getExternalSource","summary":"Get safe metadata for an external Postgres or MySQL source.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}}]},"delete":{"operationId":"disableExternalSource","summary":"Disable an external source without deleting historical evidence or audit records.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}}]}},"/v1/control/external-sources/{source_id}/test":{"post":{"operationId":"testExternalSource","summary":"Test a least-privilege Postgres or MySQL connection with redacted errors.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/credentials":{"post":{"operationId":"replaceExternalSourceCredentials","summary":"Replace saved external-source credentials for an existing source without creating a new source slot. The response returns redacted source metadata only.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/inspect":{"post":{"operationId":"inspectExternalSource","summary":"Inspect Postgres schemas or MySQL databases, tables, views, columns, primary keys, and foreign keys.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/import":{"post":{"operationId":"importExternalSourceTables","summary":"Import selected Postgres or MySQL tables/views as live-read mappings. cdc_mirror imports are preview/dev-test only and require explicit acknowledgement.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/generate":{"post":{"operationId":"generateExternalSourceTemplates","summary":"Generate safe context, capability, and workflow examples for imported Postgres or MySQL mappings.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/setup-complete":{"post":{"operationId":"completeExternalSourceSetup","summary":"Mark the signed-in existing-database setup as complete after the user reviews the read-only/writeback boundary.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/audit":{"get":{"operationId":"listExternalQueryAudit","summary":"List redacted query-audit records for an external source.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/external-sources/{source_id}/cdc/status":{"get":{"operationId":"getExternalSourceCdcStatus","summary":"Return preview/dev-test CDC mirrored-subset status for an external Postgres or MySQL source.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}}]}},"/v1/control/external-sources/{source_id}/cdc/soak-evidence":{"get":{"operationId":"listExternalSourceCdcSoakEvidence","summary":"List daily preview/dev-test CDC soak evidence records for an external source.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}}]},"post":{"operationId":"recordExternalSourceCdcSoakEvidence","summary":"Record a bounded daily/smoke CDC evidence result for operator review. This does not mark CDC production-supported.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/cdc/checkpoints":{"get":{"operationId":"listExternalSourceCdcCheckpoints","summary":"List preview/dev-test CDC source-position checkpoints used for restore validation and idempotent replay evidence.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}}]}},"/v1/control/external-sources/{source_id}/cdc/snapshot":{"post":{"operationId":"snapshotExternalSourceCdcMirror","summary":"Run an explicitly acknowledged preview/dev-test CDC mirrored-subset snapshot/catch-up for selected external source tables.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/cdc/poll":{"post":{"operationId":"pollExternalSourceCdcMirror","summary":"Run a preview/dev-test CDC mirrored-subset catch-up poll for selected external source tables.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/cdc/restore-checkpoint":{"post":{"operationId":"markExternalSourceCdcRestoreCheckpoint","summary":"Mark a CDC mirror as restore-validation-required. Mirrored reads fail closed until an acknowledged resume records a fresh source-position checkpoint.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/cdc/resume":{"post":{"operationId":"resumeExternalSourceCdcMirror","summary":"Resume a preview/dev-test CDC mirror after failure or restore validation by recording a fresh source-position checkpoint.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/writeback-mappings":{"get":{"operationId":"listExternalWritebackMappings","summary":"List trusted-worker mappings that can apply approved Synapsor proposals back to an external Postgres or MySQL source.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}}]},"post":{"operationId":"createExternalWritebackMapping","summary":"Create an allowlisted external writeback mapping for approved proposal worker application.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/writeback-runner-tokens":{"get":{"operationId":"listExternalWritebackRunnerTokens","summary":"List source-scoped trusted-runner tokens. Plaintext token values are never returned after creation.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}}]},"post":{"operationId":"createExternalWritebackRunnerToken","summary":"Create a source-scoped trusted-runner token with writeback claim, heartbeat, and result permissions. The plaintext token is shown once.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-sources/{source_id}/writeback-runners":{"get":{"operationId":"listExternalWritebackRunners","summary":"List registered trusted runners for an external source.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}}]}},"/v1/control/external-sources/{source_id}/writeback-runner-tokens/{token_id}/revoke":{"post":{"operationId":"revokeExternalWritebackRunnerToken","summary":"Revoke a source-scoped trusted-runner token.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"source_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"token_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-writebacks/proposals":{"get":{"operationId":"listExternalWritebackProposals","summary":"List external DB writeback proposals, usually filtered by source_id and approved status for workers.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"}}]},"post":{"operationId":"createExternalWritebackProposal","summary":"Create a Synapsor-tracked proposal for an external DB writeback. This does not mutate the external database.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-writebacks/proposals/{proposal_id}":{"get":{"operationId":"getExternalWritebackProposal","summary":"Inspect one external DB writeback proposal by id.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"proposal_id","in":"path","required":true,"schema":{"type":"string"}}]}},"/v1/control/external-writebacks/proposals/{proposal_id}/{action}":{"post":{"operationId":"transitionExternalWritebackProposal","summary":"Approve or reject an external DB writeback proposal before a trusted worker can apply it.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"proposal_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"action","in":"path","required":true,"schema":{"type":"string","enum":["approve","reject"]}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/external-writebacks/proposals/{proposal_id}/apply-result":{"post":{"operationId":"recordExternalWritebackApplyResult","summary":"Record trusted-worker application status for an approved external DB writeback proposal.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"proposal_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/writeback/runner/doctor":{"get":{"operationId":"doctorWritebackRunner","summary":"Validate a trusted-runner token, source scope, and required writeback permissions.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/runner/register":{"post":{"operationId":"registerRunner","summary":"Register runner metadata for a scoped trusted runner. Database credentials are never sent to Cloud.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/runner/heartbeat":{"post":{"operationId":"heartbeatRunner","summary":"Record runner status, version, engine support, current job, and health metadata for a scoped trusted runner.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/agent/adapters/tools":{"post":{"operationId":"runnerAdapterTools","summary":"List approved Synapsor adapter tools through a source-scoped trusted runner token. The model never receives database credentials or raw SQL.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/agent/adapters/call-tool":{"post":{"operationId":"runnerAdapterToolCall","summary":"Invoke one reviewed adapter tool through Cloud with trusted runner/session scope and no raw SQL exposure.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/writeback/jobs/claim":{"post":{"operationId":"claimWritebackJobs","summary":"Claim approved external DB writeback jobs for a source-scoped trusted runner. Job payloads never include database credentials or arbitrary SQL.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/writeback/jobs/{job_id}/heartbeat":{"post":{"operationId":"heartbeatWritebackJob","summary":"Extend a leased writeback job for the trusted runner that owns the lease.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/writeback/jobs/{job_id}/result":{"post":{"operationId":"recordWritebackJobResult","summary":"Record applied, conflict, or failed result for a leased trusted-runner writeback job.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/usage-events":{"get":{"operationId":"listUsageEvents","summary":"List visible usage events.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"}}]},"post":{"operationId":"recordUsageEvent","summary":"Record a usage event and enforce quotas/spend caps.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/audit-events":{"get":{"operationId":"listAuditEvents","summary":"List visible audit events.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"}}]}},"/v1/control/incidents":{"get":{"operationId":"listIncidents","summary":"List incident records. Admins see redacted operator details; developer sessions see public incident summaries only.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":500},"description":"Maximum items to return. Responses include next_cursor when another page is available."}]},"post":{"operationId":"createIncident","summary":"Create an admin-only incident record with severity, affected components, runbook link, request IDs, and redacted detail.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/incidents/{incident_id}/update":{"post":{"operationId":"updateIncident","summary":"Update an admin-only incident record and append a timeline entry.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"incident_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/alert-delivery-drills":{"get":{"operationId":"listAlertDeliveryDrills","summary":"List admin-only synthetic alert-delivery drill records used as production-readiness evidence.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":500},"description":"Maximum items to return. Responses include next_cursor when another page is available."}]},"post":{"operationId":"recordAlertDeliveryDrill","summary":"Record an admin-only synthetic alert-delivery drill with alarm state, notification, operator receipt, runbook, and cleanup evidence.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/audit-export":{"post":{"operationId":"exportAuditLog","summary":"Create a redacted scoped audit export for operator/customer review.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/data-export-requests":{"post":{"operationId":"requestDataExport","summary":"Record an account, project, or database data-export request for operator-reviewed packaging.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/data-deletion-requests":{"post":{"operationId":"requestDataDeletion","summary":"Record an account, project, or database deletion request with retention-window and backup-caveat metadata. This does not immediately destroy data.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/support-bundles":{"post":{"operationId":"createSupportBundle","summary":"Generate a scoped support bundle with recursive secret redaction and audit metadata.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/retention-metadata":{"get":{"operationId":"getRetentionMetadata","summary":"Return public-safe retention target and subprocessor metadata for the authenticated control-plane context.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/console/sql":{"post":{"operationId":"runConsoleSql","summary":"Run scoped Synapsor SQL through the browser/CLI console API.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/console/invoke":{"post":{"operationId":"invokeConsoleCapability","summary":"Invoke an agent capability through the scoped console API.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/console/evidence":{"post":{"operationId":"getConsoleEvidence","summary":"Inspect an evidence bundle or handle through the scoped console API.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/console/proposals/{action}":{"post":{"operationId":"consoleProposalAction","summary":"Preview, approve, or reject a write proposal through the scoped console API.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"action","in":"path","required":true,"schema":{"type":"string","enum":["preview","approve","reject"]}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/console/replay":{"post":{"operationId":"getConsoleReplay","summary":"Inspect a replayable agent run through the scoped console API.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/backup-jobs":{"get":{"operationId":"listBackupJobs","summary":"List visible backup jobs.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"}}]},"post":{"operationId":"upsertBackupJob","summary":"Create a backup job or update an existing job by job_id.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/backups/request":{"post":{"operationId":"requestManualBackup","summary":"Start an admin-only manual backup worker and record its job status.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/restore-jobs":{"get":{"operationId":"listRestoreJobs","summary":"List visible restore jobs.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"}}]},"post":{"operationId":"upsertRestoreJob","summary":"Create a restore job or update an existing job by job_id.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/restores/verify":{"post":{"operationId":"requestRestoreVerify","summary":"Start an admin-only restore verification worker for an existing backup prefix.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/restores/request":{"post":{"operationId":"requestRestore","summary":"Record an admin-reviewed latest or point-in-time restore request without starting a destructive restore.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/backups":{"get":{"operationId":"getBackupStatus","summary":"Return backup artifact and job status.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/billing/config":{"get":{"operationId":"getBillingConfig","summary":"Return public billing configuration.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/contact":{"post":{"operationId":"createContactMessage","summary":"Validate and forward a public contact form message through the configured contact target.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/demo/customer-service":{"post":{"operationId":"runCustomerServiceDemo","summary":"Run the public live customer-service demo with server-side OpenAI calls and redacted source-code snippets.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/demo/existing-db":{"post":{"operationId":"runExistingDbDemo","summary":"Run the public existing Postgres/MySQL live-read demo with Synapsor evidence, query audit, and proposal/writeback state.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/billing/sessions":{"get":{"operationId":"listBillingSessions","summary":"List visible billing sessions.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"project_id","in":"query","required":false,"schema":{"type":"string"}}]}},"/v1/control/billing/sessions/index/backfill":{"post":{"operationId":"backfillBillingSessionIndex","summary":"Backfill the bounded billing-session listing index.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}]}},"/v1/control/billing/checkout":{"post":{"operationId":"createCheckoutSession","summary":"Create a Stripe Checkout session.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/billing/checkout/refresh":{"post":{"operationId":"refreshCheckoutSession","summary":"Refresh Builder entitlement from a Stripe Checkout session.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/billing/portal":{"post":{"operationId":"createBillingPortalSession","summary":"Create a Stripe billing portal session.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/billing/webhook":{"post":{"operationId":"handleStripeWebhook","summary":"Handle a Stripe webhook.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/email/inbound/resend":{"post":{"operationId":"handleResendInboundEmailWebhook","summary":"Handle a Resend inbound email webhook after raw-body signature verification.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/databases":{"get":{"operationId":"listDatabases","summary":"List visible databases.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":500},"description":"Maximum items to return. Responses include next_cursor when another page is available."},{"name":"cursor","in":"query","required":false,"schema":{"type":"string"},"description":"Opaque cursor returned by a previous list response."}]},"post":{"operationId":"createDatabase","summary":"Create a hosted database resource.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/databases/{database_id}":{"get":{"operationId":"getDatabase","summary":"Get a hosted database resource.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"database_id","in":"path","required":true,"schema":{"type":"string"}}]}},"/v1/control/databases/{database_id}/pause":{"post":{"operationId":"pauseDatabase","summary":"Pause a hosted database.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"database_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/databases/{database_id}/resume":{"post":{"operationId":"resumeDatabase","summary":"Resume a hosted database.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"database_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/databases/{database_id}/runtime-isolation/verify":{"post":{"operationId":"verifyDatabaseRuntimeIsolation","summary":"Admin-only operation that attaches reviewed runtime endpoint, data directory, health, and evidence metadata before an isolated single-node database can count as production-candidate runtime evidence.","x-synapsor-admin-only":true,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"database_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/databases/{database_id}/operation-leases":{"post":{"operationId":"acquireDatabaseOperationLease","summary":"Acquire a short-lived per-database runtime operation lease before proxying SQL, capability, evidence, proposal, or replay work.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"database_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}},"/v1/control/databases/{database_id}/operation-leases/{lease_id}/release":{"post":{"operationId":"releaseDatabaseOperationLease","summary":"Release a per-database runtime operation lease. Release is idempotent.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"database_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"lease_id","in":"path","required":true,"schema":{"type":"string"}}]}},"/v1/control/databases/{database_id}/delete":{"post":{"operationId":"deleteDatabase","summary":"Delete a hosted database.","x-synapsor-admin-only":false,"responses":{"200":{"description":"Structured JSON response.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}},"security":[{"AdminOrSessionBearer":[]},{"AdminBasicAuth":[]}],"parameters":[{"name":"database_id","in":"path","required":true,"schema":{"type":"string"}},{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","maxLength":160},"description":"Optional retry key for lifecycle and other mutating operations. Used when the JSON body does not include idempotency_key, client_request_id, or request_id."}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JsonObject"}}}}}}},"components":{"securitySchemes":{"AdminOrSessionBearer":{"type":"http","scheme":"bearer"},"AdminBasicAuth":{"type":"http","scheme":"basic"}},"schemas":{"JsonObject":{"type":"object","additionalProperties":true,"properties":{"ok":{"type":"boolean"},"error":{"type":"string"},"request_id":{"type":"string"}}},"CreateApiKeyRequest":{"type":"object","additionalProperties":false,"required":["project_id"],"properties":{"project_id":{"type":"string","description":"Project that owns the API key."},"database_id":{"type":"string","description":"Optional hosted database scope. Database-scoped keys are pinned to that runtime branch."},"role":{"type":"string","enum":["admin","developer","readonly"],"default":"developer"},"name":{"type":"string","maxLength":100,"description":"Human-facing key label."},"expires_at":{"type":"integer","format":"unix-time","description":"Unix epoch seconds when the key expires. Required when CONTROL_PLANE_REQUIRE_API_KEY_EXPIRATION=true; must be in the future and within CONTROL_PLANE_API_KEY_MAX_TTL_SECONDS."}}},"RotateApiKeyRequest":{"type":"object","additionalProperties":false,"required":["project_id","key_id"],"properties":{"project_id":{"type":"string","description":"Project that owns the key being rotated."},"key_id":{"type":"string","description":"Existing active API key id to revoke after the replacement is created."},"database_id":{"type":"string","description":"Optional replacement database scope. Defaults to the old key's database scope."},"role":{"type":"string","enum":["admin","developer","readonly"],"description":"Optional replacement role. Defaults to the old key's role."},"name":{"type":"string","maxLength":100,"description":"Optional replacement key label."},"expires_at":{"type":"integer","format":"unix-time","description":"Optional replacement expiration. Defaults to the old key expiration when present."}}},"ErrorResponse":{"type":"object","additionalProperties":true,"required":["ok","error","code","request_id"],"properties":{"ok":{"type":"boolean","const":false},"error":{"type":"string","description":"Stable machine-readable error code."},"code":{"type":"string","description":"Alias of error for SDKs and generic HTTP clients that expect a code field."},"message":{"type":"string","description":"Optional human-facing explanation; clients should branch on error."},"request_id":{"type":"string","description":"Request correlation id also returned in the X-Request-Id header."}}}},"responses":{"BadRequest":{"description":"Malformed JSON, invalid content length, or invalid request fields.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"Unauthorized":{"description":"Missing, invalid, or expired admin/session credentials.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"Forbidden":{"description":"Authenticated caller is not allowed to perform this operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"RateLimited":{"description":"Control-plane rate limit exceeded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}