You're Invited:Meet the Socket Team at RSAC and BSidesSF 2026, March 23–26.RSVP
Socket
Book a DemoSign in
Socket

@aws-sdk/client-ssm

Package Overview
Dependencies
Maintainers
2
Versions
609
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aws-sdk/client-ssm

AWS SDK for JavaScript Ssm Client for Node.js, Browser and React Native

Source
npmnpm
Version
3.1012.0
Version published
Weekly downloads
4.5M
2.87%
Maintainers
2
Weekly downloads
 
Created
Source

@aws-sdk/client-ssm

Description

AWS SDK for JavaScript SSM Client for Node.js, Browser and React Native.

Amazon Web Services Systems Manager is the operations hub for your Amazon Web Services applications and resources and a secure end-to-end management solution for hybrid cloud environments that enables safe and secure operations at scale.

This reference is intended to be used with the Amazon Web Services Systems Manager User Guide. To get started, see Setting up Amazon Web Services Systems Manager.

Related resources

Installing

To install this package, use the CLI of your favorite package manager:

  • npm install @aws-sdk/client-ssm
  • yarn add @aws-sdk/client-ssm
  • pnpm add @aws-sdk/client-ssm

Getting Started

Import

The AWS SDK is modulized by clients and commands. To send a request, you only need to import the SSMClient and the commands you need, for example ListNodesCommand:

// ES5 example
const { SSMClient, ListNodesCommand } = require("@aws-sdk/client-ssm");
// ES6+ example
import { SSMClient, ListNodesCommand } from "@aws-sdk/client-ssm";

Usage

To send a request:

  • Instantiate a client with configuration (e.g. credentials, region).
  • Instantiate a command with input parameters.
  • Call the send operation on the client, providing the command object as input.
const client = new SSMClient({ region: "REGION" });

const params = { /** input parameters */ };
const command = new ListNodesCommand(params);

Async/await

We recommend using the await operator to wait for the promise returned by send operation as follows:

// async/await.
try {
  const data = await client.send(command);
  // process data.
} catch (error) {
  // error handling.
} finally {
  // finally.
}

Promises

You can also use Promise chaining.

client
  .send(command)
  .then((data) => {
    // process data.
  })
  .catch((error) => {
    // error handling.
  })
  .finally(() => {
    // finally.
  });

Aggregated client

The aggregated client class is exported from the same package, but without the "Client" suffix.

SSM extends SSMClient and additionally supports all operations, waiters, and paginators as methods. This style may be familiar to you from the AWS SDK for JavaScript v2.

If you are bundling the AWS SDK, we recommend using only the bare-bones client (SSMClient). More details are in the blog post on modular packages in AWS SDK for JavaScript.

import { SSM } from "@aws-sdk/client-ssm";

const client = new SSM({ region: "REGION" });

// async/await.
try {
  const data = await client.listNodes(params);
  // process data.
} catch (error) {
  // error handling.
}

// Promises.
client
  .listNodes(params)
  .then((data) => {
    // process data.
  })
  .catch((error) => {
    // error handling.
  });

// callbacks (not recommended).
client.listNodes(params, (err, data) => {
  // process err and data.
});

Troubleshooting

When the service returns an exception, the error will include the exception information, as well as response metadata (e.g. request id).

try {
  const data = await client.send(command);
  // process data.
} catch (error) {
  const { requestId, cfId, extendedRequestId } = error.$metadata;
  console.log({ requestId, cfId, extendedRequestId });
  /**
   * The keys within exceptions are also parsed.
   * You can access them by specifying exception names:
   * if (error.name === 'SomeServiceException') {
   *     const value = error.specialKeyInException;
   * }
   */
}

See also docs/ERROR_HANDLING.

Getting Help

Please use these community resources for getting help. We use GitHub issues for tracking bugs and feature requests, but have limited bandwidth to address them.

To test your universal JavaScript code in Node.js, browser and react-native environments, visit our code samples repo.

Contributing

This client code is generated automatically. Any modifications will be overwritten the next time the @aws-sdk/client-ssm package is updated. To contribute to client you can check our generate clients scripts.

License

This SDK is distributed under the Apache License, Version 2.0, see LICENSE for more information.

Client Commands (Operations List)

AddTagsToResource

Command API Reference / Input / Output

AssociateOpsItemRelatedItem

Command API Reference / Input / Output

CancelCommand

Command API Reference / Input / Output

CancelMaintenanceWindowExecution

Command API Reference / Input / Output

