Amazon Simple Systems Manager (SSM)
    Amazon Simple Systems Manager (SSM)
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST
    • /
      POST

      /

      The Amazon SSM multi-region endpoint
      http://ssm.{region}.amazonaws.com
      The Amazon SSM multi-region endpoint
      http://ssm.{region}.amazonaws.com
      POST
      /
      Updates an association. You can update the association name and version, the document version, schedule, parameters, and Amazon Simple Storage Service (Amazon S3) output. When you call UpdateAssociation, the system removes all optional parameters from the request and overwrites the association with null values for those parameters. This is by design. You must specify all optional parameters in the call, even if you are not changing the parameters. This includes the Name parameter. Before calling this API action, we recommend that you call the DescribeAssociation API operation and make a note of all optional parameters required for your UpdateAssociation call.
      In order to call this API operation, a user, group, or role must be granted permission to call the DescribeAssociation API operation. If you don't have permission to call DescribeAssociation, then you receive the following error: An error occurred (AccessDeniedException) when calling the UpdateAssociation operation: User: <user_arn> isn't authorized to perform: ssm:DescribeAssociation on resource: <resource_arn>
      Request Request Example
      Shell
      JavaScript
      Java
      Swift
      curl --location -g --request POST 'http://ssm.{region}.amazonaws.com/' \
      --header 'X-Amz-Target;' \
      --header 'Content-Type: application/json' \
      --data-raw '{
          "AssociationId": "string",
          "Parameters": {
              "property1": [
                  "string"
              ],
              "property2": [
                  "string"
              ]
          },
          "DocumentVersion": "string",
          "ScheduleExpression": "string",
          "OutputLocation": {
              "S3Location": {
                  "OutputS3Region": "string",
                  "OutputS3BucketName": "string",
                  "OutputS3KeyPrefix": "string"
              }
          },
          "Name": "string",
          "Targets": [],
          "AssociationName": "string",
          "AssociationVersion": "string",
          "AutomationTargetParameterName": "string",
          "MaxErrors": "string",
          "MaxConcurrency": "string",
          "ComplianceSeverity": "CRITICAL",
          "SyncCompliance": "AUTO",
          "ApplyOnlyAtCronInterval": true,
          "CalendarNames": [],
          "TargetLocations": [],
          "ScheduleOffset": 0,
          "TargetMaps": [],
          "AlarmConfiguration": {
              "IgnorePollAlarmFailure": true,
              "Alarms": []
          }
      }'
      Response Response Example
      200 - Example 1
      {
          "AssociationDescription": {
              "Name": "string",
              "InstanceId": "string",
              "AssociationVersion": "string",
              "Date": "string",
              "LastUpdateAssociationDate": "string",
              "Status": {
                  "Date": "string",
                  "Name": "Pending",
                  "Message": "string",
                  "AdditionalInfo": "string"
              },
              "Overview": {
                  "Status": "string",
                  "DetailedStatus": "string",
                  "AssociationStatusAggregatedCount": {
                      "property1": 0,
                      "property2": 0
                  }
              },
              "DocumentVersion": "string",
              "AutomationTargetParameterName": "string",
              "Parameters": {
                  "property1": [
                      "string"
                  ],
                  "property2": [
                      "string"
                  ]
              },
              "AssociationId": "string",
              "Targets": [],
              "ScheduleExpression": "string",
              "OutputLocation": {
                  "S3Location": {
                      "OutputS3Region": "string",
                      "OutputS3BucketName": "string",
                      "OutputS3KeyPrefix": "string"
                  }
              },
              "LastExecutionDate": "string",
              "LastSuccessfulExecutionDate": "string",
              "AssociationName": "string",
              "MaxErrors": "string",
              "MaxConcurrency": "string",
              "ComplianceSeverity": "CRITICAL",
              "SyncCompliance": "AUTO",
              "ApplyOnlyAtCronInterval": true,
              "CalendarNames": [],
              "TargetLocations": [],
              "ScheduleOffset": 0,
              "TargetMaps": [],
              "AlarmConfiguration": {
                  "IgnorePollAlarmFailure": true,
                  "Alarms": []
              },
              "TriggeredAlarms": []
          }
      }

      Request

      Header Params
      X-Amz-Target
      string 
      required
      Body Params application/json
      AssociationId
      string 
      required
      The ID of the association you want to update.
      Match pattern:
      [0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}
      Parameters
      object 
      optional
      The parameters you want to update for the association. If you create a parameter using Parameter Store, a capability of Amazon Web Services Systems Manager, you can reference the parameter using {{ssm:parameter-name}}.
      DocumentVersion
      string 
      optional
      The document version you want update for the association.
      Match pattern:
      ([$]LATEST|[$]DEFAULT|^[1-9][0-9]*$)
      ScheduleExpression
      string 
      optional
      The cron expression used to schedule the association that you want to update.
      >= 1 characters<= 256 characters
      OutputLocation
      object 
      optional
      An S3 bucket where you want to store the results of this request.
      S3Location
      object 
      optional
      An S3 bucket where you want to store the results of this request.
      Name
      string 
      optional
      The name of the SSM Command document or Automation runbook that contains the configuration information for the managed node.
      You can specify Amazon Web Services-predefined documents, documents you created, or a document that is shared with you from another account.
      For Systems Manager document (SSM document) that are shared with you from other Amazon Web Services accounts, you must specify the complete SSM document ARN, in the following format:
      arn:aws:ssm:region:account-id:document/document-name
      For example:
      arn:aws:ssm:us-east-2:12345678912:document/My-Shared-Document
      For Amazon Web Services-predefined documents and SSM documents you created in your account, you only need to specify the document name. For example, AWS-ApplyPatchBaseline or My-Document.
      Match pattern:
      ^[a-zA-Z0-9_\-.:/]{3,128}$
      Targets
      array [object] 
      optional
      The targets of the association.
      >= 0 items<= 5 items
      AssociationName
      string 
      optional
      The name of the association that you want to update.
      Match pattern:
      ^[a-zA-Z0-9_\-.]{3,128}$
      AssociationVersion
      string 
      optional
      This parameter is provided for concurrency control purposes. You must specify the latest association version in the service. If you want to ensure that this request succeeds, either specify $LATEST, or omit this parameter.
      Match pattern:
      ([$]LATEST)|([1-9][0-9]*)
      AutomationTargetParameterName
      string 
      optional
      Choose the parameter that will define how your automation will branch out. This target is required for associations that use an Automation runbook and target resources by using rate controls. Automation is a capability of Amazon Web Services Systems Manager.
      >= 1 characters<= 50 characters
      MaxErrors
      string 
      optional
      The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify either an absolute number of errors, for example 10, or a percentage of the target set, for example 10%. If you specify 3, for example, the system stops sending requests when the fourth error is received. If you specify 0, then the system stops sending requests after the first error is returned. If you run an association on 50 managed nodes and set MaxError to 10%, then the system stops sending the request when the sixth error is received.
      Executions that are already running an association when MaxErrors is reached are allowed to complete, but some of these executions may fail as well. If you need to ensure that there won't be more than max-errors failed executions, set MaxConcurrency to 1 so that executions proceed one at a time.
      >= 1 characters<= 7 characters
      Match pattern:
      ^([1-9][0-9]*|[0]|[1-9][0-9]%|[0-9]%|100%)$
      MaxConcurrency
      string 
      optional
      The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%. The default value is 100%, which means all targets run the association at the same time.
      If a new managed node starts and attempts to run an association while Systems Manager is running MaxConcurrency associations, the association is allowed to run. During the next association interval, the new managed node will process its association within the limit specified for MaxConcurrency.
      >= 1 characters<= 7 characters
      Match pattern:
      ^([1-9][0-9]*|[1-9][0-9]%|[1-9]%|100%)$
      ComplianceSeverity
      enum<string> 
      optional
      The severity level to assign to the association.
      Allowed values:
      CRITICALHIGHMEDIUMLOWUNSPECIFIED
      SyncCompliance
      enum<string> 
      optional
      The mode for generating association compliance. You can specify AUTO or MANUAL. In AUTO mode, the system uses the status of the association execution to determine the compliance status. If the association execution runs successfully, then the association is COMPLIANT. If the association execution doesn't run successfully, the association is NON-COMPLIANT.
      In MANUAL mode, you must specify the AssociationId as a parameter for the PutComplianceItems API operation. In this case, compliance data isn't managed by State Manager, a capability of Amazon Web Services Systems Manager. It is managed by your direct call to the PutComplianceItems API operation.
      By default, all associations use AUTO mode.
      Allowed values:
      AUTOMANUAL
      ApplyOnlyAtCronInterval
      boolean 
      optional
      By default, when you update an association, the system runs it immediately after it is updated and then according to the schedule you specified. Specify this option if you don't want an association to run immediately after you update it. This parameter isn't supported for rate expressions.
      If you chose this option when you created an association and later you edit that association or you make changes to the SSM document on which that association is based (by using the Documents page in the console), State Manager applies the association at the next specified cron interval. For example, if you chose the Latest version of an SSM document when you created an association and you edit the association by choosing a different document version on the Documents page, State Manager applies the association at the next specified cron interval if you previously selected this option. If this option wasn't selected, State Manager immediately runs the association.
      You can reset this option. To do so, specify the no-apply-only-at-cron-interval parameter when you update the association from the command line. This parameter forces the association to run immediately after updating it and according to the interval specified.
      CalendarNames
      array[string]
      optional
      The names or Amazon Resource Names (ARNs) of the Change Calendar type documents you want to gate your associations under. The associations only run when that change calendar is open. For more information, see Amazon Web Services Systems Manager Change Calendar.
      TargetLocations
      array[object (TargetLocation) {6}] 
      optional
      A location is a combination of Amazon Web Services Regions and Amazon Web Services accounts where you want to run the association. Use this action to update an association in multiple Regions and multiple accounts.
      >= 1 items<= 100 items
      Accounts
      array[string]
      optional
      The Amazon Web Services accounts targeted by the current Automation execution.
      >= 1 items<= 50 items
      Regions
      array[string]
      optional
      The Amazon Web Services Regions targeted by the current Automation execution.
      >= 1 items<= 50 items
      TargetLocationMaxConcurrency
      string 
      optional
      The maximum number of Amazon Web Services Regions and Amazon Web Services accounts allowed to run the Automation concurrently.
      >= 1 characters<= 7 characters
      Match pattern:
      ^([1-9][0-9]*|[1-9][0-9]%|[1-9]%|100%)$
      TargetLocationMaxErrors
      string 
      optional
      The maximum number of errors allowed before the system stops queueing additional Automation executions for the currently running Automation.
      >= 1 characters<= 7 characters
      Match pattern:
      ^([1-9][0-9]*|[0]|[1-9][0-9]%|[0-9]%|100%)$
      ExecutionRoleName
      string 
      optional
      The Automation execution role used by the currently running Automation. If not specified, the default value is AWS-SystemsManager-AutomationExecutionRole.
      >= 1 characters<= 64 characters
      Match pattern:
      [\w+=,.@/-]+
      TargetLocationAlarmConfiguration
      object 
      AlarmConfiguration
      optional
      The details for the CloudWatch alarm you want to apply to an automation or command.
      ScheduleOffset
      integer 
      optional
      Number of days to wait after the scheduled day to run an association. For example, if you specified a cron schedule of cron(0 0 ? * THU#2 *), you could specify an offset of 3 to run the association each Sunday after the second Thursday of the month. For more information about cron schedules for associations, see Reference: Cron and rate expressions for Systems Manager in the Amazon Web Services Systems Manager User Guide.
      >= 1<= 6
      TargetMaps
      array[object (TargetMap)] 
      optional
      A key-value mapping of document parameters to target resources. Both Targets and TargetMaps can't be specified together.
      >= 0 items<= 300 items
      AlarmConfiguration
      object (AlarmConfiguration) 
      optional
      The details for the CloudWatch alarm you want to apply to an automation or command.
      IgnorePollAlarmFailure
      boolean 
      optional
      When this value is true, your automation or command continues to run in cases where we can’t retrieve alarm status information from CloudWatch. In cases where we successfully retrieve an alarm status of OK or INSUFFICIENT_DATA, the automation or command continues to run, regardless of this value. Default is false.
      Alarms
      array[object (Alarm) {1}] 
      required
      The name of the CloudWatch alarm specified in the configuration.
      >= 1 items<= 1 items
      Examples

      Responses

      🟢200Success
      application/json
      Body
      AssociationDescription
      object 
      optional
      The description of the association that was updated.
      Name
      string 
      optional
      The name of the SSM document.
      Match pattern:
      ^[a-zA-Z0-9_\-.:/]{3,128}$
      InstanceId
      string 
      optional
      The managed node ID.
      Match pattern:
      (^i-(\w{8}|\w{17})$)|(^mi-\w{17}$)
      AssociationVersion
      string 
      optional
      The association version.
      Match pattern:
      ([$]LATEST)|([1-9][0-9]*)
      Date
      string <date-time>
      optional
      The date when the association was made.
      LastUpdateAssociationDate
      string <date-time>
      optional
      The date when the association was last updated.
      Status
      object 
      optional
      The association status.
      Overview
      object 
      optional
      Information about the association.
      DocumentVersion
      string 
      optional
      The document version.
      Match pattern:
      ([$]LATEST|[$]DEFAULT|^[1-9][0-9]*$)
      AutomationTargetParameterName
      string 
      optional
      Choose the parameter that will define how your automation will branch out. This target is required for associations that use an Automation runbook and target resources by using rate controls. Automation is a capability of Amazon Web Services Systems Manager.
      >= 1 characters<= 50 characters
      Parameters
      object 
      optional
      A description of the parameters for a document.
      AssociationId
      string 
      optional
      The association ID.
      Match pattern:
      [0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}
      Targets
      array [object] 
      optional
      The managed nodes targeted by the request.
      >= 0 items<= 5 items
      ScheduleExpression
      string 
      optional
      A cron expression that specifies a schedule when the association runs.
      >= 1 characters<= 256 characters
      OutputLocation
      object 
      optional
      An S3 bucket where you want to store the output details of the request.
      LastExecutionDate
      string <date-time>
      optional
      The date on which the association was last run.
      LastSuccessfulExecutionDate
      string <date-time>
      optional
      The last date on which the association was successfully run.
      AssociationName
      string 
      optional
      The association name.
      Match pattern:
      ^[a-zA-Z0-9_\-.]{3,128}$
      MaxErrors
      string 
      optional
      The number of errors that are allowed before the system stops sending requests to run the association on additional targets. You can specify either an absolute number of errors, for example 10, or a percentage of the target set, for example 10%. If you specify 3, for example, the system stops sending requests when the fourth error is received. If you specify 0, then the system stops sending requests after the first error is returned. If you run an association on 50 managed nodes and set MaxError to 10%, then the system stops sending the request when the sixth error is received.
      Executions that are already running an association when MaxErrors is reached are allowed to complete, but some of these executions may fail as well. If you need to ensure that there won't be more than max-errors failed executions, set MaxConcurrency to 1 so that executions proceed one at a time.
      >= 1 characters<= 7 characters
      Match pattern:
      ^([1-9][0-9]*|[0]|[1-9][0-9]%|[0-9]%|100%)$
      MaxConcurrency
      string 
      optional
      The maximum number of targets allowed to run the association at the same time. You can specify a number, for example 10, or a percentage of the target set, for example 10%. The default value is 100%, which means all targets run the association at the same time.
      If a new managed node starts and attempts to run an association while Systems Manager is running MaxConcurrency associations, the association is allowed to run. During the next association interval, the new managed node will process its association within the limit specified for MaxConcurrency.
      >= 1 characters<= 7 characters
      Match pattern:
      ^([1-9][0-9]*|[1-9][0-9]%|[1-9]%|100%)$
      ComplianceSeverity
      enum<string> 
      optional
      The severity level that is assigned to the association.
      Allowed values:
      CRITICALHIGHMEDIUMLOWUNSPECIFIED
      SyncCompliance
      enum<string> 
      optional
      The mode for generating association compliance. You can specify AUTO or MANUAL. In AUTO mode, the system uses the status of the association execution to determine the compliance status. If the association execution runs successfully, then the association is COMPLIANT. If the association execution doesn't run successfully, the association is NON-COMPLIANT.
      In MANUAL mode, you must specify the AssociationId as a parameter for the PutComplianceItems API operation. In this case, compliance data isn't managed by State Manager, a capability of Amazon Web Services Systems Manager. It is managed by your direct call to the PutComplianceItems API operation.
      By default, all associations use AUTO mode.
      Allowed values:
      AUTOMANUAL
      ApplyOnlyAtCronInterval
      boolean 
      optional
      By default, when you create a new associations, the system runs it immediately after it is created and then according to the schedule you specified. Specify this option if you don't want an association to run immediately after you create it. This parameter isn't supported for rate expressions.
      CalendarNames
      array[string]
      optional
      The names or Amazon Resource Names (ARNs) of the Change Calendar type documents your associations are gated under. The associations only run when that change calendar is open. For more information, see Amazon Web Services Systems Manager Change Calendar.
      TargetLocations
      array[object (TargetLocation) {6}] 
      optional
      The combination of Amazon Web Services Regions and Amazon Web Services accounts where you want to run the association.
      >= 1 items<= 100 items
      ScheduleOffset
      integer 
      optional
      Number of days to wait after the scheduled day to run an association.
      >= 1<= 6
      TargetMaps
      array[object (TargetMap)] 
      optional
      A key-value mapping of document parameters to target resources. Both Targets and TargetMaps can't be specified together.
      >= 0 items<= 300 items
      AlarmConfiguration
      object 
      AlarmConfiguration
      optional
      The details for the CloudWatch alarm you want to apply to an automation or command.
      TriggeredAlarms
      array[object (AlarmStateInformation) {2}] 
      optional
      The CloudWatch alarm that was invoked during the association.
      >= 1 items<= 1 items
      đźź 480InternalServerError
      đźź 481InvalidSchedule
      đźź 482InvalidParameters
      đźź 483InvalidOutputLocation
      đźź 484InvalidDocumentVersion
      đźź 485AssociationDoesNotExist
      đźź 486InvalidUpdate
      đźź 487TooManyUpdates
      đźź 488InvalidDocument
      đźź 489InvalidTarget
      đźź 490InvalidAssociationVersion
      đźź 491AssociationVersionLimitExceeded
      đźź 492InvalidTargetMaps
      Previous
      /
      Next
      /
      Built with