Create a Webhook
Creates a new webhook.
Creates a new webhook.
Code:
await seam.webhooks.create({
url: "https://example.com",
event_types: ["device.connected", "device.disconnected"],
});Output:
{
"event_types": ["device.connected", "device.disconnected"],
"secret": "mySecret",
"url": "https://example.com",
"webhook_id": "ffe5cc3c-f3f4-48e8-b377-6f76c05d09a1"
}Creates a new webhook.
Code:
curl --include --request POST "https://connect.getseam.com/webhooks/create" \
--header "Authorization: Bearer $SEAM_API_KEY" \
--json @- <<EOF
{
"url": "https://example.com",
"event_types": [
"device.connected",
"device.disconnected"
]
}
EOFOutput:
{
"webhook": {
"event_types": ["device.connected", "device.disconnected"],
"secret": "mySecret",
"url": "https://example.com",
"webhook_id": "ffe5cc3c-f3f4-48e8-b377-6f76c05d09a1"
}
}Creates a new webhook.
Code:
Output:
Creates a new webhook.
Code:
Output:
Creates a new webhook.
Code:
Output:
Creates a new webhook.
Code:
Output:
Request Parameters
url String (Required)
URL for the new webhook.
event_types Array of Strings
Types of events that you want the new webhook to receive.
Response
Returns: webhook
Last updated
Was this helpful?

