Skip to main content
GET
/
api
/
admin
/
billing
/
invoices
List all invoices (admin)
curl --request GET \
  --url https://api.example.com/api/admin/billing/invoices \
  --cookie better-auth.session_token=
[
  {
    "id": "<string>",
    "ownerType": "user",
    "ownerId": "<string>",
    "periodYear": 123,
    "periodMonth": 123,
    "periodStart": "<string>",
    "periodEnd": "<string>",
    "currency": "<string>",
    "lineItems": [
      {
        "resourceType": "<string>",
        "resourceId": "<string>",
        "billingType": "hourly",
        "quantity": 123,
        "ratePerUnit": 123,
        "amount": 123,
        "resourceLabel": "<string>"
      }
    ],
    "subtotal": 123,
    "tax": 123,
    "total": 123,
    "status": "draft",
    "createdAt": "<string>",
    "updatedAt": "<string>",
    "issuedAt": "<string>",
    "voidedAt": "<string>",
    "notes": "<string>"
  }
]

Authorizations

better-auth.session_token
string
cookie
required

Query Parameters

ownerId
string
ownerType
Available options:
user
year
number
month
number
status
Available options:
draft

Response

200 - application/json

Default Response

id
string
required
ownerType
required
Available options:
user
ownerId
string
required
periodYear
number
required
periodMonth
number
required
periodStart
string
required
periodEnd
string
required
currency
string
required
lineItems
object[]
required
subtotal
number
required
tax
number
required
total
number
required
status
required
Available options:
draft
createdAt
string
required
updatedAt
string
required
issuedAt
string
voidedAt
string
notes
string