list-invoices
dci list-invoices [flags]
Returns a list of all the current and historical invoices for your organization.
Invoices are returned in reverse chronological order by default.
Cancelled invoices and credit memos are excluded unless you filter by status:CANCELED.
dci list-invoices presents a curated table by default:
- Columns:
invoice(fromid; a clickable link to the invoice in the DoiT console in interactive terminals),platform,issued(frominvoiceDate),due(fromdueDate; blank when the invoice carries no due date, e.g. credit memos),totalandbalance(with the invoice's currency symbol), andstatus. --output jsonand explicit-C/--fieldsselections return the raw fields documented below.
Examples
# Current and historical invoices, newest first.
dci list-invoices
# Invoices issued on or after 1 August 2026 00:00 UTC (epoch milliseconds).
dci list-invoices --min-creation-time 1785542400000
# Invoices still open, searched client-side across every page.
dci list-invoices --search OPEN
# Every page as JSON, for scripts.
dci list-invoices --all --output json
Flags
| Flag | Type | Default | Example | Description |
|---|---|---|---|---|
--max-results | integer (int64) | 50 | The maximum number of results to return in a single page. Leverage the page tokens to iterate through the entire collection. | |
--page-token | string | Page token, returned by a previous call, to request the next page of results | ||
--filter | string | Supported keys: platform (an invoice platform), dueDate (milliseconds since the POSIX epoch), and status (OPEN, PAST DUE, PAID, or CANCELED). Only one status value is applied per request. Cancelled invoices and credit memos are returned only with status:CANCELED, and every other request excludes them. | ||
--min-creation-time | integer (int64) | Min value for the invoice creation time, in milliseconds since the POSIX epoch. If set, only invoices created after or at this timestamp are returned. | ||
--max-creation-time | integer (int64) | Max value for the invoice creation time, in milliseconds since the POSIX epoch. If set, only invoices created before or at this timestamp are returned. |
Every command also accepts the CLI-wide flags for output shaping — see Output formats and Table output options.
Output
OK - All available invoices returned.
By default dci renders the result as a table. Use --output json to get the full structure described below — see Output formats.
| Field | Type | Description |
|---|---|---|
invoices | array of object | Array of Invoices |
invoices[].id | string | Invoice number, identifying the invoice. |
invoices[].invoiceDate | integer (int64) | The time when this invoice was issued, in milliseconds since the epoch. |
invoices[].platform | string | Platform identifier for invoice source. One of: "google-cloud", "amazon-web-services", "microsoft-azure", "g-suite", "office-365", "superquery", "looker", "navigator", "solve". |
invoices[].dueDate | integer (int64) | The last day to pay the invoice, in milliseconds since the epoch |
invoices[].status | string | Status of the invoice. CANCELED takes precedence over the payment status. One of: "OPEN", "PAST DUE", "PAID", "CANCELED". |
invoices[].totalAmount | number (double) | Total invoiced amount |
invoices[].balanceAmount | number (double) | Invoice balance to be paid |
invoices[].currency | string | Currency code for monetary values. One of: "USD", "ILS", "EUR", "AUD", "CAD", "GBP", "DKK", "NOK", "SEK", "BRL", "SGD", "MXN", …. |
invoices[].url | string | Link to invoice details page in the DoiT console. You can download the PDF invoice from the invoice details page, or programmatically via the getInvoicePdf operation (GET /billing/v1/invoices/\{id\}/pdf). |
pageToken | string | Page token. Can be used to request the next page of results. |
rowCount | integer (int64) | Invoice rows count |
Raw JSON schema
{
"type": "object",
"properties": {
"invoices": {
"type": "array",
"description": "Array of Invoices",
"items": {
"type": "object",
"description": "Summary information about an invoice.",
"properties": {
"id": {
"type": "string",
"description": "Invoice number, identifying the invoice."
},
"invoiceDate": {
"type": "integer",
"description": "The time when this invoice was issued, in milliseconds since the epoch.",
"format": "int64"
},
"platform": {
"type": "string",
"description": "Platform identifier for invoice source.",
"enum": [
"google-cloud",
"amazon-web-services",
"microsoft-azure",
"g-suite",
"office-365",
"superquery",
"looker",
"navigator",
"solve"
]
},
"dueDate": {
"type": "integer",
"description": "The last day to pay the invoice, in milliseconds since the epoch",
"format": "int64"
},
"status": {
"type": "string",
"description": "Status of the invoice. `CANCELED` takes precedence over the payment status.",
"enum": [
"OPEN",
"PAST DUE",
"PAID",
"CANCELED"
]
},
"totalAmount": {
"type": "number",
"description": "Total invoiced amount",
"format": "double"
},
"balanceAmount": {
"type": "number",
"description": "Invoice balance to be paid",
"format": "double"
},
"currency": {
"description": "Currency code for monetary values.",
"type": "string",
"enum": [
"USD",
"ILS",
"EUR",
"AUD",
"CAD",
"GBP",
"DKK",
"NOK",
"SEK",
"BRL",
"SGD",
"MXN",
"CHF",
"MYR",
"TWD",
"EGP",
"ZAR",
"JPY",
"IDR",
"AED",
"THB",
"COP"
]
},
"url": {
"type": "string",
"description": "Link to [invoice details page](https://help.doit.com/docs/billing/invoices-and-payments/managing-invoices) in the DoiT console. You can download the PDF invoice from the invoice details page, or programmatically via the `getInvoicePdf` operation (`GET /billing/v1/invoices/{id}/pdf`)."
}
}
}
},
"pageToken": {
"type": "string",
"description": "Page token. Can be used to request the next page of results."
},
"rowCount": {
"type": "integer",
"description": "Invoice rows count",
"format": "int64"
}
}
}
Errors
On failure, dci prints a single error message — with a hint when one is available — and exits with a typed code your scripts can branch on. See Errors and exit codes for the full contract.
HTTP status to exit code mapping
| HTTP status | Exit code | Error code | Meaning |
|---|---|---|---|
| 400 | 30 | VALIDATION_ERROR | The arguments or request body were rejected. Review the command's flags and payload. |
| 401 | 10 | AUTHENTICATION_FAILED | Not signed in, or the API token is invalid. Run dci login or check DCI_API_KEY. |
| 403 | 11 | PERMISSION_DENIED | The DoiT user or the active customer context does not have access. |
| 404 | 20 | RESOURCE_NOT_FOUND | The requested resource does not exist. Check the identifier argument. |
| 500 | 40 | API_SERVER_ERROR | The API failed to process the request. Retryable; contact DoiT support if it persists. |
Related
- get-invoice — Retrieve an invoice
- get-entity-invoice-explainer — Retrieve an entity invoice explainer
- get-billing-explainer-per-payer — Retrieve a per-payer billing explainer
- API reference: GET /billing/v1/invoices
Aliases: listinvoices