---
title: "RevokeToken"
method: POST
path: "/oauth2/revoke"
tags: ["OAuth"]
---

# RevokeToken

`POST /oauth2/revoke`

Revokes an access token generated with the OAuth flow.

If an account has more than one OAuth access token for your application, this
endpoint revokes all of them, regardless of which token you specify. When an
OAuth access token is revoked, all of the active subscriptions associated
with that OAuth token are canceled immediately.

__Important:__ The `Authorization` header for this endpoint must have the
following format:

```
Authorization: Client APPLICATION_SECRET
```

Replace `APPLICATION_SECRET` with the application secret on the OAuth
page in the [developer dashboard](https://developer.squareup.com/apps).

## Request body

- RevokeTokenRequest
  - `access_token` string — The access token of the merchant whose token you want to revoke. Do not provide a value for merchant_id if you provide this parameter.
  - `client_id` string — The Square issued ID for your application, available from the [developer dashboard](https://developer.squareup.com/apps).
  - `merchant_id` string — The ID of the merchant whose token you want to revoke. Do not provide a value for access_token if you provide this parameter.
  - `revoke_only_access_token` boolean — If `true`, terminate the given single access token, but do not terminate the entire authorization. Default: `false`

## Response `200`

Success

- RevokeTokenResponse
  - `success` boolean — If the request is successful, this is true.

---

[API](https://skmtc.net/square/apis/squareup.md) · [All operations](https://skmtc.net/square/apis/squareup/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/square/squareup/revisions/8d95e3639487/schema)
