---title: CallTap---Represents a current or past tapping of a call. You can obtain instances of this class by starting a Tap with one of the following methods:- [Call.tap](./voice-call.mdx#tap)- [Call.tapAudio](./voice-call.mdx#tapaudio)#### ExampleAs soon as the other party answers the phone, start transmitting the audio ofthe call to an external service.jsimport { Voice } from @signalwire/realtime-api;const client = new Voice.Client({ project: , token: , contexts: [office],});const call = await client.dialPhone({ from: +YYYYYYYYYY, to: +XXXXXXXXXX,});// Start tapping the audio of the callconst tap = await call.tapAudio({ direction: both, device: { type: ws, uri: wss://example.domain.com/endpoint, },});console.log(Tap id:, tap.id);## Accessors### id• get **id**(): stringThe unique id for this tapping.#### Returnsstring## Methods### ended▸ **ended**(): Promise<[CallTap](./calltap.mdx)\>Returns a promise that is resolved only after this tap finishes (or is stopped).#### ReturnsPromise<[CallTap](./calltap.mdx)\>#### Examplejsconst tap = await call.tapAudio({ direction: both, device: { type: ws, uri: wss://example.domain.com/endpoint, },});await tap.ended();---### stop▸ **stop**(): Promise<[CallTap](./calltap.mdx)\>Stops the tapping.#### ReturnsPromise<[CallTap](./calltap.mdx)\>#### Examplejsconst tap = await call.tapAudio({ direction: both, device: { type: ws, uri: wss://example.domain.com/endpoint, },});await tap.stop();