GET /apiv2/billing/limits
Every limit on your postpaid account — the credit limit set by Netts and your own limits — with how much of each is used and left, and how much each product can still spend. Part of postpaid billing.
Endpoint URL
GET https://netts.io/apiv2/billing/limitsRequest headers
| Header | Required | Description |
|---|---|---|
X-API-KEY | yes | API key with the billing.read permission |
X-Netts-Billing-Format | no | contract-v1 for amounts with their currency; not sent — the original format below |
The request has no parameters.
Example
curl -s 'https://netts.io/apiv2/billing/limits' \
-H 'X-API-KEY: your-api-key'{
"success": true,
"data": {
"limits": [
{
"id": 1,
"scope": "account",
"origin": "netts",
"editable": false,
"canDisable": false,
"period": "outstanding",
"productCode": null,
"apiKeyId": null,
"enabled": true,
"revision": 3,
"limit": { "unit": "USD", "value": "30000.000000" },
"equivalent": { "unit": "TRX", "value": "90677.230000" },
"used": { "unit": "USD", "value": "1250.400000" },
"available": { "unit": "USD", "value": "28749.600000" },
"creditApplied": { "unit": "USD", "value": "0" },
"status": "ok",
"periodStart": null,
"periodEnd": null,
"cappedBy": null
},
{
"id": 5,
"scope": "account",
"origin": "client",
"editable": true,
"canDisable": true,
"period": "day",
"productCode": "energy_5m",
"apiKeyId": null,
"enabled": true,
"revision": 1,
"limit": { "unit": "USD", "value": "200.000000" },
"equivalent": { "unit": "TRX", "value": "604.514867" },
"used": { "unit": "USD", "value": "35.200000" },
"available": { "unit": "USD", "value": "164.800000" },
"creditApplied": null,
"status": "ok",
"periodStart": "2026-10-19T00:00:00+00:00",
"periodEnd": "2026-10-20T00:00:00+00:00",
"cappedBy": null
}
],
"products": {
"energy_1h": { "unit": "USD", "spendable": "28749.600000", "limitingLimitIds": [1], "maxPerOrder": null, "status": "ok" },
"energy_5m": { "unit": "USD", "spendable": "164.800000", "limitingLimitIds": [5], "maxPerOrder": null, "status": "ok" }
},
"unit": "USD",
"asOf": "2026-10-19T20:24:26.525887+00:00",
"checkedApiKeyId": 6,
"valuationStatus": "ok",
"creditUsdc": "0",
"fx": { "usdPerTrx": "0.33084276", "at": "2026-10-19T20:24:23.449930+00:00" },
"fxStatus": "ok"
},
"timestamp": "2026-10-19T20:24:26+00:00"
}A limit
| Field | Description |
|---|---|
id | the limit number — use it to change, switch off or on your own limit |
scope | account — applies to the whole account; key — applies to one API key (apiKeyId) |
origin | netts — set by Netts, read-only; client — your own limit |
editable, canDisable | whether you can change or switch off this limit |
period | outstanding, day, week or order — see what is counted |
productCode | the product the limit applies to, null for an overall limit |
enabled | false — the limit is switched off and does not apply |
revision | the current version; send it as expectedRevision when you change the limit |
limit, equivalent | the limit and, for reference, its value in the other currency at the current rate |
used, available | how much is taken and left; null for a switched-off limit and for order limits |
creditApplied | credit from overpayments counted in an outstanding limit |
maxPerOrder | for an order limit: the largest single order |
periodStart, periodEnd | for day and week: the current UTC period |
cappedBy | your limit is higher than the Netts limit after Netts lowered it: the Netts limit id that applies instead |
status | ok, limit_reached, disabled, other_key (a limit of another of your keys), or unavailable |
Products
products shows, for every product, how much the next order of that product can use: spendable is the smallest amount left among all limits that apply, and limitingLimitIds names the limits that set it. maxPerOrder is the largest single order if an order limit applies.
Key limits are counted for the key that made this request — checkedApiKeyId. If the numbers cannot be calculated right now, valuationStatus is unavailable: the limits are still listed, used, available and spendable are null. They are never shown as zero or unlimited in that case.
Response in contract-v1
With X-Netts-Billing-Format: contract-v1 the limits and products are the same, and every amount is an amount with its currency. This format is enabled per account.
{
"success": true,
"data": {
"limits": [
{
"id": 1,
"scope": "account",
"origin": "netts",
"editable": false,
"canDisable": false,
"period": "outstanding",
"productCode": null,
"apiKeyId": null,
"enabled": true,
"revision": 12,
"limit": { "amount": "0.00020000", "currency": "BTC" },
"equivalent": { "amount": "49.294668", "currency": "TRX" },
"used": { "amount": "0.00002940", "currency": "BTC" },
"available": { "amount": "0.00017060", "currency": "BTC" },
"creditApplied": { "amount": "0", "currency": "BTC" },
"status": "ok",
"periodStart": null,
"periodEnd": null,
"cappedBy": null
},
{
"id": 5,
"scope": "account",
"origin": "client",
"editable": true,
"canDisable": true,
"period": "outstanding",
"productCode": "energy_1h",
"apiKeyId": null,
"enabled": true,
"revision": 1,
"limit": { "amount": "0.00010000", "currency": "BTC" },
"equivalent": { "amount": "24.647334", "currency": "TRX" },
"used": { "amount": "0.00002940", "currency": "BTC" },
"available": { "amount": "0.00007060", "currency": "BTC" },
"creditApplied": { "amount": "0", "currency": "BTC" },
"status": "ok",
"periodStart": null,
"periodEnd": null,
"cappedBy": null
}
],
"products": {
"energy_1h": {
"spendable": { "amount": "0.00007060", "currency": "BTC" },
"maxPerOrder": null,
"limitingLimitIds": [5],
"status": "ok"
}
},
"asOf": "2026-10-23T19:26:56.812402+00:00",
"checkedApiKeyId": 6,
"valuationStatus": "ok",
"credit": { "amount": "0", "currency": "BTC" },
"exchangeRate": {
"base": "TRX",
"quote": "BTC",
"rate": "0.000004057233918579",
"at": "2026-10-23T19:26:50.321789+00:00"
},
"fxStatus": "ok"
},
"timestamp": "2026-10-23T19:26:56+00:00"
}The example uses BTC; your responses show the currency of your contract. It shows one product; the response lists all of them.
A limit of your own keeps the currency it was set in. If the currency of your contract changes, such a limit stays in the list in its old currency and switched off; give it a new value with change a limit — it then takes the currency of the Netts limit — and switch it on.
| Field | Description |
|---|---|
limit, equivalent, used, available, creditApplied | amounts with their currency; equivalent is the limit in the other currency at the current rate, for reference |
products.*.spendable, products.*.maxPerOrder | amounts with their currency. There is no separate unit field |
credit | your credit from overpayments; creditUsdc in the original format |
exchangeRate | the current rate used for equivalent; fx in the original format |
The other fields are as in the original format. The top-level unit of the original format is not sent: each amount names its currency.
Products share the account-level credit: a product limit only narrows what a product can spend, it never adds credit. spendable already applies every relevant limit.
Errors
| HTTP | code | Meaning |
|---|---|---|
| 401 | -1, -2 | the key is missing or invalid, or the IP is not whitelisted — answered by the API gateway, see response format |
| 400 | unsupported_billing_format | unknown X-Netts-Billing-Format value |
| 403 | billing_read_required | the key has no billing.read permission |
| 403 | postpaid_required | the account has no postpaid billing |
| 403 | billing_format_not_enabled | contract-v1 is not enabled for your account yet |
| 406 | billing_format_not_available | the original format was requested, but your contract uses contract-v1 only |
All codes are listed in postpaid billing.