Update a Webhook

Update the fields of a Webhook object

Parameter

Accessible via URL https://api.channel.io/open/v5/webhooks/{id} and HTTP PATCH

๐Ÿ“˜

This method accepts application/json

ParameterExampleRequiredDescriptionParameter type
id12345RequiredID of Webhook objectPath
(property)(name)OptionalProperty of WebhookBody

Example

PATCH https://api.channel.io/open/v5/webhooks/12345

Your PATCH body should look like

{
   "name":"string",
   "url":"string",
   "scopes":[
      "userChatOpened"
   ],
   "apiVersion":"string",
   "blocked":true
}

Response

Returns the changed Webhook object.

{
  "webhook": {
    "id": "string",
    "channelId": "string",
    "name": "string",
    "url": "string",
    "token": "string",
    "createdAt": 1656032153401,
    "scopes": [
      "userChatOpened"
    ],
    "apiVersion": "string",
    "lastBlockedAt": 1656032153401,
    "blocked": true
  }
}