RequestOptions.ResourceTokenExpirySeconds Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets or sets the expiry time for resource token. Used when creating/updating/reading permissions in the Azure Cosmos DB service.
public int? ResourceTokenExpirySeconds { get; set; }
member this.ResourceTokenExpirySeconds : Nullable<int> with get, set
Public Property ResourceTokenExpirySeconds As Nullable(Of Integer)
Property Value
The expiry time in seconds for the resource token.
Remarks
When working with Azure Cosmos DB Users and Permissions, the way to instantiate an instance of DocumentClient is to get the Token for the resource the User wants to access and pass this to the authKeyOrResourceToken parameter of DocumentClient constructor
When requesting this Token, a RequestOption for ResourceTokenExpirySeconds can be used to set the length of time to elapse before the token expires. This value can range from 10 seconds, to 5 hours (or 18,000 seconds) The default value for this, should none be supplied is 1 hour (or 3,600 seconds).