Menu
AWS Systems Manager
API Reference (API Version 2014-11-06)

PutParameter

Add one or more parameters to the system.

Request Syntax

{ "AllowedPattern": "string", "Description": "string", "KeyId": "string", "Name": "string", "Overwrite": boolean, "Type": "string", "Value": "string" }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

AllowedPattern

A regular expression used to validate the parameter value. For example, for String types with values restricted to numbers, you can specify the following: AllowedPattern=^\d+$

Type: String

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

Required: No

Description

Information about the parameter that you want to add to the system.

Type: String

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

Required: No

KeyId

The KMS Key ID that you want to use to encrypt a parameter when you choose the SecureString data type. If you don't specify a key ID, the system uses the default key associated with your AWS account.

Type: String

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

Pattern: ^([a-zA-Z0-9:/_-]+)$

Required: No

Name

The fully qualified name of the parameter that you want to add to the system. The fully qualified name includes the complete hierarchy of the parameter path and name. For example: /Dev/DBServer/MySQL/db-string13

Note

The maximum length constraint listed below includes capacity for additional system attributes that are not part of the name. The maximum length for the fully qualified parameter name is 1011 characters.

Type: String

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

Required: Yes

Overwrite

Overwrite an existing parameter. If not specified, will default to "false".

Type: Boolean

Required: No

Type

The type of parameter that you want to add to the system.

Type: String

Valid Values: String | StringList | SecureString

Required: Yes

Value

The parameter value that you want to add to the system.

Type: String

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

Required: Yes

Response Syntax

{ "Version": number }

Response Elements

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

The following data is returned in JSON format by the service.

Version

The new version number of a parameter. If you edit a parameter value, Parameter Store automatically creates a new version and assigns this new version a unique ID. You can reference a parameter version ID in API actions or in Systems Manager documents (SSM documents). By default, if you don't specify a specific version, the system returns the latest parameter value when a parameter is called.

Type: Long

Errors

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

HierarchyLevelLimitExceededException

A hierarchy can have a maximum of five levels. For example:

/Finance/Prod/IAD/OS/WinServ2016/license15

For more information, see Working with Systems Manager Parameters.

HTTP Status Code: 400

HierarchyTypeMismatchException

Parameter Store does not support changing a parameter type in a hierarchy. For example, you can't change a parameter from a String type to a SecureString type. You must create a new, unique parameter.

HTTP Status Code: 400

InternalServerError

An error occurred on the server side.

HTTP Status Code: 400

InvalidAllowedPatternException

The request does not meet the regular expression requirement.

HTTP Status Code: 400

InvalidKeyId

The query key ID is not valid.

HTTP Status Code: 400

ParameterAlreadyExists

The parameter already exists. You can't create duplicate parameters.

HTTP Status Code: 400

ParameterLimitExceeded

You have exceeded the number of parameters for this AWS account. Delete one or more parameters and try again.

HTTP Status Code: 400

ParameterMaxVersionLimitExceeded

The parameter exceeded the maximum number of allowed versions.

HTTP Status Code: 400

ParameterPatternMismatchException

The parameter name is not valid.

HTTP Status Code: 400

TooManyUpdates

There are concurrent updates for a resource that supports one update at a time.

HTTP Status Code: 400

UnsupportedParameterType

The parameter type is not supported.

HTTP Status Code: 400

See Also

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