Skip to content
v2.277.0

ParameterOptions Struct ​

Properties needed to create a new SSM Parameter.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_ssm as ssm } from 'aws-cdk-lib';
const parameterOptions: ssm.ParameterOptions = {
  allowedPattern: 'allowedPattern',
  description: 'description',
  parameterName: 'parameterName',
  simpleName: false,
  tier: ssm.ParameterTier.ADVANCED,
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_ssm as ssm

parameter_options = ssm.ParameterOptions(
    allowed_pattern="allowedPattern",
    description="description",
    parameter_name="parameterName",
    simple_name=False,
    tier=ssm.ParameterTier.ADVANCED
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.ssm.*;

ParameterOptions parameterOptions = ParameterOptions.builder()
        .allowedPattern("allowedPattern")
        .description("description")
        .parameterName("parameterName")
        .simpleName(false)
        .tier(ParameterTier.ADVANCED)
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.SSM;

var parameterOptions = new ParameterOptions {
    AllowedPattern = "allowedPattern",
    Description = "description",
    ParameterName = "parameterName",
    SimpleName = false,
    Tier = ParameterTier.ADVANCED
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

parameterOptions := &ParameterOptions{
	AllowedPattern: jsii.String("allowedPattern"),
	Description: jsii.String("description"),
	ParameterName: jsii.String("parameterName"),
	SimpleName: jsii.Boolean(false),
	Tier: awscdk.Aws_ssm.ParameterTier_ADVANCED,
}

Properties ​

allowedPatternoptionalstringallowed_patternoptionalstrallowedPatternoptionalStringAllowedPatternoptionalstringAllowedPatternoptional*string #
A regular expression used to validate the parameter value.

Default: no validation is performed

For example, for String types with values restricted to numbers, you can specify the following: ^\d+$

descriptionoptionalstringdescriptionoptionalstrdescriptionoptionalStringDescriptionoptionalstringDescriptionoptional*string = none #
Information about the parameter that you want to add to the system.
parameterNameoptionalstringparameter_nameoptionalstrparameterNameoptionalStringParameterNameoptionalstringParameterNameoptional*string #
The name of the parameter.

Default: a name will be generated by CloudFormation

simpleNameoptionalbooleansimple_nameoptionalboolsimpleNameoptionalBooleanSimpleNameoptionalboolSimpleNameoptional*bool #
Indicates whether the parameter name is a simple name.

Default: auto-detect based on parameterName

notes

A parameter name without any "/" is considered a simple name. If the parameter name includes "/", setting simpleName to true might cause unintended issues such as duplicate "/" in the resulting ARN.

This is required only if parameterName is a token, which means we are unable to detect if the name is simple or "path-like" for the purpose of rendering SSM parameter ARNs.

If parameterName is not specified, simpleName must be true (or undefined) since the name generated by AWS CloudFormation is always a simple name.

tieroptionalParameterTiertieroptionalParameterTiertieroptionalParameterTierTieroptionalParameterTierTieroptionalParameterTier = undefined #
The tier of the string parameter.