tencent cloud

Mobile Live Video Broadcasting

Release Notes and Announcements
TUILiveKit Release Notes
Live SDK Release Notes
User Guide
Product Introduction
Overview
Strengths
Performance Statistics
Concepts
Purchase Guide
TRTC Live Billing Overview
Billing of Video Live Component
Activating the Service (TUILiveKit)
Free Demo
Demo
Run Demo(TUILiveKit)
Integration Guide
Video Live Streaming
Preparation
Host Live Streaming
Audience Viewing
Live Stream List Live Stream List
Voice Chat Room
Preparation
Host Live Streaming
Audience Viewing
Live Stream List
Live Streaming Kit
Live Streaming Kit(Electron Desktop Application)
Live Streaming Kit(Web Desktop Browser)
Live Broadcast Monitoring
Monitoring Webpage (Web Desktop Browser React)
Monitoring Webpage (Web Desktop Browser Vue)
UI Customization
Live Stream Video Component
Video Source Editing Canvas
Audience List Component
Barrage Component
Media Source Configuration Panel
Link Management Panel
Live Gift Component
No UI Integration
Video Live Streaming
Voice Chat Room
Feature Guide
Follow Anchors (TUILiveKit)
Ultimate Image Quality (TUILiveKit)
Push Media Stream Into Room (TUILiveKit)
Gift System (TUILiveKit)
Client APIs
Android
iOS
Web
Server APIs (TUILiveKit)
Account System
REST API
Third-Party Webhooks
Error Codes (TUILiveKit)
FAQs
Platform Compilation
User Authentication
Live SDK
Product Introduction
Purchase Guide
Free Demo
Free Trial License
SDK Download
Licenses
Advanced Features
Client API
FAQs
Integration (No UI)
API Documentation
OSS information
OSS Attribution Notice

Set Battle Score

PDF
Mode fokus
Ukuran font
Terakhir diperbarui: 2026-03-11 12:11:21

Feature Description

The app admin can use this API to set the scores of the rooms in Battle.

API Call Description

Request URL Sample:

https://xxxxxx/v4/live_engine_http_pk/set_battle_score?sdkappid=88888888&identifier=admin&usersig=xxx&random=99999999&contenttype=json

Description Of Request Parameters

The table below only lists the parameters involved in modifying when calling this API and their descriptions.
Parameters
Description
xxxxxx
The exclusive domain name corresponding to the country/region of SDKAppID:
China: console.tim.qq.com
Singapore: adminapisgp.im.qcloud.com
United States: adminapiusa.im.qcloud.com
v4/live_engine_http_pk/set_battle_score
Request API
sdkappid
The SDKAppID assigned by the Chat console when creating an application
identifier
Must be an App admin account. For more details, see App Admin
usersig
Signatures generated by the App admin account. For specific operations, see Generate UserSig
random
Please enter a random 32-bit unsigned integer, value range 0 - 4294967295
contenttype
The request format has a fixed value of json

Maximum Call Frequency

200 times/second.

Request Packet Sample

Basic form
{

"BattleId":"HuYM036AMk2JJeSUgnv5H0KDJpc+HXfqTAtGuYWzRPs=",
"OpType":1,
"ScoreList":[
{
"RoomId":"pk-live1",
"Score":100
},
{
"RoomId":"pk-live2",
"Score":100
}

]


}


Request Packet Field Description

Field
Type
Attribute
Description
BattleId
String
Required
The ID of battle
OpType
String
Required
Set type: 1 for accumulate, 2 for overwrite setting
ScoreList
Array
Required
Set score list
RoomId
String
Required
Room ID
Score
Integer
Required
The score corresponding to the room

Example Of a Response Packet Body

Basic form
{
"ErrorCode": 0,
"ErrorInfo": "",
"ActionStatus": "OK",
"RequestId": "Id-e7625183568d4058bd48c9924d4b1ed7-O-Seq-125382",
"Response": {
"Result": [
{
"RoomId": "pk-3",
"ResultCode": 0
},
{
"RoomId": "pk-4",
"ResultCode": 0
}
]
}
}

Response Packet Field Description

Field
Type
Description
ErrorCode
Integer
Error code, 0 indicates success, non-zero indicates failure.
ErrorInfo
String
Error message.
ActionStatus
String
Result of request processing, OK indicates success, FAIL indicates failure.
RequestId
String
Unique request ID, returned with each request, needed for troubleshooting.
Result
Array
Operation Result
ResultCode
Integer
Result, 0 indicates successful setting, 1 indicates a non-existent room.
RoomId
String
Room ID

Error Code Description

Unless a network error occurs (such as a 502 error), the HTTP return code for this API is always 200. The actual error code and error message are in the response packet body. Represented by `ErrorCode` and `ErrorInfo`.
Common error codes (60000 to 79999) refer to the Error Code document.
The private error codes of this API are as follows:
Error Code
Description
100001
Server internal error, please retry.
100002
The parameter is invalid. Check whether the request is correct according to the error description.
100006
The current PK has not started or has ended yet, and it is not allowed to set the score again.

Bantuan dan Dukungan

Apakah halaman ini membantu?

masukan