title | description | ms.date | author | ms.author | ms.topic |
---|---|---|---|---|---|
Azure .NET APIs |
Overview of the Azure APIs for .NET |
10/19/2017 |
CamSoper |
casoper |
conceptual |
The Azure .NET APIs let you use Azure services and manage Azure resources from your application code. The APIs are available as NuGet packages for use in your .NET projects.
The Azure libraries for .NET let you create and manage Azure resources from your .NET applications.
Many of the packages for managing Azure resources have a fluent interface to configure resources exactly to your specifications. For example, to create a Windows VM you would write the following code:
var windowsVM = azure.VirtualMachines.Define(windowsVmName)
.WithRegion(Region.USEast)
.WithNewResourceGroup(rgName)
.WithNewPrimaryNetwork("10.0.0.0/28")
.WithPrimaryPrivateIPAddressDynamic()
.WithNewPrimaryPublicIPAddress(publicIpDnsLabel)
.WithPopularWindowsImage(KnownWindowsVirtualMachineImage.WindowsServer2012R2Datacenter)
.WithAdminUsername(username)
.WithAdminPassword(password)
.WithSize(VirtualMachineSizeTypes.StandardD3V2)
.Create();
Review the .NET service list to start using the libraries immediately with your projects. Then read the get started article to set up authentication and run sample code against your own Azure subscription. The concepts article goes into the conventions the SDK uses and how to leverage them to simplify your application code. New features, breaking changes, and migration instructions are available in the release notes.
In addition to using .NET APIs to create and programmatically manage resources within Azure, you can also then use .NET APIs to connect your applications to these resources and use them at runtime. For example, you might connect to a SQL Database or store data within Azure Storage. You can identify which NuGet package to use for a particular Azure service by browsing our full list of service APIs.
The following samples cover common automation tasks with the Azure libraries for .NET:
A unified reference is available for all packages in both the service and management libraries. New features, breaking changes, and migration instructions are available in the release notes.
[!includeContribute and community]