GetConfiguration - Amazon AppConfig
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).


(Deprecated) Retrieves the latest deployed configuration.


Note the following important information.

Request Syntax

GET /applications/Application/environments/Environment/configurations/Configuration?client_configuration_version=ClientConfigurationVersion&client_id=ClientId HTTP/1.1

URI Request Parameters

The request uses the following URI parameters.


The application to get. Specify either the application name or the application ID.

Length Constraints: Minimum length of 1. Maximum length of 64.

Required: Yes


The configuration version returned in the most recent GetConfiguration response.


Amazon AppConfig uses the value of the ClientConfigurationVersion parameter to identify the configuration version on your clients. If you don’t send ClientConfigurationVersion with each call to GetConfiguration, your clients receive the current configuration. You are charged each time your clients receive a configuration.

To avoid excess charges, we recommend you use the StartConfigurationSession and GetLatestConfiguration APIs, which track the client configuration version on your behalf. If you choose to continue using GetConfiguration, we recommend that you include the ClientConfigurationVersion value with every call to GetConfiguration. The value to use for ClientConfigurationVersion comes from the ConfigurationVersion attribute returned by GetConfiguration when there is new or updated data, and should be saved for subsequent calls to GetConfiguration.

For more information about working with configurations, see Retrieving the Configuration in the Amazon AppConfig User Guide.

Length Constraints: Minimum length of 1. Maximum length of 1024.


The clientId parameter in the following command is a unique, user-specified ID to identify the client for the configuration. This ID enables Amazon AppConfig to deploy the configuration in intervals, as defined in the deployment strategy.

Length Constraints: Minimum length of 1. Maximum length of 64.

Required: Yes


The configuration to get. Specify either the configuration name or the configuration ID.

Length Constraints: Minimum length of 1. Maximum length of 64.

Required: Yes


The environment to get. Specify either the environment name or the environment ID.

Length Constraints: Minimum length of 1. Maximum length of 64.

Required: Yes

Request Body

The request does not have a request body.

Response Syntax

HTTP/1.1 200 Configuration-Version: ConfigurationVersion Content-Type: ContentType Content

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The response returns the following HTTP headers.


The configuration version.

Length Constraints: Minimum length of 1. Maximum length of 1024.


A standard MIME type describing the format of the configuration content. For more information, see Content-Type.

The response returns the following as the HTTP body.


The content of the configuration or the configuration data.


The Content attribute only contains data if the system finds new or updated configuration data. If there is no new or updated data and ClientConfigurationVersion matches the version of the current configuration, Amazon AppConfig returns a 204 No Content HTTP response code and the Content value will be empty.


For information about the errors that are common to all actions, see Common Errors.


The input fails to satisfy the constraints specified by an Amazon service.

HTTP Status Code: 400


There was an internal failure in the Amazon AppConfig service.

HTTP Status Code: 500


The requested resource could not be found.

HTTP Status Code: 404



This example illustrates one usage of GetConfiguration.

Sample Request

GET /applications/test-application/environments/Example-Environment/configurations/Example-Configuration-Profile?client_id=test-id HTTP/1.1 Host: Accept-Encoding: identity User-Agent: aws-cli/2.2.4 Python/3.8.8 Linux/5.4.134-73.228.amzn2int.x86_64 exe/x86_64.amzn.2 prompt/off command/appconfig.get-configuration X-Amz-Date: 20210917T215745Z Authorization: AWS4-HMAC-SHA256 Credential=AKIAIOSFODNN7EXAMPLE/20210917/us-east-1/appconfig/aws4_request, SignedHeaders=host;x-amz-date, Signature=39c3b3042cd2aEXAMPLE

Sample Response

{ "ConfigurationVersion": "1", "ContentType": "application/octet-stream" }

See Also

For more information about using this API in one of the language-specific Amazon SDKs, see the following: