Available
ApiKeys
post
/v1/api-keysCreate an API key (ADMIN/OWNER only; production keys require ADMIN+ approval)
curl -X POST https://api.tbbnetwork.com/v1/api-keys \
-H "Authorization: Bearer <session access token>" \
-H "Idempotency-Key: 5f2f...b91" \
-H "Content-Type: application/json" \
-d '{
"environment": "SANDBOX",
"scopes": [
"value"
]
}'Parameters
Request body
| Field | Type | Required |
|---|---|---|
| environment | SANDBOX | PRODUCTION | yes |
| scopes | string[] | yes |
Response (201)
| Field | Type | Required |
|---|---|---|
| id | string (uuid) | — |
| merchantId | string (uuid) | — |
| keyPrefix | string | — |
| scopes | string[] | — |
| environment | SANDBOX | PRODUCTION | — |
| status | ACTIVE | ROTATED | REVOKED | — |
| createdAt | string (date-time) | — |
| expiresAt | string,null (date-time) | — |
| fullKey | string | — |
Example 201 response
{
"id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
"merchantId": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
"keyPrefix": "keyPrefix",
"scopes": [
"value"
],
"environment": "SANDBOX",
"status": "ACTIVE",
"createdAt": "2026-07-01T12:00:00Z",
"expiresAt": "2026-07-01T12:00:00Z",
"fullKey": "fullKey"
}get
/v1/api-keysList API keys (never returns the full key, only the prefix)
curl -X GET https://api.tbbnetwork.com/v1/api-keys \
-H "Authorization: Bearer <session access token>" \Parameters
Response (200)
| Field | Type | Required |
|---|---|---|
| data | object[] | — |
| nextCursor | stringnull | — |
Example 200 response
{
"data": [
{
"id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
"merchantId": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
"keyPrefix": "keyPrefix",
"scopes": [],
"environment": "SANDBOX",
"status": "ACTIVE",
"createdAt": "2026-07-01T12:00:00Z",
"expiresAt": "2026-07-01T12:00:00Z"
}
],
"nextCursor": null
}post
/v1/api-keys/{id}/rotateRotate a key (old key marked ROTATED, still valid for a grace window)
curl -X POST https://api.tbbnetwork.com/v1/api-keys/{id}/rotate \
-H "Authorization: Bearer <session access token>" \
-H "Idempotency-Key: 5f2f...b91" \Parameters
| id | path | required |
Response (200)
| Field | Type | Required |
|---|---|---|
| id | string (uuid) | — |
| merchantId | string (uuid) | — |
| keyPrefix | string | — |
| scopes | string[] | — |
| environment | SANDBOX | PRODUCTION | — |
| status | ACTIVE | ROTATED | REVOKED | — |
| createdAt | string (date-time) | — |
| expiresAt | string,null (date-time) | — |
| fullKey | string | — |
Example 200 response
{
"id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
"merchantId": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
"keyPrefix": "keyPrefix",
"scopes": [
"value"
],
"environment": "SANDBOX",
"status": "ACTIVE",
"createdAt": "2026-07-01T12:00:00Z",
"expiresAt": "2026-07-01T12:00:00Z",
"fullKey": "fullKey"
}delete
/v1/api-keys/{id}Revoke a key immediately
curl -X DELETE https://api.tbbnetwork.com/v1/api-keys/{id} \
-H "Authorization: Bearer <session access token>" \
-H "Idempotency-Key: 5f2f...b91" \Parameters
| id | path | required |
