v39

latestOpenAPI 3.0.1raw.githubusercontent.com2025-10-031646108.8 KB
Agreements

Search agreements for recurring payments

You can use this endpoint to search for recurring payments agreements. The agreements are sorted by date, with the most recently-created agreements appearing first.

get/v1/agreements

Query parameters

referencestring

Returns agreements with a reference that exactly matches the value you sent. This parameter is not case sensitive. A reference was associated with the agreement when that agreement was created.

status'created' | 'active' | 'cancelled' | 'inactive'

Returns agreements in a matching status. status reflects where an agreement is in its lifecycle. You can read more about the meanings of the different agreement status values.

pagestring

Returns a specific page of results. Defaults to 1. You can read about search pagination

display_sizestring

The number of agreements returned per results page. Defaults to 500. Maximum value is 500. You can read about search pagination

Response

OK - your request was successful.

countinteger

Number of agreements on the current page of search results.

pageinteger

The page of agreements you’re viewing. To view other pages, make this request again using the page parameter.

totalinteger

Total number of agreements matching your search criteria.

Example response

{
  "_links": {
    "first_page": {
      "href": "https://an.example.link/from/payment/platform",
      "method": "GET"
    },
    "last_page": {
      "href": "https://an.example.link/from/payment/platform",
      "method": "GET"
    },
    "next_page": {
      "href": "https://an.example.link/from/payment/platform",
      "method": "GET"
    },
    "prev_page": {
      "href": "https://an.example.link/from/payment/platform",
      "method": "GET"
    },
    "self": {
      "href": "https://an.example.link/from/payment/platform",
      "method": "GET"
    }
  },
  "count": 20,
  "page": 1,
  "results": [
    {
      "agreement_id": "cgc1ocvh0pt9fqs0ma67r42l58",
      "cancelled_date": "2022-07-08T14:33:00.000Z",
      "created_date": "2022-07-08T14:33:00.000Z",
      "description": "Dorset Council 2022/23 council tax subscription.",
      "payment_instrument": {
        "CardDetails": {
          "billing_address": {
            "city": "address city",
            "country": "GB",
            "line1": "address line 1",
            "line2": "address line 2",
            "postcode": "AB1 2CD"
          }
        },
        "created_date": "2022-07-08T14:33:00.000Z"
      },
      "reference": "CT-22-23-0001",
      "user_identifier": "user-3fb81107-76b7-4910"
    }
  ],
  "total": 100
}
All 16 operations