The Per-Service Webhook resource allows you to control the effects of webhooks in a particular Conversation Service. The webhooks will only fire for activity at the service-level.
Services allow you to:
Every service can have unique webhook targets. This means you can include different metadata in the URLs or even trigger different behavior for different services.
Webhook targets for the Service Instance (the URL that Twilio will invoke) are configured in the Twilio Console.
If configured, service-scoped webhooks will override your global webhook settings such that only the service-scoped hooks will fire. This applies only to the services where service-level hooks are configured. See Conversations Webhooksfor more information.
account_sid
type: SID<AC>The unique ID of the Account responsible for this service.
^AC[0-9a-fA-F]{32}$
34
34
chat_service_sid
type: SID<IS>The unique ID of the Conversation Service this conversation belongs to.
^IS[0-9a-fA-F]{32}$
34
34
pre_webhook_url
type: string<uri>The absolute url the pre-event webhook request should be sent to.
post_webhook_url
type: string<uri>The absolute url the post-event webhook request should be sent to.
filters
type: 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
type: enum<string>The HTTP method to be used when sending a webhook request. One of GET
or POST
.
GET
POST
GET https://conversations.twilio.com/v1/Services/{ChatServiceSid}/Configuration/Webhooks
ChatServiceSid
type: SID<IS>The unique ID of the Conversation Service this conversation belongs to.
^IS[0-9a-fA-F]{32}$
34
34
POST https://conversations.twilio.com/v1/Services/{ChatServiceSid}/Configuration/Webhooks
ChatServiceSid
type: SID<IS>The unique ID of the Conversation Service this conversation belongs to.
^IS[0-9a-fA-F]{32}$
34
34
PreWebhookUrl
type: string<uri>The absolute url the pre-event webhook request should be sent to.
PostWebhookUrl
type: string<uri>The absolute url the post-event webhook request should be sent to.
Filters
type: 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
type: stringThe HTTP method to be used when sending a webhook request. One of GET
or POST
.