The Search Invoices endpoint allows you to search and retrieve a list of invoices based on various criteria such as invoiced date range, paid date range, status, and associated load numbers. To ensure compatibility and stability, it is essential to include the correct version number in the URL path when making a request. For more information on versioning, refer to the Versioning page.

Request Parameters

The following parameters are required in the URL path:

ParameterTypeRequiredDescription
versionStringYesThe API version to interact with.

Request Body

The following fields are required in the request body:

ParameterTypeRequiredDescription
pageIntegerNoThe page number for pagination.
pageSizeIntegerYesThe number of records per page for pagination.
invoicedDateRangeObjectConditionallyThe range of invoiced dates to filter the results. This field is required if the other conditionally required fields are left empty.
invoicedDateRange.startString (Date-Time)ConditionallyThe start date for the invoiced date range. This field is required if the other conditionally required fields are left empty.
invoicedDateRange.endString (Date-Time)ConditionallyThe end date for the invoiced date range. This field is required if the other conditionally required fields are left empty.
paidDateRangeObjectConditionallyThe range of paid dates to filter the results. This field is required if the other conditionally required fields are left empty.
paidDateRange.startString (Date-Time)ConditionallyThe start date for the paid date range. This field is required if the other conditionally required fields are left empty.
paidDateRange.endString (Date-Time)ConditionallyThe end date for the paid date range. This field is required if the other conditionally required fields are left empty.
statusArray of StringsConditionallyA list of invoice statuses to filter the results. This field is required if the other conditionally required fields are left empty.
loadNumbersArray of StringsConditionallyA list of load numbers associated with the invoices. This field is required if the other conditionally required fields are left empty.
poNumbersArray of StringsConditionallyA list of purchase order numbers associated with the invoices. This field is required if the other conditionally required fields are left empty.
orderNumbersArray of StringsConditionallyA list of order numbers associated with the invoices. This field is required if the other conditionally required fields are left empty.
customerIdStringConditionallyThe customer ID to filter the results. This field is required if the other conditionally required fields are left empty.

Example CURL request

Use the Current API version number and make sure to replace the Authorization header value with your actual Bearer token for the request:

curl --location 'https://integrations.alvys.com/api/p/v1/invoices/search' \
--header 'Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJjaWQiOiJBT...' \
--header 'Content-Type: application/json' \
--data '{
  "page": 0,
  "pageSize": 100,
  "invoicedDateRange": {
     "start": "2023-08-02T09:53:34.251Z",
     "end": "2024-08-02T09:53:34.251Z"
  },
  "paidDateRange": {
     "start": "2023-08-02T09:53:34.251Z",
     "end": "2024-08-02T09:53:34.251Z"
  },
  "status": [
     "Paid"
  ],
  "loadNumbers": [
     "123456789"
  ],
  "customerId": ""
}'

Response Parameters

The following table lists the parameters included in the response for invoice-related requests.

