Skip to main content

1-to-1 Call Event callback

When a 1-to-1 call ends, the 1-to-1 Call Event callback is called. Applications can do the following tasks with the 1-to-1 Call Event callback.

  • Leave call logs
  • Check the call status (for example, whether the call ended normally)
  • Collect statistical data

Method and URI

  • Method: GET
  • URI: {on_call_evt_cb_url}

Query parameters

ParameterTypeNullableDescriptionExample
sidStringNSession ID (UUID format).
You can identify a call using a sid.
Fixed size of 36 bytes without NULL.
6364e8b3-bdac-436e-9631-0bce2498ce0c
from_service_idStringNCaller service IDcaller-service-id
from_user_idStringNCaller user IDcaller-user-id
to_service_idStringNCallee service IDcallee-service-id
to_user_idStringNCallee user IDcallee-user-id
typeStringNCall type
- A: Audio call
- V: Video call
A
stidStringYDeprecated.
Application data delivered from makeCall() in PlanetKit SDK
generated-by-application
setup_timeLongNTime when this call was made (seconds)0
start_timeLongNTime when this call started (seconds)0
end_timeLongNTime when this call ended (seconds)0
durationIntegerNCall duration (seconds).
end_time - start_time.
The duration will be 0 if this call has failed.
30
srcipStringNCaller IP address1.2.3.4
dstipStringNCallee IP address1.2.3.3
terminateIntegerNQ.850 cause value.
If duration is greater than 0, the terminate value will be '16 (Normal)'.
Refer to Call release reason.
16
rel_codeIntegerNDetailed release code of a call. This is used to track the call release reason in the platform.
Refer to Call release reason.
2
rel_code_strStringNDetailed release code of a call. This is used to track the call release reason in the platform.
Refer to Call release reason.
CANCEL
user_rel_codeStringYApplication definition release code.
Refer to Call release reason.
billing_secIntegerNCall duration for billing (in seconds, with milliseconds rounded up)
Note: Depending on the call connection status, the billing call duration might be less than the actual call duration (duration).
25
rc_idcStringNRepresents the IDC that processed the caller. All uppercase in the ISO 3166-1 alpha-2 code format.KR
disconnect_reasonIntegerNDisconnect reason. For more information, see Disconnect reasons.1001
releaser_typeIntegerNType of the releaser (disconnect source). For more information, see Disconnect sources.1
app_svr_dataStringYApplication data delivered from makeCall() in PlanetKit SDK.
For more information, refer to the app server data guide for each client platform:
- Android
- iOS/macOS
- Windows
- Web
Note: This parameter delivers the same data as stid.
generated-by-application

Example

# Let's suppose on_call_evt_cb_url is
# http://sample.server.com:20200/call_event
# LINE Planet server will send a request to on_call_evt_cb_url as follows.

GET http://sample.server.com:20200/call_event?
sid=6364e8b3-bdac-436e-9631-0bce2498ce0c&
type=V&
from_user_id=9286&
from_service_id=caller-service-id&
to_user_id=2809&
to_service_id=callee-service-id&
setup_time=1582527400&
start_time=1582527404&
end_time=1582527434&
duration=30&
terminate=16&
srcip=1.2.3.4&
dstip=1.2.3.5&
stid=voip.next&
rel_code=1&
rel_code_str=NORMAL&
billing_sec=25&
rc_idc=KR&
disconnect_reason=1001&
releaser_type=1&
app_svr_data=appSvrData