***

title: tap
slug: /reference/typescript/rest/calling/tap
description: Tap call audio to an external endpoint via REST.
max-toc-depth: 3
---------------------

For a complete index of all SignalWire documentation pages, fetch https://signalwire.com/docs/llms.txt

Start tapping audio from an active call and sending it to an external endpoint
(e.g., a WebSocket or RTP destination). Returns a `control_id` for stopping
the tap.

<EndpointSchemaSnippet endpoint="POST /api/calling/calls" />

## **Response Example**

<EndpointResponseSnippet endpoint="POST /api/calling/calls" />

## **Example**

```typescript {9}
import { RestClient } from "@signalwire/sdk";

const client = new RestClient({
  project: "your-project-id",
  token: "your-api-token",
  host: "your-space.signalwire.com"
});

const result = await client.calling.tap("call-id-xxx", {
  tap: { type: "audio", params: { direction: "both" } },
  device: { type: "ws", params: { uri: "wss://example.com/tap" } },
});
const controlId = result.control_id;
```