OpenAPI Documentation
OpenAPI Documentation
Get wallet balance
Get the USD balance available to the current caller for Open API purchases.
API information
| Item | Value |
|---|---|
| Method | GET |
| Path | /open-api/v1/wallet/balance |
| Authentication | X-API-Key |
| Processing | Synchronous |
Request parameters
This API accepts no query parameters or request body. Sending any query parameter returns 400009.
Request example
curl --request GET \
--url 'https://api-test.puraroute.com/gin/open-api/v1/wallet/balance' \
--header 'Accept: application/json' \
--header 'X-API-Key: <YOUR_API_KEY>'
Response fields
| Field | Type | Always returned | Description |
|---|---|---|---|
available_balance |
string | Yes | Current available balance as a USD decimal string |
currency |
string | Yes | Always USD |
Successful response example
{
"code": 0,
"msg": "success",
"data": {
"available_balance": "125.5000",
"currency": "USD"
},
"next": null
}
Possible error codes
code |
Description |
|---|---|
400001 |
Authentication failed |
400009 |
The request contains unsupported parameters |
500000 |
System processing failed; the request did not complete |
Do not cache balance responses or write them to public logs or monitoring labels.