Table of Contents

Class OAuthHelper

Namespace
AntRunnerLib.Identity
Assembly
AntRunnerLib.dll

Gets an OAuth token for a given client ID and tenant ID.

public class OAuthHelper
Inheritance
System.Object
OAuthHelper
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()

Methods

GetToken(String, String, String[], String)

Gets an OAuth token for a given client ID and tenant ID.

public static async Task<string> GetToken(string clientId, string tenantId, string[] scopes, string redirectUri = "http://localhost")

Parameters

clientId System.String

The client ID, a unique identifier assigned to the client application.

tenantId System.String

The tenant ID, which identifies the organization or tenant.

scopes System.String[]

The permissions or scopes that the client application is requesting.

redirectUri System.String

The redirect URI where the authorization server will redirect the user after authentication. Default value is "http://localhost".

Returns

Task<System.String>

The OAuth token as a string.