In-App Calling

In-App Calling enables you to embed real-time voice communication directly into your mobile or web applications using the Voice API. Built on WebRTC technology, it provides the core capabilities required to create rich, interactive calling experiences between users inside your app, while still allowing calls to connect to external endpoints when needed.

In-App Calling allows your application users to place and receive voice calls without leaving the app interface. It supports both one-to-one and group conversations and provides controls and events that help you build a seamless communication experience.

This capability is powered by the Voice API and client-side SDKs, which together handle media streaming, call signaling, and call lifecycle management.

Core Capabilities

User Controls

Applications can provide built-in audio controls so users can manage their call experience in real time. Common controls include:

  • Muting and unmuting the microphone
  • Earmuff functionality to silence incoming audio without ending the call

These controls enable flexible interaction and improve usability during calls.

Call Notifications

You can notify users about incoming calls using push notifications. This ensures that users remain reachable even when the app is running in the background or the device is locked.

1:1 and Group Calls

In-App Calling supports both direct calls between two users and dynamic group calls. You can configure calls so participants can be added or removed in real time, enabling conferencing and collaborative use cases.

DTMF Support

The feature supports sending DTMF tones during a call, allowing interaction with IVR systems or other telephony services.

Call Continuity

You can improve reliability and user experience with features such as:

  • Automatic reconnection to dropped calls
  • Moving an active call between different devices for the same user

These capabilities help maintain uninterrupted communication across network changes or device switches.

Extendability Through the Voice API

In-App Calling is part of the broader Voice API platform from Vonage. This integration allows you to extend in-app calls beyond app-to-app communication and connect to external telephony and real-time services.

The Voice API has the following capabilities:

This flexibility lets you combine in-app communication with traditional telephony and automated voice workflows.

Data Retention and Storage

By default, conversations created by calls and their associated call legs are stored for 2 days. You can modify this retention period by configuring the Conversations TTL or Legs Persistence Time in the API Dashboard under the advanced Voice capability settings.

Adjusting these values allows you to align data storage with your application’s operational and compliance requirements.

Create a User

Create a User who will log in to Vonage Client and participate in the In-App Calling functionality: Conversations, Calls and so on.

Run the following command in your terminal to create a user named Alice:

vonage users create `
  --name='Alice'
  
✅ Creating User

User ID: USR-00000000-0000-0000-0000-000000000000
Name: Alice
Display Name: Not Set
Image URL: Not Set
Time to Live: Not Set

Channels:
  None Set

The user ID is used to perform tasks by the SDK, such as login, starting a call and more.

Generate a User JWT

JWTs are used to authenticate a user into the Client SDK.

To generate a JWT for Alice run the following command (replacing with your information):

# A command with parameters
vonage jwt create `
--app-id='00000000-0000-0000-0000-000000000000' `
--private-key=./private.key `
--sub='Alice' `
--acl='{\"paths\":{\"\/*\/users\/**\":{},\"\/*\/conversations\/**\":{},\"\/*\/sessions\/**\":{},\"\/*\/devices\/**\":{},\"\/*\/push\/**\":{},\"\/*\/knocking\/**\":{},\"\/*\/legs\/**\":{}}}'

# Will produce a token
eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJhY2wiOnsicGF0aHMiOnsiLyovcnRjLyoqIjp7fSwiLyovdXNlcnMvKioiOnt9LCIvKi9jb252ZXJzYXRpb25zLyoqIjp7fSwiLyovc2Vzc2lvbnMvKioiOnt9LCIvKi9kZXZpY2VzLyoqIjp7fSwiLyovcHVzaC8qKiI6e30sIi8qL2tub2NraW5nLyoqIjp7fSwiLyovbGVncy8qKiI6e319fSwiZXhwIjoxNzQxMTgyMzA3LCJzdWIiOiJBbGljZSIsImp0aSI6Ijg1MTViNzk2LTA1YjktNGFkMS04MTRkLTE1NWZjZTQzZWM1YiIsImlhdCI6MTc0MTE4MTQwNywiYXBwbGljYXRpb25faWQiOiIwMDAwMDAwMC0wMDAwLTAwMDAtMDAwMC0wMDAwMDAwMDAwMDAifQ.BscMdDXZ1-nuLtKyPJvw9tE8E8ZjJvTPJPMT9y0TjPz4Q7qqNaqxcjglc5QPtYEjh2YpZH6btSKbUF4XTClI026Hl5_QOBlnayYo7jXwhba16fa5PeyzSf30QFGFrHbANwrQJFVCjd329SZUpwK4GxgB1gf230NhbfmkhegKezqicru2WTGCKm8kQncYliFwIEYUlcRAb2c8xcaVrn_6QNNahyeJRwGFfWpIkX0Oe-S4RDlPjoq47_gYWac9MmaetB4Dd3Yp531AuniGV5JiIShkaEwuY4Zyov4Hcmajm4Lm_UFY119la7vzHis0P7cT9pPUDe5cyPj7eT8-VhitfQ

The above command defaults the expiry of the JWT to 24 hours. You may change the expiration to a shortened amount of time using the --exp flag.

NOTE: In production apps, it is expected that your backend will expose an endpoint that generates JWT per your client request.