Help Center/ Meeting/ Server API Reference/ Meeting Control/ APIs/ Obtaining a Meeting Control Token
Updated on 2024-01-19 GMT+08:00

Obtaining a Meeting Control Token

Description

This API is used to obtain a meeting control token of an ongoing meeting. (If this API is called for a meeting that has not started, a failure message is returned.) A token is valid for half an hour.

Debugging

You can debug this API in API Explorer.

Prototype

Table 1 Prototype

Request Method

GET

Request Address

/v1/mmc/control/conferences/token

Transport Protocol

HTTPS

Request Parameters

Table 2 Parameters

Parameter

Mandatory

Type

Location

Description

conferenceID

Yes

String

Query

Meeting ID.

NOTE:

conferenceID returned when a meeting is created. The value is not the value of vmrConferenceID.

X-Conference-Authorization

No

String

Header

Meeting control token.

NOTE:
  • This parameter is carried only when the meeting control token keeps alive.
  • If the session has expired and the request contains a password, re-authentication is required. A new meeting control token is returned.

X-Password

Yes

String

Header

Host password.

NOTE:

When the meeting control token keeps alive, the host password is not authenticated.

X-Login-Type

Yes

Integer

Header

Request type.

  • The value is fixed at 1.

X-Nonce

No

String

Header

Temporary nonce token of a user.

Status Codes

Table 3 Status codes

HTTP Status Code

Description

200

Operation successful.

400

Invalid parameters.

500

Server exception.

Response Parameters

Table 4 Response parameters

Parameter

Type

Description

data

data object

Meeting control token information.

addressToken

String

Temporary token for querying the corporate directory.

gloablPublicIP

String

URL of the Huawei Cloud Meeting Management Platform.

Table 5 Data structure of data

Parameter

Type

Description

token

String

Meeting control token. The token is valid for half an hour.

NOTE:

You can use a meeting control token in either of the following ways:

  • Use it directly in all subsequent meeting control APIs. Example: X-Conference-Authorization:stbaf8fa2ea8a1b0e3ab2e007a85a75f88c55d5f6d5c1912dfb
  • Use it after base64 transcoding. The transcoding format is Basic Base64(token). Example: X-Conference-Authorization:Basic Y25yYjQyNmNhMzgyMWY4YTE4ZTc4ZDU5ZGE1NzJhNDIxNjQ0YzUyZGZkOWE0NzMwMjk4

tmpWsToken

String

Authentication token for setting up a meeting control WebSocket connection.

wsURL

String

URL for setting up a meeting control WebSocket connection.

role

Integer

Participant role in the meeting.

  • 0: common participant.
  • 1: meeting host.

expireTime

long

Expiration timestamp of the meeting control token, in milliseconds.

userID

String

UUID of the user who schedules the meeting.

orgID

String

ID of the enterprise that the meeting belongs to.

participantID

String

Site ID returned after a terminal joins the meeting.

NOTE:

This parameter will be discarded. Do not use it.

confTokenExpireTime

Integer

Validity period of the meeting control token, in seconds.

vmrCurrentConfID

String

ID of the cloud meeting room used to hold the meeting.

supportNotifyType

Array of strings

Type of WebSocket messages that can be pushed.

Example Request

GET /v1/mmc/control/conferences/token?conferenceID=914083901
Connection: keep-alive
X-Password: *******
X-Login-Type: 1
Host: api.meeting.huaweicloud.com
User-Agent: Apache-HttpClient/4.5.3 (Java/1.8.0_191)

Example Response

HTTP/1.1 200 
Date: Wed, 18 Dec 2019 06:20:40 GMT
Content-Type: application/json;charset=UTF-8
Content-Length: 337
Connection: keep-alive
Expires: 0
Pragma: No-cache
Cache-Control: no-cache
http_proxy_id: 630c3bc684928cfa780860fe6a14f38f
Server: api-gateway
X-Request-Id: d689482097c019094f8aa41e57e52e8e

{
    "data": {
        "token": "stb15afe94b97a5cd7f152d5308c420dbdce85beda4a3b39f26",
        "tmpWsToken": "stba0a69f40a78e50f3789e72386f7da84809fbc86a1400bea5",
        "wsURL": "wss://119.3.200.83:443",
        "role": 1,
        "expireTime": 1576651143250,
        "userID": "ff808081699b56cb0169be103500012b",
        "orgID": "15659",
        "confTokenExpireTime": 1800,
        "vmrCurrentConfID": "914083901",
        "supportNotifyType": [
            "INCREMENT"
        ]
    },
    "addressToken": "stbWdPZ2ooVesQTWqZESu7AjVlH9Pv4O1KcQ",
    "gloablPublicIP": "meeting.huaweicloud.com"
}

Error Codes

If an error code starting with MMC or USG is returned when you use this API, rectify the fault by following the instructions provided in Huawei Cloud API Error Center.

Example cURL Command

curl -k -i -X GET -H 'X-Login-Type: 1' -H 'X-Password: ******' 'https://api.meeting.huaweicloud.com/v1/mmc/control/conferences/token?conferenceID=914083901'