get

View as MarkdownOpen in Claude

Retrieve a single SWML webhook resource.

Path parameters

idstringRequiredformat: "uuid"
Unique ID of a SWML Webhook.

Response

idstringRequiredformat: "uuid"
Unique ID of the SWML Webhook.
project_idstringRequiredformat: "uuid"
Unique ID of the Project.
display_namestringRequired
Display name of the SWML Webhook Fabric Resource
typeenumRequired
Type of the Fabric Resource
created_atdatetimeRequired
Date and time when the resource was created.
updated_atdatetimeRequired
Date and time when the resource was updated.
swml_webhookobjectRequired
SWML Webhook data.

Response Example

Response
{
"id": "a87db7ed-8ebe-42e4-829f-8ba5a4152f54",
"project_id": "99151cf8-9548-4860-ba70-a8de824f3312",
"display_name": "Booking Assistant",
"type": "swml_webhook",
"created_at": "2024-05-06T12:20:00Z",
"updated_at": "2024-05-06T12:20:00Z",
"swml_webhook": {
"id": "a87db7ed-8ebe-42e4-829f-8ba5a4152f54",
"name": "My SWML Webhook",
"used_for": "calling",
"primary_request_url": "https://primary.com",
"primary_request_method": "GET",
"fallback_request_url": "https://fallback.com",
"fallback_request_method": "GET",
"status_callback_url": "https://callback.com",
"status_callback_method": "POST"
}
}

Example

import { RestClient } from "@signalwire/sdk";
const client = new RestClient({
project: "your-project-id",
token: "your-api-token",
host: "your-space.signalwire.com",
});
const webhook = await client.fabric.swmlWebhooks.get("webhook-id");
console.log("Swml Webhook:", webhook.display_name, "ID:", webhook.id);