waitForEnded
Wait for the call to reach the ended state. This is a convenience method
equivalent to waiting for a calling.call.state event with state === "ended".
Parameters
timeout
Maximum milliseconds to wait. Throws an Error if exceeded. undefined
waits indefinitely.
Returns
Promise<RelayEvent> — The state-change event indicating the call has ended.