DescribeTagsCommand

Describes the specified tags for the specified WorkSpaces resource.

Example Syntax

Use a bare-bones client and the command you need to make an API call.

import { WorkSpacesClient, DescribeTagsCommand } from "@aws-sdk/client-workspaces"; // ES Modules import
// const { WorkSpacesClient, DescribeTagsCommand } = require("@aws-sdk/client-workspaces"); // CommonJS import
const client = new WorkSpacesClient(config);
const input = { // DescribeTagsRequest
  ResourceId: "STRING_VALUE", // required
};
const command = new DescribeTagsCommand(input);
const response = await client.send(command);
// { // DescribeTagsResult
//   TagList: [ // TagList
//     { // Tag
//       Key: "STRING_VALUE", // required
//       Value: "STRING_VALUE",
//     },
//   ],
// };

DescribeTagsCommand Input

See DescribeTagsCommandInput for more details

Parameter
Type
Description
ResourceId
Required
string | undefined

The identifier of the WorkSpaces resource. The supported resource types are WorkSpaces, registered directories, images, custom bundles, IP access control groups, and connection aliases.

DescribeTagsCommand Output

Parameter
Type
Description
$metadata
Required
ResponseMetadata
Metadata pertaining to this request.
TagList
Tag[] | undefined

The tags.

Throws

Name
Fault
Details
ResourceNotFoundException
client

The resource could not be found.

WorkSpacesServiceException
Base exception class for all service exceptions from WorkSpaces service.