Skip to main content

Role of the app server

The app server, which is a server application, has two roles.

  • Notify a callee (or participants) of an incoming call when setting up a 1-to-1 call or a group call (conference)
  • Deliver appropriate information depending on the call type, which is required by LINE Planet to enable communication

1-to-1 call - cc_param

The app server must deliver cc_param to a callee, which is copied from param in the Notify callback (notify_cb).

Data from notfy_cbTypeCorresponding push payload key
paramStringcc_param

As with most mobile apps, you can use your mobile platform's push system for this task. The following assumes you are using Apple Push Notification service (APNs) or Firebase Cloud Messaging (FCM).

{
...,
/*
* You have to deliver "cc_param"
* that can be obtained from "param" in "notify_cb".
*
* The callee must receive the "cc_param" value
* to complete the call setup normally.
*/
"cc_param": "...BYdVhGZW5UM1o4WmFwV....",
...
}

In addition, you can define your application's push data using other fields from notify_cb to handle application requirements such as showing caller information or call type. Take a look at the following examples. Applications can add any fields to be sent to the callee, but this is not required for PlanetKit's call setup.

APNs example

{
/*
* cc_param field is required.
*/
"cc_param": "...BYdVhGZW5UM1o4WmFwV....",
...
,
/*
* The following fields are optional.
* Application can add any fields to deliver
* to the callee but it's not required.
* Please note that
* LINE PlanetKit SDK requires only "cc_param" value
* to complete the call setup normally.
*/
"your_field_1": "some-optional-value-1",
"your_field_2": "some-optional-value-2",
...
}

GCM/FCM example

{
/*
* "cc_param" field is required.
*/
"cc_param": "...BYdVhGZW5UM1o4WmFwV....",
...
,
/*
* The following fields are optional.
* Application can add any fields to deliver
* to the callee but it's not required.
* Please note that
* LINE PlanetKit SDK requires only "cc_param" value
* to complete the call setup normally.
*/
"your_field_1": "some-optional-value-1",
"your_field_2": "some-optional-value-2",
...
}

Group call

Unlike 1-to-1 calls, there is no requirement for the app server to set up a group call. However, ensure that all participants share the same service ID and room ID to communicate in the same room. Applications can share this information between clients through an application-specific channel. In this case, you do not need to handle Group Call Event callback (on_gcall_evt_cb).

To use on_gcall_evt_cb in your application, copy the service ID and room ID from the following fields.

  • Service ID: svc_id
  • Room ID: id