Azure Key Vault JavaScript SDK

API Reference

The Azure Key Vault JavaScript SDK provides a set of client libraries to interact with secrets, keys, and certificates stored in Azure Key Vault.

Clients

SecretsClient

Manage secrets: create, retrieve, update, delete.

View Docs →

KeysClient

Operations for creating, importing, and managing keys.

View Docs →

CertificatesClient

Handle certificate creation, import, and lifecycle.

View Docs →

CryptographyClient

Perform cryptographic operations using keys stored in Key Vault.

View Docs →

Getting Started Example

Below is a quick example showing how to retrieve a secret using SecretsClient.

import { SecretClient } from "@azure/keyvault-secrets";
import { DefaultAzureCredential } from "@azure/identity";

const credential = new DefaultAzureCredential();
const vaultUrl = "https://<YOUR-KEYVAULT-NAME>.vault.azure.net";

async function getSecret(name) {
  const client = new SecretClient(vaultUrl, credential);
  const secret = await client.getSecret(name);
  console.log(`Secret: ${secret.name} = ${secret.value}`);
}

getSecret("mySecret");

Full Reference

Explore the full class reference on the individual pages linked above. Each page includes method signatures, overloads, and code snippets.