Revoke a connected app
cooper_revoke_oauth_grantUse this when an OAuth app should lose access to this account. Requires auth. Destructive. Inputs: client_id (required; the OAuth client id from cooper_list_oauth_grants). Deletes every access and refresh token for that client on this account, and every unused authorization code for that client, in one transaction. The client registration stays, so the app can connect again. Returns {object:"oauth_grant", id, revoked:true, tokens_revoked}. tokens_revoked is how many token rows were removed. Those access tokens then return 401, and their refresh tokens fail at /oauth/token. Other apps and API keys keep working. An unknown client, or a client that belongs to another account, returns 404 oauth_grant_not_found. An inbox-scoped key receives 403 permission_denied. A key without key_write receives 403 permission_denied.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| client_id | Yes | OAuth client id from cooper_list_oauth_grants. This is the grant id. |