Getting Started
Make your first authenticated request to the Cadence API.
Getting Started
This guide walks you through your first API call.
1. Get your API credentials
Sign in to your dashboard and open Settings → API. You'll find your API Key and API Secret there. Treat the secret like a password — never expose it in client-side code.
2. Make a request
Every request is authenticated with two headers: X-Api-Key and X-Api-Secret.
Here's a request that lists your active plans:
curl -X GET \
"https://api.cadence.dev/plans/list?page=1&pageSize=10" \
-H "X-Api-Key: {your-api-key}" \
-H "X-Api-Secret: {your-api-secret}"A successful response uses the standard envelope:
{
"status": "success",
"data": [],
"total": 0,
"page": 1,
"pageSize": 10,
"totalPages": 0
}3. Build a checkout flow
The typical integration path:
- List plans and let the customer pick one.
- Initialize a checkout with the customer's details.
- Render the returned
checkoutFormContent, or redirect topaymentPageUrl. - Handle the callback and confirm the subscription.
- Subscribe to webhooks to track lifecycle events.
Response envelope
All endpoints return a top-level status of either "success" or "failure".
On failure, an error message (and where relevant an error code) is included.