Skip to main content
POST
/
invoices
/
search
Search invoices
curl --request POST \
  --url https://api.salesbricks.com/api/v2/invoices/search \
  --header 'Content-Type: application/json' \
  --header 'X-SALESBRICKS-KEY: <api-key>' \
  --data '
{
  "invoice_numbers": [
    "<string>"
  ],
  "invoice_ids": [
    "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  ],
  "customer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
'
{
  "count": 123,
  "results": [
    {
      "invoice_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "subscription_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "customer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "invoice_number": "<string>",
      "due_at": "2023-11-07T05:31:56Z",
      "bill_at": "2023-11-07T05:31:56Z",
      "issued_at": "2023-11-07T05:31:56Z",
      "status": "<string>",
      "fully_paid_at": "2023-11-07T05:31:56Z",
      "grand_total": 123,
      "remaining_amount": 123,
      "currency": "<string>",
      "is_renewal_estimate": true,
      "time_zone": "<string>",
      "payments": [
        {
          "payment_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "invoice_number": "<string>",
          "paid_amount": 123,
          "paid_at": "2023-11-07T05:31:56Z",
          "currency": "<string>",
          "error": "<string>"
        }
      ],
      "attachments": [
        "<unknown>"
      ],
      "line_items": [
        {
          "brick_name": "<string>",
          "brick_id": "<string>",
          "quantity": 123,
          "tax": 123,
          "grand_total": 123
        }
      ]
    }
  ],
  "next": "http://api.example.org/accounts/?offset=400&limit=100",
  "previous": "http://api.example.org/accounts/?offset=200&limit=100"
}

Documentation Index

Fetch the complete documentation index at: https://docs.salesbricks.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

X-SALESBRICKS-KEY
string
header
required

API key for authentication

Query Parameters

limit
integer

Number of results to return per page.

offset
integer

The initial index from which to return the results.

Body

invoice_numbers
string[]

List of invoice numbers to search for (e.g. '6c12021a-4')

invoice_ids
string<uuid>[]

List of invoice UUIDs to search for

customer_id
string<uuid>

Filter invoices by customer ID

Response

count
integer
required
Example:

123

results
object[]
required
next
string<uri> | null
Example:

"http://api.example.org/accounts/?offset=400&limit=100"

previous
string<uri> | null
Example:

"http://api.example.org/accounts/?offset=200&limit=100"