All API requests must be sent to the following base URL:
https://api.flow-payments.com/api
https://api-staging.flow-payments.com/api
The Flow Payments API uses JSON format for all requests and responses.
All requests must include the following headers:
Content-Type: application/json
Accept: application/json
Authorization: Bearer {your_api_token}
The API implements rate limiting to ensure service stability. Limits are applied per API token.
!NOTE If you exceed the rate limit, you will receive an HTTP
429 Too Many Requestsresponse. Please reduce the frequency of your requests.
The API uses standard HTTP status codes to indicate the success or failure of a request.
| Code | Description |
|---|---|
200 | Success - The request was processed successfully |
201 | Created - The resource was created successfully |
400 | Bad Request - Missing or invalid parameters |
401 | Unauthorized - Missing or invalid API token |
403 | Forbidden - Access denied to the resource |
404 | Not Found - The requested resource does not exist |
422 | Unprocessable Entity - Validation errors |
429 | Too Many Requests - Rate limit exceeded |
500 | Server Error - An error occurred on the server side |
Error responses include a descriptive message:
{
"message": "The given data was invalid.",
"errors": {
"amount": [
"The amount must be at least 5."
]
}
}
Here's a simple example to retrieve the list of available cryptocurrencies:
curl -X GET https://api.flow-payments.com/api/assets \
-H "Authorization: Bearer your_api_token" \
-H "Accept: application/json"
{
"data": [
{
"id": 1,
"name": "Bitcoin",
"symbol": "BTC",
"chain": "bitcoin",
"type": "native",
"decimals": 8,
"usd_rate": "45000.00",
"network_fee": "0.0001"
},
{
"id": 2,
"name": "Ethereum",
"symbol": "ETH",
"chain": "ethereum",
"type": "native",
"decimals": 18,
"usd_rate": "3000.00",
"network_fee": "0.001"
}
]
}
Endpoints that return lists of resources are paginated. You can control pagination with the following parameters:
| Parameter | Description | Default |
|---|---|---|
page | Page number | 1 |
perPage | Number of items per page | 10 |
{
"data": [...],
"links": {
"first": "https://api.flow-payments.com/api/invoices?page=1",
"last": "https://api.flow-payments.com/api/invoices?page=5",
"prev": null,
"next": "https://api.flow-payments.com/api/invoices?page=2"
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 5,
"per_page": 10,
"to": 10,
"total": 50
}
}