이 페이지는 현재 영어로만 제공되며 한국어 버전은 곧 제공될 예정입니다. 기다려 주셔서 감사드립니다.

After a Room Is Created

Feature Overview

The app backend can use this callback to view real-time information about users creating rooms, including when the app backend receives a notification of successful room creation, allowing for data synchronization and other operations.

Notes

To enable the callback, a callback URL must be configured and the switch corresponding to this callback protocol activated. For configuration methods, see Third-party Callback Configuration document.
During this callback, the Live backend initiates an HTTP POST request to the app backend.
After receiving the callback request, the app backend must check whether the SDKAppID contained in the request URL is consistent with its own SDKAppID.

Scenarios that may trigger this callback

App users successfully create a room through the client
App administrators successfully create a room via the REST API

Callback Trigger Time

After the room is created successfully.

API description

Sample request URL

In the following example, the callback URL configured in the app is https://www.example.com. Example:
https://www.example.com?SdkAppid=$SDKAppID&CallbackCommand=$CallbackCommand&contenttype=json&ClientIP=$ClientIP&OptPlatform=$OptPlatform

Request parameters

Parameter
Description
https
The request protocol is HTTPS, and the request method is POST
www.example.com
Callback URL
SdkAppid
SDKAppID assigned by the Instant Messaging console when an application is created
CallbackCommand
Fixed as Live.CallbackAfterCreateRoom
contenttype
Fixed value: JSON
ClientIP
Client IP, such as 127.0.0.1
OptPlatform
Client Platform, for value reference see Webhook Overview: Callback Protocol for the meaning of the OptPlatform parameter

Sample request packets

{
"CallbackCommand":"Live.CallbackAfterCreateRoom",
"Operator_Account":"admin",
"RoomInfo":{
"RoomId":"tandy-test-rest",
"RoomName":"tandy-test-rest",
"RoomType":"Live",
"Owner_Account":"user3",
"MaxMemberCount":300,
"IsMessageDisabled":true,
"CustomInfo":"custom123",
"IsSeatEnabled":true,
"TakeSeatMode":"ApplyToTake",
"MaxSeatCount":16,
"CreateTime":1703589922,
"IsPublicVisible":true,
"CoverURL":"cover url",
"Category":[1,2]
}
}

Request packet fields

Field
Type
Description
CallbackCommand
String
Callback command
Operator_Account
String
Operator UserID initiating group creation request
RoomId
String
Room ID
RoomName
String
Room Name
RoomType
String
Room Type: Meeting (Meeting Room)
Owner_Account
String
Host ID
MaxMemberCount
Integer
Maximum number of room members
IsMessageDisabled
Bool
Prohibit all members from sending text messages
CustomInfo
String
Custom Definition Fields
IsSeatEnabled
Bool
Is microphone support available?
MaxSeatCount
Integer
Maximum Number of Microphones
TakeSeatMode
String
Seat Mode: None (Off), FreeToTake (Free to Join the Podium), ApplyToTake (Apply to join the microphone)
CreateTime
Integer
Scheduled meeting start time
IsPublicVisible
Bool
Room is public or not
CoverURL
String
Room cover URL
Category
Array
Room Type Identification, Integer array type
EventTime
Integer
Event trigger timestamp in milliseconds

Response packet example

A callback response packet is sent after the app backend synchronizes the data.
{
"ActionStatus": "OK",
"ErrorInfo": "",
"ErrorCode": 0 // Ignore callback result
}

Response Packet Field Description

Field
Type
Attribute
Description
ActionStatus
String
Mandatory
The result of the request process: OK indicates success; FAIL indicates failure
ErrorCode
Integer
Mandatory
Error Code, here 0 means to ignore the response result
ErrorInfo
String
Mandatory
Error message

Reference

REST API:Create Room