> This page is for Cash App Pay Partner API.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://developers.cash.app/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://developers.cash.app/_mcp/server.

# Revoke customer grant

POST https://api.cash.app/network/v1/customers/{customer_id}/grants/{grant_id}/revoke

Revokes a customer grant, rendering it unusable. Other endpoints will no longer be able to use the grant to perform its associated action.

You cannot un-revoke a grant. Use with caution.

**This endpoint is not rate limited.**

Scopes: `GRANTS_WRITE`

Reference: https://developers.cash.app/cash-app-pay-partner-api/api-reference/network-api/revoke-customer-grant

## Servers

- `https://api.cash.app/network/v1` (Production, default)
- `https://sandbox.api.cash.app/network/v1` (Sandbox)

## Request

### Path parameters

- `customer_id` (string, required) — ID of the customer that approved the customer grant.
- `grant_id` (string, required) — ID of the customer grant to retrieve.

## Response

### 200

OK

- `grant` (Grant, required) — Describes a grant that can be used to perform actions specified in a customer request using the Network API.

## Errors

### 400 Revoke Customer Grant Request Bad Request Error

Bad Request

- `errors` (list of Error, required) — A list of errors that occurred while processing the request. Min number of items: `1`

### 404 Revoke Customer Grant Request Not Found Error

Not Found

- `errors` (list of Error, required) — A list of errors that occurred while processing the request. Min number of items: `1`

## Types

### Grant

Describes a grant that can be used to perform actions specified in a customer request using the Network API.

- `id` (string, required) — Unique identifier for this grant issued by Cash App. Min length: `1` Max length: `256`
- `customer_id` (string, required) — ID of the customer that approved this grant. Min length: `1` Max length: `128`
- `request_id` (string, required) — A unique identifier issued by Cash App for the customer request that resulted in the creation of this grant. Min length: `1` Max length: `128`
- `action` (Action, required) — Represents what the client intends to do to a customer if given authorization.
- `status` (enum, required) — Describes whether or not this grant can be used to perform the action associated with it. If `ACTIVE`, it can be used to perform the action. If `EXPIRED`, it may no longer be used to perform the action due to the current time being past the "expires_at" time. If `CONSUMED`, it was already redeemed to perform the action and cannot be used again. If `REVOKED`, the customer or merchant explicitly unauthorized the grant, preventing it from being used to perform the action.
  - Allowed values: `ACTIVE`, `CONSUMED`, `REVOKED`, `EXPIRED`
- `type` (enum, required) — Describes whether this grant can be only be used once (`ONE_TIME`) or repeatedly (`EXTENDED`).
  - Allowed values: `ONE_TIME`, `EXTENDED`
- `channel` (enum, required) — How the customer is expected to interact with the request. - `IN_PERSON`: The customer presents or scans a QR code at a physical location to approve the request. - `ONLINE`: The customer scans a QR code or is redirected to Cash App from a browser context. - `IN_APP`: The customer scans a QR code or is redirected to Cash App from a native mobile application context.
  - Allowed values: `IN_PERSON`, `ONLINE`, `IN_APP`
- `created_at` (datetime, required) — When this grant was created, in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339) format (UTC).
- `updated_at` (datetime, required) — When this grant was last updated, in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339) format (UTC).
- `expires_at` (datetime, optional) — If present, indicates when the grant's status will become `EXPIRED`, preventing a client from using it to create payments or refunds. The timestamp is in the [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339) format (UTC).

### Error

Represents an error encountered during a request to the API.

- `category` (enum, required) — The high-level reason the error occurred.
  - Allowed values: `API_ERROR`, `AUTHENTICATION_ERROR`, `BRAND_ERROR`, `DISPUTE_ERROR`, `MERCHANT_ERROR`, `INVALID_REQUEST_ERROR`, `PAYMENT_PROCESSING_ERROR`, `RATE_LIMIT_ERROR`, `WEBHOOK_ERROR`, `API_KEY_ERROR`, `GRANT_ERROR`
