RelayActionsDetectActionstopCopy page|View as Markdown|Open in Claude|More actionsThis page is for Server SDKs.Stop detection immediately. Returns Promise<Record<string, unknown>> — Server acknowledgment. Example import { RelayClient } from '@signalwire/sdk';const client = new RelayClient({ project: process.env.SIGNALWIRE_PROJECT_ID!, token: process.env.SIGNALWIRE_API_TOKEN!, contexts: ['default']});client.onCall(async (call) => { await call.answer(); const action = await call.detect({ type: 'machine', params: { initialTimeout: 5.0 }, }); // Stop detection early await action.stop();});await client.run();