OAuthApplicationCredential class final

A credential to access OAuth token-secured ArcGIS resources using the application's credentials.

The OAuth application credential generates a short-lived access token that gives your application permission to access token-secured ArcGIS content and services, such as the ArcGIS location services.

The OAuthApplicationCredential requires a private client secret. It is important to treat this as you would your password. You must keep it confidential and we recommended not storing in your application.

If you use this OAuthApplicationCredential as part of the secure resource challenge handling, it will be stored in the ArcGISCredentialStore of the AuthenticationManager. It can then be used by all subsequent requests that have a matching URL context.

Inheritance

Properties

clientId String
A unique identifier associated with an application registered with the portal that assists with client/server OAuth authentication.
no setter
hashCode int
The hash code for this object.
no setterinherited
portalUri Uri
The URL of the portal to authenticate with.
no setter
referer String
The referer used to generate a token.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
serverContext Uri
The URL by which the root of a server is accessed.
no setterinherited
tokenExpirationInterval int
The length of time a token credential remains valid. Represented in minutes. If not explicitly set, the server default is used.
no setter
username String
The user associated with the credential.
no setterinherited

Methods

getTokenInfo() Future<OAuthApplicationTokenInfo>
Returns an instance of OAuthApplicationTokenInfo generated by this credential.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Returns a JSON representation of this Object in the data type used by jsonDecode.
inherited
toJsonString() String
Returns a JSON representation of this Object as a String.
inherited
toString() String
A string representation of this object.
inherited

Operators

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

Static Methods

create({required Uri portalUri, required String clientId, required String clientSecret, int tokenExpirationInterval = 0}) Future<OAuthApplicationCredential>
Creates an OAuthApplicationCredential with information needed to access an ArcGIS resource.