Wallet
GET/v1/wallet
API key requiredSuccess 200
Parameters
| Name | Type | Description |
|---|---|---|
X-Project-IDheader | string | The project to act on; the default project when omitted; nullable |
Response 200 application/json
| Name | Type | Description |
|---|---|---|
balance_centsrequired | integer | |
held_centsrequired | integer | Reserved for videos in production; released or charged when each one ends |
available_centsrequired | integer | |
low_balance_centsrequired | integer | nullable |
currencyrequired | string | Always HKD: every amount is in Hong Kong dollar cents |
organization_idrequired | string | |
mock_left_cents | integer | Demo payments only: how much more demo credit this organization can top up in total; absent when payments are real; nullable |
Example
curl "https://axiomlab.online/v1/wallet" \ -H "Authorization: Bearer $AZIMO_API_KEY"
Wallet Entries
GET/v1/wallet/entries
API key requiredSuccess 200
Parameters
| Name | Type | Description |
|---|---|---|
afterquery | string | length ≤ 64; nullable |
limitquery | integer | Default 50; range 1–200 |
X-Project-IDheader | string | The project to act on; the default project when omitted; nullable |
Response 200 application/json
| Name | Type | Description |
|---|---|---|
datarequired | array<object> | |
data[].idrequired | string | |
data[].organization_idrequired | string | |
data[].kindrequired | string | |
data[].amount_centsrequired | integer | |
data[].hold_centsrequired | integer | |
data[].job_idrequired | string | nullable |
data[].noterequired | string | nullable |
data[].actorrequired | string | nullable |
data[].created_atrequired | number | |
data[].currencyrequired | string | Unit of amount_cents and hold_cents: HKD, or USD for entries written before the wallet switched to HKD (the switch itself is an adjust entry whose note states the conversion rate) |
next_cursor | string | Opaque; pass as cursor (or the after alias) for the next page; nullable |
has_more | boolean | Default false |
Example
curl "https://axiomlab.online/v1/wallet/entries" \ -H "Authorization: Bearer $AZIMO_API_KEY"
Checkout
POST/v1/wallet/checkout
API key requiredSuccess 201
Parameters
| Name | Type | Description |
|---|---|---|
Idempotency-Keyrequiredheader | string | A unique value you generate and keep; reuse it when retrying so the request never runs twice; length 1–128 |
X-Project-IDheader | string | The project to act on; the default project when omitted; nullable |
Request body application/json
| Name | Type | Description |
|---|---|---|
amount_centsrequired | integer | HKD cents, HK$20–HK$100,000; range 2000–10000000 |
Response 201 application/json
| Name | Type | Description |
|---|---|---|
idrequired | string | |
urlrequired | string | |
amount_centsrequired | integer | HKD cents credited to the wallet once paid |
currency | string | Default HKD |
charge_currency | string | Currency Stripe charges: HKD, the wallet's own currency; Default HKD |
charge_amount | integer | Amount Stripe charges, in charge_currency cents (equal to amount_cents); Default 0 |
Example
curl -X POST "https://axiomlab.online/v1/wallet/checkout" \
-H "Authorization: Bearer $AZIMO_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{"amount_cents": 2000}'Usage
GET/v1/usage
API key requiredSuccess 200
The amount billed to this project's wallet in [from, to) (default: the last 30 days) and its paid calls and job counts,
grouped on request. group_by=job pages by job id with after.
Parameters
| Name | Type | Description |
|---|---|---|
fromquery | number | range ≥ 0; nullable |
toquery | number | range ≥ 0; nullable |
group_byquery | string | Default none |
limitquery | integer | Default 50; range 1–200 |
afterquery | string | length ≤ 32; nullable |
X-Project-IDheader | string | The project to act on; the default project when omitted; nullable |
Response 200 application/json
| Name | Type | Description |
|---|---|---|
project_idrequired | string | |
rangerequired | map<string, number> | |
jobsrequired | map<string, integer> | |
billed_centsrequired | integer | Amount charged to the wallet in the range, in cents of currency |
currencyrequired | string | Always HKD |
group_byrequired | string | |
groupsrequired | array<object> | nullable |
next_cursorrequired | string | nullable |
Example
curl "https://axiomlab.online/v1/usage" \ -H "Authorization: Bearer $AZIMO_API_KEY"