Show / Hide Table of Contents

Method CreateAsync

CreateAsync(OAuthUserConfiguration, CancellationToken)

Creates an OAuthUserCredential with information needed to access an ArcGIS resource. This initiates the OAuth login process by presenting the OAuth login page.

Declaration
public static Task<OAuthUserCredential> CreateAsync(OAuthUserConfiguration configuration, CancellationToken cancellationToken = default)
Parameters
Type Name Description
OAuthUserConfiguration configuration

The OAuth configuration details of an application that can sign into an ArcGIS Online or ArcGIS Enterprise portal using OAuth.

CancellationToken cancellationToken

Cancellation token.

Returns
Type Description
Task<OAuthUserCredential>

A task that represents the asynchronous creation operation. The value of the task result is an OAuthUserCredential.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0200.6 - 200.8
.NET200.6 - 300.0
.NET Windows200.6 - 300.0
.NET Android200.6 - 300.0
.NET iOS200.6 - 300.0
.NET Framework200.6 - 200.8
UWP200.6 - 200.8

CreateAsync(OAuthUserConfiguration, object?, CancellationToken)

Creates an OAuthUserCredential with information needed to access an ArcGIS resource. This initiates the OAuth login process by presenting the OAuth login page.

Declaration
public static Task<OAuthUserCredential> CreateAsync(OAuthUserConfiguration configuration, object? state, CancellationToken cancellationToken = default)
Parameters
Type Name Description
OAuthUserConfiguration configuration

The OAuth configuration details of an application that can sign into an ArcGIS Online or ArcGIS Enterprise portal using OAuth.

object state

An optional state object passed to the logout callback's State parameter.

CancellationToken cancellationToken

Cancellation token.

Returns
Type Description
Task<OAuthUserCredential>

A task that represents the asynchronous creation operation. The value of the task result is an OAuthUserCredential.

Applies to

Platforms and versions
TargetVersions
.NET300
.NET Windows300
.NET Android300
.NET iOS300
In this article
Provide feedback
Back to top Copyright © 2025 Esri.