- `code` (string, required) — A unique identifier for the specific type of error that occurred. For more information, see [Error Code Reference](/cash-app-pay-partner-api/guides/technical-guides/api-fundamentals/errors/error-code-reference). Min length: `1`
- `detail` (string, optional) — Human-readable description of why the error occurred and how to resolve it. Min length: `1`
- `field` (string, optional) — The field in the request that caused the error, using array and object dot notation. Min length: `1`

### Action

Represents what the client intends to do to a customer if given authorization.

- `type`: `ONE_TIME_PAYMENT`
  - `scope_id` (string, required) — ID of the client, brand, or merchant that will charge the customer. If a client ID is passed, the grant from this action can be used to create a payment for any merchant owned by the client. If a brand ID is passed, the grant from this action can be used to create a payment for any merchant that has a matching brand ID. If a merchant ID is passed, the grant from this action can be used to create a payment for the merchant with a matching ID. Min length: `1` Max length: `128`
  - `amount` (integer, optional) — Amount to charge the customer, in the lowest unit of the associated currency. Min value: `1`
  - `currency` (enum, optional) — Indicates the country associated with an entity. Values are from the [ISO-4217 Alpha-3](https://www.iso.org/iso-4217-currency-codes.html) specification. Current values: - `USD`: United States Dollar
    - Allowed values: `USD`
- `type`: `ON_FILE_PAYMENT`
  - `scope_id` (string, required) — ID of the client or brand that will charge customers. If a client ID is passed, the grant from this action can be used to create a payment for any merchant owned by the client. If a brand ID is passed, the grant from this action can be used to create a payment for any merchant that has a matching brand ID. Merchant IDs may *not* be passed. Min length: `1` Max length: `128`
  - `account_reference_id` (string, optional) — Identifier of the account or customer associated to the on file action.
- `type`: `ON_FILE_DEPOSIT`
  - `account_reference_id` (string, required) — Identifier of the account or customer associated to the on file action.
  - `scope_id` (string, required) — ID of the client or brand that indicates the set of merchants that will deposit to customers. If a client ID is passed, the grant from this action can be used to create a deposit for any merchant owned by the client. If a brand ID is passed, the grant from this action can be used to create a deposit for any merchant that has a matching brand ID. Min length: `1` Max length: `128`
- `type`: `LINK_ACCOUNT`

## Examples

**Response**

```json
{
  "grant": {
    "id": "GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50",
    "customer_id": "CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY",
    "request_id": "GRR_1hrxhz136krcq6ezdte2ha5q",
    "action": {
      "type": "ONE_TIME_PAYMENT",
      "scope_id": "MMI_4vxs5egfk7hmta3qx2h6rp91x",
      "amount": 2500,
      "currency": "USD"
    },
    "status": "ACTIVE",
    "type": "ONE_TIME",
    "channel": "ONLINE",
    "created_at": "2019-08-24T14:15:22Z",
    "updated_at": "2019-08-24T14:15:22Z",
    "expires_at": "2022-04-01T12:00:00Z"
  }
}
```

**SDK Code**

```python
import requests

url = "https://api.cash.app/network/v1/customers/CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY/grants/GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50/revoke"

response = requests.post(url)

print(response.json())
```

```javascript
const url = 'https://api.cash.app/network/v1/customers/CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY/grants/GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50/revoke';
const options = {method: 'POST'};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.cash.app/network/v1/customers/CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY/grants/GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50/revoke"

	req, _ := http.NewRequest("POST", url, nil)

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.cash.app/network/v1/customers/CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY/grants/GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50/revoke")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.cash.app/network/v1/customers/CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY/grants/GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50/revoke")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.cash.app/network/v1/customers/CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY/grants/GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50/revoke');

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.cash.app/network/v1/customers/CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY/grants/GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50/revoke");
var request = new RestRequest(Method.POST);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "https://api.cash.app/network/v1/customers/CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY/grants/GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50/revoke")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```