curl --request GET \
--url https://api.withorb.com/v1/credit_blocks/{block_id}/invoices \
--header 'Authorization: Bearer <token>'{
"block": {
"metadata": {},
"id": "<string>",
"balance": 123,
"effective_date": "2023-11-07T05:31:56Z",
"expiry_date": "2023-11-07T05:31:56Z",
"per_unit_cost_basis": "<string>",
"status": "active",
"maximum_initial_balance": 123,
"filters": [
{
"field": "price_id",
"operator": "includes",
"values": [
"<string>"
]
}
]
},
"invoices": [
{
"id": "<string>",
"invoice_number": "<string>",
"status": "issued",
"customer": {
"id": "<string>",
"external_customer_id": "<string>"
},
"subscription": {
"id": "<string>"
}
}
]
}This endpoint returns the credit block and its associated purchasing invoices.
If a credit block was purchased (as opposed to being manually added), this endpoint returns the invoices that were created to charge the customer for the credit block. For credit blocks with payment schedules spanning multiple periods (e.g., monthly payments over 12 months), multiple invoices will be returned.
For credit blocks created by subscription allocation prices, this endpoint returns the subscription invoice containing the allocation line item that created the block.
If the credit block was not purchased (e.g., manual increment), an empty invoices list is returned.
Note: This endpoint is currently experimental and its interface may change in future releases. Please contact support before building production integrations against this endpoint.
curl --request GET \
--url https://api.withorb.com/v1/credit_blocks/{block_id}/invoices \
--header 'Authorization: Bearer <token>'{
"block": {
"metadata": {},
"id": "<string>",
"balance": 123,
"effective_date": "2023-11-07T05:31:56Z",
"expiry_date": "2023-11-07T05:31:56Z",
"per_unit_cost_basis": "<string>",
"status": "active",
"maximum_initial_balance": 123,
"filters": [
{
"field": "price_id",
"operator": "includes",
"values": [
"<string>"
]
}
]
},
"invoices": [
{
"id": "<string>",
"invoice_number": "<string>",
"status": "issued",
"customer": {
"id": "<string>",
"external_customer_id": "<string>"
},
"subscription": {
"id": "<string>"
}
}
]
}Documentation Index
Fetch the complete documentation index at: https://docs.withorb.com/llms.txt
Use this file to discover all available pages before exploring further.
API Keys can be issued in the Orb's web application.
Was this page helpful?