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) #### Example As soon as the other party answers the phone, start transmitting the audio of the call to an external service. js import { Voice } from @signalwire/realtime-api; const client = new Voice.Client({ project: , token: , topics: [office], }); const call = await client.dialPhone({ from: +YYYYYYYYYY, to: +XXXXXXXXXX, }); // Start tapping the audio of the call const tap = await call.tapAudio({ direction: both, device: { type: ws, uri: wss://example.domain.com/endpoint, }, }); ## Properties ### id The unique id for this tapping. **Syntax:** CallTap.id() **Returns:** string ## Methods ### ended ▸ **ended**(): Promise - See [CallTap](./calltap.mdx) for more details. Returns a promise that is resolved only after this tap finishes (or is stopped). #### Returns Promise - See [CallTap](./calltap.mdx) for more details. #### Example js const tap = await call.tapAudio({ direction: both, device: { type: ws, uri: wss://example.domain.com/endpoint, }, }); await tap.ended(); ### stop ▸ **stop**(): Promise - See [CallTap](./calltap.mdx) for more details. Stops the tapping. #### Returns Promise - See [CallTap](./calltap.mdx) for more details. #### Example js const tap = await call.tapAudio({ direction: both, device: { type: ws, uri: wss://example.domain.com/endpoint }, }); await tap.stop();