CreateActivation

Command API Reference / Input / Output

CreateAssociation

Command API Reference / Input / Output

CreateAssociationBatch

Command API Reference / Input / Output

CreateDocument

Command API Reference / Input / Output

CreateMaintenanceWindow

Command API Reference / Input / Output

CreateOpsItem

Command API Reference / Input / Output

CreateOpsMetadata

Command API Reference / Input / Output

CreatePatchBaseline

Command API Reference / Input / Output

CreateResourceDataSync

Command API Reference / Input / Output

DeleteActivation

Command API Reference / Input / Output

DeleteAssociation

Command API Reference / Input / Output

DeleteDocument

Command API Reference / Input / Output

DeleteInventory

Command API Reference / Input / Output

DeleteMaintenanceWindow

Command API Reference / Input / Output

DeleteOpsItem

Command API Reference / Input / Output

DeleteOpsMetadata

Command API Reference / Input / Output

DeleteParameter

Command API Reference / Input / Output

DeleteParameters

Command API Reference / Input / Output

DeletePatchBaseline

Command API Reference / Input / Output

DeleteResourceDataSync

Command API Reference / Input / Output

DeleteResourcePolicy

Command API Reference / Input / Output

DeregisterManagedInstance

Command API Reference / Input / Output

DeregisterPatchBaselineForPatchGroup

Command API Reference / Input / Output

DeregisterTargetFromMaintenanceWindow

Command API Reference / Input / Output

DeregisterTaskFromMaintenanceWindow

Command API Reference / Input / Output

DescribeActivations

Command API Reference / Input / Output

DescribeAssociation

Command API Reference / Input / Output

DescribeAssociationExecutions

Command API Reference / Input / Output

DescribeAssociationExecutionTargets

Command API Reference / Input / Output

DescribeAutomationExecutions

Command API Reference / Input / Output

DescribeAutomationStepExecutions

Command API Reference / Input / Output

DescribeAvailablePatches

Command API Reference / Input / Output

DescribeDocument

Command API Reference / Input / Output

DescribeDocumentPermission

Command API Reference / Input / Output

DescribeEffectiveInstanceAssociations

Command API Reference / Input / Output

DescribeEffectivePatchesForPatchBaseline

Command API Reference / Input / Output

DescribeInstanceAssociationsStatus

Command API Reference / Input / Output

DescribeInstanceInformation

Command API Reference / Input / Output

DescribeInstancePatches

Command API Reference / Input / Output

DescribeInstancePatchStates

Command API Reference / Input / Output

DescribeInstancePatchStatesForPatchGroup

Command API Reference / Input / Output

DescribeInstanceProperties

Command API Reference / Input / Output

DescribeInventoryDeletions

Command API Reference / Input / Output

DescribeMaintenanceWindowExecutions

Command API Reference / Input / Output

DescribeMaintenanceWindowExecutionTaskInvocations

Command API Reference / Input / Output

DescribeMaintenanceWindowExecutionTasks

Command API Reference / Input / Output

DescribeMaintenanceWindows

Command API Reference / Input / Output

DescribeMaintenanceWindowSchedule

Command API Reference / Input / Output

DescribeMaintenanceWindowsForTarget

Command API Reference / Input / Output

DescribeMaintenanceWindowTargets

Command API Reference / Input / Output

DescribeMaintenanceWindowTasks

Command API Reference / Input / Output

DescribeOpsItems

Command API Reference / Input / Output

DescribeParameters

Command API Reference / Input / Output

DescribePatchBaselines

Command API Reference / Input / Output

DescribePatchGroups

Command API Reference / Input / Output

DescribePatchGroupState

Command API Reference / Input / Output

DescribePatchProperties

Command API Reference / Input / Output

DescribeSessions

Command API Reference / Input / Output

DisassociateOpsItemRelatedItem

Command API Reference / Input / Output

GetAccessToken

Command API Reference / Input / Output

GetAutomationExecution

Command API Reference / Input / Output

GetCalendarState

Command API Reference / Input / Output

GetCommandInvocation

Command API Reference / Input / Output

GetConnectionStatus

Command API Reference / Input / Output

GetDefaultPatchBaseline

Command API Reference / Input / Output

GetDeployablePatchSnapshotForInstance

Command API Reference / Input / Output

GetDocument

Command API Reference / Input / Output

GetExecutionPreview

Command API Reference / Input / Output

GetInventory

Command API Reference / Input / Output

GetInventorySchema

