Revoke a grant
const url = 'https://api.inboxcnx.com/v1/grants/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0';const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request DELETE \ --url https://api.inboxcnx.com/v1/grants/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0 \ --header 'Authorization: Bearer <token>'Revokes a grant and deletes its stored mail, for an end user who disconnects or leaves. From the response on, no route serves the grant’s mail and no new mail of it is processed; a grant token of it answers 409 grant_revoked. Its stored mail, threads and the grant itself are deleted within 24 hours, with no grace period: export what you need first. With the grant of the last Application on the mailbox, InboxCNX also revokes its access at the provider. Subscribed endpoints receive grant.revoked. A repeated call answers the same; once the grant is deleted it answers 404. To stop processing but keep the stored mail, pause the grant with PATCH /v1/grants/{id} instead.
Requires the write:connections scope.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Responses
Section titled “Responses”The grant is revoked; its stored mail is deleted within 24 hours
object
Example
{ "id": "9b2f0c4e-6a1d-4f3b-8c55-0d7e2a91b3c4", "status": "revoked", "revokedAt": "2026-10-23T08:00:00.000Z"}The credential lacks the write:connections scope
object
object
Example generated
{ "error": { "code": "example", "message": "example" }}No such grant for the caller’s organization and application
object
object
Example generated
{ "error": { "code": "example", "message": "example" }}