/api/v1/mystery/redemption/quote cards:redeemA pre-checkout shipping quote for redeeming an item physically. Validates the address and returns the cheapest live rate. Supply purchase_id OR token_id. Creates nothing, so it’s safe to call just to show shipping cost before the user commits.
POST /api/v1/mystery/redemption/quote write These inputs are shared across all docs pages — an id entered here carries over.
{
"shipping_address": {
"name": "Demo Buyer",
"street1": "1 Market St",
"city": "San Francisco",
"state": "CA",
"zip": "94105",
"country": "US"
}
}Not run yet — press Run to make a live call against https://service.rip.fun (through this demo's server-side proxy; the API key never reaches the browser).
curl -X POST 'https://service.rip.fun/api/v1/mystery/redemption/quote' \
-H 'X-API-Key: rip_…' \
-H 'Content-Type: application/json' \
-d '{"shipping_address":{"name":"Demo Buyer","street1":"1 Market St","city":"San Francisco","state":"CA","zip":"94105","country":"US"}}' | Field | Type | Required | Description |
|---|---|---|---|
purchase_id | number | — | The fulfilled purchase holding the item (supply this OR token_id) |
token_id | string | — | On-chain token id (supply this OR purchase_id; also disambiguates a multi-item purchase) |
item_type | string | — | "CARD" | "GRADED_CARD" | "PACKET" | "SEALED_PRODUCT" — disambiguates a token number that exists as more than one asset (raw Card #N vs GradedCard slab #N) |
shipping_address.name | string | yes | Recipient full name |
shipping_address.street1 | string | yes | Street line 1 (`street2` optional) |
shipping_address.city | string | yes | City |
shipping_address.state | string | — | State / region |
shipping_address.zip | string | yes | Postal code |
shipping_address.country | string | yes | ISO country code, e.g. `US` (`phone`, `email` optional) |
data)| Field | Description |
|---|---|
shipping_quote.amount_usdc | Quoted shipping cost (USD decimal string) |
shipping_quote.carrier / service / service_token | Cheapest live Shippo rate — provider, service name, and Shippo servicelevel token (the token the warehouse exact-matches when buying the fresh label) |
shipping_quote.estimated_days | Carrier transit estimate |
shipping_quote.rate_id / quoted_at | Shippo rate object id + quote timestamp |
| Status | Code | When |
|---|---|---|
| 400 | purchase_or_token_required | neither purchase_id nor token_id supplied |
| 400 | missing_shipping_address | shipping_address omitted or incomplete |
| 400 | invalid_address | Shippo cannot validate the address |
| 404 | token_not_found | token-first: no rip.fun item for that token |
| 409 | ambiguous_token | the token number is both a raw and a graded card — pass item_type |
| 409 | item_type_mismatch | item_type contradicts what the token actually is |
| 409 | not_fulfilled | purchase has not revealed yet |
See Errors for the response envelope and the full code list.