v1

latestOpenAPI 3.1.02026-07-13143194365.4 KB
onramp

Create an Apple Pay onramp order (v2 Headless API)

Create a Coinbase v2 headless onramp order for Apple Pay.

Returns a payment_link_url to load in an iframe/webview for Apple Pay checkout. The user never leaves the app — they tap the Apple Pay button rendered by the iframe.

Requirements:

  • Account must have a verified email address
  • Account must have a verified phone number (re-verified within the last 60 days)
  • Account must have a Smart Account (earning wallet) on the target network

Flow:

  1. Frontend calls this endpoint with amount and agreement timestamp
  2. Backend validates identity, creates CDP v2 order, returns payment link
  3. Frontend loads payment_link_url in iframe
  4. Frontend listens for postMessage events from iframe
  5. On success, frontend calls POST /v1/onramp/settled with settled amount
  6. Existing SA→tipping transfer flow completes the deposit

See: https://docs.cdp.coinbase.com/onramp/headless-onramp/overview

post/v1/onramp/apple-pay/order

Headers

authorizationstring nullable

Bearer JWT issued by Grove.

Bearer JWT issued by Grove.

Request body

amountstring required

Fiat amount in USD (e.g., '10.00')

agreement_accepted_atstring required

ISO 8601 timestamp when user accepted Coinbase Guest Checkout ToS

networkstring

Target blockchain network (e.g., base, base-sepolia)

tokenstring

Token to purchase (e.g., USDC)

domainstring nullable

Web app domain for iframe Apple Pay button rendering (required for web)

Response

Successful Response

event_idstring required

Onramp event ID for lifecycle tracking

payment_link_urlstring required

URL for Apple Pay iframe/webview

order_idstring required

CDP v2 order ID

order_statusstring required

CDP order status

payment_totalstring nullable

Total fiat amount including fees

purchase_amountstring nullable

Crypto amount to receive