For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
GuidesAPI Reference
GuidesAPI Reference
  • Welcome
    • Getting Started
    • Business Hub
    • Afterpay Migration
  • Platforms
    • Platforms Quickstart
    • Adobe Commerce (Magento)
    • Adyen
    • BigCommerce
    • Ecwid
    • PrestaShop
    • Salesforce Commerce Cloud
    • Shopify
    • Stripe
    • Wix
    • WooCommerce
  • Afterpay Messaging
    • Getting Started
    • Placement
    • Implementation
    • Migration
    • Older Messaging Information and Links
    • Launch Afterpay Info Modal Anywhere
  • API Development
    • API Quickstart
    • Test Environments
    • Certification
    • Disputes
    • Webhook Signature Generation
      • Overview
      • Cash App Pay On File
      • POSTRetrieve Cash App Pay Grant
      • POSTRevoke Cash App Pay Grant
      • POSTEvent: grant.status.updated
  • SDK
    • SDK Migration Guide
    • iOS SDK
    • Android SDK
    • React Native SDK
  • Marketing
    • Shop Directory
    • Brand Assets
LogoLogo
API DevelopmentAdd Cash App Pay to Your Site

Retrieve Cash App Pay Grant

POST
/v2/grants/retrieve
POST
/v2/grants/retrieve
$curl -X POST https://global-api-sandbox.afterpay.com/v2/grants/retrieve \
> -H "User-Agent: User-Agent" \
> -H "Content-Type: application/json" \
> -u "<username>:<password>" \
> -d '{
> "customerId": "CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY",
> "grantId": "GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50"
>}'
1{
2 "grant": {
3 "id": "GRG_221243dc6985a6819ff6950c1a21332f7bc4a46ebd49b5a7002908ab768e8e5ff7831e084d0d2c9d8d939793b55eff50",
4 "intent": "ON_FILE",
5 "type": "CASHAPP",
6 "details": {
7 "status": "ACTIVE",
8 "cashapp": {
9 "customerId": "CST_AQmxh4y_QGoNNIG5NUw0jttqyYedL1LklACQdyJ3H-Vs6WmLtP6A_C7XjQNohvY",
10 "cashtag": "$someCashTag"
11 },
12 "createdAt": "2024-07-08T22:42:46.039Z",
13 "updatedAt": "2024-07-08T22:42:46.039Z",
14 "expiresAt": "2034-07-08T22:42:46.039Z"
15 }
16 }
17}
Retrieves a Cash App Pay customer grant by the ID of the customer that approved it and its own ID.
Was this page helpful?
Previous

Revoke Cash App Pay Grant

Next
Built with

Authentication

AuthorizationBasic

Basic authentication of the form Basic <base64(username:password)>.

Headers

User-AgentstringRequired
AcceptstringOptionalDefaults to application/json
Accept

Request

customerIdstringRequired1-128 characters
ID of the customer that approved the customer grant.
grantIdstringRequired1-256 characters
ID of the customer grant to retrieve.

Response

OK
grantobject
Describes a grant provided by Cash App.

Errors

401
Unauthorized Error
403
Forbidden Error