TwilioCustomTokenOptions
Defined in: lib/token/twilio-token.interface.ts:114
Options for a token carrying grants you construct yourself: TaskRouter, Playback, or several grants at once.
Extends
Section titled “Extends”Properties
Section titled “Properties”| Property | Type | Description | Inherited from | Defined in |
|---|---|---|---|---|
grants |
TwilioGrant[] |
Grants to attach. At least one is required for a usable token. | - | lib/token/twilio-token.interface.ts:116 |
identity |
string |
Identity the token represents, normally a username in your system. Voice tokens accept only alphanumeric characters and underscores; this is enforced when minting a Voice token. | TwilioTokenOptions.identity |
lib/token/twilio-token.interface.ts:34 |
nbf? |
number |
Epoch seconds before which the token is not accepted. | TwilioTokenOptions.nbf |
lib/token/twilio-token.interface.ts:44 |
region? |
string |
Twilio Region for the token. Currently honoured for Voice tokens only. See https://www.twilio.com/docs/global-infrastructure/understanding-twilio-regions | TwilioTokenOptions.region |
lib/token/twilio-token.interface.ts:51 |
ttl? |
number |
Lifetime in seconds. Defaults to the SDK’s 3600. Twilio caps tokens at 24 hours (86400), and recommends the shortest lifetime your application can tolerate. | TwilioTokenOptions.ttl |
lib/token/twilio-token.interface.ts:41 |