GET /openapi/memorylake/admin/v1/billing/orders/{order_id}
Permission required:
order:readPath Parameters
string
required
Order number (
order_id)curl -X GET 'https://app.memorylake.ai/openapi/memorylake/admin/v1/billing/orders/2ea2c7c1d2145b58dc6229dde0cca855' \
-H 'Authorization: Bearer sk_xxxxxx'
Response
object
Show Billing Order object
Show Billing Order object
object
integer
Unix seconds
string
The invoice (GET /billing/invoices/{invoice_id}); null when none was issued
string
Order number (the trade number shown on receipts)
string
The payment provider’s receipt page; null when none
string
Payment state; closed = abandoned before payment. One of:
pending, succeeded, failed, closed, refunded, disputed.integer
Tokens the order adds to the balance once paid (0 for subscription payments — their tokens arrive as a subscription grant)
string
onetime = a credit purchase; auto_topup = an automatic top-up charge; subscription = a subscription payment
object
integer
Unix seconds
{
"success": true,
"message": "Operation completed successfully",
"data": {
"amount": {
"amount": 1999,
"currency": "usd"
},
"created_at": 1760000000,
"invoice_id": "8ed8f98873f8216d20a57a529c68b80f",
"order_id": "15180b2f335b821ab2d276984445fd81",
"receipt_url": "https://example.com/receipt",
"status": "pending",
"tokens_granted": 1200000,
"type": "onetime",
"refunded_amount": {
"amount": 1999,
"currency": "usd"
},
"refunded_at": 1760000000
}
}
Errors
Errors answer withsuccess: false, a message and an error_code. See Error Codes for every code.
| Status | Meaning |
|---|---|
401 | The API key is missing, invalid, disabled or expired |
403 | The key is not allowed to do this |
404 | The resource does not exist |
422 | The body or a parameter failed validation |
429 | Too many requests. Wait for the time in Retry-After |
500 | Server-side error |