Start a new project
There are several techniques you can use to start a new project to access AWS services. The following are some of those techniques:
-
If you're new to .NET development on AWS or at least new to the AWS SDK for .NET, you can see complete examples in Take a quick tour. It gives you an introduction to the SDK.
-
You can start a basic project by using the .NET CLI. To see an example of this, open a command prompt or terminal, create a folder or directory and navigate to it, and then enter the following.
dotnet new console --name [SOME-NAME]
An empty project is created to which you can add code and NuGet packages. For more information, see the .NET Core guide
. To see a list of project templates, use the following:
dotnet new --list
-
The AWS Toolkit for Visual Studio includes C# project templates for a variety of AWS services. After you install the toolkit in Visual Studio, you can access the templates while creating a new project.
To see this, go to Working with AWS services in the AWS Toolkit for Visual Studio User Guide. Several of the examples in that section create new projects.
-
If you develop with Visual Studio on Windows but without the AWS Toolkit for Visual Studio, use your typical techniques for creating a new project.
To see an example, open Visual Studio and choose File, New, Project. Search for ".net core" and choose the C# version of the Console App (.NET Core) or WPF App (.NET Core) template. An empty project is created to which you can add code and NuGet packages.
You can find some examples of how to work with AWS services in Code examples with guidance.
Important
If you're using AWS IAM Identity Center for authentication, your application must reference the following NuGet packages so that SSO resolution can work:
-
AWSSDK.SSO
-
AWSSDK.SSOOIDC
Failure to reference these packages will result in a runtime exception.