Gets the list of all webhooks that the user owns (if a user-generated token was used to make the request) or the list of all webhooks associated with the third-party app (if a third-party app made the request). Items in the response are ordered by API cient name > webhook name > creation date.
includeAll | boolean Default: false If true, include all results, that is, do not paginate. Mutually exclusive with page and pageSize (they are ignored if includeAll=true is specified). |
page | number Default: 1 Which page to return. Defaults to 1 if not specified. If you specify a value greater than the total number of pages, the last page of results is returned. |
pageSize | number Default: 100 The maximum number of items to return per page. Unless otherwise stated for a specific endpoint, defaults to 100. If only page is specified, defaults to a page size of 100. For reports, the default is 100 rows. If you need larger sets of data from your report, returns a maximum of 10,000 rows per request. |
Authorization | string API Access Token used to authenticate requests to Smartsheet APIs. Example: Bearer JKlMNOpQ12RStUVwxYZAbcde3F5g6hijklM789 |
curl https://api.smartsheet.com/2.0/webhooks \ -H "Authorization: Bearer JKlMNOpQ12RStUVwxYZAbcde3F5g6hijklM789"
{- "pageNumber": 1,
- "pageSize": 50,
- "totalPages": 25,
- "totalCount": 136,
- "data": [
- {
- "events": [
- "*.*"
], - "name": "Webhook for Sheet Creation",
- "version": 1,
- "enabled": true,
- "id": 8444254503626628,
- "apiClientId": 555555,
- "scopeObjectId": 3285357287499652,
- "apiClientName": "Awesome Smartsheet Application",
- "createdAt": "2019-08-24T14:15:22Z",
- "disabledDetails": "string",
- "modifiedAt": "2019-08-24T14:15:22Z",
- "scope": "sheet",
- "sharedSecret": "216ejjzdnq17mq1q8xs7d4hu8b",
- "stats": {
- "lastCallbackAttempt": "2019-08-24T14:15:22Z",
- "lastCallbackAttemptRetryCount": 0,
- "lastSuccessfulCallback": "2019-08-24T14:15:22Z"
}, - "status": "ENABLED",
- "subscope": {
- "columnIds": [
- 7318427511613316,
- 7318427511613123
]
}
}
]
}
Creates a new Webhook.
A webhook is not enabled by default when it is created. Once you've created a webhook, you can enable it by using the Update Webhook operation to set enabled to true.
When a row is deleted on a sheet, even if you are using a subscope to monitor columns only and the cell in that column for that row is empty, you will receive a "row.deleted" event.
Authorization | string API Access Token used to authenticate requests to Smartsheet APIs. Example: Bearer JKlMNOpQ12RStUVwxYZAbcde3F5g6hijklM789 |
Content-Type | string Default: application/json Required for POST and PUT requests. Defines the structure for the request body. |
callbackUrl required | string HTTPS URL where callbacks are sent. |
events required | Array of strings Array of the events that are subscribed to. Currently, must be an array of size 1 that contains the string value '*.*' (asterisk period asterisk), which means "all objects" and "all events". |
name required | string Webhook name. |
version required | number [ 1 .. 1 ] Webhook version. Currently, the only supported value is 1. This attribute is intended to ensure backward compatibility as new webhook functionality is released. For example, a webhook with a version of 1 is guaranteed to always be sent callback objects that are compatible with the version 1 release of webhooks. |
{- "events": [
- "*.*"
], - "name": "Webhook for Sheet Creation",
- "version": 1
}
{- "version": 0,
- "failedItems": [
- {
- "rowId": 0,
- "error": {
- "refId": "string",
- "errorCode": 0,
- "message": "string"
}, - "index": 0
}
], - "message": "SUCCESS",
- "resultCode": 0,
- "result": {
- "events": [
- "*.*"
], - "name": "Webhook for Sheet Creation",
- "version": 1,
- "enabled": true,
- "id": 8444254503626628,
- "apiClientId": 555555,
- "scopeObjectId": 3285357287499652,
- "apiClientName": "Awesome Smartsheet Application",
- "createdAt": "2019-08-24T14:15:22Z",
- "disabledDetails": "string",
- "modifiedAt": "2019-08-24T14:15:22Z",
- "scope": "sheet",
- "sharedSecret": "216ejjzdnq17mq1q8xs7d4hu8b",
- "stats": {
- "lastCallbackAttempt": "2019-08-24T14:15:22Z",
- "lastCallbackAttemptRetryCount": 0,
- "lastSuccessfulCallback": "2019-08-24T14:15:22Z"
}, - "status": "ENABLED",
- "subscope": {
- "columnIds": [
- 7318427511613316,
- 7318427511613123
]
}
}
}
Gets a Webhook based on the specified ID
webhookId required | string The Id of a Webhook |
Authorization | string API Access Token used to authenticate requests to Smartsheet APIs. Example: Bearer JKlMNOpQ12RStUVwxYZAbcde3F5g6hijklM789 |
curl https://api.smartsheet.com/2.0/webhooks/{webhookId} \ -H "Authorization: Bearer JKlMNOpQ12RStUVwxYZAbcde3F5g6hijklM789"
{- "events": [
- "*.*"
], - "name": "Webhook for Sheet Creation",
- "version": 1,
- "enabled": true,
- "id": 8444254503626628,
- "apiClientId": 555555,
- "scopeObjectId": 3285357287499652,
- "apiClientName": "Awesome Smartsheet Application",
- "createdAt": "2019-08-24T14:15:22Z",
- "disabledDetails": "string",
- "modifiedAt": "2019-08-24T14:15:22Z",
- "scope": "sheet",
- "sharedSecret": "216ejjzdnq17mq1q8xs7d4hu8b",
- "stats": {
- "lastCallbackAttempt": "2019-08-24T14:15:22Z",
- "lastCallbackAttemptRetryCount": 0,
- "lastSuccessfulCallback": "2019-08-24T14:15:22Z"
}, - "status": "ENABLED",
- "subscope": {
- "columnIds": [
- 7318427511613316,
- 7318427511613123
]
}
}
Updates the specified Webhook. The following properties can be updated:
When setting a webhook's enabled to true using this operation, the behavior and result depend on the webhook's status and may result in a webhook verification being triggered, or in some cases, an error being returned. See Webhook Status for more details.
webhookId required | string The Id of a Webhook |
Authorization | string API Access Token used to authenticate requests to Smartsheet APIs. Example: Bearer JKlMNOpQ12RStUVwxYZAbcde3F5g6hijklM789 |
Content-Type | string Default: application/json Required for POST and PUT requests. Defines the structure for the request body. |
callbackUrl | string HTTPS URL where callbacks are sent. |
events | Array of strings Array of the events that are subscribed to. Currently, must be an array of size 1 that contains the string value '*.*' (asterisk period asterisk), which means "all objects" and "all events". |
name | string Webhook name. |
version | number [ 1 .. 1 ] Webhook version. Currently, the only supported value is 1. This attribute is intended to ensure backward compatibility as new webhook functionality is released. For example, a webhook with a version of 1 is guaranteed to always be sent callback objects that are compatible with the version 1 release of webhooks. |
enabled | boolean Indicates whether the webhook is on (true) or off (false). |
{- "events": [
- "*.*"
], - "name": "Webhook for Sheet Creation",
- "version": 1,
- "enabled": true
}
{- "version": 0,
- "failedItems": [
- {
- "rowId": 0,
- "error": {
- "refId": "string",
- "errorCode": 0,
- "message": "string"
}, - "index": 0
}
], - "message": "SUCCESS",
- "resultCode": 0,
- "result": {
- "events": [
- "*.*"
], - "name": "Webhook for Sheet Creation",
- "version": 1,
- "enabled": true,
- "id": 8444254503626628,
- "apiClientId": 555555,
- "scopeObjectId": 3285357287499652,
- "apiClientName": "Awesome Smartsheet Application",
- "createdAt": "2019-08-24T14:15:22Z",
- "disabledDetails": "string",
- "modifiedAt": "2019-08-24T14:15:22Z",
- "scope": "sheet",
- "sharedSecret": "216ejjzdnq17mq1q8xs7d4hu8b",
- "stats": {
- "lastCallbackAttempt": "2019-08-24T14:15:22Z",
- "lastCallbackAttemptRetryCount": 0,
- "lastSuccessfulCallback": "2019-08-24T14:15:22Z"
}, - "status": "ENABLED",
- "subscope": {
- "columnIds": [
- 7318427511613316,
- 7318427511613123
]
}
}
}
Deletes the specified Webhook.
Using this operation permanently deletes the specified webhook. To temporarily disable a webhook, use the Update Webhook operation to set enabled to false.
webhookId required | string The Id of a Webhook |
Authorization | string API Access Token used to authenticate requests to Smartsheet APIs. Example: Bearer JKlMNOpQ12RStUVwxYZAbcde3F5g6hijklM789 |
curl https://api.smartsheet.com/2.0/webhooks/{webhookId} \ -H "Authorization: Bearer JKlMNOpQ12RStUVwxYZAbcde3F5g6hijklM789" \ -X DELETE
{- "version": 0,
- "failedItems": [
- {
- "rowId": 0,
- "error": {
- "refId": "string",
- "errorCode": 0,
- "message": "string"
}, - "index": 0
}
], - "message": "SUCCESS",
- "resultCode": 0
}