Skip to navigation

transfer

View as MarkdownOpen in Claude

Transfer an active call to a new destination. Pass a destination string, such as a SIP address, or an inline SWML document that takes over the call.

Request

idstringRequiredformat: "uuid"
The unique identifying ID of an existing call.
paramsobjectRequired
An object of parameters that will be utilized by the active command.

Response

Call LegobjectRequired
Returned when the call is a standard PSTN, SIP, or WebRTC call.
OR
Fabric Subscriber Device LegobjectRequired

Returned when the call is a Fabric subscriber device leg. The status field is always null for this type.

Example

import { RestClient } from "@signalwire/sdk";
const client = new RestClient({
project: "your-project-id",
token: "your-api-token",
host: "your-space.signalwire.com"
});
await client.calling.transfer("call-id-xxx", {
version: "1.0.0",
sections: {
main: [{ connect: { to: "+15559876543" } }],
},
});