***

title: TapAction
slug: /reference/python/relay/actions/tap-action
description: Action handle for an active media tap operation.
max-toc-depth: 3
---------------------

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

[call-tap]: /docs/server-sdks/reference/python/relay/call/tap

[base-action-interface]: /docs/server-sdks/reference/python/relay/actions

[stop]: /docs/server-sdks/reference/python/relay/actions/tap-action/stop

Returned from [`call.tap()`][call-tap]. Tracks
an active media tap (audio interception) operation. Terminal state: `finished`.

Inherits all properties and methods from the
[base Action interface][base-action-interface] (`control_id`,
`is_done`, `completed`, `result`, `wait()`).

## **Properties**

No additional properties beyond the [base Action interface][base-action-interface].

## **Methods**

<CardGroup cols={2}>
  <Card title="stop" href="/docs/server-sdks/reference/python/relay/actions/tap-action/stop">
    Stop media interception.
  </Card>
</CardGroup>

## **Example**

```python
from signalwire.relay import RelayClient

client = RelayClient(
    project="your-project-id",
    token="your-api-token",
    host="your-space.signalwire.com",
    contexts=["default"],
)

@client.on_call
async def handle_call(call):
    await call.answer()
    action = await call.tap(
        tap={"type": "audio", "params": {"direction": "both"}},
        device={"type": "ws", "params": {"uri": "wss://example.com/tap"}},
    )

    event = await action.wait()

client.run()
```