List webhook subscriptions BETA
Lists all webhook subscriptions owned by your application.
Name | Description |
---|---|
cursor
|
A pagination cursor returned by a previous call to this endpoint. Provide this to retrieve the next set of results for your original query. For more information, see Pagination. |
include_
|
Includes disabled Subscriptions. By default, all enabled Subscriptions are returned. |
sort_
|
Sorts the returned list by when the Subscription was created with the specified order. This field defaults to ASC. |
limit
|
The maximum number of results to be returned in a single page. It is possible to receive fewer results than the specified limit on a given page. The default value of 100 is also the maximum allowed value. Default: 100 |
Response Fields
Name | Description |
---|---|
errors
|
Information on errors encountered during the request. |
subscriptions
|
The requested list of Subscriptions. |
cursor
|
The pagination cursor to be used in a subsequent request. If empty, this is the final response. For more information, see Pagination. |
Examples
- cURL
- Ruby
- Python
- C#
- Java
- PHP
- Node.js
curl https://connect.squareup.com/v2/webhooks/subscriptions \
-H 'Square-Version: 2023-01-19' \
-H 'Authorization: Bearer ACCESS_TOKEN' \
-H 'Content-Type: application/json'
{
"subscriptions": [
{
"id": "wbhk_b35f6b3145074cf9ad513610786c19d5",
"name": "Example Webhook Subscription",
"enabled": true,
"event_types": [
"payment.created",
"payment.updated"
],
"notification_url": "https://example-webhook-url.com",
"api_version": "2021-12-15",
"created_at": "2022-01-10 23:29:48 +0000 UTC",
"updated_at": "2022-01-10 23:29:48 +0000 UTC"
}
]
}