ConversationsWebhook

Update Service Webhook Configuration

POST
/v1/Services/{ChatServiceSid}/Configuration/Webhooks

Update a specific Webhook.

Authorization

accountSid_authToken
AuthorizationBasic <token>

In: header

Path Parameters

ChatServiceSid*string

The unique ID of the Conversation Service this conversation belongs to.

Match^IS[0-9a-fA-F]{32}$
Length34 <= length <= 34

Request Body

application/x-www-form-urlencoded

PreWebhookUrl?string

The absolute url the pre-event webhook request should be sent to.

Formaturi
PostWebhookUrl?string

The absolute url the post-event webhook request should be sent to.

Formaturi
Filters?array<string>

The list of events that your configured webhook targets will receive. Events not configured here will not fire. Possible values are onParticipantAdd, onParticipantAdded, onDeliveryUpdated, onConversationUpdated, onConversationRemove, onParticipantRemove, onConversationUpdate, onMessageAdd, onMessageRemoved, onParticipantUpdated, onConversationAdded, onMessageAdded, onConversationAdd, onConversationRemoved, onParticipantUpdate, onMessageRemove, onMessageUpdated, onParticipantRemoved, onMessageUpdate or onConversationStateUpdated.

Method?string

The HTTP method to be used when sending a webhook request. One of GET or POST.

Response Body

application/json

curl -X POST "https://example.com/v1/Services/stringstringstringstringstringstri/Configuration/Webhooks" \  -H "Content-Type: application/x-www-form-urlencoded" \  -d 'PreWebhookUrl=https%3A%2F%2Fwww.example.com%2Fpre&PostWebhookUrl=https%3A%2F%2Fwww.example.com%2Fpost&Filters=onMessageRemoved%2ConParticipantAdded&Method=GET'
{  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",  "chat_service_sid": "ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",  "pre_webhook_url": "https://www.example.com/pre",  "post_webhook_url": "https://www.example.com/post",  "filters": [    "onMessageRemoved",    "onParticipantAdded"  ],  "method": "GET",  "url": "https://conversations.twilio.com/v1/Services/ISaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Configuration/Webhooks"}