For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Platform docsVideosCommunitySign up
CapabilitiesGetting startedVoice AI OrchestrationVoxEngine PlatformAPI ReferenceFAQ
CapabilitiesGetting startedVoice AI OrchestrationVoxEngine PlatformAPI ReferenceFAQ
  • Voice AI on Voximplant
    • Getting started
    • VoxEngine Overview
    • LLM & Speech Engines
    • Telephony Networks
    • Guide Usage
  • Configure Voximplant
    • Configure Voximplant
    • Create an account
    • Create an application
    • Create a scenario
    • Setup routing
    • Application Storage
  • Network options
    • Phone Numbers & PSTN
    • SIP
    • WhatsApp
    • Web & Mobile
  • Inbound vs. Outbound calling
    • Inbound calls
    • Outbound calls
  • What's next?
    • Enhance and deploy
    • Telephony and Voice AI
    • Build and Deploy
LogoLogo
Platform docsVideosCommunitySign up
On this page
  • Use AppEvents.CallAlerting as the entry point
  • Inbound guidelines:
  • More information:
Inbound vs. Outbound calling

Inbound calls

Flows where the caller initiates the session
||View as Markdown|
Was this page helpful?
Edit this page
Previous

Web & Mobile

Next

Outbound calls

Built with

For the complete documentation index, see llms.txt.

Inbound flows start when a caller reaches your destination (phone number, WhatsApp destination, SIP username, or app user alias) and a routing rule launches your scenario.

Use AppEvents.CallAlerting as the entry point

All inbound calls use the same entry point, allowing easy, common handling regardless of the channel. Use AppEvents.CallAlerting to answer the call and start your Voice AI logic.

For example:

Inbound Voice AI pattern
1VoxEngine.addEventListener(AppEvents.CallAlerting, async (event) => {
2 const call = event.call; // call object for the inbound session
3 call.answer(); // stops ringing and connects media
4
5 // Termination functions - add cleanup and logging as needed
6 call.addEventListener(CallEvents.Disconnected, ()=>VoxEngine.terminate());
7 call.addEventListener(CallEvents.Failed, ()=>VoxEngine.terminate());
8
9 // Connect the Voice AI client
10 const voiceAIClient = OpenAI.createRealtimeAPIClient({apiKey: "your-key", model: "your-realtime-model"});
11
12 // Bridge media between the call and the Voice AI client so they can speak and hear each other
13 VoxEngine.sendMediaBetween(call, voiceAIClient);
14});

Inbound guidelines:

  • Answer quickly with call.answer()
  • Listen for key call events (Disconnected, Failed, etc.) and handle as needed
  • Create/configure the connector client
  • Bridge media between call and connector:
    • Use VoxEngine.sendMediaBetween(...) for simple two-party bridging
    • Alternatively use call.sendMediaTo(...) and connector.sendMediaTo(...) for more complex pipelines
  • Invoke methods and handle events from the connector to drive your Voice AI logic

More information:

  • Calls and Sessions concepts
  • Processing calls in scenarios guide
  • Launching a routing rule
  • VoxEngine Call class