List Payments
GET/paymentsDescription
Retrieve a list of all payments. The payments are returned in descending order by creation date, with the most recent payments appearing first.
Headers
| Header | Description | Required |
|---|---|---|
| Authorization | Bearer token with your API key | yes |
Query Parameters
| Name | Type | Description | Required |
|---|---|---|---|
| limit | number | Maximum number of payments to return (default: 10, max: 100). | no |
| starting_after | string | Cursor for pagination. Returns payments created after this payment ID. | no |
| ending_before | string | Cursor for pagination. Returns payments created before this payment ID. | no |
| status | string | Filter by payment status: authorized, captured, refunded, succeeded, or failed. | no |
| checkout_id | string | Filter payments by checkout ID. | no |
| subscription_id | string | Filter payments by subscription ID. | no |
| payment_mode | string | Filter by payment mode: direct or two_step. | no |
| created_gte | string | Filter payments created on or after this ISO 8601 timestamp. | no |
| created_lte | string | Filter payments created on or before this ISO 8601 timestamp. | no |
Example Request
const response = await fetch('https://checkout.exodus.com/payments?limit=20&status=authorized', {
headers: {
Authorization: 'Bearer sk_live_xxxxxxxxxxxxxxxx',
},
});Response
SUCCESSFUL RESPONSE
{
"object": "list",
"data": [
{
"id": "pay_0987654321fedcba",
"object": "payment",
"amount": 5000,
"currency": "USD",
"status": "authorized",
"payment_mode": "two_step",
"checkout_id": "chk_1234567890abcdef",
"stablecoin": "USDC",
"network": "ethereum",
"customer_email": "[email protected]",
"metadata": {
"order_id": "12345"
},
"created_at": "2024-01-15T12:30:00Z"
},
{
"id": "pay_fedcba0987654321",
"object": "payment",
"amount": 2999,
"currency": "USD",
"status": "captured",
"payment_mode": "two_step",
"subscription_id": "sub_abcdef1234567890",
"stablecoin": "USDT",
"network": "solana",
"customer_email": "[email protected]",
"metadata": {},
"created_at": "2024-01-14T10:00:00Z",
"captured_at": "2024-01-14T12:00:00Z"
}
],
"has_more": true
}Pagination
Use cursor-based pagination to navigate through large result sets:
// Get the next page of results
const nextPage = await fetch(
'https://checkout.exodus.com/payments?limit=20&starting_after=pay_fedcba0987654321',
{
headers: {
Authorization: 'Bearer sk_live_xxxxxxxxxxxxxxxx',
},
}
);