start_input_timers

View as MarkdownOpen in Claude

Manually start the initial_timeout timer on the active collect operation. Useful when start_input_timers was set to false during the initial call.

Returns

dict — Server acknowledgment.

Example

1from signalwire.relay import RelayClient
2
3client = RelayClient(
4 project="your-project-id",
5 token="your-api-token",
6 host="your-space.signalwire.com",
7 contexts=["default"],
8)
9
10@client.on_call
11async def handle_call(call):
12 await call.answer()
13 action = await call.play_and_collect(
14 media=[{"type": "tts", "text": "Press 1 for sales, 2 for support."}],
15 collect={
16 "digits": {"max": 1, "digit_timeout": 5.0},
17 "start_input_timers": False,
18 },
19 )
20
21 # Start timers when ready
22 await action.start_input_timers()
23
24 event = await action.wait()
25
26client.run()