Base URL
The same base URL is used for both development and production. Your API key prefix determines the environment:
lk_dev_keys operate in sandbox mode (test data, no real charges)lk_live_keys operate in production mode (real transactions)
Authentication
All endpoints require authentication via theApi-Key header:
Request Format
- All request bodies must be JSON-encoded
- Include
Content-Type: application/jsonheader for POST/PATCH requests
Response Format
All responses are JSON-encoded with the following structure: Success:HTTP Status Codes
| Code | Description |
|---|---|
200 | Success |
201 | Created |
400 | Bad Request - Invalid parameters |
401 | Unauthorized - Invalid or missing API key |
403 | Forbidden - Access denied |
404 | Not Found - Resource doesn’t exist |
429 | Too Many Requests - Rate limited |
500 | Server Error |
Pagination
List endpoints support cursor-based pagination:| Parameter | Type | Default | Description |
|---|---|---|---|
limit | number | 20 | Items per page (max 100) |
cursor | string | - | Cursor from previous response |
Idempotency
For POST requests, you can include anIdempotency-Key header to safely retry requests: