LiteralTokenSource class

A token source that provides a fixed set of credentials without dynamic fetching.

This is useful for testing, development, or when you have pre-generated tokens that don't need to be refreshed dynamically.

For dynamic token fetching, use EndpointTokenSource or implement TokenSourceConfigurable.

Implemented types

Constructors

LiteralTokenSource({required String serverUrl, required String participantToken, String? participantName, String? roomName})
Initialize with fixed credentials.

Properties

hashCode → int
The hash code for this object.
no setterinherited
participantName → String?
The display name for the participant (optional).
final
participantToken → String
The JWT token for participant authentication.
final
roomName → String?
The name of the room to join (optional).
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
serverUrl → String
The LiveKit server URL to connect to.
final

Methods

fetch() → Future<TokenSourceResponse>
Returns the fixed credentials without any network requests.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited