Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Type aliases

AudioMusicParam

AudioMusicParam: { endTimeMS?: number; id: number; isShortFile?: boolean; loopCount?: number; path: string; publish?: boolean; startTimeMS?: number }
  • Music and audio effect API parameters

Type declaration

  • Optional endTimeMS?: number
    • Description: end time (ms) for music playback. 0 or -1 means to play the music to the end.
  • id: number
    • Description: music ID
    • Note: The SDK allows you to play multiple music tracks. You use music ID to identify a music track and control its playback, volume, etc.
  • Optional isShortFile?: boolean
    • Description: whether to play a short music file
    • Value: YES: short music track that needs to be looped; NO (default): normal-length music track
  • Optional loopCount?: number
    • Description: music loop times
    • Value: 0 (default value) or any positive integer. 0 indicates that the music is played once, 1 twice, and so on.
  • path: string
    • Description: absolute path of a music file
  • Optional publish?: boolean
    • Description: whether to send music to remote users
    • Value: YES: publish the music played locally to the cloud so that remote users can hear it; NO (default): play the music locally only and do not publish it
  • Optional startTimeMS?: number
    • Description: start time (ms) for music playback

TRTCAudioRecordingParams

TRTCAudioRecordingParams: { filePath: string }
  • Audio recording parameters
  • Description: the path to save the recording file (required). You need to specify a custom path and make sure that the path exists and is writable.
  • Note: The path must contain the filename and extension. The extension determines the format of the recording file. Supported formats include PCM, WAV, and AAC. For example, if you set this parameter to path/to/audio.aac, the recording file will be in AAC format. Please use a valid path that is readable and writable so that the recording file can be generated successfully.

Type declaration

  • filePath: string

TRTCPublishCDNParam

TRTCPublishCDNParam: { appId: number; bizId: number; url: string }
  • CDN relaying parameters

Type declaration

  • appId: number
    • Tencent Cloud appId. In the TRTC console, find the application you created, and click Application Info to view its ID in the Relayed Live Streaming Info section.
  • bizId: number
    • CSS bizid. In the TRTC console, find the application you created, and click Application Info to view its bizid in the Relayed Live Streaming Info section.
  • url: string
    • Relayed push URL

TRTCSwitchRoomConfig

TRTCSwitchRoomConfig: { privateMapKey?: string; roomId?: number; strRoomId?: string; userSig: string }
  • Room switch parameters

Type declaration

  • Optional privateMapKey?: string
    • Description: room signature (optional). You can use this parameter to allow only specified users (userId) to enter a room.
    • Value: Use this parameter only if you have high security requirements. For more information, please see Enabling Advanced Permission Control.
  • Optional roomId?: number
    • Description: numeric room ID (required). Users (userId) in the same room can see one another and make a video call.
    • Value: value range: 1-4294967294
  • Optional strRoomId?: string
    • Description: string-type room ID (optional). Users in the same room can see one another and make a video call.
    • Note: You must specify either roomId or strRoomId. If both are specified, roomId will be used.
  • userSig: string
    • Description: user signature (required) of the current userId, which functions as the login password for Tencent Cloud services
    • Value: For how to calculate user signatures, please see UserSig.

Generated using TypeDoc