Command API Reference / Input / Output

GetMaintenanceWindow

Command API Reference / Input / Output

GetMaintenanceWindowExecution

Command API Reference / Input / Output

GetMaintenanceWindowExecutionTask

Command API Reference / Input / Output

GetMaintenanceWindowExecutionTaskInvocation

Command API Reference / Input / Output

GetMaintenanceWindowTask

Command API Reference / Input / Output

GetOpsItem

Command API Reference / Input / Output

GetOpsMetadata

Command API Reference / Input / Output

GetOpsSummary

Command API Reference / Input / Output

GetParameter

Command API Reference / Input / Output

GetParameterHistory

Command API Reference / Input / Output

GetParameters

Command API Reference / Input / Output

GetParametersByPath

Command API Reference / Input / Output

GetPatchBaseline

Command API Reference / Input / Output

GetPatchBaselineForPatchGroup

Command API Reference / Input / Output

GetResourcePolicies

Command API Reference / Input / Output

GetServiceSetting

Command API Reference / Input / Output

LabelParameterVersion

Command API Reference / Input / Output

ListAssociations

Command API Reference / Input / Output

ListAssociationVersions

Command API Reference / Input / Output

ListCommandInvocations

Command API Reference / Input / Output

ListCommands

Command API Reference / Input / Output

ListComplianceItems

Command API Reference / Input / Output

ListComplianceSummaries

Command API Reference / Input / Output

ListDocumentMetadataHistory

Command API Reference / Input / Output

ListDocuments

Command API Reference / Input / Output

ListDocumentVersions

Command API Reference / Input / Output

ListInventoryEntries

Command API Reference / Input / Output

ListNodes

Command API Reference / Input / Output

ListNodesSummary

Command API Reference / Input / Output

ListOpsItemEvents

Command API Reference / Input / Output

ListOpsItemRelatedItems

Command API Reference / Input / Output

ListOpsMetadata

Command API Reference / Input / Output

ListResourceComplianceSummaries

Command API Reference / Input / Output

ListResourceDataSync

Command API Reference / Input / Output

ListTagsForResource

Command API Reference / Input / Output

ModifyDocumentPermission

Command API Reference / Input / Output

PutComplianceItems

Command API Reference / Input / Output

PutInventory

Command API Reference / Input / Output

PutParameter

Command API Reference / Input / Output

PutResourcePolicy

Command API Reference / Input / Output

RegisterDefaultPatchBaseline

Command API Reference / Input / Output

RegisterPatchBaselineForPatchGroup

Command API Reference / Input / Output

RegisterTargetWithMaintenanceWindow

Command API Reference / Input / Output

RegisterTaskWithMaintenanceWindow

Command API Reference / Input / Output

RemoveTagsFromResource

Command API Reference / Input / Output

ResetServiceSetting

Command API Reference / Input / Output

ResumeSession

Command API Reference / Input / Output

SendAutomationSignal

Command API Reference / Input / Output

SendCommand

Command API Reference / Input / Output

StartAccessRequest

Command API Reference / Input / Output

StartAssociationsOnce

Command API Reference / Input / Output

StartAutomationExecution

Command API Reference / Input / Output

StartChangeRequestExecution

Command API Reference / Input / Output

StartExecutionPreview

Command API Reference / Input / Output

StartSession

Command API Reference / Input / Output

StopAutomationExecution

Command API Reference / Input / Output

TerminateSession

Command API Reference / Input / Output

UnlabelParameterVersion

Command API Reference / Input / Output

UpdateAssociation

Command API Reference / Input / Output

UpdateAssociationStatus

Command API Reference / Input / Output

UpdateDocument

Command API Reference / Input / Output

UpdateDocumentDefaultVersion

Command API Reference / Input / Output

UpdateDocumentMetadata

Command API Reference / Input / Output

UpdateMaintenanceWindow

Command API Reference / Input / Output

UpdateMaintenanceWindowTarget

Command API Reference / Input / Output

UpdateMaintenanceWindowTask

Command API Reference / Input / Output

UpdateManagedInstanceRole

Command API Reference / Input / Output

UpdateOpsItem

Command API Reference / Input / Output

UpdateOpsMetadata

Command API Reference / Input / Output

UpdatePatchBaseline

Command API Reference / Input / Output

UpdateResourceDataSync

Command API Reference / Input / Output

UpdateServiceSetting

Command API Reference / Input / Output

FAQs

Package last updated on 18 Mar 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts