Skip to main content
PATCH
/
api
/
admin
/
billing
/
invoices
/
{id}
/
void
Void invoice
curl --request PATCH \
  --url https://api.example.com/api/admin/billing/invoices/{id}/void \
  --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

Path Parameters

id
string
required

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