---
title: "Disconnect an account"
method: DELETE
path: "/v1/admin/source-connections/oauth/grants/{id}"
tags: ["Source Plane"]
---

# Disconnect an account

`DELETE /v1/admin/source-connections/oauth/grants/{id}`

## Request

- Base URL: `https://brain.inite.ai`
- URL: `https://brain.inite.ai/v1/admin/source-connections/oauth/grants/{id}`
- Auth: HTTP bearer

Revokes the token at the provider (best effort; `providerRevoked` says whether it accepted) and marks the grant revoked. Connections that run as it fail their next sync by name until reconnected. Connected accounts (docs/source-plane.md § Connected accounts): the brain as an outbound OAuth 2.1 client for the cloud connectors (gdrive, onedrive, dropbox). Answers a bare 404 until `SOURCE_PLANE_ENABLED=1` and `SOURCE_OAUTH_CLIENT=1`; needs `SOURCE_CREDENTIAL_ENCRYPTION_KEY` — tokens are never stored in the clear.

Required scope: `brain:admin`.

## Path parameters

- `id` string, required

## Response `200`

Disconnected.

- RevokeGrantResponse
  - `providerRevoked` boolean, required
  - `revoked` boolean, required

## Other responses

- `400`: Validation failed.
- `401`: Missing or unknown bearer key.
- `403`: The key lacks the required scope.
- `404`: No such resource in this tenant.

---

[API](https://skmtc.dev/inite/apis/inite-brain-platform-api.md) · [All operations](https://skmtc.dev/inite/apis/inite-brain-platform-api/llms.txt) · [OpenAPI document](https://skmtc.dev/inite/apis/inite-brain-platform-api/revisions/c7c3eb5e304b?raw)
