Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildToken ¶
func BuildToken(appId string, appCertificate string, userId string, expire uint32, streamName string) (string, error)
BuildToken creates an access token with the specified parameters. If streamName is provided, it adds the RTC service with the given streamName.
Parameters:
- appId: The application ID for the access token.
- appCertificate: The application certificate for the access token.
- userId: The user ID for the access token.
- expire: The expiration time in seconds for the access token.
- streamName: The name of the stream (optional).
Returns:
- The generated access token as a string.
- An error if there was an issue generating the token.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.