Megosztás a következőn keresztül:


Microsoft Azure Storage management client library for .NET

Microsoft Azure Storage is a Microsoft-managed service providing cloud storage that is highly available, secure, durable, scalable, and redundant.

This library supports managing Microsoft Azure Storage resources, including the creation of new storage accounts.

This library follows the new Azure SDK guidelines, and provides many core capabilities:

- Support MSAL.NET, Azure.Identity is out of box for supporting MSAL.NET.
- Support [OpenTelemetry](https://opentelemetry.io/) for distributed tracing.
- HTTP pipeline with custom policies.
- Better error-handling.
- Support uniform telemetry across all languages.

Getting started

Install the package

Install the Microsoft Azure Storage management library for .NET with NuGet:

dotnet add package Azure.ResourceManager.Storage

Prerequisites

First, to install the Microsoft Azure Identity package:

dotnet add package Azure.Identity

Set up a way to authenticate to Microsoft Azure with Azure Identity.

Some options are:

More information and different authentication approaches using Microsoft Azure Identity can be found in this document.

Authenticate the Client

The default option to create an authenticated client is to use DefaultAzureCredential. Since all management APIs go through the same endpoint, in order to interact with resources, only one top-level ArmClient has to be created.

To authenticate to Microsoft Azure and create an ArmClient, do the following code:

using Azure.Identity;
using Azure.ResourceManager;
ArmClient armClient = new ArmClient(new DefaultAzureCredential());

More documentation for the Azure.Identity.DefaultAzureCredential class can be found in this document.

Key concepts

Key concepts of the Microsoft Azure SDK for .NET can be found here

Examples

Troubleshooting

Next steps

For more information about Microsoft Azure SDK, see this website.

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 https://cla.microsoft.com.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (for example, label, comment). Follow the instructions provided by the bot. You'll only need to do this action 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 opencode@microsoft.com with any other questions or comments.