Options
All
  • Public
  • Public/Protected
  • All
Menu

@azure/keyvault-secrets

Package version

Index

Type aliases

ParsedWWWAuthenticate

ParsedWWWAuthenticate: {}

Type declaration

ValidParsedWWWAuthenticateProperties

ValidParsedWWWAuthenticateProperties: "authorization" | "resource" | "scope"

Variables

Const LATEST_API_VERSION

LATEST_API_VERSION: "7.1" = "7.1"

The latest supported KeyVault service API version

Const SDK_VERSION

SDK_VERSION: string = "4.2.0-beta.2"

Const logger

logger: any = createClientLogger("keyvault-secrets")

The @azure/logger configuration for this package.

Functions

challengeBasedAuthenticationPolicy

  • challengeBasedAuthenticationPolicy(credential: TokenCredential): RequestPolicyFactory

createSpan

  • createSpan(methodName: string, requestOptions?: RequestOptionsBase): Span
  • Creates a span using the tracer that was set by the user

    Parameters

    • methodName: string

      The name of the method creating the span.

    • Default value requestOptions: RequestOptionsBase = {}

    Returns Span

getSecretFromSecretBundle

  • getSecretFromSecretBundle(bundle: SecretBundle | DeletedSecretBundle): KeyVaultSecret

parseKeyVaultSecretId

  • Parses the given Key Vault Secret Id. An example is:

    https://.vault.azure.net/secrets//

    On parsing the above Id, this function returns:

      {
         sourceId: "https://<keyvault-name>.vault.azure.net/secrets/<secret-name>/<unique-version-id>",
         vaultUrl: "https://<keyvault-name>.vault.azure.net",
         version: "<unique-version-id>",
         name: "<secret-name>"
      }
    internal

    Parameters

    • id: string

      The Id of the Key Vault Secret.

    Returns KeyVaultSecretId

parseKeyvaultIdentifier

parseWWWAuthenticate

  • Parses an WWW-Authenticate response. This transforms a string value like: Bearer authorization="some_authorization", resource="https://some.url" into an object like: { authorization: "some_authorization", resource: "https://some.url" }

    Parameters

    • wwwAuthenticate: string

      String value in the WWW-Authenticate header

    Returns ParsedWWWAuthenticate

setParentSpan

  • setParentSpan(span: Span, options?: RequestOptionsBase): RequestOptionsBase
  • Returns updated HTTP options with the given span as the parent of future spans, if applicable.

    Parameters

    • span: Span

      The span for the current operation.

    • Default value options: RequestOptionsBase = {}

      The options for the underlying HTTP request.

    Returns RequestOptionsBase

Generated using TypeDoc