List gift cards
Lists gift cards, newest first. Codes are masked and a full code is never returned.
AuthorizationBearer <token>
Admin API key (server-to-server). Issue via the dashboard at Settings → API keys. Plain-text key is shown once — store in a secret manager. Format: Authorization: Bearer brainerce_xxxxxxxxx.
In: header
Query Parameters
search?string
Matches the last four characters of the code, or part of the recipient email. A full code cannot be searched.
filter?string
Which cards to list. active is active and not expired, withBalance has a balance above zero, expired is past its expiry date, disabled is disabled or revoked. An unknown value lists all.
Default
"all"Value in
"all" | "active" | "withBalance" | "expired" | "disabled"limit?integer
Items per page. Default 20. Maximum 100. Larger values are capped to 100.
Default
20Range
1 <= value <= 100page?integer
1-based page number.
Default
1Range
1 <= valuecurl -X GET "https://api.brainerce.com/api/v1/gift-cards?search=string&filter=all&limit=20&page=1"{
"data": [
{
"id": "clx1a2b3c4d5e6f7g8h9",
"codeLast4": "K7QX",
"maskedCode": "••••-••••-••••-K7QX",
"initialAmount": "200.00",
"balance": "120.00",
"heldAmount": "20.00",
"spendable": "100.00",
"currency": "ILS",
"status": "ACTIVE",
"customerId": "clx1a2b3c4d5e6f7g8h9",
"recipientEmail": "[email protected]",
"expiresAt": "2027-01-15T00:00:00.000Z",
"expiredAt": null,
"createdAt": "2026-09-02T10:30:00.000Z",
"expired": false
}
],
"meta": {
"page": 1,
"limit": 20,
"total": 137,
"totalPages": 7
}
}{
"statusCode": 401,
"code": "UNAUTHORIZED",
"message": "Invalid or expired credential",
"timestamp": "2026-08-23T10:15:00.000Z",
"path": "/api/v1/products/bulk/{jobId}"
}{
"statusCode": 403,
"code": "INSUFFICIENT_SCOPE",
"message": "API key does not have the required scope: products:write",
"timestamp": "2026-08-23T10:15:00.000Z",
"path": "/api/v1/gift-cards"
}{
"statusCode": 429,
"code": "RATE_LIMITED",
"message": "Too many requests",
"details": {
"retryAfterSeconds": 12
},
"timestamp": "2026-08-23T10:15:00.000Z",
"path": "/api/v1/store"
}