Update Webhook Subscription
Update mutable fields of a webhook subscription.
Requires the webhooks:write scope on the API key.
PATCH
/
v1
/
webhooks
/
{webhook_id}
Update Webhook Subscription
curl --request PATCH \
--url https://api.topo.io/v1/webhooks/{webhook_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"url": "<string>",
"description": "<string>",
"event_types": [],
"sequence_template_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
]
}
'const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
url: '<string>',
description: '<string>',
event_types: [],
sequence_template_ids: ['3c90c3cc-0d44-4b50-8888-8dd25736052a']
})
};
fetch('https://api.topo.io/v1/webhooks/{webhook_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.topo.io/v1/webhooks/{webhook_id}"
payload = {
"name": "<string>",
"url": "<string>",
"description": "<string>",
"event_types": [],
"sequence_template_ids": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"url": "<string>",
"description": "<string>",
"event_types": [
"message.sent"
],
"sequence_template_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"status": "ACTIVE",
"secret_prefix": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}Authorizations
Bearer API key issued from Settings → Developers.
Path Parameters
ID of the webhook.
Body
application/json
Update Webhook Subscription payload
New name for the subscription.
Required string length:
1 - 255New delivery URL.
Required string length:
1 - 2083New description. Pass null to clear.
Maximum string length:
1000New event-type filter.
Minimum array length:
1Available options:
message.sent, message.opened, message.link_clicked, message.replied, invitation.sent, invitation.accepted, hot_lead.created, meeting.created, sequence.created, sequence.paused, sequence.resumed, sequence.stopped, sequence.completed, task.created, task.completed, task.skipped, task.reopened, contact_entry.resolved, event.resolved, contact_exclusion.created New sequence-template scope. Pass null to receive events from all templates.
Minimum array length:
1New lifecycle status.
Available options:
ACTIVE, PAUSED, DISABLED Response
200 - application/json
Successful Response
Unique identifier.
Name of the subscription.
Delivery URL events are POSTed to.
Free-form description.
Event types this subscription receives.
Available options:
message.sent, message.opened, message.link_clicked, message.replied, invitation.sent, invitation.accepted, hot_lead.created, meeting.created, sequence.created, sequence.paused, sequence.resumed, sequence.stopped, sequence.completed, task.created, task.completed, task.skipped, task.reopened, contact_entry.resolved, event.resolved, contact_exclusion.created Sequence-template scope.
Lifecycle status.
Available options:
ACTIVE, PAUSED, DISABLED Leading characters of the signing secret, safe to display.
When the subscription was created.
When the subscription last changed.
Was this page helpful?
⌘I
Update Webhook Subscription
curl --request PATCH \
--url https://api.topo.io/v1/webhooks/{webhook_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"url": "<string>",
"description": "<string>",
"event_types": [],
"sequence_template_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
]
}
'const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
url: '<string>',
description: '<string>',
event_types: [],
sequence_template_ids: ['3c90c3cc-0d44-4b50-8888-8dd25736052a']
})
};
fetch('https://api.topo.io/v1/webhooks/{webhook_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.topo.io/v1/webhooks/{webhook_id}"
payload = {
"name": "<string>",
"url": "<string>",
"description": "<string>",
"event_types": [],
"sequence_template_ids": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"url": "<string>",
"description": "<string>",
"event_types": [
"message.sent"
],
"sequence_template_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"status": "ACTIVE",
"secret_prefix": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}