Method CreateAsync
CreateAsync(Uri, String, String, TimeSpan, CancellationToken)
Creates an OAuth
Declaration
public static Task<OAuthApplicationCredential> CreateAsync(Uri portalUrl, string clientId, string clientSecret, TimeSpan tokenExpirationInterval = default(TimeSpan), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
System. |
portalUrl | The URL of the portal to authenticate with. |
System. |
clientId | A unique identifier associated with an application registered with the portal that assists with client/server OAuth authentication. |
System. |
clientSecret | A private key that verifies the application is authorized to access the registered service. |
System. |
tokenExpirationInterval | The duration the token will remain valid, represented in minutes. The value must be at least 1 minute, otherwise the server default is used. |
System. |
cancellationToken | Cancellation token |
Returns
Type | Description |
---|---|
System. |
Returns an OAuth |
Applies to
Platforms and versions
Target | Versions |
---|---|
.NET Standard 2.0 | 200.5 - 200.6 |
.NET | 200.5 - 200.6 |
.NET Windows | 200.5 - 200.6 |
.NET Android | 200.5 - 200.6 |
.NET iOS | 200.5 - 200.6 |
.NET Framework | 200.5 - 200.6 |
UWP | 200.5 - 200.6 |