AuthorizationCodeCredential Constructors
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.
Overloads
AuthorizationCodeCredential() |
Protected constructor for mocking. |
AuthorizationCodeCredential(String, String, String, String) |
Creates an instance of the ClientSecretCredential with the details needed to authenticate against Microsoft Entra ID with a prefetched authorization code. |
AuthorizationCodeCredential(String, String, String, String, AuthorizationCodeCredentialOptions) |
Creates an instance of the ClientSecretCredential with the details needed to authenticate against Microsoft Entra ID with a prefetched authorization code. |
AuthorizationCodeCredential()
Protected constructor for mocking.
protected AuthorizationCodeCredential ();
Protected Sub New ()
Applies to
AuthorizationCodeCredential(String, String, String, String)
Creates an instance of the ClientSecretCredential with the details needed to authenticate against Microsoft Entra ID with a prefetched authorization code.
public AuthorizationCodeCredential (string tenantId, string clientId, string clientSecret, string authorizationCode);
new Azure.Identity.AuthorizationCodeCredential : string * string * string * string -> Azure.Identity.AuthorizationCodeCredential
Public Sub New (tenantId As String, clientId As String, clientSecret As String, authorizationCode As String)
Parameters
- tenantId
- String
The Microsoft Entra tenant (directory) ID of the service principal.
- clientId
- String
The client (application) ID of the service principal
- clientSecret
- String
A client secret that was generated for the App Registration used to authenticate the client.
- authorizationCode
- String
The authorization code obtained from a call to authorize. The code should be obtained with all required scopes. See https://learn.microsoft.com/entra/identity-platform/v2-oauth2-auth-code-flow for more information.
Applies to
AuthorizationCodeCredential(String, String, String, String, AuthorizationCodeCredentialOptions)
Creates an instance of the ClientSecretCredential with the details needed to authenticate against Microsoft Entra ID with a prefetched authorization code.
public AuthorizationCodeCredential (string tenantId, string clientId, string clientSecret, string authorizationCode, Azure.Identity.AuthorizationCodeCredentialOptions options);
new Azure.Identity.AuthorizationCodeCredential : string * string * string * string * Azure.Identity.AuthorizationCodeCredentialOptions -> Azure.Identity.AuthorizationCodeCredential
Public Sub New (tenantId As String, clientId As String, clientSecret As String, authorizationCode As String, options As AuthorizationCodeCredentialOptions)
Parameters
- tenantId
- String
The Microsoft Entra tenant (directory) ID of the service principal.
- clientId
- String
The client (application) ID of the service principal
- clientSecret
- String
A client secret that was generated for the App Registration used to authenticate the client.
- authorizationCode
- String
The authorization code obtained from a call to authorize. The code should be obtained with all required scopes. See https://learn.microsoft.com/entra/identity-platform/v2-oauth2-auth-code-flow for more information.
Options that allow to configure the management of the requests sent to Microsoft Entra ID.