Revoke OAuth Session
Delete a stored OAuth session, disconnecting the MCP entry.
Deleting the row (rather than clearing its tokens) means the next
initiate_oauth call for this deployment/entry starts a fresh PKCE
flow instead of finding stale state. A missing session is treated as
already-revoked and is not an error.
Args: deployment_id: Deployment the entry belongs to. entry_id: Bundle entry (MCP) whose OAuth session to revoke. session: Database session. context: Caller's security context; the caller must own the deployment.
Authorization
OAuth2AuthorizationCodeBearer AuthorizationBearer <token>
In: header
Path Parameters
deployment_id*Deployment Id
Format
uuidentry_id*Entry Id
Format
uuidQuery Parameters
verify_locally?Verify Locally
Default
trueResponse Body
application/json
curl -X DELETE "https://example.com/v1/oauth2/sessions/497f6eca-6276-4993-bfeb-53cbbbba6f08/497f6eca-6276-4993-bfeb-53cbbbba6f08"Empty
{ "detail": [ { "loc": [ "string" ], "msg": "string", "type": "string" } ]}