Documentation Index
Fetch the complete documentation index at: https://docs.chipipay.com/llms.txt
Use this file to discover all available pages before exploring further.
Gift Cards are live. You pre-fund Chipi credits in USDC, mint a redeemable
code, share it however you want, and the recipient claims into a Starknet or Solana wallet. Cross-chain delivery uses Circle’s CCTP bridge under the hood.At a glance
Funded from credits
USDC held on Chipi’s Starknet treasury; created code is a claim on that hold
Two destination chains
Recipient picks Starknet or Solana at redeem time
Per-code limits
maxRedeems (total) + maxRedeemsPerUser5 gift types
PROMOTIONAL, GIFT_CARD, REFERRAL, LOYALTY, COMPENSATION
How it works
- You create a gift code via
POST /v1/giftswith an amount, expiry, and per-user/total redeem caps. Chipi holds the total potential payout (amount × maxRedeems) from your credits balance on creation, so no over-spend. - You share the code any way you like — email, link in your app, QR. The
codeis the redeem key. - A recipient redeems via
POST /v1/gifts/claim/:code/redeemwith their wallet address and target chain. Starknet recipients receive instantly; Solana recipients go through CCTP burn → Circle attestation → mint on Solana (status transitions visible via the redeem polling endpoint).
Endpoints
All under/v1/gifts/* on https://api.chipipay.com. Org-facing endpoints (create, list, stats) use ApiKeyGuard (sk_ in Authorization OR pk_ in x-api-key); claim/status endpoints are public.
| Method + path | Auth | Purpose |
|---|---|---|
POST /v1/gifts | ApiKeyGuard | Create a gift code |
POST /v1/gifts/bulk | ApiKeyGuard | Create N codes in one call |
GET /v1/gifts | ApiKeyGuard | List your org’s codes |
GET /v1/gifts/:id | ApiKeyGuard | Single code detail |
GET /v1/gifts/usage | ApiKeyGuard | Aggregate redeem stats for your org |
GET /v1/gifts/history/redeems | ApiKeyGuard | List redeems against your codes |
GET /v1/gifts/history/redeems/:id | ApiKeyGuard | Single redeem detail |
GET /v1/gifts/claim/:code | Public | Recipient previews the code (amount, expiry, etc.) |
POST /v1/gifts/claim/:code/redeem | Public | Recipient claims into their wallet |
GET /v1/gifts/claim/:code/status/:redeemId | Public | Recipient polls redeem status |
GET /v1/gifts/redeems/:id/status | ApiKeyGuard | Org-side polling on a specific redeem |
Cross-chain delivery
| Recipient picks | Path | Typical latency |
|---|---|---|
chain: "starknet" | Direct transfer from Chipi’s Starknet treasury | Seconds (one Starknet tx) |
chain: "solana" | CCTP burn on Starknet → Circle attestation → mint on Solana | 60–120 seconds (Circle attestation gates it) |
GiftRedeemStatus: PENDING → BRIDGING (CCTP burn submitted) → ATTESTED (attestation received from Circle) → SUCCESS (USDC minted on Solana). Recipients poll the public status endpoint.
If anything fails between BRIDGING and SUCCESS, the redeem moves to FAILED and the hold against your credits is released. You’re not charged for failed redeems.
Gift types
Thetype field on every gift is one of:
PROMOTIONAL— marketing campaigns, sign-up bonusesGIFT_CARD— explicit gift product (e.g. a $25 USDC card)REFERRAL— referral rewardsLOYALTY— repeat-customer rewardsCOMPENSATION— refunds or make-goods
Where to go next
- Quickstart — first
POST /v1/giftscall to create a code, then claim it. - Endpoints — full request/response shapes per route.
- Cross-chain — CCTP wire details, Solana recipient flow.
- Dashboard — org-side admin: bulk create, view stats, retire codes.
