AWS SDK Version 2 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

.NET Framework 3.5
 
Credentials that are retrieved using the stored profile. The SDK Store is searched which is the credentials store shared with the SDK, PowerShell CLI and Toolkit. To manage the SDK Store with the SDK use Amazon.Util.ProfileManager. If the profile is not found in the SDK Store then credentials file shared with other AWS SDKs is searched. The credentials file is stored in the .aws directory in the current user's home directory.

The profile name can be specified in the App.config using the AWSProfileName setting.

The location to search for credentials can be overridden in the App.config using the AWSProfilesLocation setting.

Inheritance Hierarchy

System.Object
  Amazon.Runtime.AWSCredentials
    Amazon.Runtime.StoredProfileAWSCredentials

Namespace: Amazon.Runtime
Assembly: AWSSDK.dll
Version: (assembly version)

Syntax

C#
public class StoredProfileAWSCredentials : AWSCredentials

The StoredProfileAWSCredentials type exposes the following members

Constructors

NameDescription
Public Method StoredProfileAWSCredentials() Constructs an instance of StoredProfileAWSCredentials. This constructor searches for credentials using the account name specified in the App.config. If no account is specified then the default credentials are used.
Public Method StoredProfileAWSCredentials(string) Constructs an instance of StoredProfileAWSCredentials. Credentials will be searched for using the profileName parameter.
Public Method StoredProfileAWSCredentials(string, string) Constructs an instance of StoredProfileAWSCredentials. Credentials will be searched for using the profileName parameter.

Properties

NameTypeDescription
Public Property ProfileName System.String Name of the profile being used.
Public Property ProfilesLocation System.String Location of the profiles, if used.

Methods

NameDescription
Public Method GetCredentials() Returns an instance of ImmutableCredentials for this instance

Version Information

.NET Framework:
Supported in: 4.5, 4.0, 3.5