ApiKeyAuthenticationPolicy Class

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.

A PipelinePolicy that uses an ApiKeyCredential to set a value on a PipelineRequest to authenticate with the cloud service.

C#
public class ApiKeyAuthenticationPolicy : System.ClientModel.Primitives.PipelinePolicy
Inheritance
ApiKeyAuthenticationPolicy

Methods

CreateBasicAuthorizationPolicy(ApiKeyCredential)

Create a new instance of the ApiKeyAuthenticationPolicy class, where the credential value will be set in the Authorization header on the PipelineRequest with a Basic prefix.

CreateBearerAuthorizationPolicy(ApiKeyCredential)

Create a new instance of the ApiKeyAuthenticationPolicy class, where the credential value will be set in the Authorization header on the PipelineRequest with a Bearer prefix.

CreateHeaderApiKeyPolicy(ApiKeyCredential, String, String)

Create a new instance of the ApiKeyAuthenticationPolicy class, where the credential value will be specified in a request header.

Process(PipelineMessage, IReadOnlyList<PipelinePolicy>, Int32)

Process the provided PipelineMessage according to the intended purpose of this PipelinePolicyinstance. Derived types must pass control to the next PipelinePolicy in the pipeline by calling ProcessNext(PipelineMessage, IReadOnlyList<PipelinePolicy>, Int32).

ProcessAsync(PipelineMessage, IReadOnlyList<PipelinePolicy>, Int32)

Process the provided PipelineMessage according to the intended purpose of this PipelinePolicyinstance. Derived types must pass control to the next PipelinePolicy in the pipeline by calling ProcessNextAsync(PipelineMessage, IReadOnlyList<PipelinePolicy>, Int32).

Applies to

منتج الإصدارات
Azure SDK for .NET Latest, Preview