ParameterTypeDescription
pageIntegerThe current page number of the result set.
pageSizeIntegerThe number of records per page.
totalIntegerThe total number of records matching the search criteria.
itemsArray of ObjectsThe list of invoices that match the search criteria.
items.idStringThe unique identifier of the invoice.
items.numberStringThe invoice number.
items.typeStringThe type of the invoice (e.g., Standard, Credit Memo).
items.statusStringThe current status of the invoice (e.g., Open, Paid, Overdue).
items.createdDateString (Date-Time)The date and time when the invoice was created.
items.invoicedDateString (Date-Time)The date and time when the invoice was issued.
items.dueDateString (Date-Time)The due date for the invoice payment.
items.paidDateString (Date-Time)The date when the invoice was fully paid.
items.totalObjectThe total amount of the invoice.
items.total.amountNumberThe monetary value of the total amount.
items.total.currencyStringThe currency in which the invoice is issued.
items.amountPaidObjectThe amount that has been paid towards the invoice.
items.amountPaid.amountNumberThe monetary value of the amount paid.
items.amountPaid.currencyStringThe currency in which the payment was made.
items.remainingBalanceObjectThe remaining balance due on the invoice.
items.remainingBalance.amountNumberThe monetary value of the remaining balance.
items.remainingBalance. currencyStringThe currency in which the balance is due.
items.overPaymentAmountObjectThe overpayment amount if any.
items.overPaymentAmount.amountNumberThe monetary value of the overpayment.
items.overPaymentAmount.currencyStringThe currency in which the overpayment was made.
items.isSubmittedBooleanIndicates if the invoice has been submitted.
items.lastSendDateString (Date-Time)The last date and time when the invoice was sent.
items.supplementalInvoiceTypeStringThe type of supplemental invoice if applicable.
items.vendorObjectVendor details associated with the invoice.
items.vendor.idStringThe unique identifier of the vendor.
items.vendor.nameStringThe name of the vendor.
items.vendor.remitAddressObjectThe remit address of the vendor.
items.vendor.remitAddress.streetStringThe street address of the vendor.
items.vendor.remitAddress.cityStringThe city of the vendor's address.
items.vendor.remitAddress.stateStringThe state of the vendor's address.
items.vendor.remitAddress.zipCodeStringThe zip code of the vendor's address.
items.vendor.remitEmailStringThe email address for remittances to the vendor.
items.vendor. remitPhoneStringThe phone number for remittances to the vendor.
items.customerObjectCustomer details associated with the invoice.
items.customer.idStringThe unique identifier of the customer.
items.customer.nameStringThe name of the customer.
items.customer.emailAddressesArray of StringsThe list of email addresses for the customer.
items.customer.phoneNumbersArray of StringsThe list of phone numbers for the customer.
items.customer.billingAddressObjectThe billing address of the customer.
items.customer.billingAddress.streetStringThe street address of the customer.
items.customer.billingAddress.cityStringThe city of the customer's billing address.
items.customer.billingAddress.stateStringThe state of the customer's billing address.
items.customer.billingAddress.zipCodeStringThe zip code of the customer's billing address.
items.customer.shippingAddressObjectThe shipping address of the customer.
items.customer.shippingAddress.streetStringThe street address of the customer.
items.customer.shippingAddress.cityStringThe city of the customer's shipping address.
items.customer.shippingAddress.stateStringThe state of the customer's shipping address.
items.customer.shippingAddress.zipCodeStringThe zip code of the customer's shipping address.
items.lineItemsArray of ObjectsThe line items included in the invoice.
items.lineItems.idStringThe unique identifier of the line item.
items.lineItems.nameStringThe name of the line item.
items.lineItems.amountObjectThe amount associated with the line item.
items.lineItems.amount.amountNumberThe monetary value of the line item.
items.lineItems.amount.currencyStringThe currency in which the line item is priced.
items.lineItems.rateObjectThe rate details for the line item.
items.lineItems.rate.unitOfMeasurementStringThe unit of measurement for the rate (e.g., hours, miles).
items.lineItems.rate.unitsNumberThe number of units billed.
items.lineItems.rate.rateNumberThe rate per unit.
items.lineItems.loadNumberStringThe load number associated with the line item.
items.lineItems.customerIdStringThe customer ID associated with the line item.
items.lineItems.categoryStringThe category of the line item.
items.loadsArray of ObjectsThe loads associated with the invoice.
items.loads.idStringThe unique identifier of the load.
items.loads.loadNumberStringThe load number associated with the invoice.
items.loads.subsidiaryNameStringThe name of the subsidiary associated with the load.
items.loads.sourceStringThe source of the load.
items.loads.orderNumberStringThe order number associated with the load.
items.loads.poNumberStringThe purchase order number associated with the load.
items.paymentsArray of ObjectsThe payments made against the invoice.
items.payments.idStringThe unique identifier of the payment.
items.payments.paymentDateString (Date-Time)The date and time when the payment was made.
items.payments.amountObjectThe amount paid in the payment.
items.payments.amount.amountNumberThe monetary value of the payment.
items.payments.amount.currencyStringThe currency in which the payment was made.
items.payments.checkNumberStringThe check number associated with the payment.
items.payments.paymentReferenceStringThe payment reference number.

Example Response

On the right side, you can see examples of different error codes by clicking "Example" and selecting the response code.

Rate Limits

This endpoint is subject to standard rate limiting. The default rate limit is 10 requests per minute. For more information, refer to the Rate Limits page.

This page is interactive, allowing you to try a request by specifying the API version in the URL path and providing the necessary request body. As you fill out the parameters, the Curl command on the right side of the page will be automatically updated. Alternatively, you can directly edit the Curl command. Make sure to authorize yourself before trying a request.

Language
Credentials
Header
URL
Click Try It! to start a request and see the response here!