Skip to main content
GET
/
contract_v2
List contracts
curl --request GET \
  --url https://api.zenskar.com/contract_v2 \
  --header 'organisation: <api-key>' \
  --header 'x-api-key: <api-key>'
{
  "results": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "name": "<string>",
      "status": "draft",
      "currency": "<string>",
      "created_at": "2023-11-07T05:31:56Z",
      "updated_at": "2023-11-07T05:31:56Z",
      "customer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "customer": {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "external_id": "<string>",
        "customer_name": "<string>",
        "custom_data": {},
        "address": {
          "line1": "<string>",
          "line2": "<string>",
          "line3": "<string>",
          "city": "<string>",
          "state": "<string>",
          "zipCode": "<string>",
          "country": "<string>",
          "country_code": "<string>",
          "validation_status": "<string>",
          "connector_validation": {}
        },
        "ship_to_address": {
          "line1": "<string>",
          "line2": "<string>",
          "line3": "<string>",
          "city": "<string>",
          "state": "<string>",
          "zipCode": "<string>",
          "country": "<string>",
          "country_code": "<string>",
          "validation_status": "<string>",
          "connector_validation": {}
        },
        "tax_info": [],
        "email": "<string>",
        "custom_attributes": {},
        "phone_number": "<string>",
        "communications_enabled": true,
        "auto_charge_enabled": true,
        "business_entity_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      },
      "description": "<string>",
      "tags": [
        "<unknown>"
      ],
      "start_date": "2023-11-07T05:31:56Z",
      "end_date": "2023-11-07T05:31:56Z",
      "custom_attributes": {},
      "source": {},
      "anchor_date": "2023-11-07T05:31:56Z",
      "is_last_day_of_month": true,
      "plan_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "renewal_policy": "do_not_renew",
      "phases": [],
      "invoice_payer_customer": {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "external_id": "<string>",
        "customer_name": "<string>",
        "custom_data": {},
        "address": {
          "line1": "<string>",
          "line2": "<string>",
          "line3": "<string>",
          "city": "<string>",
          "state": "<string>",
          "zipCode": "<string>",
          "country": "<string>",
          "country_code": "<string>",
          "validation_status": "<string>",
          "connector_validation": {}
        },
        "ship_to_address": {
          "line1": "<string>",
          "line2": "<string>",
          "line3": "<string>",
          "city": "<string>",
          "state": "<string>",
          "zipCode": "<string>",
          "country": "<string>",
          "country_code": "<string>",
          "validation_status": "<string>",
          "connector_validation": {}
        },
        "tax_info": [],
        "email": "<string>",
        "custom_attributes": {},
        "phone_number": "<string>",
        "communications_enabled": true,
        "auto_charge_enabled": true,
        "business_entity_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      },
      "current_phase": {
        "name": "<string>",
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "start_date": "2023-11-07T05:31:56Z",
        "end_date": "2023-11-07T05:31:56Z",
        "phase_type": "active",
        "phase_metadata": {}
      },
      "contract_link": "<string>",
      "bill_parent_customer": false,
      "invoice_payer_customer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
    }
  ],
  "next": "V2VsbCBhcmV1IGN1cmlvdxM=",
  "previous": "GmBsbCBhcmV1IGN1cmlvdxM=",
  "total_count": 123
}

Documentation Index

Fetch the complete documentation index at: https://docs2.zenskar.com/llms.txt

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

Authorizations

x-api-key
string
header
default:<your-api-key>
required
organisation
string
header
default:<your-organisation-id>
required

Query Parameters

cursor
string | null

The cursor indicating a unique set of results - this should be auto generated and you get it from the next and previous fields of the response

Example:

"V2VsbCBhcmV1IGN1cmlvdxM="

limit
integer | null

The number of results to return - defaults to 10

Example:

10

order
string | null
default:-created_at
Example:

"order=created_at"

id
string<uuid> | null
id__in
string | null
id__isnull
boolean | null
customer_id
string<uuid> | null
customer_id__in
string | null
customer_id__isnull
boolean | null
name
string | null
name__ilike
string | null
name__like
string | null
name__in
string | null
name__isnull
boolean | null
start_date
string<date-time> | null
start_date__neq
string<date-time> | null
start_date__gt
string<date-time> | null
start_date__gte
string<date-time> | null
start_date__lt
string<date-time> | null
start_date__lte
string<date-time> | null
start_date__isnull
boolean | null
start_date__in
string | null
created_at
string<date-time> | null
created_at__neq
string<date-time> | null
created_at__gt
string<date-time> | null
created_at__gte
string<date-time> | null
created_at__lt
string<date-time> | null
created_at__lte
string<date-time> | null
created_at__isnull
boolean | null
created_at__in
string | null
end_date
string<date-time> | null
end_date__neq
string<date-time> | null
end_date__gt
string<date-time> | null
end_date__gte
string<date-time> | null
end_date__lt
string<date-time> | null
end_date__lte
string<date-time> | null
end_date__isnull
boolean | null
end_date__in
string | null
status
enum<string> | null
Available options:
draft,
active,
paused,
expired,
disputed
status__in
string | null
contract_type
enum<string> | null

Classifies how a contract is billed. STANDARD is the default; EVENT_BASED contracts are driven by usage events and require P1D cadence + postpaid.

Available options:
standard,
event_based
contract_type__in
string | null
contract_type__isnull
boolean | null

Response

Contracts retrieved successfully with pagination cursors

results
ContractResponseSchema · object[]
required

The results for the current page

next
string | null

The cursor for the next page of results

Example:

"V2VsbCBhcmV1IGN1cmlvdxM="

previous
string | null

The cursor for the previous page of results

Example:

"GmBsbCBhcmV1IGN1cmlvdxM="

total_count
integer | null

The total count of rows