Update a webhook endpoint
PATCH
/webhook-endpoints/{id}
const url = 'https://mail.teamander.com/v1/webhook-endpoints/a1b2c3d4-e5f6-7890-abcd-ef1234567890';const options = { method: 'PATCH', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"active":false}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PATCH \ --url https://mail.teamander.com/v1/webhook-endpoints/a1b2c3d4-e5f6-7890-abcd-ef1234567890 \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "active": false }'Change the URL, subscribed events, or toggle active.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”id
required
Resource identifier
string
Example
a1b2c3d4-e5f6-7890-abcd-ef1234567890Request Body
Section titled “Request Body”Media typeapplication/json
object
url
string format: uri
events
Array<string>
active
boolean
Example
{ "active": false}Responses
Section titled “Responses”Updated endpoint
Media typeapplication/json
object
id
required
integer
url
required
string
events
required
Array<string>
active
required
boolean
created_at
required
string
Examplegenerated
{ "id": 1, "url": "example", "events": [ "example" ], "active": true, "created_at": "example"}Validation failed
Media typeapplication/json
object
error
required
string
details
object
key
additional properties
Example
{ "error": "Validation failed", "details": {}}Missing or invalid API key
Media typeapplication/json
object
error
required
string
message
string
Example
{ "error": "Invalid API key"}Not found
Media typeapplication/json
object
error
required
string
message
string
Example
{ "error": "not_found"}