All Products
Search
Document Center

Server Load Balancer:API key authentication component

Last Updated:Apr 01, 2026

The API key authentication component validates incoming requests by extracting an API key from the HTTP request and checking it against a list of trusted credentials. Configure the component to read the key from a URL parameter, request header, or cookie.

Feature category: Authentication and authorization

Field descriptions

ComponentConfig

ParameterTypeRequiredDefaultDescription
ConfigApiKeyConfigYes-The API key authentication configuration.

ApiKeyConfig

ParameterTypeRequiredDefaultDescription
ApiKeySourcesApiKeySourcesConfigYes-Where to extract the API key from. Only one extraction source is supported.
ApiKeyCredentialsApiKeyCredential[]Yes-The list of trusted API key credentials to validate against.

ApiKeySourcesConfig

Specify exactly one of the following fields. The component reads the API key from the configured source.

ParameterTypeRequiredDefaultDescription
HeadersString[]No-The request headers to extract the API key from.
ParamsString[]No-The URL parameters to extract the API key from.
CookiesString[]No-The cookies to extract the API key from.

ApiKeyCredential

ParameterTypeRequiredDefaultDescription
ProviderApiKeyCredentialProviderYesSystemThe credential type. Valid values: System, Custom.
CredentialStringConditional-The API key string. Required when Provider is Custom. Length: 8–512 characters.

ApiKeyCredentialProvider

ValueDescription
SystemA system-generated credential.
CustomA user-uploaded credential.

Error codes

HTTP status codeError messageCause
401Client authentication failed.API key verification failed. The API key is invalid or missing.