Skip to main content
Version: 1.2

App server data

Applications can share application data between an app client and the app server when making a 1-to-1 call or joining a group call (conference). App server data is name of the application data delivered from an app client to the app server.

Supported call typeSupported SDK version
1-to-1 call, group call1.2

Sending app server data

The following sections describe how to send app server data based on the call type.

1-to-1 call

In 1-to-1 calls, only the caller can send app server data.

To send app server data in a 1-to-1 call, set the app server data in a PlanetKitMakeCallParam, and pass the PlanetKitMakeCallParam when calling makeCall().

final param = PlanetKitMakeCallParamBuilder()
.setMyUserId(myUserId)
.setMyServiceId(myServiceId)
.setPeerUserId(peerUserId)
.setPeerServiceId(peerServiceId)
.setAccessToken(accessToken)
.setAppServerData("App server data for a 1-to-1 call")
.build();

final result = await PlanetKitManager.instance.makeCall(param, eventHandler);

The app server data is delivered in the app_svr_data parameter of Notify and 1-to-1 Call Event server callbacks.

Group call

In group calls, all participants are eligible to send app server data.

To send app server data in a group call, set the app server data in a PlanetKitJoinConferenceParam, and pass the PlanetKitJoinConferenceParam when calling joinConference().

final param = PlanetKitJoinConferenceParamBuilder()
.setMyUserId(myUserId)
.setMyServiceId(myServiceId)
.setRoomId(roomId)
.setRoomServiceId(roomServiceId)
.setAccessToken(accessToken)
.setAppServerData("App server data for a group call")
.build();

final result = await PlanetKitManager.instance.joinConference(param, eventHandler);

The app server data is delivered in the app_svr_data parameter of the Group Call Event server callback.

Size limitation

The maximum size of app server data is 4096 bytes including the null termination character.

APIs related to the app server data function are as follows.

1-to-1 call

Client API

Server API

Group call

Client API

Server API