GenerateClientTokenOptions interface
Options for generating a token to connect a client to the Azure Web Pubsub service.
- Extends
Properties
expiration |
Minutes until the token expires. |
groups | The groups to join when the client connects |
roles | The roles that the connection with the generated token will have. Roles give the client initial permissions to leave, join, or publish to groups when using PubSub subprotocol
https://azure.github.io/azure-webpubsub/references/pubsub-websocket-subprotocol#permissions |
user |
The userId for the client. |
Inherited Properties
abort |
The signal which can be used to abort requests. |
on |
A function to be called each time a response is received from the server while performing the requested operation. May be called multiple times. |
request |
Options used when creating and sending HTTP requests for this operation. |
serializer |
Options to override serialization/de-serialization behavior. |
tracing |
Options used when tracing is enabled. |
Property Details
expirationTimeInMinutes
Minutes until the token expires.
expirationTimeInMinutes?: number
Property Value
number
groups
The groups to join when the client connects
groups?: string[]
Property Value
string[]
roles
The roles that the connection with the generated token will have. Roles give the client initial permissions to leave, join, or publish to groups when using PubSub subprotocol
webpubsub.joinLeaveGroup
: the client can join or leave any groupwebpubsub.sendToGroup
: the client can send messages to any groupwebpubsub.joinLeaveGroup.<group>
: the client can join or leave group<group>
webpubsub.sendToGroup.<group>
: the client can send messages to group<group>
https://azure.github.io/azure-webpubsub/references/pubsub-websocket-subprotocol#permissions
roles?: string[]
Property Value
string[]
userId
The userId for the client.
userId?: string
Property Value
string
Inherited Property Details
abortSignal
The signal which can be used to abort requests.
abortSignal?: AbortSignalLike
Property Value
Inherited From OperationOptions.abortSignal
onResponse
A function to be called each time a response is received from the server while performing the requested operation. May be called multiple times.
onResponse?: RawResponseCallback
Property Value
Inherited From OperationOptions.onResponse
requestOptions
Options used when creating and sending HTTP requests for this operation.
requestOptions?: OperationRequestOptions
Property Value
Inherited From OperationOptions.requestOptions
serializerOptions
Options to override serialization/de-serialization behavior.
serializerOptions?: SerializerOptions
Property Value
Inherited From OperationOptions.serializerOptions
tracingOptions
Options used when tracing is enabled.
tracingOptions?: OperationTracingOptions
Property Value
Inherited From OperationOptions.tracingOptions