List subscriptions¶
Warning
The v1 API has been deprecated. The v1 API will be supported for the foreseeable future, at least until July 2023. However, new features will only be added to the v2 API.
The documentation for listing subscriptions in the new v2 API can be found here. For more information on the v2 API, refer to our v2 migration guide.
GET
https://api.mollie.com/v1/customers/*customerId*/subscriptions
Retrieve all subscriptions of a customer.
Parameters¶
Replace customerId
in the endpoint URL by the customer’s ID, for example cst_8wmqcHMN4U
.
offset
integeroptionalcount
integeroptionalAccess token parameters¶
If you are using organization access tokens or are creating an
OAuth app, the only mandatory extra query string parameter is the profileId
parameter.
With it, you can specify for which profile you want to retrieve subscriptions. Organizations can have multiple profiles
for each of their websites. See Profiles API for more information.
pfl_3RkSN1zuPE
.true
to retrieve test mode subscriptions.Response¶
200
application/json
totalCount
integeroffset
integercount
integerdata
, which is either the requested number (with a maximum of 250) or the
default number.data
arraylinks
objectLinks to help navigate through the lists of subscriptions, based on the given offset.
previous
stringnext
stringfirst
stringlast
stringExample¶
Request¶
1 2 | curl -X GET https://api.mollie.com/v1/customers/cst_8wmqcHMN4U/subscriptions \ -H "Authorization: Bearer test_dHar4XY7LxsDOtmnkVtjNVWXLSlXsM" |
Response¶
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | HTTP/1.1 200 OK Content-Type: application/json { "totalCount": 3, "offset": 0, "count": 3, "data": [ { "resource": "subscription", "id": "sub_rVKGtNd6s3", "customerId": "cst_8wmqcHMN4U", "mode": "live", "createdDatetime": "2016-06-01T12:23:34.0Z", "status": "active", "amount": "25.00", "times": 4, "interval": "3 months", "description": "Quarterly payment", "method": null, "cancelledDatetime": null, "links": { "webhookUrl": "https://webshop.example.org/payments/webhook" } } { }, { } ] } |