Skip to main content

Get Payment Terms

Retrieves a paginated list of payment terms, such as "Net 30" or "Due on fulfillment". Payment terms can be assigned to companies and orders.

HTTP Request​

  • URL: /paymentTerms
  • Method: GET
  • Headers:
    • accessToken: Required. Your API access token.
  • Required scope: READ_ORDER

Query Parameters​

ParameterTypeDescription
pageNumberPage number to retrieve. Default is 1.
limitNumberNumber of payment terms per page. Default is 10.
statusBooleanUse true for active payment terms or false for inactive ones.
idsStringComma-separated list of payment term IDs.

cURL Example​

curl --location '<BASE_URL>/paymentTerms?page=1&limit=20&status=true' \
--header 'accessToken: <ACCESS_TOKEN>'

Response​

  • 200 OK: The list of payment terms was returned successfully.
  • 400 Bad Request: The access token is missing or invalid, the token does not have the required scope, or a query parameter is not valid.

Sample JSON Response​

{
"success": true,
"data": [
{
"id": "67a1ed576ec18627bb245946",
"name": "Due on fulfillment",
"status": true,
"dueType": "fulfillment",
"paymentDueDays": 0,
"createdAt": "2025-02-04T10:35:03.014Z",
"updatedAt": "2025-02-04T10:40:21.065Z"
},
{
"id": "67a1eeba9269290064a159a4",
"name": "Net 30",
"status": true,
"dueType": "net",
"paymentDueDays": 30,
"createdAt": "2025-02-04T10:40:58.825Z",
"updatedAt": "2025-02-04T10:40:58.825Z"
}
],
"pagination": {
"page": 1,
"total": 2,
"count": 2
}
}

Response Details​

FieldTypeDescription
successBooleanWhether the request was successful.
dataArrayList of payment terms. See below.
paginationObjectPagination details. See below.

Payment Term Data​

FieldTypeDescription
idStringUnique identifier of the payment term.
nameStringName of the payment term.
statusBooleanWhether the payment term is active.
dueTypeStringnet (due a number of days later) or fulfillment (due when the order is fulfilled).
paymentDueDaysNumberNumber of days until payment is due.
createdAtStringDate and time the payment term was created (ISO 8601).
updatedAtStringDate and time the payment term was last updated (ISO 8601).

Pagination Details​

FieldTypeDescription
pageNumberCurrent page number.
totalNumberTotal number of payment terms that match.
countNumberNumber of payment terms returned on this page.