azure-sdk-for-js is a free, open source browsers & extensions project written in TypeScript and released under MIT. It has 2,296 GitHub stars, 1,397 forks and 680 open issues, and was last pushed 4 hours ago. On this registry it ranks #100 of 137 tracked projects in Browsers & Extensions, with 5 head-to-head comparisons available.

What is azure-sdk-for-js?

The Azure SDK for JavaScript is Microsoft's open-source monorepo of Node.js and browser libraries for the breadth of Azure services, built for JavaScript and TypeScript developers who need to provision Azure resources or consume them from application code.

What it is

This repository holds the Azure SDK for JavaScript, covering both Node.js and the browser, and it is written in TypeScript under the MIT licence. It contains libraries for the breadth of Azure services, split into two categories: management libraries, which are packages used to provision and manage Azure resources, and client libraries, which are packages used to consume those resources and interact with them. Client libraries assume an Azure resource already exists. Management libraries work through the Azure Resource Manager, or ARM, and are recognizable by @azure/arm- in their package names; they are purely auto-generated from the swagger files that represent the resource management APIs.

Most client libraries follow the Azure SDK Design Guidelines for JavaScript & TypeScript and share core functionality such as retries, logging, transport protocols, and authentication protocols, with others to be updated in the near future. Newer management libraries also follow the design guidelines and add shared capabilities including the Azure Identity library, an HTTP Pipeline with custom policies, error handling, and distributed tracing. The README notes that some packages have beta versions, and that code intended for production should use a stable, non-beta package.

The concrete problem it solves is the per-service DIY approach: instead of hand-writing HTTP calls and credential handling against each individual Azure service API, developers install packages that already implement retries, logging, transport, authentication, and tracing in a consistent shape. The library lives in the npm ecosystem, where each package is published and where its landing page carries the same readme found in the corresponding service folder under /sdk in this repository.

Key capabilities

  • Client libraries that consume existing Azure resources and interact with them from Node.js and browser code.
  • Management libraries identified by @azure/arm- package name prefixes, used to provision and manage Azure resources via Azure Resource Manager (ARM).
  • Management libraries auto-generated from the swagger files representing the resource management APIs.
  • Shared core behaviour across libraries: the Azure Identity library, an HTTP Pipeline with custom policies, error handling, distributed tracing, retries, logging, transport protocols, and authentication protocols.
  • Conformance to the Azure SDK Design Guidelines for JavaScript & TypeScript, with a releases page listing the client and management libraries that follow them.
  • A migration guide at documentation/MIGRATION-guide-for-next-generation-management-libraries.md covering the transition from older management library versions.
  • Separate stable and beta package tracks, with stable, non-beta packages recommended for production code.

Who uses it and how

  • Application teams consuming an Azure resource that already exists, from either a Node.js service or browser code.
  • Infrastructure and platform teams provisioning and managing Azure resources programmatically through the @azure/arm- management libraries.
  • Teams upgrading management packages, who must also update authentication code; the README points to the migration guide for the correct steps when authentication issues appear after an upgrade.
  • Developers reading API reference documentation, split between the public developer docs for latest versions and the versioned developer docs for older versions.
  • Contributors working in an active repository of 2,296 stars, 1,397 forks, and 680 open issues, with the hacktoberfest topic applied.

Getting started

Install the individual per-service package from npm and follow the readme in that package's folder under /sdk, which is repeated on the package landing page on npm. Latest API reference documentation is at the public developer docs, and older versions are at the versioned developer docs.

How it compares

The facts provided name no paid products that this project replaces, and they name no other comparable SDK or tool. It stands alone in this registry as the vendor's own monorepo of Azure client and management libraries for JavaScript and TypeScript.

When to use it — and when not to

Use it when the work is JavaScript or TypeScript against Azure and the goal is to consume existing resources with client libraries or to automate provisioning with @azure/arm- management libraries. Do not pick it for production code that depends on a beta package, since the README explicitly advises stable, non-beta packages when code must be production-ready, and do not treat this repository as the documentation channel: consumers are directed to the public developer docs and the versioned developer docs instead. The README excerpt supplied here is also cut off mid-sentence in its "Need help?" section, so the support and issue-filing details should be read from the full repository rather than from this summary.

project readme (upstream, from github) — read inline

Azure SDK for JavaScript

Packages Dependencies DependencyGraph

This repository is for the Azure SDK for JavaScript (Node.js & Browser). It contains libraries for the breadth of Azure services. Management libraries are packages that you would use to provision and manage Azure resources. Client libraries are packages that you would use to consume these resources and interact with them.

