Show / Hide Table of Contents

Struct TRTCParams

6.1. Room entry parameters

You can call `enterRoom` to enter the specified room successfully only if you set the parameters as required.

Inherited Members
System.ValueType.Equals(System.Object)
System.ValueType.GetHashCode()
System.ValueType.ToString()
System.Object.Equals(System.Object, System.Object)
System.Object.GetType()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: trtc
Assembly: cs.temp.dll.dll
Syntax
public struct TRTCParams

Fields

businessInfo

Description: business information (optional). This parameter is needed only for some advanced features.

**Value:** This parameter is not recommended.

Declaration
public String businessInfo
Field Value
Type Description
String

privateMapKey

Declaration
public String privateMapKey
Field Value
Type Description
String

role

Description: role in live streaming scenarios (TRTCAppSceneLIVE). This parameter is not available in call scenarios.

**Value:** default value: `TRTCRoleAnchor` (anchor)

Declaration
public TRTCRoleType role
Field Value
Type Description
TRTCRoleType

roomId

Description: numeric room ID (required). Users in the same room can see one another and have a video call.

**Value:** a custom value, which must be unique. You can use the user ID of the room creator – if it is numeric – as the room ID.

Declaration
public UInt32 roomId
Field Value
Type Description
UInt32

sdkAppId

Description: application ID (required). Tencent Video Cloud bills by sdkAppId.

After creating an application, you can view its `sdkAppId` on the **Application Info** page of the [TRTC console](https://console.cloud.tencent.com/trtc/).

Declaration
public UInt32 sdkAppId
Field Value
Type Description
UInt32

streamId

Description: stream ID bound to Tencent Cloud’s live streaming CDN (optional). If this parameter is specified, audience will be able to play the user’s stream via Tencent Cloud’s CDN using a standard streaming protocol (FLV or HLS).

**Value:** 64 bytes or shorter (optional). To make it easier to distinguish between different stream IDs and avoid application conflicts, we recommend that you set this parameter to `sdkappid_roomid_userid_main`.

**Note:** To use Tencent Cloud’s live streaming CDN, you need to enable relayed push on the **Function Configuration** page of the [console](https://console.cloud.tencent.com/trtc/).

**Reference:** [CDN Relayed Live Streaming](https://cloud.tencent.com/document/product/647/16826)

Declaration
public String streamId
Field Value
Type Description
String

strRoomId

Declaration
public String strRoomId
Field Value
Type Description
String

userDefineRecordId

Description: recording ID in the callback for on-cloud recording

**Value:** 64 bytes or shorter; support letters (a-z and A-Z), digits (0-9), underscores, and hyphens

**Reference:** [On-Cloud Recording and Playback](https://cloud.tencent.com/document/product/647/16823)

Declaration
public String userDefineRecordId
Field Value
Type Description
String

userId

Description: UTF-8-encoded user ID (required)

**Value:** If a user’s ID in your account system is `abc`, you can set `userId` to `abc`.

Declaration
public String userId
Field Value
Type Description
String

userSig

Description: user signature of the current user (required), which functions as the login password

**Value:** For how to calculate user signatures, please see [UserSig](https://cloud.tencent.com/document/product/647/17275).

Declaration
public String userSig
Field Value
Type Description
String
In This Article
Back to top Generated by DocFX