Getting started

A few helpful resources to get started are:

  • The readme for each package contains code samples and package information. This readme can be found in the corresponding package folder under the folder of the service of your choice in the /sdk folder of this repository. The same readme file can be found on the landing page for the package in npm.
  • The API reference documentation of the latest versions of these packages, can be found at our public developer docs.
  • The API reference documentation of older versions, can be found in our versioned developer docs.

Each service might have a number of libraries available from each of the following categories:

NOTE: Some of these packages have beta versions. If you need to ensure your code is ready for production, use one of the stable, non-beta packages.

Client

Given an Azure resource already exists, you would use the client libraries to consume it and interact with it. Most of these libraries follow the Azure SDK Design Guidelines for JavaScript & TypeScript and share a number of core functionalities such as retries, logging, transport protocols, authentication protocols, etc. Others will be updated in the near future to follow the guidelines as well.

To get a list of all client libraries that follow the new guidelines, please visit our Azure SDK releases page.

Management

Management libraries enable you to provision and manage Azure resources via the Azure Resource Manager i.e. ARM. You can recognize these libraries by @azure/arm- in their package names. These are purely auto-generated based on the swagger files that represent the APIs for resource management.

Newer versions of these libraries follow the Azure SDK Design Guidelines for TypeScript. These new versions provide a number of core capabilities that are shared amongst all Azure SDKs, including the intuitive Azure Identity library, an HTTP Pipeline with custom policies, error-handling, distributed tracing, and much more. A few helpful resources to get started with these are:

NOTE: If you are experiencing authentication issues with the management libraries after upgrading certain packages, it's possible that you upgraded to the new versions of SDK without changing the authentication code, please refer to the migration guide mentioned above for proper instructions.

Need help?

Data Collection

The software may collect information about you and your use of the software and send it to Microsoft. Microsoft may use this information to provide services and improve our products and services. You may turn off the telemetry as described below. You can learn more about data collection and use in the help documentation and Microsoft’s privacy statement. For more information on the data collected by the Azure SDK, please visit the Telemetry Guidelines page.

Telemetry Configuration

Telemetry collection is on by default.

To opt out, you can disable telemetry at client construction. Create a custom HTTP pipeline policy that removes the user agent string, and then pass that policy into the additionalPolicies option during client creation. This will disable telemetry for all methods in the client. Do this for every new client.

The example below uses the @azure/keyvault-secrets package. In your code, you can replace @azure/keyvault-secrets with the package you are using.

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

function removeUserAgentPolicy() {
  return {
    name: "removeUserAgentPolicy",
    sendRequest(request, next) {
      request.headers.delete("User-Agent");
      return next(request);
    },
  };
}

/**
 * Creates a SecretClient with managed identity authentication and empty user agent
 * @param keyvaultUri - The URI of the Azure Key Vault
 * @returns configured SecretClient instance
 */
function createSecretClientWithManagedIdentity(
  keyvaultUri: string
): SecretClient {
  // Create ManagedIdentityCredential for managed identity authentication
  const credential = new ManagedIdentityCredential();

  // Create secret client with managed identity and empty user agent
  const secretClient = new SecretClient(keyvaultUri, credential, {
    additionalPolicies: [
      {
        position: "perCall",
        policy: removeUserAgentPolicy(),
      },
    ],
  });

  return secretClient;
}

// Usage example
const keyvaultUri = "https://your-keyvault-name.vault.azure.net";
const secretClient = createSecretClientWithManagedIdentity(keyvaultUri);

// Now you can use the secret client to perform operations
// For example:
// const secretValue = await secretClient.getSecret("your-secret-name");

Community

Try our community resources.

Reporting security issues and security bugs

Security issues and bugs should be reported privately, via email, to the Microsoft Security Response Center (MSRC) . You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Further information, including the MSRC PGP key, can be found in the Security TechCenter.

Contributing

For details on contributing to this repository, see the contributing guide.

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit .

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repositories using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information, see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

Frequently asked questions

Is azure-sdk-for-js free to use?

azure-sdk-for-js is open source under the MIT licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does azure-sdk-for-js do?

This repository is for active development of the Azure SDK for JavaScript (NodeJS & Browser). For consumers of the SDK we recommend visiting our public develope

What is azure-sdk-for-js written in?

azure-sdk-for-js is primarily written in TypeScript. Its source is publicly available at https://github.com/Azure/azure-sdk-for-js, and it has 2,296 GitHub stars.