From 22f9f330378378f82337bf55588fe2e3a341bbd4 Mon Sep 17 00:00:00 2001 From: awstools Date: Mon, 30 Sep 2024 19:18:47 +0000 Subject: [PATCH] feat(client-resource-groups): This update includes new APIs to support application groups and to allow users to manage resource tag-sync tasks in applications. --- clients/client-resource-groups/README.md | 42 +- .../src/ResourceGroups.ts | 115 +- .../src/ResourceGroupsClient.ts | 20 +- .../src/commands/CancelTagSyncTaskCommand.ts | 125 ++ .../src/commands/CreateGroupCommand.ts | 9 + .../src/commands/DeleteGroupCommand.ts | 6 + .../src/commands/GetGroupCommand.ts | 6 + .../src/commands/GetTagSyncTaskCommand.ts | 133 ++ .../src/commands/GetTagsCommand.ts | 2 +- .../src/commands/GroupResourcesCommand.ts | 10 +- .../src/commands/ListGroupResourcesCommand.ts | 2 +- .../commands/ListGroupingStatusesCommand.ts | 130 ++ .../src/commands/ListGroupsCommand.ts | 12 +- .../src/commands/ListTagSyncTasksCommand.ts | 143 +++ .../src/commands/StartTagSyncTaskCommand.ts | 143 +++ .../src/commands/TagCommand.ts | 2 +- .../src/commands/UpdateGroupCommand.ts | 9 + .../src/commands/index.ts | 5 + clients/client-resource-groups/src/index.ts | 2 +- .../src/models/models_0.ts | 970 ++++++++++++--- .../ListGroupingStatusesPaginator.ts | 24 + .../pagination/ListTagSyncTasksPaginator.ts | 24 + .../src/pagination/index.ts | 2 + .../src/protocols/Aws_restJson1.ts | 328 ++++- .../aws-models/resource-groups.json | 1089 ++++++++++++++++- 25 files changed, 3097 insertions(+), 256 deletions(-) create mode 100644 clients/client-resource-groups/src/commands/CancelTagSyncTaskCommand.ts create mode 100644 clients/client-resource-groups/src/commands/GetTagSyncTaskCommand.ts create mode 100644 clients/client-resource-groups/src/commands/ListGroupingStatusesCommand.ts create mode 100644 clients/client-resource-groups/src/commands/ListTagSyncTasksCommand.ts create mode 100644 clients/client-resource-groups/src/commands/StartTagSyncTaskCommand.ts create mode 100644 clients/client-resource-groups/src/pagination/ListGroupingStatusesPaginator.ts create mode 100644 clients/client-resource-groups/src/pagination/ListTagSyncTasksPaginator.ts diff --git a/clients/client-resource-groups/README.md b/clients/client-resource-groups/README.md index 446518b70a5b..a0ba37d8561d 100644 --- a/clients/client-resource-groups/README.md +++ b/clients/client-resource-groups/README.md @@ -30,7 +30,7 @@ resource query entities

Applying, editing, and removing tags from resource groups

  • -

    Resolving resource group member ARNs so they can be returned as search +

    Resolving resource group member Amazon resource names (ARN)s so they can be returned as search results

  • @@ -236,6 +236,14 @@ see LICENSE for more information. ## Client Commands (Operations List) +
    + +CancelTagSyncTask + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/resource-groups/command/CancelTagSyncTaskCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/CancelTagSyncTaskCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/CancelTagSyncTaskCommandOutput/) + +
    CreateGroup @@ -291,6 +299,14 @@ GetTags [Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/resource-groups/command/GetTagsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/GetTagsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/GetTagsCommandOutput/) +
    +
    + +GetTagSyncTask + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/resource-groups/command/GetTagSyncTaskCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/GetTagSyncTaskCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/GetTagSyncTaskCommandOutput/) +
    @@ -299,6 +315,14 @@ GroupResources [Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/resource-groups/command/GroupResourcesCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/GroupResourcesCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/GroupResourcesCommandOutput/) +
    +
    + +ListGroupingStatuses + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/resource-groups/command/ListGroupingStatusesCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/ListGroupingStatusesCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/ListGroupingStatusesCommandOutput/) +
    @@ -315,6 +339,14 @@ ListGroups [Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/resource-groups/command/ListGroupsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/ListGroupsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/ListGroupsCommandOutput/) +
    +
    + +ListTagSyncTasks + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/resource-groups/command/ListTagSyncTasksCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/ListTagSyncTasksCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/ListTagSyncTasksCommandOutput/) +
    @@ -331,6 +363,14 @@ SearchResources [Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/resource-groups/command/SearchResourcesCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/SearchResourcesCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/SearchResourcesCommandOutput/) +
    +
    + +StartTagSyncTask + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/resource-groups/command/StartTagSyncTaskCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/StartTagSyncTaskCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-resource-groups/Interface/StartTagSyncTaskCommandOutput/) +
    diff --git a/clients/client-resource-groups/src/ResourceGroups.ts b/clients/client-resource-groups/src/ResourceGroups.ts index 942bad95dd2b..af125cd46c79 100644 --- a/clients/client-resource-groups/src/ResourceGroups.ts +++ b/clients/client-resource-groups/src/ResourceGroups.ts @@ -2,6 +2,11 @@ import { createAggregatedClient } from "@smithy/smithy-client"; import { HttpHandlerOptions as __HttpHandlerOptions } from "@smithy/types"; +import { + CancelTagSyncTaskCommand, + CancelTagSyncTaskCommandInput, + CancelTagSyncTaskCommandOutput, +} from "./commands/CancelTagSyncTaskCommand"; import { CreateGroupCommand, CreateGroupCommandInput, CreateGroupCommandOutput } from "./commands/CreateGroupCommand"; import { DeleteGroupCommand, DeleteGroupCommandInput, DeleteGroupCommandOutput } from "./commands/DeleteGroupCommand"; import { @@ -21,17 +26,32 @@ import { GetGroupQueryCommandOutput, } from "./commands/GetGroupQueryCommand"; import { GetTagsCommand, GetTagsCommandInput, GetTagsCommandOutput } from "./commands/GetTagsCommand"; +import { + GetTagSyncTaskCommand, + GetTagSyncTaskCommandInput, + GetTagSyncTaskCommandOutput, +} from "./commands/GetTagSyncTaskCommand"; import { GroupResourcesCommand, GroupResourcesCommandInput, GroupResourcesCommandOutput, } from "./commands/GroupResourcesCommand"; +import { + ListGroupingStatusesCommand, + ListGroupingStatusesCommandInput, + ListGroupingStatusesCommandOutput, +} from "./commands/ListGroupingStatusesCommand"; import { ListGroupResourcesCommand, ListGroupResourcesCommandInput, ListGroupResourcesCommandOutput, } from "./commands/ListGroupResourcesCommand"; import { ListGroupsCommand, ListGroupsCommandInput, ListGroupsCommandOutput } from "./commands/ListGroupsCommand"; +import { + ListTagSyncTasksCommand, + ListTagSyncTasksCommandInput, + ListTagSyncTasksCommandOutput, +} from "./commands/ListTagSyncTasksCommand"; import { PutGroupConfigurationCommand, PutGroupConfigurationCommandInput, @@ -42,6 +62,11 @@ import { SearchResourcesCommandInput, SearchResourcesCommandOutput, } from "./commands/SearchResourcesCommand"; +import { + StartTagSyncTaskCommand, + StartTagSyncTaskCommandInput, + StartTagSyncTaskCommandOutput, +} from "./commands/StartTagSyncTaskCommand"; import { TagCommand, TagCommandInput, TagCommandOutput } from "./commands/TagCommand"; import { UngroupResourcesCommand, @@ -63,6 +88,7 @@ import { import { ResourceGroupsClient, ResourceGroupsClientConfig } from "./ResourceGroupsClient"; const commands = { + CancelTagSyncTaskCommand, CreateGroupCommand, DeleteGroupCommand, GetAccountSettingsCommand, @@ -70,11 +96,15 @@ const commands = { GetGroupConfigurationCommand, GetGroupQueryCommand, GetTagsCommand, + GetTagSyncTaskCommand, GroupResourcesCommand, + ListGroupingStatusesCommand, ListGroupResourcesCommand, ListGroupsCommand, + ListTagSyncTasksCommand, PutGroupConfigurationCommand, SearchResourcesCommand, + StartTagSyncTaskCommand, TagCommand, UngroupResourcesCommand, UntagCommand, @@ -84,6 +114,23 @@ const commands = { }; export interface ResourceGroups { + /** + * @see {@link CancelTagSyncTaskCommand} + */ + cancelTagSyncTask( + args: CancelTagSyncTaskCommandInput, + options?: __HttpHandlerOptions + ): Promise; + cancelTagSyncTask( + args: CancelTagSyncTaskCommandInput, + cb: (err: any, data?: CancelTagSyncTaskCommandOutput) => void + ): void; + cancelTagSyncTask( + args: CancelTagSyncTaskCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: CancelTagSyncTaskCommandOutput) => void + ): void; + /** * @see {@link CreateGroupCommand} */ @@ -178,6 +225,20 @@ export interface ResourceGroups { cb: (err: any, data?: GetTagsCommandOutput) => void ): void; + /** + * @see {@link GetTagSyncTaskCommand} + */ + getTagSyncTask( + args: GetTagSyncTaskCommandInput, + options?: __HttpHandlerOptions + ): Promise; + getTagSyncTask(args: GetTagSyncTaskCommandInput, cb: (err: any, data?: GetTagSyncTaskCommandOutput) => void): void; + getTagSyncTask( + args: GetTagSyncTaskCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: GetTagSyncTaskCommandOutput) => void + ): void; + /** * @see {@link GroupResourcesCommand} */ @@ -192,6 +253,23 @@ export interface ResourceGroups { cb: (err: any, data?: GroupResourcesCommandOutput) => void ): void; + /** + * @see {@link ListGroupingStatusesCommand} + */ + listGroupingStatuses( + args: ListGroupingStatusesCommandInput, + options?: __HttpHandlerOptions + ): Promise; + listGroupingStatuses( + args: ListGroupingStatusesCommandInput, + cb: (err: any, data?: ListGroupingStatusesCommandOutput) => void + ): void; + listGroupingStatuses( + args: ListGroupingStatusesCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: ListGroupingStatusesCommandOutput) => void + ): void; + /** * @see {@link ListGroupResourcesCommand} */ @@ -222,6 +300,24 @@ export interface ResourceGroups { cb: (err: any, data?: ListGroupsCommandOutput) => void ): void; + /** + * @see {@link ListTagSyncTasksCommand} + */ + listTagSyncTasks(): Promise; + listTagSyncTasks( + args: ListTagSyncTasksCommandInput, + options?: __HttpHandlerOptions + ): Promise; + listTagSyncTasks( + args: ListTagSyncTasksCommandInput, + cb: (err: any, data?: ListTagSyncTasksCommandOutput) => void + ): void; + listTagSyncTasks( + args: ListTagSyncTasksCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: ListTagSyncTasksCommandOutput) => void + ): void; + /** * @see {@link PutGroupConfigurationCommand} */ @@ -254,6 +350,23 @@ export interface ResourceGroups { cb: (err: any, data?: SearchResourcesCommandOutput) => void ): void; + /** + * @see {@link StartTagSyncTaskCommand} + */ + startTagSyncTask( + args: StartTagSyncTaskCommandInput, + options?: __HttpHandlerOptions + ): Promise; + startTagSyncTask( + args: StartTagSyncTaskCommandInput, + cb: (err: any, data?: StartTagSyncTaskCommandOutput) => void + ): void; + startTagSyncTask( + args: StartTagSyncTaskCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: StartTagSyncTaskCommandOutput) => void + ): void; + /** * @see {@link TagCommand} */ @@ -362,7 +475,7 @@ export interface ResourceGroups { *

    Applying, editing, and removing tags from resource groups

    *
  • *
  • - *

    Resolving resource group member ARNs so they can be returned as search + *

    Resolving resource group member Amazon resource names (ARN)s so they can be returned as search * results

    *
  • *
  • diff --git a/clients/client-resource-groups/src/ResourceGroupsClient.ts b/clients/client-resource-groups/src/ResourceGroupsClient.ts index cf88385c48ef..8b585c14b696 100644 --- a/clients/client-resource-groups/src/ResourceGroupsClient.ts +++ b/clients/client-resource-groups/src/ResourceGroupsClient.ts @@ -53,6 +53,7 @@ import { HttpAuthSchemeResolvedConfig, resolveHttpAuthSchemeConfig, } from "./auth/httpAuthSchemeProvider"; +import { CancelTagSyncTaskCommandInput, CancelTagSyncTaskCommandOutput } from "./commands/CancelTagSyncTaskCommand"; import { CreateGroupCommandInput, CreateGroupCommandOutput } from "./commands/CreateGroupCommand"; import { DeleteGroupCommandInput, DeleteGroupCommandOutput } from "./commands/DeleteGroupCommand"; import { GetAccountSettingsCommandInput, GetAccountSettingsCommandOutput } from "./commands/GetAccountSettingsCommand"; @@ -63,14 +64,21 @@ import { } from "./commands/GetGroupConfigurationCommand"; import { GetGroupQueryCommandInput, GetGroupQueryCommandOutput } from "./commands/GetGroupQueryCommand"; import { GetTagsCommandInput, GetTagsCommandOutput } from "./commands/GetTagsCommand"; +import { GetTagSyncTaskCommandInput, GetTagSyncTaskCommandOutput } from "./commands/GetTagSyncTaskCommand"; import { GroupResourcesCommandInput, GroupResourcesCommandOutput } from "./commands/GroupResourcesCommand"; +import { + ListGroupingStatusesCommandInput, + ListGroupingStatusesCommandOutput, +} from "./commands/ListGroupingStatusesCommand"; import { ListGroupResourcesCommandInput, ListGroupResourcesCommandOutput } from "./commands/ListGroupResourcesCommand"; import { ListGroupsCommandInput, ListGroupsCommandOutput } from "./commands/ListGroupsCommand"; +import { ListTagSyncTasksCommandInput, ListTagSyncTasksCommandOutput } from "./commands/ListTagSyncTasksCommand"; import { PutGroupConfigurationCommandInput, PutGroupConfigurationCommandOutput, } from "./commands/PutGroupConfigurationCommand"; import { SearchResourcesCommandInput, SearchResourcesCommandOutput } from "./commands/SearchResourcesCommand"; +import { StartTagSyncTaskCommandInput, StartTagSyncTaskCommandOutput } from "./commands/StartTagSyncTaskCommand"; import { TagCommandInput, TagCommandOutput } from "./commands/TagCommand"; import { UngroupResourcesCommandInput, UngroupResourcesCommandOutput } from "./commands/UngroupResourcesCommand"; import { UntagCommandInput, UntagCommandOutput } from "./commands/UntagCommand"; @@ -95,18 +103,23 @@ export { __Client }; * @public */ export type ServiceInputTypes = + | CancelTagSyncTaskCommandInput | CreateGroupCommandInput | DeleteGroupCommandInput | GetAccountSettingsCommandInput | GetGroupCommandInput | GetGroupConfigurationCommandInput | GetGroupQueryCommandInput + | GetTagSyncTaskCommandInput | GetTagsCommandInput | GroupResourcesCommandInput | ListGroupResourcesCommandInput + | ListGroupingStatusesCommandInput | ListGroupsCommandInput + | ListTagSyncTasksCommandInput | PutGroupConfigurationCommandInput | SearchResourcesCommandInput + | StartTagSyncTaskCommandInput | TagCommandInput | UngroupResourcesCommandInput | UntagCommandInput @@ -118,18 +131,23 @@ export type ServiceInputTypes = * @public */ export type ServiceOutputTypes = + | CancelTagSyncTaskCommandOutput | CreateGroupCommandOutput | DeleteGroupCommandOutput | GetAccountSettingsCommandOutput | GetGroupCommandOutput | GetGroupConfigurationCommandOutput | GetGroupQueryCommandOutput + | GetTagSyncTaskCommandOutput | GetTagsCommandOutput | GroupResourcesCommandOutput | ListGroupResourcesCommandOutput + | ListGroupingStatusesCommandOutput | ListGroupsCommandOutput + | ListTagSyncTasksCommandOutput | PutGroupConfigurationCommandOutput | SearchResourcesCommandOutput + | StartTagSyncTaskCommandOutput | TagCommandOutput | UngroupResourcesCommandOutput | UntagCommandOutput @@ -333,7 +351,7 @@ export interface ResourceGroupsClientResolvedConfig extends ResourceGroupsClient *

    Applying, editing, and removing tags from resource groups

    *
  • *
  • - *

    Resolving resource group member ARNs so they can be returned as search + *

    Resolving resource group member Amazon resource names (ARN)s so they can be returned as search * results

    *
  • *
  • diff --git a/clients/client-resource-groups/src/commands/CancelTagSyncTaskCommand.ts b/clients/client-resource-groups/src/commands/CancelTagSyncTaskCommand.ts new file mode 100644 index 000000000000..3fb89fbcfa47 --- /dev/null +++ b/clients/client-resource-groups/src/commands/CancelTagSyncTaskCommand.ts @@ -0,0 +1,125 @@ +// smithy-typescript generated code +import { getEndpointPlugin } from "@smithy/middleware-endpoint"; +import { getSerdePlugin } from "@smithy/middleware-serde"; +import { Command as $Command } from "@smithy/smithy-client"; +import { MetadataBearer as __MetadataBearer } from "@smithy/types"; + +import { commonParams } from "../endpoint/EndpointParameters"; +import { CancelTagSyncTaskInput } from "../models/models_0"; +import { de_CancelTagSyncTaskCommand, se_CancelTagSyncTaskCommand } from "../protocols/Aws_restJson1"; +import { ResourceGroupsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../ResourceGroupsClient"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link CancelTagSyncTaskCommand}. + */ +export interface CancelTagSyncTaskCommandInput extends CancelTagSyncTaskInput {} +/** + * @public + * + * The output of {@link CancelTagSyncTaskCommand}. + */ +export interface CancelTagSyncTaskCommandOutput extends __MetadataBearer {} + +/** + *

    Cancels the specified tag-sync task.

    + *

    + * Minimum permissions + *

    + *

    To run this command, you must have the following permissions:

    + * + * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { ResourceGroupsClient, CancelTagSyncTaskCommand } from "@aws-sdk/client-resource-groups"; // ES Modules import + * // const { ResourceGroupsClient, CancelTagSyncTaskCommand } = require("@aws-sdk/client-resource-groups"); // CommonJS import + * const client = new ResourceGroupsClient(config); + * const input = { // CancelTagSyncTaskInput + * TaskArn: "STRING_VALUE", // required + * }; + * const command = new CancelTagSyncTaskCommand(input); + * const response = await client.send(command); + * // {}; + * + * ``` + * + * @param CancelTagSyncTaskCommandInput - {@link CancelTagSyncTaskCommandInput} + * @returns {@link CancelTagSyncTaskCommandOutput} + * @see {@link CancelTagSyncTaskCommandInput} for command's `input` shape. + * @see {@link CancelTagSyncTaskCommandOutput} for command's `response` shape. + * @see {@link ResourceGroupsClientResolvedConfig | config} for ResourceGroupsClient's `config` shape. + * + * @throws {@link BadRequestException} (client fault) + *

    The request includes one or more parameters that violate validation rules.

    + * + * @throws {@link ForbiddenException} (client fault) + *

    The caller isn't authorized to make the request. Check permissions.

    + * + * @throws {@link InternalServerErrorException} (server fault) + *

    An internal error occurred while processing the request. Try again later.

    + * + * @throws {@link MethodNotAllowedException} (client fault) + *

    The request uses an HTTP method that isn't allowed for the specified resource.

    + * + * @throws {@link TooManyRequestsException} (client fault) + *

    You've exceeded throttling limits by making too many requests in a period of + * time.

    + * + * @throws {@link UnauthorizedException} (client fault) + *

    The request was rejected because it doesn't have valid credentials for the target + * resource.

    + * + * @throws {@link ResourceGroupsServiceException} + *

    Base exception class for all service exceptions from ResourceGroups service.

    + * + * @public + */ +export class CancelTagSyncTaskCommand extends $Command + .classBuilder< + CancelTagSyncTaskCommandInput, + CancelTagSyncTaskCommandOutput, + ResourceGroupsClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: ResourceGroupsClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("Ardi", "CancelTagSyncTask", {}) + .n("ResourceGroupsClient", "CancelTagSyncTaskCommand") + .f(void 0, void 0) + .ser(se_CancelTagSyncTaskCommand) + .de(de_CancelTagSyncTaskCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: CancelTagSyncTaskInput; + output: {}; + }; + sdk: { + input: CancelTagSyncTaskCommandInput; + output: CancelTagSyncTaskCommandOutput; + }; + }; +} diff --git a/clients/client-resource-groups/src/commands/CreateGroupCommand.ts b/clients/client-resource-groups/src/commands/CreateGroupCommand.ts index feabbe1ee21a..75600b339641 100644 --- a/clients/client-resource-groups/src/commands/CreateGroupCommand.ts +++ b/clients/client-resource-groups/src/commands/CreateGroupCommand.ts @@ -73,6 +73,9 @@ export interface CreateGroupCommandOutput extends CreateGroupOutput, __MetadataB * ], * }, * ], + * Criticality: Number("int"), + * Owner: "STRING_VALUE", + * DisplayName: "STRING_VALUE", * }; * const command = new CreateGroupCommand(input); * const response = await client.send(command); @@ -81,6 +84,12 @@ export interface CreateGroupCommandOutput extends CreateGroupOutput, __MetadataB * // GroupArn: "STRING_VALUE", // required * // Name: "STRING_VALUE", // required * // Description: "STRING_VALUE", + * // Criticality: Number("int"), + * // Owner: "STRING_VALUE", + * // DisplayName: "STRING_VALUE", + * // ApplicationTag: { // ApplicationTag + * // "": "STRING_VALUE", + * // }, * // }, * // ResourceQuery: { // ResourceQuery * // Type: "TAG_FILTERS_1_0" || "CLOUDFORMATION_STACK_1_0", // required diff --git a/clients/client-resource-groups/src/commands/DeleteGroupCommand.ts b/clients/client-resource-groups/src/commands/DeleteGroupCommand.ts index 2cd229d4f79a..5655c68fe582 100644 --- a/clients/client-resource-groups/src/commands/DeleteGroupCommand.ts +++ b/clients/client-resource-groups/src/commands/DeleteGroupCommand.ts @@ -58,6 +58,12 @@ export interface DeleteGroupCommandOutput extends DeleteGroupOutput, __MetadataB * // GroupArn: "STRING_VALUE", // required * // Name: "STRING_VALUE", // required * // Description: "STRING_VALUE", + * // Criticality: Number("int"), + * // Owner: "STRING_VALUE", + * // DisplayName: "STRING_VALUE", + * // ApplicationTag: { // ApplicationTag + * // "": "STRING_VALUE", + * // }, * // }, * // }; * diff --git a/clients/client-resource-groups/src/commands/GetGroupCommand.ts b/clients/client-resource-groups/src/commands/GetGroupCommand.ts index a8feafac1696..bdba40f187db 100644 --- a/clients/client-resource-groups/src/commands/GetGroupCommand.ts +++ b/clients/client-resource-groups/src/commands/GetGroupCommand.ts @@ -57,6 +57,12 @@ export interface GetGroupCommandOutput extends GetGroupOutput, __MetadataBearer * // GroupArn: "STRING_VALUE", // required * // Name: "STRING_VALUE", // required * // Description: "STRING_VALUE", + * // Criticality: Number("int"), + * // Owner: "STRING_VALUE", + * // DisplayName: "STRING_VALUE", + * // ApplicationTag: { // ApplicationTag + * // "": "STRING_VALUE", + * // }, * // }, * // }; * diff --git a/clients/client-resource-groups/src/commands/GetTagSyncTaskCommand.ts b/clients/client-resource-groups/src/commands/GetTagSyncTaskCommand.ts new file mode 100644 index 000000000000..cad244eab870 --- /dev/null +++ b/clients/client-resource-groups/src/commands/GetTagSyncTaskCommand.ts @@ -0,0 +1,133 @@ +// smithy-typescript generated code +import { getEndpointPlugin } from "@smithy/middleware-endpoint"; +import { getSerdePlugin } from "@smithy/middleware-serde"; +import { Command as $Command } from "@smithy/smithy-client"; +import { MetadataBearer as __MetadataBearer } from "@smithy/types"; + +import { commonParams } from "../endpoint/EndpointParameters"; +import { GetTagSyncTaskInput, GetTagSyncTaskOutput } from "../models/models_0"; +import { de_GetTagSyncTaskCommand, se_GetTagSyncTaskCommand } from "../protocols/Aws_restJson1"; +import { ResourceGroupsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../ResourceGroupsClient"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link GetTagSyncTaskCommand}. + */ +export interface GetTagSyncTaskCommandInput extends GetTagSyncTaskInput {} +/** + * @public + * + * The output of {@link GetTagSyncTaskCommand}. + */ +export interface GetTagSyncTaskCommandOutput extends GetTagSyncTaskOutput, __MetadataBearer {} + +/** + *

    Returns information about a specified tag-sync task.

    + *

    + * Minimum permissions + *

    + *

    To run this command, you must have the following permissions:

    + *
      + *
    • + *

      + * resource-groups:GetTagSyncTask on the application group

      + *
    • + *
    + * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { ResourceGroupsClient, GetTagSyncTaskCommand } from "@aws-sdk/client-resource-groups"; // ES Modules import + * // const { ResourceGroupsClient, GetTagSyncTaskCommand } = require("@aws-sdk/client-resource-groups"); // CommonJS import + * const client = new ResourceGroupsClient(config); + * const input = { // GetTagSyncTaskInput + * TaskArn: "STRING_VALUE", // required + * }; + * const command = new GetTagSyncTaskCommand(input); + * const response = await client.send(command); + * // { // GetTagSyncTaskOutput + * // GroupArn: "STRING_VALUE", + * // GroupName: "STRING_VALUE", + * // TaskArn: "STRING_VALUE", + * // TagKey: "STRING_VALUE", + * // TagValue: "STRING_VALUE", + * // RoleArn: "STRING_VALUE", + * // Status: "ACTIVE" || "ERROR", + * // ErrorMessage: "STRING_VALUE", + * // CreatedAt: new Date("TIMESTAMP"), + * // }; + * + * ``` + * + * @param GetTagSyncTaskCommandInput - {@link GetTagSyncTaskCommandInput} + * @returns {@link GetTagSyncTaskCommandOutput} + * @see {@link GetTagSyncTaskCommandInput} for command's `input` shape. + * @see {@link GetTagSyncTaskCommandOutput} for command's `response` shape. + * @see {@link ResourceGroupsClientResolvedConfig | config} for ResourceGroupsClient's `config` shape. + * + * @throws {@link BadRequestException} (client fault) + *

    The request includes one or more parameters that violate validation rules.

    + * + * @throws {@link ForbiddenException} (client fault) + *

    The caller isn't authorized to make the request. Check permissions.

    + * + * @throws {@link InternalServerErrorException} (server fault) + *

    An internal error occurred while processing the request. Try again later.

    + * + * @throws {@link MethodNotAllowedException} (client fault) + *

    The request uses an HTTP method that isn't allowed for the specified resource.

    + * + * @throws {@link NotFoundException} (client fault) + *

    One or more of the specified resources don't exist.

    + * + * @throws {@link TooManyRequestsException} (client fault) + *

    You've exceeded throttling limits by making too many requests in a period of + * time.

    + * + * @throws {@link UnauthorizedException} (client fault) + *

    The request was rejected because it doesn't have valid credentials for the target + * resource.

    + * + * @throws {@link ResourceGroupsServiceException} + *

    Base exception class for all service exceptions from ResourceGroups service.

    + * + * @public + */ +export class GetTagSyncTaskCommand extends $Command + .classBuilder< + GetTagSyncTaskCommandInput, + GetTagSyncTaskCommandOutput, + ResourceGroupsClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: ResourceGroupsClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("Ardi", "GetTagSyncTask", {}) + .n("ResourceGroupsClient", "GetTagSyncTaskCommand") + .f(void 0, void 0) + .ser(se_GetTagSyncTaskCommand) + .de(de_GetTagSyncTaskCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: GetTagSyncTaskInput; + output: GetTagSyncTaskOutput; + }; + sdk: { + input: GetTagSyncTaskCommandInput; + output: GetTagSyncTaskCommandOutput; + }; + }; +} diff --git a/clients/client-resource-groups/src/commands/GetTagsCommand.ts b/clients/client-resource-groups/src/commands/GetTagsCommand.ts index 9ff0a386b38d..dec4066cb32b 100644 --- a/clients/client-resource-groups/src/commands/GetTagsCommand.ts +++ b/clients/client-resource-groups/src/commands/GetTagsCommand.ts @@ -29,7 +29,7 @@ export interface GetTagsCommandOutput extends GetTagsOutput, __MetadataBearer {} /** *

    Returns a list of tags that are associated with a resource group, specified by an - * ARN.

    + * Amazon resource name (ARN).

    *

    * Minimum permissions *

    diff --git a/clients/client-resource-groups/src/commands/GroupResourcesCommand.ts b/clients/client-resource-groups/src/commands/GroupResourcesCommand.ts index f0859a62e6da..9af739de0a67 100644 --- a/clients/client-resource-groups/src/commands/GroupResourcesCommand.ts +++ b/clients/client-resource-groups/src/commands/GroupResourcesCommand.ts @@ -30,8 +30,7 @@ export interface GroupResourcesCommandOutput extends GroupResourcesOutput, __Met /** *

    Adds the specified resources to the specified group.

    * - *

    You can use this operation with only resource groups that are configured with the - * following types:

    + *

    You can only use this operation with the following groups:

    *
      *
    • *

      @@ -43,8 +42,13 @@ export interface GroupResourcesCommandOutput extends GroupResourcesOutput, __Met * AWS::EC2::CapacityReservationPool *

      *
    • + *
    • + *

      + * AWS::ResourceGroups::ApplicationGroup + *

      + *
    • *
    - *

    Other resource group type and resource types aren't currently supported by this + *

    Other resource group types and resource types are not currently supported by this * operation.

    *
    *

    diff --git a/clients/client-resource-groups/src/commands/ListGroupResourcesCommand.ts b/clients/client-resource-groups/src/commands/ListGroupResourcesCommand.ts index e814e0faa8f1..f1b6f162c97b 100644 --- a/clients/client-resource-groups/src/commands/ListGroupResourcesCommand.ts +++ b/clients/client-resource-groups/src/commands/ListGroupResourcesCommand.ts @@ -28,7 +28,7 @@ export interface ListGroupResourcesCommandInput extends ListGroupResourcesInput export interface ListGroupResourcesCommandOutput extends ListGroupResourcesOutput, __MetadataBearer {} /** - *

    Returns a list of ARNs of the resources that are members of a specified resource + *

    Returns a list of Amazon resource names (ARNs) of the resources that are members of a specified resource * group.

    *

    * Minimum permissions diff --git a/clients/client-resource-groups/src/commands/ListGroupingStatusesCommand.ts b/clients/client-resource-groups/src/commands/ListGroupingStatusesCommand.ts new file mode 100644 index 000000000000..4d01a8a979b1 --- /dev/null +++ b/clients/client-resource-groups/src/commands/ListGroupingStatusesCommand.ts @@ -0,0 +1,130 @@ +// smithy-typescript generated code +import { getEndpointPlugin } from "@smithy/middleware-endpoint"; +import { getSerdePlugin } from "@smithy/middleware-serde"; +import { Command as $Command } from "@smithy/smithy-client"; +import { MetadataBearer as __MetadataBearer } from "@smithy/types"; + +import { commonParams } from "../endpoint/EndpointParameters"; +import { ListGroupingStatusesInput, ListGroupingStatusesOutput } from "../models/models_0"; +import { de_ListGroupingStatusesCommand, se_ListGroupingStatusesCommand } from "../protocols/Aws_restJson1"; +import { ResourceGroupsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../ResourceGroupsClient"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link ListGroupingStatusesCommand}. + */ +export interface ListGroupingStatusesCommandInput extends ListGroupingStatusesInput {} +/** + * @public + * + * The output of {@link ListGroupingStatusesCommand}. + */ +export interface ListGroupingStatusesCommandOutput extends ListGroupingStatusesOutput, __MetadataBearer {} + +/** + *

    Returns the status of the last grouping or ungrouping action for + * each resource in the specified application group.

    + * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { ResourceGroupsClient, ListGroupingStatusesCommand } from "@aws-sdk/client-resource-groups"; // ES Modules import + * // const { ResourceGroupsClient, ListGroupingStatusesCommand } = require("@aws-sdk/client-resource-groups"); // CommonJS import + * const client = new ResourceGroupsClient(config); + * const input = { // ListGroupingStatusesInput + * Group: "STRING_VALUE", // required + * MaxResults: Number("int"), + * Filters: [ // ListGroupingStatusesFilterList + * { // ListGroupingStatusesFilter + * Name: "status" || "resource-arn", // required + * Values: [ // ListGroupingStatusesFilterValues // required + * "STRING_VALUE", + * ], + * }, + * ], + * NextToken: "STRING_VALUE", + * }; + * const command = new ListGroupingStatusesCommand(input); + * const response = await client.send(command); + * // { // ListGroupingStatusesOutput + * // Group: "STRING_VALUE", + * // GroupingStatuses: [ // GroupingStatusesList + * // { // GroupingStatusesItem + * // ResourceArn: "STRING_VALUE", + * // Action: "GROUP" || "UNGROUP", + * // Status: "SUCCESS" || "FAILED" || "IN_PROGRESS" || "SKIPPED", + * // ErrorMessage: "STRING_VALUE", + * // ErrorCode: "STRING_VALUE", + * // UpdatedAt: new Date("TIMESTAMP"), + * // }, + * // ], + * // NextToken: "STRING_VALUE", + * // }; + * + * ``` + * + * @param ListGroupingStatusesCommandInput - {@link ListGroupingStatusesCommandInput} + * @returns {@link ListGroupingStatusesCommandOutput} + * @see {@link ListGroupingStatusesCommandInput} for command's `input` shape. + * @see {@link ListGroupingStatusesCommandOutput} for command's `response` shape. + * @see {@link ResourceGroupsClientResolvedConfig | config} for ResourceGroupsClient's `config` shape. + * + * @throws {@link BadRequestException} (client fault) + *

    The request includes one or more parameters that violate validation rules.

    + * + * @throws {@link ForbiddenException} (client fault) + *

    The caller isn't authorized to make the request. Check permissions.

    + * + * @throws {@link InternalServerErrorException} (server fault) + *

    An internal error occurred while processing the request. Try again later.

    + * + * @throws {@link MethodNotAllowedException} (client fault) + *

    The request uses an HTTP method that isn't allowed for the specified resource.

    + * + * @throws {@link TooManyRequestsException} (client fault) + *

    You've exceeded throttling limits by making too many requests in a period of + * time.

    + * + * @throws {@link ResourceGroupsServiceException} + *

    Base exception class for all service exceptions from ResourceGroups service.

    + * + * @public + */ +export class ListGroupingStatusesCommand extends $Command + .classBuilder< + ListGroupingStatusesCommandInput, + ListGroupingStatusesCommandOutput, + ResourceGroupsClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: ResourceGroupsClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("Ardi", "ListGroupingStatuses", {}) + .n("ResourceGroupsClient", "ListGroupingStatusesCommand") + .f(void 0, void 0) + .ser(se_ListGroupingStatusesCommand) + .de(de_ListGroupingStatusesCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: ListGroupingStatusesInput; + output: ListGroupingStatusesOutput; + }; + sdk: { + input: ListGroupingStatusesCommandInput; + output: ListGroupingStatusesCommandOutput; + }; + }; +} diff --git a/clients/client-resource-groups/src/commands/ListGroupsCommand.ts b/clients/client-resource-groups/src/commands/ListGroupsCommand.ts index 47b92f4535d1..40fcdb299d85 100644 --- a/clients/client-resource-groups/src/commands/ListGroupsCommand.ts +++ b/clients/client-resource-groups/src/commands/ListGroupsCommand.ts @@ -49,7 +49,7 @@ export interface ListGroupsCommandOutput extends ListGroupsOutput, __MetadataBea * const input = { // ListGroupsInput * Filters: [ // GroupFilterList * { // GroupFilter - * Name: "resource-type" || "configuration-type", // required + * Name: "resource-type" || "configuration-type" || "owner" || "display-name" || "criticality", // required * Values: [ // GroupFilterValues // required * "STRING_VALUE", * ], @@ -65,6 +65,10 @@ export interface ListGroupsCommandOutput extends ListGroupsOutput, __MetadataBea * // { // GroupIdentifier * // GroupName: "STRING_VALUE", * // GroupArn: "STRING_VALUE", + * // Description: "STRING_VALUE", + * // Criticality: Number("int"), + * // Owner: "STRING_VALUE", + * // DisplayName: "STRING_VALUE", * // }, * // ], * // Groups: [ // GroupList @@ -72,6 +76,12 @@ export interface ListGroupsCommandOutput extends ListGroupsOutput, __MetadataBea * // GroupArn: "STRING_VALUE", // required * // Name: "STRING_VALUE", // required * // Description: "STRING_VALUE", + * // Criticality: Number("int"), + * // Owner: "STRING_VALUE", + * // DisplayName: "STRING_VALUE", + * // ApplicationTag: { // ApplicationTag + * // "": "STRING_VALUE", + * // }, * // }, * // ], * // NextToken: "STRING_VALUE", diff --git a/clients/client-resource-groups/src/commands/ListTagSyncTasksCommand.ts b/clients/client-resource-groups/src/commands/ListTagSyncTasksCommand.ts new file mode 100644 index 000000000000..b15f8e381ba8 --- /dev/null +++ b/clients/client-resource-groups/src/commands/ListTagSyncTasksCommand.ts @@ -0,0 +1,143 @@ +// smithy-typescript generated code +import { getEndpointPlugin } from "@smithy/middleware-endpoint"; +import { getSerdePlugin } from "@smithy/middleware-serde"; +import { Command as $Command } from "@smithy/smithy-client"; +import { MetadataBearer as __MetadataBearer } from "@smithy/types"; + +import { commonParams } from "../endpoint/EndpointParameters"; +import { ListTagSyncTasksInput, ListTagSyncTasksOutput } from "../models/models_0"; +import { de_ListTagSyncTasksCommand, se_ListTagSyncTasksCommand } from "../protocols/Aws_restJson1"; +import { ResourceGroupsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../ResourceGroupsClient"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link ListTagSyncTasksCommand}. + */ +export interface ListTagSyncTasksCommandInput extends ListTagSyncTasksInput {} +/** + * @public + * + * The output of {@link ListTagSyncTasksCommand}. + */ +export interface ListTagSyncTasksCommandOutput extends ListTagSyncTasksOutput, __MetadataBearer {} + +/** + *

    Returns a list of tag-sync tasks.

    + *

    + * Minimum permissions + *

    + *

    To run this command, you must have the following permissions:

    + *
      + *
    • + *

      + * resource-groups:ListTagSyncTasks with the group passed in the filters as the resource + * or * if using no filters

      + *
    • + *
    + * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { ResourceGroupsClient, ListTagSyncTasksCommand } from "@aws-sdk/client-resource-groups"; // ES Modules import + * // const { ResourceGroupsClient, ListTagSyncTasksCommand } = require("@aws-sdk/client-resource-groups"); // CommonJS import + * const client = new ResourceGroupsClient(config); + * const input = { // ListTagSyncTasksInput + * Filters: [ // ListTagSyncTasksFilterList + * { // ListTagSyncTasksFilter + * GroupArn: "STRING_VALUE", + * GroupName: "STRING_VALUE", + * }, + * ], + * MaxResults: Number("int"), + * NextToken: "STRING_VALUE", + * }; + * const command = new ListTagSyncTasksCommand(input); + * const response = await client.send(command); + * // { // ListTagSyncTasksOutput + * // TagSyncTasks: [ // TagSyncTaskList + * // { // TagSyncTaskItem + * // GroupArn: "STRING_VALUE", + * // GroupName: "STRING_VALUE", + * // TaskArn: "STRING_VALUE", + * // TagKey: "STRING_VALUE", + * // TagValue: "STRING_VALUE", + * // RoleArn: "STRING_VALUE", + * // Status: "ACTIVE" || "ERROR", + * // ErrorMessage: "STRING_VALUE", + * // CreatedAt: new Date("TIMESTAMP"), + * // }, + * // ], + * // NextToken: "STRING_VALUE", + * // }; + * + * ``` + * + * @param ListTagSyncTasksCommandInput - {@link ListTagSyncTasksCommandInput} + * @returns {@link ListTagSyncTasksCommandOutput} + * @see {@link ListTagSyncTasksCommandInput} for command's `input` shape. + * @see {@link ListTagSyncTasksCommandOutput} for command's `response` shape. + * @see {@link ResourceGroupsClientResolvedConfig | config} for ResourceGroupsClient's `config` shape. + * + * @throws {@link BadRequestException} (client fault) + *

    The request includes one or more parameters that violate validation rules.

    + * + * @throws {@link ForbiddenException} (client fault) + *

    The caller isn't authorized to make the request. Check permissions.

    + * + * @throws {@link InternalServerErrorException} (server fault) + *

    An internal error occurred while processing the request. Try again later.

    + * + * @throws {@link MethodNotAllowedException} (client fault) + *

    The request uses an HTTP method that isn't allowed for the specified resource.

    + * + * @throws {@link TooManyRequestsException} (client fault) + *

    You've exceeded throttling limits by making too many requests in a period of + * time.

    + * + * @throws {@link UnauthorizedException} (client fault) + *

    The request was rejected because it doesn't have valid credentials for the target + * resource.

    + * + * @throws {@link ResourceGroupsServiceException} + *

    Base exception class for all service exceptions from ResourceGroups service.

    + * + * @public + */ +export class ListTagSyncTasksCommand extends $Command + .classBuilder< + ListTagSyncTasksCommandInput, + ListTagSyncTasksCommandOutput, + ResourceGroupsClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: ResourceGroupsClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("Ardi", "ListTagSyncTasks", {}) + .n("ResourceGroupsClient", "ListTagSyncTasksCommand") + .f(void 0, void 0) + .ser(se_ListTagSyncTasksCommand) + .de(de_ListTagSyncTasksCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: ListTagSyncTasksInput; + output: ListTagSyncTasksOutput; + }; + sdk: { + input: ListTagSyncTasksCommandInput; + output: ListTagSyncTasksCommandOutput; + }; + }; +} diff --git a/clients/client-resource-groups/src/commands/StartTagSyncTaskCommand.ts b/clients/client-resource-groups/src/commands/StartTagSyncTaskCommand.ts new file mode 100644 index 000000000000..96be541b36f6 --- /dev/null +++ b/clients/client-resource-groups/src/commands/StartTagSyncTaskCommand.ts @@ -0,0 +1,143 @@ +// smithy-typescript generated code +import { getEndpointPlugin } from "@smithy/middleware-endpoint"; +import { getSerdePlugin } from "@smithy/middleware-serde"; +import { Command as $Command } from "@smithy/smithy-client"; +import { MetadataBearer as __MetadataBearer } from "@smithy/types"; + +import { commonParams } from "../endpoint/EndpointParameters"; +import { StartTagSyncTaskInput, StartTagSyncTaskOutput } from "../models/models_0"; +import { de_StartTagSyncTaskCommand, se_StartTagSyncTaskCommand } from "../protocols/Aws_restJson1"; +import { ResourceGroupsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../ResourceGroupsClient"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link StartTagSyncTaskCommand}. + */ +export interface StartTagSyncTaskCommandInput extends StartTagSyncTaskInput {} +/** + * @public + * + * The output of {@link StartTagSyncTaskCommand}. + */ +export interface StartTagSyncTaskCommandOutput extends StartTagSyncTaskOutput, __MetadataBearer {} + +/** + *

    Creates a new tag-sync task to onboard and sync resources tagged with a specific tag key-value pair to an + * application.

    + *

    + * Minimum permissions + *

    + *

    To run this command, you must have the following permissions:

    + *
      + *
    • + *

      + * resource-groups:StartTagSyncTask on the application group

      + *
    • + *
    • + *

      + * resource-groups:CreateGroup + *

      + *
    • + *
    • + *

      + * iam:PassRole on the role provided in the request

      + *
    • + *
    + * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { ResourceGroupsClient, StartTagSyncTaskCommand } from "@aws-sdk/client-resource-groups"; // ES Modules import + * // const { ResourceGroupsClient, StartTagSyncTaskCommand } = require("@aws-sdk/client-resource-groups"); // CommonJS import + * const client = new ResourceGroupsClient(config); + * const input = { // StartTagSyncTaskInput + * Group: "STRING_VALUE", // required + * TagKey: "STRING_VALUE", // required + * TagValue: "STRING_VALUE", // required + * RoleArn: "STRING_VALUE", // required + * }; + * const command = new StartTagSyncTaskCommand(input); + * const response = await client.send(command); + * // { // StartTagSyncTaskOutput + * // GroupArn: "STRING_VALUE", + * // GroupName: "STRING_VALUE", + * // TaskArn: "STRING_VALUE", + * // TagKey: "STRING_VALUE", + * // TagValue: "STRING_VALUE", + * // RoleArn: "STRING_VALUE", + * // }; + * + * ``` + * + * @param StartTagSyncTaskCommandInput - {@link StartTagSyncTaskCommandInput} + * @returns {@link StartTagSyncTaskCommandOutput} + * @see {@link StartTagSyncTaskCommandInput} for command's `input` shape. + * @see {@link StartTagSyncTaskCommandOutput} for command's `response` shape. + * @see {@link ResourceGroupsClientResolvedConfig | config} for ResourceGroupsClient's `config` shape. + * + * @throws {@link BadRequestException} (client fault) + *

    The request includes one or more parameters that violate validation rules.

    + * + * @throws {@link ForbiddenException} (client fault) + *

    The caller isn't authorized to make the request. Check permissions.

    + * + * @throws {@link InternalServerErrorException} (server fault) + *

    An internal error occurred while processing the request. Try again later.

    + * + * @throws {@link MethodNotAllowedException} (client fault) + *

    The request uses an HTTP method that isn't allowed for the specified resource.

    + * + * @throws {@link NotFoundException} (client fault) + *

    One or more of the specified resources don't exist.

    + * + * @throws {@link TooManyRequestsException} (client fault) + *

    You've exceeded throttling limits by making too many requests in a period of + * time.

    + * + * @throws {@link UnauthorizedException} (client fault) + *

    The request was rejected because it doesn't have valid credentials for the target + * resource.

    + * + * @throws {@link ResourceGroupsServiceException} + *

    Base exception class for all service exceptions from ResourceGroups service.

    + * + * @public + */ +export class StartTagSyncTaskCommand extends $Command + .classBuilder< + StartTagSyncTaskCommandInput, + StartTagSyncTaskCommandOutput, + ResourceGroupsClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: ResourceGroupsClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("Ardi", "StartTagSyncTask", {}) + .n("ResourceGroupsClient", "StartTagSyncTaskCommand") + .f(void 0, void 0) + .ser(se_StartTagSyncTaskCommand) + .de(de_StartTagSyncTaskCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: StartTagSyncTaskInput; + output: StartTagSyncTaskOutput; + }; + sdk: { + input: StartTagSyncTaskCommandInput; + output: StartTagSyncTaskCommandOutput; + }; + }; +} diff --git a/clients/client-resource-groups/src/commands/TagCommand.ts b/clients/client-resource-groups/src/commands/TagCommand.ts index d915c5918939..8f3a83ba05f3 100644 --- a/clients/client-resource-groups/src/commands/TagCommand.ts +++ b/clients/client-resource-groups/src/commands/TagCommand.ts @@ -28,7 +28,7 @@ export interface TagCommandInput extends TagInput {} export interface TagCommandOutput extends TagOutput, __MetadataBearer {} /** - *

    Adds tags to a resource group with the specified ARN. Existing tags on a resource + *

    Adds tags to a resource group with the specified Amazon resource name (ARN). Existing tags on a resource * group are not changed if they are not specified in the request parameters.

    * *

    Do not store personally identifiable information (PII) or other confidential or diff --git a/clients/client-resource-groups/src/commands/UpdateGroupCommand.ts b/clients/client-resource-groups/src/commands/UpdateGroupCommand.ts index 5791e72ae342..cb020b24b09f 100644 --- a/clients/client-resource-groups/src/commands/UpdateGroupCommand.ts +++ b/clients/client-resource-groups/src/commands/UpdateGroupCommand.ts @@ -51,6 +51,9 @@ export interface UpdateGroupCommandOutput extends UpdateGroupOutput, __MetadataB * GroupName: "STRING_VALUE", * Group: "STRING_VALUE", * Description: "STRING_VALUE", + * Criticality: Number("int"), + * Owner: "STRING_VALUE", + * DisplayName: "STRING_VALUE", * }; * const command = new UpdateGroupCommand(input); * const response = await client.send(command); @@ -59,6 +62,12 @@ export interface UpdateGroupCommandOutput extends UpdateGroupOutput, __MetadataB * // GroupArn: "STRING_VALUE", // required * // Name: "STRING_VALUE", // required * // Description: "STRING_VALUE", + * // Criticality: Number("int"), + * // Owner: "STRING_VALUE", + * // DisplayName: "STRING_VALUE", + * // ApplicationTag: { // ApplicationTag + * // "": "STRING_VALUE", + * // }, * // }, * // }; * diff --git a/clients/client-resource-groups/src/commands/index.ts b/clients/client-resource-groups/src/commands/index.ts index db0fc62a3f87..84b824744d26 100644 --- a/clients/client-resource-groups/src/commands/index.ts +++ b/clients/client-resource-groups/src/commands/index.ts @@ -1,16 +1,21 @@ // smithy-typescript generated code +export * from "./CancelTagSyncTaskCommand"; export * from "./CreateGroupCommand"; export * from "./DeleteGroupCommand"; export * from "./GetAccountSettingsCommand"; export * from "./GetGroupCommand"; export * from "./GetGroupConfigurationCommand"; export * from "./GetGroupQueryCommand"; +export * from "./GetTagSyncTaskCommand"; export * from "./GetTagsCommand"; export * from "./GroupResourcesCommand"; export * from "./ListGroupResourcesCommand"; +export * from "./ListGroupingStatusesCommand"; export * from "./ListGroupsCommand"; +export * from "./ListTagSyncTasksCommand"; export * from "./PutGroupConfigurationCommand"; export * from "./SearchResourcesCommand"; +export * from "./StartTagSyncTaskCommand"; export * from "./TagCommand"; export * from "./UngroupResourcesCommand"; export * from "./UntagCommand"; diff --git a/clients/client-resource-groups/src/index.ts b/clients/client-resource-groups/src/index.ts index 9b0ae67f0d3a..96a0c545569e 100644 --- a/clients/client-resource-groups/src/index.ts +++ b/clients/client-resource-groups/src/index.ts @@ -25,7 +25,7 @@ *

    Applying, editing, and removing tags from resource groups

    *
  • *
  • - *

    Resolving resource group member ARNs so they can be returned as search + *

    Resolving resource group member Amazon resource names (ARN)s so they can be returned as search * results

    *
  • *
  • diff --git a/clients/client-resource-groups/src/models/models_0.ts b/clients/client-resource-groups/src/models/models_0.ts index 6c0e1530abbd..27bde4415ef2 100644 --- a/clients/client-resource-groups/src/models/models_0.ts +++ b/clients/client-resource-groups/src/models/models_0.ts @@ -80,6 +80,129 @@ export class BadRequestException extends __BaseException { } } +/** + * @public + */ +export interface CancelTagSyncTaskInput { + /** + *

    The Amazon resource name (ARN) of the tag-sync task.

    + * @public + */ + TaskArn: string | undefined; +} + +/** + *

    The caller isn't authorized to make the request. Check permissions.

    + * @public + */ +export class ForbiddenException extends __BaseException { + readonly name: "ForbiddenException" = "ForbiddenException"; + readonly $fault: "client" = "client"; + Message?: string; + /** + * @internal + */ + constructor(opts: __ExceptionOptionType) { + super({ + name: "ForbiddenException", + $fault: "client", + ...opts, + }); + Object.setPrototypeOf(this, ForbiddenException.prototype); + this.Message = opts.Message; + } +} + +/** + *

    An internal error occurred while processing the request. Try again later.

    + * @public + */ +export class InternalServerErrorException extends __BaseException { + readonly name: "InternalServerErrorException" = "InternalServerErrorException"; + readonly $fault: "server" = "server"; + Message?: string; + /** + * @internal + */ + constructor(opts: __ExceptionOptionType) { + super({ + name: "InternalServerErrorException", + $fault: "server", + ...opts, + }); + Object.setPrototypeOf(this, InternalServerErrorException.prototype); + this.Message = opts.Message; + } +} + +/** + *

    The request uses an HTTP method that isn't allowed for the specified resource.

    + * @public + */ +export class MethodNotAllowedException extends __BaseException { + readonly name: "MethodNotAllowedException" = "MethodNotAllowedException"; + readonly $fault: "client" = "client"; + Message?: string; + /** + * @internal + */ + constructor(opts: __ExceptionOptionType) { + super({ + name: "MethodNotAllowedException", + $fault: "client", + ...opts, + }); + Object.setPrototypeOf(this, MethodNotAllowedException.prototype); + this.Message = opts.Message; + } +} + +/** + *

    You've exceeded throttling limits by making too many requests in a period of + * time.

    + * @public + */ +export class TooManyRequestsException extends __BaseException { + readonly name: "TooManyRequestsException" = "TooManyRequestsException"; + readonly $fault: "client" = "client"; + Message?: string; + /** + * @internal + */ + constructor(opts: __ExceptionOptionType) { + super({ + name: "TooManyRequestsException", + $fault: "client", + ...opts, + }); + Object.setPrototypeOf(this, TooManyRequestsException.prototype); + this.Message = opts.Message; + } +} + +/** + *

    The request was rejected because it doesn't have valid credentials for the target + * resource.

    + * @public + */ +export class UnauthorizedException extends __BaseException { + readonly name: "UnauthorizedException" = "UnauthorizedException"; + readonly $fault: "client" = "client"; + Message?: string; + /** + * @internal + */ + constructor(opts: __ExceptionOptionType) { + super({ + name: "UnauthorizedException", + $fault: "client", + ...opts, + }); + Object.setPrototypeOf(this, UnauthorizedException.prototype); + this.Message = opts.Message; + } +} + /** *

    A parameter for a group configuration item. For details about group service * configuration syntax, see Service configurations for resource @@ -183,7 +306,7 @@ export interface ResourceQuery { * CLOUDFORMATION_STACK_1_0: * Specifies that you * want the group to contain the members of an CloudFormation stack. The Query - * contains a StackIdentifier element with an ARN for a CloudFormation + * contains a StackIdentifier element with an Amazon resource name (ARN) for a CloudFormation * stack.

    *
  • *
  • @@ -351,6 +474,26 @@ export interface CreateGroupInput { * @public */ Configuration?: GroupConfigurationItem[]; + + /** + *

    The critical rank of the application group on a scale of 1 to 10, with a + * rank of 1 being the most critical, and a rank of 10 being least critical.

    + * @public + */ + Criticality?: number; + + /** + *

    A name, email address or other identifier for the person or group + * who is considered as the owner of this application group within your organization.

    + * @public + */ + Owner?: string; + + /** + *

    The name of the application group, which you can change at any time.

    + * @public + */ + DisplayName?: string; } /** @@ -375,7 +518,7 @@ export interface CreateGroupInput { */ export interface Group { /** - *

    The ARN of the resource group.

    + *

    The Amazon resource name (ARN) of the resource group.

    * @public */ GroupArn: string | undefined; @@ -391,6 +534,33 @@ export interface Group { * @public */ Description?: string; + + /** + *

    The critical rank of the application group on a scale of 1 to 10, with a + * rank of 1 being the most critical, and a rank of 10 being least critical.

    + * @public + */ + Criticality?: number; + + /** + *

    A name, email address or other identifier for the person or group + * who is considered as the owner of this application group within your organization.

    + * @public + */ + Owner?: string; + + /** + *

    The name of the application group, which you can change at any time.

    + * @public + */ + DisplayName?: string; + + /** + *

    A tag that defines the application group membership. This tag is only supported + * for application groups.

    + * @public + */ + ApplicationTag?: Record; } /** @@ -476,95 +646,6 @@ export interface CreateGroupOutput { GroupConfiguration?: GroupConfiguration; } -/** - *

    The caller isn't authorized to make the request. Check permissions.

    - * @public - */ -export class ForbiddenException extends __BaseException { - readonly name: "ForbiddenException" = "ForbiddenException"; - readonly $fault: "client" = "client"; - Message?: string; - /** - * @internal - */ - constructor(opts: __ExceptionOptionType) { - super({ - name: "ForbiddenException", - $fault: "client", - ...opts, - }); - Object.setPrototypeOf(this, ForbiddenException.prototype); - this.Message = opts.Message; - } -} - -/** - *

    An internal error occurred while processing the request. Try again later.

    - * @public - */ -export class InternalServerErrorException extends __BaseException { - readonly name: "InternalServerErrorException" = "InternalServerErrorException"; - readonly $fault: "server" = "server"; - Message?: string; - /** - * @internal - */ - constructor(opts: __ExceptionOptionType) { - super({ - name: "InternalServerErrorException", - $fault: "server", - ...opts, - }); - Object.setPrototypeOf(this, InternalServerErrorException.prototype); - this.Message = opts.Message; - } -} - -/** - *

    The request uses an HTTP method that isn't allowed for the specified resource.

    - * @public - */ -export class MethodNotAllowedException extends __BaseException { - readonly name: "MethodNotAllowedException" = "MethodNotAllowedException"; - readonly $fault: "client" = "client"; - Message?: string; - /** - * @internal - */ - constructor(opts: __ExceptionOptionType) { - super({ - name: "MethodNotAllowedException", - $fault: "client", - ...opts, - }); - Object.setPrototypeOf(this, MethodNotAllowedException.prototype); - this.Message = opts.Message; - } -} - -/** - *

    You've exceeded throttling limits by making too many requests in a period of - * time.

    - * @public - */ -export class TooManyRequestsException extends __BaseException { - readonly name: "TooManyRequestsException" = "TooManyRequestsException"; - readonly $fault: "client" = "client"; - Message?: string; - /** - * @internal - */ - constructor(opts: __ExceptionOptionType) { - super({ - name: "TooManyRequestsException", - $fault: "client", - ...opts, - }); - Object.setPrototypeOf(this, TooManyRequestsException.prototype); - this.Message = opts.Message; - } -} - /** * @public */ @@ -578,7 +659,7 @@ export interface DeleteGroupInput { GroupName?: string; /** - *

    The name or the ARN of the resource group to delete.

    + *

    The name or the Amazon resource name (ARN) of the resource group to delete.

    * @public */ Group?: string; @@ -641,7 +722,7 @@ export interface GetGroupInput { GroupName?: string; /** - *

    The name or the ARN of the resource group to retrieve.

    + *

    The name or the Amazon resource name (ARN) of the resource group to retrieve.

    * @public */ Group?: string; @@ -665,7 +746,7 @@ export interface GetGroupOutput { */ export interface GetGroupConfigurationInput { /** - *

    The name or the ARN of the resource group for which you want to retrive the service + *

    The name or the Amazon resource name (ARN) of the resource group for which you want to retrive the service * configuration.

    * @public */ @@ -698,7 +779,7 @@ export interface GetGroupQueryInput { GroupName?: string; /** - *

    The name or the ARN of the resource group to query.

    + *

    The name or the Amazon resource name (ARN) of the resource group to query.

    * @public */ Group?: string; @@ -743,7 +824,7 @@ export interface GetGroupQueryOutput { */ export interface GetTagsInput { /** - *

    The ARN of the resource group whose tags you want to retrieve.

    + *

    The Amazon resource name (ARN) of the resource group whose tags you want to retrieve.

    * @public */ Arn: string | undefined; @@ -752,103 +833,376 @@ export interface GetTagsInput { /** * @public */ -export interface GetTagsOutput { - /** - *

    The ARN of the tagged resource group.

    - * @public - */ - Arn?: string; - - /** - *

    The tags associated with the specified resource group.

    - * @public - */ - Tags?: Record; -} +export interface GetTagsOutput { + /** + *

    TheAmazon resource name (ARN) of the tagged resource group.

    + * @public + */ + Arn?: string; + + /** + *

    The tags associated with the specified resource group.

    + * @public + */ + Tags?: Record; +} + +/** + * @public + */ +export interface GetTagSyncTaskInput { + /** + *

    The Amazon resource name (ARN) of the tag-sync task.

    + * @public + */ + TaskArn: string | undefined; +} + +/** + * @public + * @enum + */ +export const TagSyncTaskStatus = { + ACTIVE: "ACTIVE", + ERROR: "ERROR", +} as const; + +/** + * @public + */ +export type TagSyncTaskStatus = (typeof TagSyncTaskStatus)[keyof typeof TagSyncTaskStatus]; + +/** + * @public + */ +export interface GetTagSyncTaskOutput { + /** + *

    The Amazon resource name (ARN) of the application group.

    + * @public + */ + GroupArn?: string; + + /** + *

    The name of the application group.

    + * @public + */ + GroupName?: string; + + /** + *

    The Amazon resource name (ARN) of the tag-sync task.

    + * @public + */ + TaskArn?: string; + + /** + *

    The tag key.

    + * @public + */ + TagKey?: string; + + /** + *

    The tag value.

    + * @public + */ + TagValue?: string; + + /** + *

    The Amazon resource name (ARN) of the role assumed by Resource Groups to tag and untag resources on your behalf.

    + *

    For more information about this role, review Tag-sync required permissions. + *

    + * @public + */ + RoleArn?: string; + + /** + *

    The status of the tag-sync task.

    + *

    Valid values include:

    + * + * @public + */ + Status?: TagSyncTaskStatus; + + /** + *

    The specific error message in cases where the tag-sync task status + * is ERROR.

    + * @public + */ + ErrorMessage?: string; + + /** + *

    The timestamp of when the tag-sync task was created.

    + * @public + */ + CreatedAt?: Date; +} + +/** + * @public + */ +export interface GroupResourcesInput { + /** + *

    The name or the Amazon resource name (ARN) of the resource group to add resources to.

    + * @public + */ + Group: string | undefined; + + /** + *

    The list of Amazon resource names (ARNs) of the resources to be added to the group.

    + * @public + */ + ResourceArns: string[] | undefined; +} + +/** + *

    A resource that failed to be added to or removed from a group.

    + * @public + */ +export interface FailedResource { + /** + *

    The Amazon resource name (ARN) of the resource that failed to be added or removed.

    + * @public + */ + ResourceArn?: string; + + /** + *

    The error message text associated with the failure.

    + * @public + */ + ErrorMessage?: string; + + /** + *

    The error code associated with the failure.

    + * @public + */ + ErrorCode?: string; +} + +/** + *

    A structure that identifies a resource that is currently pending addition to the group + * as a member. Adding a resource to a resource group happens asynchronously as a + * background task and this one isn't completed yet.

    + * @public + */ +export interface PendingResource { + /** + *

    The Amazon resource name (ARN) of the resource that's in a pending state.

    + * @public + */ + ResourceArn?: string; +} + +/** + * @public + */ +export interface GroupResourcesOutput { + /** + *

    A list of Amazon resource names (ARNs) of the resources that this operation successfully added to the + * group.

    + * @public + */ + Succeeded?: string[]; + + /** + *

    A list of Amazon resource names (ARNs) of any resources that this operation failed to add to the group.

    + * @public + */ + Failed?: FailedResource[]; + + /** + *

    A list of Amazon resource names (ARNs) of any resources that this operation is still in the process adding to + * the group. These pending additions continue asynchronously. You can check the status of + * pending additions by using the + * ListGroupResources + * + * operation, and checking the Resources array in the response and the + * Status field of each object in that array.

    + * @public + */ + Pending?: PendingResource[]; +} + +/** + * @public + * @enum + */ +export const ListGroupingStatusesFilterName = { + ResourceArn: "resource-arn", + Status: "status", +} as const; + +/** + * @public + */ +export type ListGroupingStatusesFilterName = + (typeof ListGroupingStatusesFilterName)[keyof typeof ListGroupingStatusesFilterName]; + +/** + *

    A filter name and value pair that is used to obtain more specific results from the list of grouping statuses.

    + * @public + */ +export interface ListGroupingStatusesFilter { + /** + *

    The name of the filter. Filter names are case-sensitive.

    + * @public + */ + Name: ListGroupingStatusesFilterName | undefined; + + /** + *

    One or more filter values. Allowed filter values vary by resource filter name, and are case-sensitive.

    + * @public + */ + Values: string[] | undefined; +} + +/** + * @public + */ +export interface ListGroupingStatusesInput { + /** + *

    The application group identifier, expressed as an Amazon resource name (ARN) or the application group name.

    + * @public + */ + Group: string | undefined; + + /** + *

    The maximum number of resources and their statuses returned in the + * response.

    + * @public + */ + MaxResults?: number; + + /** + *

    The filter name and value pair that is used to return more + * specific results from a list of resources.

    + * @public + */ + Filters?: ListGroupingStatusesFilter[]; + + /** + *

    The parameter for receiving additional results if you receive a + * NextToken response in a previous request. A NextToken + * response indicates that more output is available. Set this parameter to the + * value provided by a previous call's NextToken response to indicate + * where the output should continue from.

    + * @public + */ + NextToken?: string; +} + +/** + * @public + * @enum + */ +export const GroupingType = { + GROUP: "GROUP", + UNGROUP: "UNGROUP", +} as const; + +/** + * @public + */ +export type GroupingType = (typeof GroupingType)[keyof typeof GroupingType]; + +/** + * @public + * @enum + */ +export const GroupingStatus = { + FAILED: "FAILED", + IN_PROGRESS: "IN_PROGRESS", + SKIPPED: "SKIPPED", + SUCCESS: "SUCCESS", +} as const; + +/** + * @public + */ +export type GroupingStatus = (typeof GroupingStatus)[keyof typeof GroupingStatus]; /** + *

    The information about a grouping or ungrouping resource action.

    * @public */ -export interface GroupResourcesInput { +export interface GroupingStatusesItem { /** - *

    The name or the ARN of the resource group to add resources to.

    + *

    The Amazon resource name (ARN) of a resource.

    * @public */ - Group: string | undefined; + ResourceArn?: string; /** - *

    The list of ARNs of the resources to be added to the group.

    + *

    Describes the resource grouping action with values of + * GROUP or UNGROUP.

    * @public */ - ResourceArns: string[] | undefined; -} + Action?: GroupingType; -/** - *

    A resource that failed to be added to or removed from a group.

    - * @public - */ -export interface FailedResource { /** - *

    The ARN of the resource that failed to be added or removed.

    + *

    Describes the resource grouping status with values of + * SUCCESS, FAILED, IN_PROGRESS, + * or SKIPPED.

    * @public */ - ResourceArn?: string; + Status?: GroupingStatus; /** - *

    The error message text associated with the failure.

    + *

    A message that explains the ErrorCode.

    * @public */ ErrorMessage?: string; /** - *

    The error code associated with the failure.

    + *

    Specifies the error code that was raised.

    * @public */ ErrorCode?: string; -} -/** - *

    A structure that identifies a resource that is currently pending addition to the group - * as a member. Adding a resource to a resource group happens asynchronously as a - * background task and this one isn't completed yet.

    - * @public - */ -export interface PendingResource { /** - *

    The Amazon resource name (ARN) of the resource that's in a pending state.

    + *

    A timestamp of when the status was last updated.

    * @public */ - ResourceArn?: string; + UpdatedAt?: Date; } /** * @public */ -export interface GroupResourcesOutput { +export interface ListGroupingStatusesOutput { /** - *

    A list of ARNs of the resources that this operation successfully added to the - * group.

    + *

    The application group identifier, expressed as an Amazon resource name (ARN) or the application group name.

    * @public */ - Succeeded?: string[]; + Group?: string; /** - *

    A list of ARNs of any resources that this operation failed to add to the group.

    + *

    Returns details about the grouping or ungrouping status of the + * resources in the specified application group.

    * @public */ - Failed?: FailedResource[]; + GroupingStatuses?: GroupingStatusesItem[]; /** - *

    A list of ARNs of any resources that this operation is still in the process adding to - * the group. These pending additions continue asynchronously. You can check the status of - * pending additions by using the - * ListGroupResources - * - * operation, and checking the Resources array in the response and the - * Status field of each object in that array.

    + *

    If present, indicates that more output is available than is included in the current response. + * Use this value in the NextToken request parameter in a subsequent call to the operation to get the next part of the output. + * You should repeat this until the NextToken response element comes back as null.

    * @public */ - Pending?: PendingResource[]; + NextToken?: string; } /** @@ -904,7 +1258,7 @@ export interface ListGroupResourcesInput { GroupName?: string; /** - *

    The name or the ARN of the resource group

    + *

    The name or the Amazon resource name (ARN) of the resource group.

    * @public */ Group?: string; @@ -1007,7 +1361,7 @@ export interface QueryError { */ export interface ResourceIdentifier { /** - *

    The ARN of a resource.

    + *

    The Amazon resource name (ARN) of a resource.

    * @public */ ResourceArn?: string; @@ -1118,35 +1472,15 @@ export interface ListGroupResourcesOutput { QueryErrors?: QueryError[]; } -/** - *

    The request was rejected because it doesn't have valid credentials for the target - * resource.

    - * @public - */ -export class UnauthorizedException extends __BaseException { - readonly name: "UnauthorizedException" = "UnauthorizedException"; - readonly $fault: "client" = "client"; - Message?: string; - /** - * @internal - */ - constructor(opts: __ExceptionOptionType) { - super({ - name: "UnauthorizedException", - $fault: "client", - ...opts, - }); - Object.setPrototypeOf(this, UnauthorizedException.prototype); - this.Message = opts.Message; - } -} - /** * @public * @enum */ export const GroupFilterName = { ConfigurationType: "configuration-type", + Criticality: "criticality", + DisplayName: "display-name", + Owner: "owner", ResourceType: "resource-type", } as const; @@ -1198,6 +1532,11 @@ export interface ListGroupsInput { *
      *
    • *

      + * AWS::ResourceGroups::ApplicationGroup + *

      + *
    • + *
    • + *

      * AWS::AppRegistry::Application *

      *
    • @@ -1268,10 +1607,36 @@ export interface GroupIdentifier { GroupName?: string; /** - *

      The ARN of the resource group.

      + *

      The Amazon resource name (ARN) of the resource group.

      * @public */ GroupArn?: string; + + /** + *

      The description of the application group.

      + * @public + */ + Description?: string; + + /** + *

      The critical rank of the application group on a scale of 1 to 10, with a + * rank of 1 being the most critical, and a rank of 10 being least critical.

      + * @public + */ + Criticality?: number; + + /** + *

      A name, email address or other identifier for the person or group + * who is considered as the owner of this group within your organization.

      + * @public + */ + Owner?: string; + + /** + *

      The name of the application group, which you can change at any time.

      + * @public + */ + DisplayName?: string; } /** @@ -1311,12 +1676,156 @@ export interface ListGroupsOutput { NextToken?: string; } +/** + *

      Returns tag-sync tasks filtered by the Amazon resource name (ARN) or name of a + * specified application group.

      + * @public + */ +export interface ListTagSyncTasksFilter { + /** + *

      The Amazon resource name (ARN) of the application group.

      + * @public + */ + GroupArn?: string; + + /** + *

      The name of the application group.

      + * @public + */ + GroupName?: string; +} + +/** + * @public + */ +export interface ListTagSyncTasksInput { + /** + *

      The Amazon resource name (ARN) or name of the application group for which you want to return a + * list of tag-sync tasks.

      + * @public + */ + Filters?: ListTagSyncTasksFilter[]; + + /** + *

      The maximum number of results to be included in the response.

      + * @public + */ + MaxResults?: number; + + /** + *

      The parameter for receiving additional results if you receive a + * NextToken response in a previous request. A NextToken + * response indicates that more output is available. Set this parameter to the + * value provided by a previous call's NextToken response to indicate + * where the output should continue from.

      + * @public + */ + NextToken?: string; +} + +/** + *

      The Amazon resource name (ARN) of the tag-sync task.

      + * @public + */ +export interface TagSyncTaskItem { + /** + *

      The Amazon resource name (ARN) of the application group.

      + * @public + */ + GroupArn?: string; + + /** + *

      The name of the application group.

      + * @public + */ + GroupName?: string; + + /** + *

      The Amazon resource name (ARN) of the tag-sync task.

      + * @public + */ + TaskArn?: string; + + /** + *

      The tag key.

      + * @public + */ + TagKey?: string; + + /** + *

      The tag value.

      + * @public + */ + TagValue?: string; + + /** + *

      The Amazon resource name (ARN) of the role assumed by the service to tag and untag resources on your behalf.

      + * @public + */ + RoleArn?: string; + + /** + *

      The status of the tag-sync task.

      + *

      Valid values include:

      + *
        + *
      • + *

        + * ACTIVE - The tag-sync task is actively managing resources in + * the application by adding or removing the awsApplication tag from resources + * when they are tagged or untagged with the specified tag key-value pair. + *

        + *
      • + *
      • + *

        + * ERROR - The tag-sync task is not actively managing resources + * in the application. Review the ErrorMessage for more information about + * resolving the error. + *

        + *
      • + *
      + * @public + */ + Status?: TagSyncTaskStatus; + + /** + *

      The specific error message in cases where the tag-sync task status + * is Error.

      + * @public + */ + ErrorMessage?: string; + + /** + *

      The timestamp of when the tag-sync task was created.

      + * @public + */ + CreatedAt?: Date; +} + +/** + * @public + */ +export interface ListTagSyncTasksOutput { + /** + *

      A list of tag-sync tasks and information about each task.

      + * @public + */ + TagSyncTasks?: TagSyncTaskItem[]; + + /** + *

      If present, indicates that more output is available than is included in the current response. + * Use this value in the NextToken request parameter in a subsequent call to the operation to get the next part of the output. + * You should repeat this until the NextToken response element comes back as null.

      + * @public + */ + NextToken?: string; +} + /** * @public */ export interface PutGroupConfigurationInput { /** - *

      The name or ARN of the resource group with the configuration that you want to + *

      The name or Amazon resource name (ARN) of the resource group with the configuration that you want to * update.

      * @public */ @@ -1422,12 +1931,86 @@ export interface SearchResourcesOutput { QueryErrors?: QueryError[]; } +/** + * @public + */ +export interface StartTagSyncTaskInput { + /** + *

      The Amazon resource name (ARN) or name of the application group for which you want to create a tag-sync task.

      + * @public + */ + Group: string | undefined; + + /** + *

      The tag key. Resources tagged with this tag key-value pair will be added to + * the application. If a resource with this tag is later untagged, the tag-sync task removes + * the resource from the application.

      + * @public + */ + TagKey: string | undefined; + + /** + *

      The tag value. Resources tagged with this tag key-value pair will be added to + * the application. If a resource with this tag is later untagged, the tag-sync task removes + * the resource from the application.

      + * @public + */ + TagValue: string | undefined; + + /** + *

      The Amazon resource name (ARN) of the role assumed by the service to tag and untag resources on your behalf.

      + * @public + */ + RoleArn: string | undefined; +} + +/** + * @public + */ +export interface StartTagSyncTaskOutput { + /** + *

      The Amazon resource name (ARN) of the application group for which you want to add or remove resources.

      + * @public + */ + GroupArn?: string; + + /** + *

      The name of the application group to onboard and sync resources.

      + * @public + */ + GroupName?: string; + + /** + *

      The Amazon resource name (ARN) of the new tag-sync task.

      + * @public + */ + TaskArn?: string; + + /** + *

      The tag key of the tag-sync task.

      + * @public + */ + TagKey?: string; + + /** + *

      The tag value of the tag-sync task.

      + * @public + */ + TagValue?: string; + + /** + *

      The Amazon resource name (ARN) of the role assumed by the service to tag and untag resources on your behalf.

      + * @public + */ + RoleArn?: string; +} + /** * @public */ export interface TagInput { /** - *

      The ARN of the resource group to which to add tags.

      + *

      The Amazon resource name (ARN) of the resource group to which to add tags.

      * @public */ Arn: string | undefined; @@ -1445,7 +2028,7 @@ export interface TagInput { */ export interface TagOutput { /** - *

      The ARN of the tagged resource.

      + *

      The Amazon resource name (ARN) of the tagged resource.

      * @public */ Arn?: string; @@ -1462,13 +2045,13 @@ export interface TagOutput { */ export interface UngroupResourcesInput { /** - *

      The name or the ARN of the resource group from which to remove the resources.

      + *

      The name or the Amazon resource name (ARN) of the resource group from which to remove the resources.

      * @public */ Group: string | undefined; /** - *

      The ARNs of the resources to be removed from the group.

      + *

      The Amazon resource names (ARNs) of the resources to be removed from the group.

      * @public */ ResourceArns: string[] | undefined; @@ -1509,7 +2092,7 @@ export interface UngroupResourcesOutput { */ export interface UntagInput { /** - *

      The ARN of the resource group from which to remove tags. The command removed both the + *

      The Amazon resource name (ARN) of the resource group from which to remove tags. The command removed both the * specified keys and any values associated with those keys.

      * @public */ @@ -1527,7 +2110,7 @@ export interface UntagInput { */ export interface UntagOutput { /** - *

      The ARN of the resource group from which tags have been removed.

      + *

      The Amazon resource name (ARN) of the resource group from which tags have been removed.

      * @public */ Arn?: string; @@ -1545,6 +2128,7 @@ export interface UntagOutput { export interface UpdateAccountSettingsInput { /** *

      Specifies whether you want to turn group lifecycle events on or off.

      + *

      You can't turn on group lifecycle events if your resource groups quota is greater than 2,000.

      * @public */ GroupLifecycleEventsDesiredStatus?: GroupLifecycleEventsDesiredStatus; @@ -1574,7 +2158,7 @@ export interface UpdateGroupInput { GroupName?: string; /** - *

      The name or the ARN of the resource group to modify.

      + *

      The name or the ARN of the resource group to update.

      * @public */ Group?: string; @@ -1585,6 +2169,26 @@ export interface UpdateGroupInput { * @public */ Description?: string; + + /** + *

      The critical rank of the application group on a scale of 1 to 10, with a + * rank of 1 being the most critical, and a rank of 10 being least critical.

      + * @public + */ + Criticality?: number; + + /** + *

      A name, email address or other identifier for the person or group + * who is considered as the owner of this application group within your organization.

      + * @public + */ + Owner?: string; + + /** + *

      The name of the application group, which you can change at any time.

      + * @public + */ + DisplayName?: string; } /** @@ -1611,7 +2215,7 @@ export interface UpdateGroupQueryInput { GroupName?: string; /** - *

      The name or the ARN of the resource group to query.

      + *

      The name or the Amazon resource name (ARN) of the resource group to query.

      * @public */ Group?: string; diff --git a/clients/client-resource-groups/src/pagination/ListGroupingStatusesPaginator.ts b/clients/client-resource-groups/src/pagination/ListGroupingStatusesPaginator.ts new file mode 100644 index 000000000000..0bbc288df7fa --- /dev/null +++ b/clients/client-resource-groups/src/pagination/ListGroupingStatusesPaginator.ts @@ -0,0 +1,24 @@ +// smithy-typescript generated code +import { createPaginator } from "@smithy/core"; +import { Paginator } from "@smithy/types"; + +import { + ListGroupingStatusesCommand, + ListGroupingStatusesCommandInput, + ListGroupingStatusesCommandOutput, +} from "../commands/ListGroupingStatusesCommand"; +import { ResourceGroupsClient } from "../ResourceGroupsClient"; +import { ResourceGroupsPaginationConfiguration } from "./Interfaces"; + +/** + * @public + */ +export const paginateListGroupingStatuses: ( + config: ResourceGroupsPaginationConfiguration, + input: ListGroupingStatusesCommandInput, + ...rest: any[] +) => Paginator = createPaginator< + ResourceGroupsPaginationConfiguration, + ListGroupingStatusesCommandInput, + ListGroupingStatusesCommandOutput +>(ResourceGroupsClient, ListGroupingStatusesCommand, "NextToken", "NextToken", "MaxResults"); diff --git a/clients/client-resource-groups/src/pagination/ListTagSyncTasksPaginator.ts b/clients/client-resource-groups/src/pagination/ListTagSyncTasksPaginator.ts new file mode 100644 index 000000000000..b7469e59dd41 --- /dev/null +++ b/clients/client-resource-groups/src/pagination/ListTagSyncTasksPaginator.ts @@ -0,0 +1,24 @@ +// smithy-typescript generated code +import { createPaginator } from "@smithy/core"; +import { Paginator } from "@smithy/types"; + +import { + ListTagSyncTasksCommand, + ListTagSyncTasksCommandInput, + ListTagSyncTasksCommandOutput, +} from "../commands/ListTagSyncTasksCommand"; +import { ResourceGroupsClient } from "../ResourceGroupsClient"; +import { ResourceGroupsPaginationConfiguration } from "./Interfaces"; + +/** + * @public + */ +export const paginateListTagSyncTasks: ( + config: ResourceGroupsPaginationConfiguration, + input: ListTagSyncTasksCommandInput, + ...rest: any[] +) => Paginator = createPaginator< + ResourceGroupsPaginationConfiguration, + ListTagSyncTasksCommandInput, + ListTagSyncTasksCommandOutput +>(ResourceGroupsClient, ListTagSyncTasksCommand, "NextToken", "NextToken", "MaxResults"); diff --git a/clients/client-resource-groups/src/pagination/index.ts b/clients/client-resource-groups/src/pagination/index.ts index af5eddbb7d1e..f1eb7905687d 100644 --- a/clients/client-resource-groups/src/pagination/index.ts +++ b/clients/client-resource-groups/src/pagination/index.ts @@ -1,5 +1,7 @@ // smithy-typescript generated code export * from "./Interfaces"; export * from "./ListGroupResourcesPaginator"; +export * from "./ListGroupingStatusesPaginator"; export * from "./ListGroupsPaginator"; +export * from "./ListTagSyncTasksPaginator"; export * from "./SearchResourcesPaginator"; diff --git a/clients/client-resource-groups/src/protocols/Aws_restJson1.ts b/clients/client-resource-groups/src/protocols/Aws_restJson1.ts index caea8df271be..96bd0391abca 100644 --- a/clients/client-resource-groups/src/protocols/Aws_restJson1.ts +++ b/clients/client-resource-groups/src/protocols/Aws_restJson1.ts @@ -7,10 +7,12 @@ import { collectBody, decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, + expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, extendedEncodeURIComponent as __extendedEncodeURIComponent, map, + parseEpochTimestamp as __parseEpochTimestamp, resolvedPath as __resolvedPath, take, withBaseException, @@ -21,6 +23,7 @@ import { SerdeContext as __SerdeContext, } from "@smithy/types"; +import { CancelTagSyncTaskCommandInput, CancelTagSyncTaskCommandOutput } from "../commands/CancelTagSyncTaskCommand"; import { CreateGroupCommandInput, CreateGroupCommandOutput } from "../commands/CreateGroupCommand"; import { DeleteGroupCommandInput, DeleteGroupCommandOutput } from "../commands/DeleteGroupCommand"; import { GetAccountSettingsCommandInput, GetAccountSettingsCommandOutput } from "../commands/GetAccountSettingsCommand"; @@ -31,14 +34,21 @@ import { } from "../commands/GetGroupConfigurationCommand"; import { GetGroupQueryCommandInput, GetGroupQueryCommandOutput } from "../commands/GetGroupQueryCommand"; import { GetTagsCommandInput, GetTagsCommandOutput } from "../commands/GetTagsCommand"; +import { GetTagSyncTaskCommandInput, GetTagSyncTaskCommandOutput } from "../commands/GetTagSyncTaskCommand"; import { GroupResourcesCommandInput, GroupResourcesCommandOutput } from "../commands/GroupResourcesCommand"; +import { + ListGroupingStatusesCommandInput, + ListGroupingStatusesCommandOutput, +} from "../commands/ListGroupingStatusesCommand"; import { ListGroupResourcesCommandInput, ListGroupResourcesCommandOutput } from "../commands/ListGroupResourcesCommand"; import { ListGroupsCommandInput, ListGroupsCommandOutput } from "../commands/ListGroupsCommand"; +import { ListTagSyncTasksCommandInput, ListTagSyncTasksCommandOutput } from "../commands/ListTagSyncTasksCommand"; import { PutGroupConfigurationCommandInput, PutGroupConfigurationCommandOutput, } from "../commands/PutGroupConfigurationCommand"; import { SearchResourcesCommandInput, SearchResourcesCommandOutput } from "../commands/SearchResourcesCommand"; +import { StartTagSyncTaskCommandInput, StartTagSyncTaskCommandOutput } from "../commands/StartTagSyncTaskCommand"; import { TagCommandInput, TagCommandOutput } from "../commands/TagCommand"; import { UngroupResourcesCommandInput, UngroupResourcesCommandOutput } from "../commands/UngroupResourcesCommand"; import { UntagCommandInput, UntagCommandOutput } from "../commands/UntagCommand"; @@ -54,16 +64,42 @@ import { GroupConfigurationItem, GroupConfigurationParameter, GroupFilter, + GroupingStatusesItem, InternalServerErrorException, + ListGroupingStatusesFilter, + ListTagSyncTasksFilter, MethodNotAllowedException, NotFoundException, ResourceFilter, ResourceQuery, + TagSyncTaskItem, TooManyRequestsException, UnauthorizedException, } from "../models/models_0"; import { ResourceGroupsServiceException as __BaseException } from "../models/ResourceGroupsServiceException"; +/** + * serializeAws_restJson1CancelTagSyncTaskCommand + */ +export const se_CancelTagSyncTaskCommand = async ( + input: CancelTagSyncTaskCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = { + "content-type": "application/json", + }; + b.bp("/cancel-tag-sync-task"); + let body: any; + body = JSON.stringify( + take(input, { + TaskArn: [], + }) + ); + b.m("POST").h(headers).b(body); + return b.build(); +}; + /** * serializeAws_restJson1CreateGroupCommand */ @@ -80,8 +116,11 @@ export const se_CreateGroupCommand = async ( body = JSON.stringify( take(input, { Configuration: (_) => _json(_), + Criticality: [], Description: [], + DisplayName: [], Name: [], + Owner: [], ResourceQuery: (_) => _json(_), Tags: (_) => _json(_), }) @@ -212,6 +251,28 @@ export const se_GetTagsCommand = async ( return b.build(); }; +/** + * serializeAws_restJson1GetTagSyncTaskCommand + */ +export const se_GetTagSyncTaskCommand = async ( + input: GetTagSyncTaskCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = { + "content-type": "application/json", + }; + b.bp("/get-tag-sync-task"); + let body: any; + body = JSON.stringify( + take(input, { + TaskArn: [], + }) + ); + b.m("POST").h(headers).b(body); + return b.build(); +}; + /** * serializeAws_restJson1GroupResourcesCommand */ @@ -235,6 +296,31 @@ export const se_GroupResourcesCommand = async ( return b.build(); }; +/** + * serializeAws_restJson1ListGroupingStatusesCommand + */ +export const se_ListGroupingStatusesCommand = async ( + input: ListGroupingStatusesCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = { + "content-type": "application/json", + }; + b.bp("/list-grouping-statuses"); + let body: any; + body = JSON.stringify( + take(input, { + Filters: (_) => _json(_), + Group: [], + MaxResults: [], + NextToken: [], + }) + ); + b.m("POST").h(headers).b(body); + return b.build(); +}; + /** * serializeAws_restJson1ListGroupResourcesCommand */ @@ -287,6 +373,30 @@ export const se_ListGroupsCommand = async ( return b.build(); }; +/** + * serializeAws_restJson1ListTagSyncTasksCommand + */ +export const se_ListTagSyncTasksCommand = async ( + input: ListTagSyncTasksCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = { + "content-type": "application/json", + }; + b.bp("/list-tag-sync-tasks"); + let body: any; + body = JSON.stringify( + take(input, { + Filters: (_) => _json(_), + MaxResults: [], + NextToken: [], + }) + ); + b.m("POST").h(headers).b(body); + return b.build(); +}; + /** * serializeAws_restJson1PutGroupConfigurationCommand */ @@ -334,6 +444,31 @@ export const se_SearchResourcesCommand = async ( return b.build(); }; +/** + * serializeAws_restJson1StartTagSyncTaskCommand + */ +export const se_StartTagSyncTaskCommand = async ( + input: StartTagSyncTaskCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = { + "content-type": "application/json", + }; + b.bp("/start-tag-sync-task"); + let body: any; + body = JSON.stringify( + take(input, { + Group: [], + RoleArn: [], + TagKey: [], + TagValue: [], + }) + ); + b.m("POST").h(headers).b(body); + return b.build(); +}; + /** * serializeAws_restJson1TagCommand */ @@ -434,9 +569,12 @@ export const se_UpdateGroupCommand = async ( let body: any; body = JSON.stringify( take(input, { + Criticality: [], Description: [], + DisplayName: [], Group: [], GroupName: [], + Owner: [], }) ); b.m("POST").h(headers).b(body); @@ -467,6 +605,23 @@ export const se_UpdateGroupQueryCommand = async ( return b.build(); }; +/** + * deserializeAws_restJson1CancelTagSyncTaskCommand + */ +export const de_CancelTagSyncTaskCommand = async ( + output: __HttpResponse, + context: __SerdeContext +): Promise => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return de_CommandError(output, context); + } + const contents: any = map({ + $metadata: deserializeMetadata(output), + }); + await collectBody(output.body, context); + return contents; +}; + /** * deserializeAws_restJson1CreateGroupCommand */ @@ -618,6 +773,35 @@ export const de_GetTagsCommand = async ( return contents; }; +/** + * deserializeAws_restJson1GetTagSyncTaskCommand + */ +export const de_GetTagSyncTaskCommand = async ( + output: __HttpResponse, + context: __SerdeContext +): Promise => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return de_CommandError(output, context); + } + const contents: any = map({ + $metadata: deserializeMetadata(output), + }); + const data: Record = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body"); + const doc = take(data, { + CreatedAt: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + ErrorMessage: __expectString, + GroupArn: __expectString, + GroupName: __expectString, + RoleArn: __expectString, + Status: __expectString, + TagKey: __expectString, + TagValue: __expectString, + TaskArn: __expectString, + }); + Object.assign(contents, doc); + return contents; +}; + /** * deserializeAws_restJson1GroupResourcesCommand */ @@ -641,6 +825,29 @@ export const de_GroupResourcesCommand = async ( return contents; }; +/** + * deserializeAws_restJson1ListGroupingStatusesCommand + */ +export const de_ListGroupingStatusesCommand = async ( + output: __HttpResponse, + context: __SerdeContext +): Promise => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return de_CommandError(output, context); + } + const contents: any = map({ + $metadata: deserializeMetadata(output), + }); + const data: Record = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body"); + const doc = take(data, { + Group: __expectString, + GroupingStatuses: (_) => de_GroupingStatusesList(_, context), + NextToken: __expectString, + }); + Object.assign(contents, doc); + return contents; +}; + /** * deserializeAws_restJson1ListGroupResourcesCommand */ @@ -688,6 +895,28 @@ export const de_ListGroupsCommand = async ( return contents; }; +/** + * deserializeAws_restJson1ListTagSyncTasksCommand + */ +export const de_ListTagSyncTasksCommand = async ( + output: __HttpResponse, + context: __SerdeContext +): Promise => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return de_CommandError(output, context); + } + const contents: any = map({ + $metadata: deserializeMetadata(output), + }); + const data: Record = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body"); + const doc = take(data, { + NextToken: __expectString, + TagSyncTasks: (_) => de_TagSyncTaskList(_, context), + }); + Object.assign(contents, doc); + return contents; +}; + /** * deserializeAws_restJson1PutGroupConfigurationCommand */ @@ -728,6 +957,32 @@ export const de_SearchResourcesCommand = async ( return contents; }; +/** + * deserializeAws_restJson1StartTagSyncTaskCommand + */ +export const de_StartTagSyncTaskCommand = async ( + output: __HttpResponse, + context: __SerdeContext +): Promise => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return de_CommandError(output, context); + } + const contents: any = map({ + $metadata: deserializeMetadata(output), + }); + const data: Record = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body"); + const doc = take(data, { + GroupArn: __expectString, + GroupName: __expectString, + RoleArn: __expectString, + TagKey: __expectString, + TagValue: __expectString, + TaskArn: __expectString, + }); + Object.assign(contents, doc); + return contents; +}; + /** * deserializeAws_restJson1TagCommand */ @@ -877,12 +1132,12 @@ const de_CommandError = async (output: __HttpResponse, context: __SerdeContext): case "TooManyRequestsException": case "com.amazonaws.resourcegroups#TooManyRequestsException": throw await de_TooManyRequestsExceptionRes(parsedOutput, context); - case "NotFoundException": - case "com.amazonaws.resourcegroups#NotFoundException": - throw await de_NotFoundExceptionRes(parsedOutput, context); case "UnauthorizedException": case "com.amazonaws.resourcegroups#UnauthorizedException": throw await de_UnauthorizedExceptionRes(parsedOutput, context); + case "NotFoundException": + case "com.amazonaws.resourcegroups#NotFoundException": + throw await de_NotFoundExceptionRes(parsedOutput, context); default: const parsedBody = parsedOutput.body; return throwDefaultError({ @@ -1041,6 +1296,16 @@ const de_UnauthorizedExceptionRes = async ( // se_GroupParameterList omitted. +// se_ListGroupingStatusesFilter omitted. + +// se_ListGroupingStatusesFilterList omitted. + +// se_ListGroupingStatusesFilterValues omitted. + +// se_ListTagSyncTasksFilter omitted. + +// se_ListTagSyncTasksFilterList omitted. + // se_ResourceArnList omitted. // se_ResourceFilter omitted. @@ -1057,6 +1322,8 @@ const de_UnauthorizedExceptionRes = async ( // de_AccountSettings omitted. +// de_ApplicationTag omitted. + // de_FailedResource omitted. // de_FailedResourceList omitted. @@ -1077,6 +1344,32 @@ const de_UnauthorizedExceptionRes = async ( // de_GroupIdentifierList omitted. +/** + * deserializeAws_restJson1GroupingStatusesItem + */ +const de_GroupingStatusesItem = (output: any, context: __SerdeContext): GroupingStatusesItem => { + return take(output, { + Action: __expectString, + ErrorCode: __expectString, + ErrorMessage: __expectString, + ResourceArn: __expectString, + Status: __expectString, + UpdatedAt: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + }) as any; +}; + +/** + * deserializeAws_restJson1GroupingStatusesList + */ +const de_GroupingStatusesList = (output: any, context: __SerdeContext): GroupingStatusesItem[] => { + const retVal = (output || []) + .filter((e: any) => e != null) + .map((entry: any) => { + return de_GroupingStatusesItem(entry, context); + }); + return retVal; +}; + // de_GroupList omitted. // de_GroupParameterList omitted. @@ -1109,6 +1402,35 @@ const de_UnauthorizedExceptionRes = async ( // de_Tags omitted. +/** + * deserializeAws_restJson1TagSyncTaskItem + */ +const de_TagSyncTaskItem = (output: any, context: __SerdeContext): TagSyncTaskItem => { + return take(output, { + CreatedAt: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + ErrorMessage: __expectString, + GroupArn: __expectString, + GroupName: __expectString, + RoleArn: __expectString, + Status: __expectString, + TagKey: __expectString, + TagValue: __expectString, + TaskArn: __expectString, + }) as any; +}; + +/** + * deserializeAws_restJson1TagSyncTaskList + */ +const de_TagSyncTaskList = (output: any, context: __SerdeContext): TagSyncTaskItem[] => { + const retVal = (output || []) + .filter((e: any) => e != null) + .map((entry: any) => { + return de_TagSyncTaskItem(entry, context); + }); + return retVal; +}; + const deserializeMetadata = (output: __HttpResponse): __ResponseMetadata => ({ httpStatusCode: output.statusCode, requestId: diff --git a/codegen/sdk-codegen/aws-models/resource-groups.json b/codegen/sdk-codegen/aws-models/resource-groups.json index abdaf1682dea..6b26bd614616 100644 --- a/codegen/sdk-codegen/aws-models/resource-groups.json +++ b/codegen/sdk-codegen/aws-models/resource-groups.json @@ -55,10 +55,38 @@ "smithy.api#documentation": "

      The Resource Groups settings for this Amazon Web Services account.

      " } }, + "com.amazonaws.resourcegroups#ApplicationArn": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 12, + "max": 1600 + }, + "smithy.api#pattern": "^arn:aws(-[a-z]+)*:resource-groups:[a-z]{2}(-[a-z]+)+-\\d{1}:[0-9]{12}:group/[a-zA-Z0-9_\\.-]{1,150}/[a-zA-Z0-9]{22,26}$" + } + }, + "com.amazonaws.resourcegroups#ApplicationTag": { + "type": "map", + "key": { + "target": "com.amazonaws.resourcegroups#ApplicationTagKey" + }, + "value": { + "target": "com.amazonaws.resourcegroups#ApplicationArn" + } + }, + "com.amazonaws.resourcegroups#ApplicationTagKey": { + "type": "string", + "traits": { + "smithy.api#pattern": "^awsApplication$" + } + }, "com.amazonaws.resourcegroups#Ardi": { "type": "service", "version": "2017-11-27", "operations": [ + { + "target": "com.amazonaws.resourcegroups#CancelTagSyncTask" + }, { "target": "com.amazonaws.resourcegroups#CreateGroup" }, @@ -80,21 +108,33 @@ { "target": "com.amazonaws.resourcegroups#GetTags" }, + { + "target": "com.amazonaws.resourcegroups#GetTagSyncTask" + }, { "target": "com.amazonaws.resourcegroups#GroupResources" }, + { + "target": "com.amazonaws.resourcegroups#ListGroupingStatuses" + }, { "target": "com.amazonaws.resourcegroups#ListGroupResources" }, { "target": "com.amazonaws.resourcegroups#ListGroups" }, + { + "target": "com.amazonaws.resourcegroups#ListTagSyncTasks" + }, { "target": "com.amazonaws.resourcegroups#PutGroupConfiguration" }, { "target": "com.amazonaws.resourcegroups#SearchResources" }, + { + "target": "com.amazonaws.resourcegroups#StartTagSyncTask" + }, { "target": "com.amazonaws.resourcegroups#Tag" }, @@ -126,7 +166,7 @@ "name": "resource-groups" }, "aws.protocols#restJson1": {}, - "smithy.api#documentation": "

      Resource Groups lets you organize Amazon Web Services resources such as Amazon Elastic Compute Cloud instances, Amazon Relational Database Service\n databases, and Amazon Simple Storage Service buckets into groups using criteria that you define as tags. A\n resource group is a collection of resources that match the resource types specified in a\n query, and share one or more tags or portions of tags. You can create a group of\n resources based on their roles in your cloud infrastructure, lifecycle stages, regions,\n application layers, or virtually any criteria. Resource Groups enable you to automate management\n tasks, such as those in Amazon Web Services Systems Manager Automation documents, on tag-related resources in\n Amazon Web Services Systems Manager. Groups of tagged resources also let you quickly view a custom console in\n Amazon Web Services Systems Manager that shows Config compliance and other monitoring data about member\n resources.

      \n

      To create a resource group, build a resource query, and specify tags that identify the\n criteria that members of the group have in common. Tags are key-value pairs.

      \n

      For more information about Resource Groups, see the Resource Groups User Guide.

      \n

      Resource Groups uses a REST-compliant API that you can use to perform the following types of\n operations.

      \n
        \n
      • \n

        Create, Read, Update, and Delete (CRUD) operations on resource groups and\n resource query entities

        \n
      • \n
      • \n

        Applying, editing, and removing tags from resource groups

        \n
      • \n
      • \n

        Resolving resource group member ARNs so they can be returned as search\n results

        \n
      • \n
      • \n

        Getting data about resources that are members of a group

        \n
      • \n
      • \n

        Searching Amazon Web Services resources based on a resource query

        \n
      • \n
      ", + "smithy.api#documentation": "

      Resource Groups lets you organize Amazon Web Services resources such as Amazon Elastic Compute Cloud instances, Amazon Relational Database Service\n databases, and Amazon Simple Storage Service buckets into groups using criteria that you define as tags. A\n resource group is a collection of resources that match the resource types specified in a\n query, and share one or more tags or portions of tags. You can create a group of\n resources based on their roles in your cloud infrastructure, lifecycle stages, regions,\n application layers, or virtually any criteria. Resource Groups enable you to automate management\n tasks, such as those in Amazon Web Services Systems Manager Automation documents, on tag-related resources in\n Amazon Web Services Systems Manager. Groups of tagged resources also let you quickly view a custom console in\n Amazon Web Services Systems Manager that shows Config compliance and other monitoring data about member\n resources.

      \n

      To create a resource group, build a resource query, and specify tags that identify the\n criteria that members of the group have in common. Tags are key-value pairs.

      \n

      For more information about Resource Groups, see the Resource Groups User Guide.

      \n

      Resource Groups uses a REST-compliant API that you can use to perform the following types of\n operations.

      \n
        \n
      • \n

        Create, Read, Update, and Delete (CRUD) operations on resource groups and\n resource query entities

        \n
      • \n
      • \n

        Applying, editing, and removing tags from resource groups

        \n
      • \n
      • \n

        Resolving resource group member Amazon resource names (ARN)s so they can be returned as search\n results

        \n
      • \n
      • \n

        Getting data about resources that are members of a group

        \n
      • \n
      • \n

        Searching Amazon Web Services resources based on a resource query

        \n
      • \n
      ", "smithy.api#title": "AWS Resource Groups", "smithy.rules#endpointRuleSet": { "version": "1.0", @@ -1147,6 +1187,58 @@ "smithy.api#httpError": 400 } }, + "com.amazonaws.resourcegroups#CancelTagSyncTask": { + "type": "operation", + "input": { + "target": "com.amazonaws.resourcegroups#CancelTagSyncTaskInput" + }, + "output": { + "target": "smithy.api#Unit" + }, + "errors": [ + { + "target": "com.amazonaws.resourcegroups#BadRequestException" + }, + { + "target": "com.amazonaws.resourcegroups#ForbiddenException" + }, + { + "target": "com.amazonaws.resourcegroups#InternalServerErrorException" + }, + { + "target": "com.amazonaws.resourcegroups#MethodNotAllowedException" + }, + { + "target": "com.amazonaws.resourcegroups#TooManyRequestsException" + }, + { + "target": "com.amazonaws.resourcegroups#UnauthorizedException" + } + ], + "traits": { + "smithy.api#documentation": "

      Cancels the specified tag-sync task.

      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:CancelTagSyncTask on the application group

        \n
      • \n
      • \n

        \n resource-groups:DeleteGroup\n

        \n
      • \n
      ", + "smithy.api#http": { + "method": "POST", + "uri": "/cancel-tag-sync-task", + "code": 200 + } + } + }, + "com.amazonaws.resourcegroups#CancelTagSyncTaskInput": { + "type": "structure", + "members": { + "TaskArn": { + "target": "com.amazonaws.resourcegroups#TagSyncTaskArn", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the tag-sync task.

      ", + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, "com.amazonaws.resourcegroups#CreateGroup": { "type": "operation", "input": { @@ -1185,7 +1277,7 @@ "type": "structure", "members": { "Name": { - "target": "com.amazonaws.resourcegroups#GroupName", + "target": "com.amazonaws.resourcegroups#CreateGroupName", "traits": { "smithy.api#documentation": "

      The name of the group, which is the identifier of the group in other operations. You\n can't change the name of a resource group after you create it. A resource group name can\n consist of letters, numbers, hyphens, periods, and underscores. The name cannot start\n with AWS, aws, or any other possible capitalization; these are\n reserved. A resource group name must be unique within each Amazon Web Services Region in your Amazon Web Services\n account.

      ", "smithy.api#required": {} @@ -1214,12 +1306,40 @@ "traits": { "smithy.api#documentation": "

      A configuration associates the resource group with an Amazon Web Services service and specifies how\n the service can interact with the resources in the group. A configuration is an array of\n GroupConfigurationItem elements. For details about the syntax of\n service configurations, see Service configurations for Resource Groups.

      \n \n

      A resource group can contain either a Configuration or a\n ResourceQuery, but not both.

      \n
      " } + }, + "Criticality": { + "target": "com.amazonaws.resourcegroups#Criticality", + "traits": { + "smithy.api#documentation": "

      The critical rank of the application group on a scale of 1 to 10, with a \n rank of 1 being the most critical, and a rank of 10 being least critical.

      " + } + }, + "Owner": { + "target": "com.amazonaws.resourcegroups#Owner", + "traits": { + "smithy.api#documentation": "

      A name, email address or other identifier for the person or group \n who is considered as the owner of this application group within your organization.

      " + } + }, + "DisplayName": { + "target": "com.amazonaws.resourcegroups#DisplayName", + "traits": { + "smithy.api#documentation": "

      The name of the application group, which you can change at any time.

      " + } } }, "traits": { "smithy.api#input": {} } }, + "com.amazonaws.resourcegroups#CreateGroupName": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 1, + "max": 300 + }, + "smithy.api#pattern": "^[a-zA-Z0-9_\\.-]+$" + } + }, "com.amazonaws.resourcegroups#CreateGroupOutput": { "type": "structure", "members": { @@ -1252,6 +1372,15 @@ "smithy.api#output": {} } }, + "com.amazonaws.resourcegroups#Criticality": { + "type": "integer", + "traits": { + "smithy.api#range": { + "min": 1, + "max": 10 + } + } + }, "com.amazonaws.resourcegroups#DeleteGroup": { "type": "operation", "input": { @@ -1302,9 +1431,9 @@ } }, "Group": { - "target": "com.amazonaws.resourcegroups#GroupString", + "target": "com.amazonaws.resourcegroups#GroupStringV2", "traits": { - "smithy.api#documentation": "

      The name or the ARN of the resource group to delete.

      " + "smithy.api#documentation": "

      The name or the Amazon resource name (ARN) of the resource group to delete.

      " } } }, @@ -1336,6 +1465,16 @@ "smithy.api#pattern": "^[\\sa-zA-Z0-9_\\.-]*$" } }, + "com.amazonaws.resourcegroups#DisplayName": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 0, + "max": 300 + }, + "smithy.api#pattern": "^([\\p{L}\\p{Z}\\p{N}_.:/=+\\-@]*)$" + } + }, "com.amazonaws.resourcegroups#ErrorCode": { "type": "string", "traits": { @@ -1360,7 +1499,7 @@ "ResourceArn": { "target": "com.amazonaws.resourcegroups#ResourceArn", "traits": { - "smithy.api#documentation": "

      The ARN of the resource that failed to be added or removed.

      " + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the resource that failed to be added or removed.

      " } }, "ErrorMessage": { @@ -1527,7 +1666,7 @@ "Group": { "target": "com.amazonaws.resourcegroups#GroupString", "traits": { - "smithy.api#documentation": "

      The name or the ARN of the resource group for which you want to retrive the service\n configuration.

      " + "smithy.api#documentation": "

      The name or the Amazon resource name (ARN) of the resource group for which you want to retrive the service\n configuration.

      " } } }, @@ -1562,9 +1701,9 @@ } }, "Group": { - "target": "com.amazonaws.resourcegroups#GroupString", + "target": "com.amazonaws.resourcegroups#GroupStringV2", "traits": { - "smithy.api#documentation": "

      The name or the ARN of the resource group to retrieve.

      " + "smithy.api#documentation": "

      The name or the Amazon resource name (ARN) of the resource group to retrieve.

      " } } }, @@ -1638,7 +1777,7 @@ "Group": { "target": "com.amazonaws.resourcegroups#GroupString", "traits": { - "smithy.api#documentation": "

      The name or the ARN of the resource group to query.

      " + "smithy.api#documentation": "

      The name or the Amazon resource name (ARN) of the resource group to query.

      " } } }, @@ -1660,6 +1799,123 @@ "smithy.api#output": {} } }, + "com.amazonaws.resourcegroups#GetTagSyncTask": { + "type": "operation", + "input": { + "target": "com.amazonaws.resourcegroups#GetTagSyncTaskInput" + }, + "output": { + "target": "com.amazonaws.resourcegroups#GetTagSyncTaskOutput" + }, + "errors": [ + { + "target": "com.amazonaws.resourcegroups#BadRequestException" + }, + { + "target": "com.amazonaws.resourcegroups#ForbiddenException" + }, + { + "target": "com.amazonaws.resourcegroups#InternalServerErrorException" + }, + { + "target": "com.amazonaws.resourcegroups#MethodNotAllowedException" + }, + { + "target": "com.amazonaws.resourcegroups#NotFoundException" + }, + { + "target": "com.amazonaws.resourcegroups#TooManyRequestsException" + }, + { + "target": "com.amazonaws.resourcegroups#UnauthorizedException" + } + ], + "traits": { + "smithy.api#documentation": "

      Returns information about a specified tag-sync task.

      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:GetTagSyncTask on the application group

        \n
      • \n
      ", + "smithy.api#http": { + "method": "POST", + "uri": "/get-tag-sync-task", + "code": 200 + } + } + }, + "com.amazonaws.resourcegroups#GetTagSyncTaskInput": { + "type": "structure", + "members": { + "TaskArn": { + "target": "com.amazonaws.resourcegroups#TagSyncTaskArn", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the tag-sync task.

      ", + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.resourcegroups#GetTagSyncTaskOutput": { + "type": "structure", + "members": { + "GroupArn": { + "target": "com.amazonaws.resourcegroups#GroupArnV2", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the application group.

      " + } + }, + "GroupName": { + "target": "com.amazonaws.resourcegroups#GroupName", + "traits": { + "smithy.api#documentation": "

      The name of the application group.

      " + } + }, + "TaskArn": { + "target": "com.amazonaws.resourcegroups#TagSyncTaskArn", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the tag-sync task.

      " + } + }, + "TagKey": { + "target": "com.amazonaws.resourcegroups#TagKey", + "traits": { + "smithy.api#documentation": "

      The tag key.

      " + } + }, + "TagValue": { + "target": "com.amazonaws.resourcegroups#TagValue", + "traits": { + "smithy.api#documentation": "

      The tag value.

      " + } + }, + "RoleArn": { + "target": "com.amazonaws.resourcegroups#RoleArn", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the role assumed by Resource Groups to tag and untag resources on your behalf.

      \n

      For more information about this role, review Tag-sync required permissions. \n

      " + } + }, + "Status": { + "target": "com.amazonaws.resourcegroups#TagSyncTaskStatus", + "traits": { + "smithy.api#documentation": "

      The status of the tag-sync task.

      \n

      Valid values include:

      \n
        \n
      • \n

        \n ACTIVE - The tag-sync task is actively managing resources in \n the application by adding or removing the awsApplication tag from resources \n when they are tagged or untagged with the specified tag key-value pair. \n

        \n
      • \n
      • \n

        \n ERROR - The tag-sync task is not actively managing resources \n in the application. Review the ErrorMessage for more information about \n resolving the error. \n

        \n
      • \n
      " + } + }, + "ErrorMessage": { + "target": "com.amazonaws.resourcegroups#ErrorMessage", + "traits": { + "smithy.api#documentation": "

      The specific error message in cases where the tag-sync task status\n is ERROR.

      " + } + }, + "CreatedAt": { + "target": "com.amazonaws.resourcegroups#timestamp", + "traits": { + "smithy.api#documentation": "

      The timestamp of when the tag-sync task was created.

      " + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, "com.amazonaws.resourcegroups#GetTags": { "type": "operation", "input": { @@ -1689,7 +1945,7 @@ } ], "traits": { - "smithy.api#documentation": "

      Returns a list of tags that are associated with a resource group, specified by an\n ARN.

      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:GetTags\n

        \n
      • \n
      ", + "smithy.api#documentation": "

      Returns a list of tags that are associated with a resource group, specified by an\n Amazon resource name (ARN).

      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:GetTags\n

        \n
      • \n
      ", "smithy.api#http": { "method": "GET", "uri": "/resources/{Arn}/tags", @@ -1701,9 +1957,9 @@ "type": "structure", "members": { "Arn": { - "target": "com.amazonaws.resourcegroups#GroupArn", + "target": "com.amazonaws.resourcegroups#GroupArnV2", "traits": { - "smithy.api#documentation": "

      The ARN of the resource group whose tags you want to retrieve.

      ", + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the resource group whose tags you want to retrieve.

      ", "smithy.api#httpLabel": {}, "smithy.api#required": {} } @@ -1717,9 +1973,9 @@ "type": "structure", "members": { "Arn": { - "target": "com.amazonaws.resourcegroups#GroupArn", + "target": "com.amazonaws.resourcegroups#GroupArnV2", "traits": { - "smithy.api#documentation": "

      The ARN of the tagged resource group.

      " + "smithy.api#documentation": "

      TheAmazon resource name (ARN) of the tagged resource group.

      " } }, "Tags": { @@ -1737,9 +1993,9 @@ "type": "structure", "members": { "GroupArn": { - "target": "com.amazonaws.resourcegroups#GroupArn", + "target": "com.amazonaws.resourcegroups#GroupArnV2", "traits": { - "smithy.api#documentation": "

      The ARN of the resource group.

      ", + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the resource group.

      ", "smithy.api#required": {} } }, @@ -1755,6 +2011,30 @@ "traits": { "smithy.api#documentation": "

      The description of the resource group.

      " } + }, + "Criticality": { + "target": "com.amazonaws.resourcegroups#Criticality", + "traits": { + "smithy.api#documentation": "

      The critical rank of the application group on a scale of 1 to 10, with a \n rank of 1 being the most critical, and a rank of 10 being least critical.

      " + } + }, + "Owner": { + "target": "com.amazonaws.resourcegroups#Owner", + "traits": { + "smithy.api#documentation": "

      A name, email address or other identifier for the person or group \n who is considered as the owner of this application group within your organization.

      " + } + }, + "DisplayName": { + "target": "com.amazonaws.resourcegroups#DisplayName", + "traits": { + "smithy.api#documentation": "

      The name of the application group, which you can change at any time.

      " + } + }, + "ApplicationTag": { + "target": "com.amazonaws.resourcegroups#ApplicationTag", + "traits": { + "smithy.api#documentation": "

      A tag that defines the application group membership. This tag is only supported \n for application groups.

      " + } } }, "traits": { @@ -1768,7 +2048,17 @@ "min": 12, "max": 1600 }, - "smithy.api#pattern": "^arn:aws(-[a-z]+)*:resource-groups:[a-z]{2}(-[a-z]+)+-\\d{1}:[0-9]{12}:group/[a-zA-Z0-9_\\.-]{1,300}$" + "smithy.api#pattern": "^arn:aws(-[a-z]+)*:resource-groups:[a-z]{2}(-[a-z]+)+-\\d{1}:[0-9]{12}:group/([a-zA-Z0-9_\\.-]{1,300}|[a-zA-Z0-9_\\.-]{1,150}/[a-z0-9]{26})$" + } + }, + "com.amazonaws.resourcegroups#GroupArnV2": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 12, + "max": 1600 + }, + "smithy.api#pattern": "^arn:aws(-[a-z]+)*:resource-groups:[a-z]{2}(-[a-z]+)+-\\d{1}:[0-9]{12}:group/([a-zA-Z0-9_\\.-]{1,300}|[a-zA-Z0-9_\\.-]{1,150}/[a-z0-9]{26})$" } }, "com.amazonaws.resourcegroups#GroupConfiguration": { @@ -1961,6 +2251,24 @@ "traits": { "smithy.api#enumValue": "configuration-type" } + }, + "Owner": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "owner" + } + }, + "DisplayName": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "display-name" + } + }, + "Criticality": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "criticality" + } } } }, @@ -1969,9 +2277,9 @@ "traits": { "smithy.api#length": { "min": 1, - "max": 128 + "max": 300 }, - "smithy.api#pattern": "^AWS::(AllSupported|[a-zA-Z0-9]+::[a-zA-Z0-9]+)$" + "smithy.api#pattern": "^AWS::(AllSupported|[a-zA-Z0-9]+::[a-zA-Z0-9]+)|[\\s\\p{L}0-9_\\.-]*$" } }, "com.amazonaws.resourcegroups#GroupFilterValues": { @@ -1998,7 +2306,31 @@ "GroupArn": { "target": "com.amazonaws.resourcegroups#GroupArn", "traits": { - "smithy.api#documentation": "

      The ARN of the resource group.

      " + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the resource group.

      " + } + }, + "Description": { + "target": "com.amazonaws.resourcegroups#Description", + "traits": { + "smithy.api#documentation": "

      The description of the application group.

      " + } + }, + "Criticality": { + "target": "com.amazonaws.resourcegroups#Criticality", + "traits": { + "smithy.api#documentation": "

      The critical rank of the application group on a scale of 1 to 10, with a \n rank of 1 being the most critical, and a rank of 10 being least critical.

      " + } + }, + "Owner": { + "target": "com.amazonaws.resourcegroups#Owner", + "traits": { + "smithy.api#documentation": "

      A name, email address or other identifier for the person or group \n who is considered as the owner of this group within your organization.

      " + } + }, + "DisplayName": { + "target": "com.amazonaws.resourcegroups#DisplayName", + "traits": { + "smithy.api#documentation": "

      The name of the application group, which you can change at any time.

      " } } }, @@ -2080,7 +2412,7 @@ "min": 1, "max": 300 }, - "smithy.api#pattern": "^[a-zA-Z0-9_\\.-]+$" + "smithy.api#pattern": "^[a-zA-Z0-9_\\.-]{1,300}|[a-zA-Z0-9_\\.-]{1,150}/[a-z0-9]{26}$" } }, "com.amazonaws.resourcegroups#GroupParameterList": { @@ -2140,7 +2472,7 @@ } ], "traits": { - "smithy.api#documentation": "

      Adds the specified resources to the specified group.

      \n \n

      You can use this operation with only resource groups that are configured with the\n following types:

      \n
        \n
      • \n

        \n AWS::EC2::HostManagement\n

        \n
      • \n
      • \n

        \n AWS::EC2::CapacityReservationPool\n

        \n
      • \n
      \n

      Other resource group type and resource types aren't currently supported by this\n operation.

      \n
      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:GroupResources\n

        \n
      • \n
      ", + "smithy.api#documentation": "

      Adds the specified resources to the specified group.

      \n \n

      You can only use this operation with the following groups:

      \n
        \n
      • \n

        \n AWS::EC2::HostManagement\n

        \n
      • \n
      • \n

        \n AWS::EC2::CapacityReservationPool\n

        \n
      • \n
      • \n

        \n AWS::ResourceGroups::ApplicationGroup\n

        \n
      • \n
      \n

      Other resource group types and resource types are not currently supported by this\n operation.

      \n
      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:GroupResources\n

        \n
      • \n
      ", "smithy.api#http": { "method": "POST", "uri": "/group-resources", @@ -2152,16 +2484,16 @@ "type": "structure", "members": { "Group": { - "target": "com.amazonaws.resourcegroups#GroupString", + "target": "com.amazonaws.resourcegroups#GroupStringV2", "traits": { - "smithy.api#documentation": "

      The name or the ARN of the resource group to add resources to.

      ", + "smithy.api#documentation": "

      The name or the Amazon resource name (ARN) of the resource group to add resources to.

      ", "smithy.api#required": {} } }, "ResourceArns": { "target": "com.amazonaws.resourcegroups#ResourceArnList", "traits": { - "smithy.api#documentation": "

      The list of ARNs of the resources to be added to the group.

      ", + "smithy.api#documentation": "

      The list of Amazon resource names (ARNs) of the resources to be added to the group.

      ", "smithy.api#required": {} } } @@ -2176,19 +2508,19 @@ "Succeeded": { "target": "com.amazonaws.resourcegroups#ResourceArnList", "traits": { - "smithy.api#documentation": "

      A list of ARNs of the resources that this operation successfully added to the\n group.

      " + "smithy.api#documentation": "

      A list of Amazon resource names (ARNs) of the resources that this operation successfully added to the\n group.

      " } }, "Failed": { "target": "com.amazonaws.resourcegroups#FailedResourceList", "traits": { - "smithy.api#documentation": "

      A list of ARNs of any resources that this operation failed to add to the group.

      " + "smithy.api#documentation": "

      A list of Amazon resource names (ARNs) of any resources that this operation failed to add to the group.

      " } }, "Pending": { "target": "com.amazonaws.resourcegroups#PendingResourceList", "traits": { - "smithy.api#documentation": "

      A list of ARNs of any resources that this operation is still in the process adding to\n the group. These pending additions continue asynchronously. You can check the status of\n pending additions by using the \n ListGroupResources\n \n operation, and checking the Resources array in the response and the\n Status field of each object in that array.

      " + "smithy.api#documentation": "

      A list of Amazon resource names (ARNs) of any resources that this operation is still in the process adding to\n the group. These pending additions continue asynchronously. You can check the status of\n pending additions by using the \n ListGroupResources\n \n operation, and checking the Resources array in the response and the\n Status field of each object in that array.

      " } } }, @@ -2203,16 +2535,122 @@ "min": 1, "max": 1600 }, - "smithy.api#pattern": "^(arn:aws(-[a-z]+)*:resource-groups:[a-z]{2}(-[a-z]+)+-\\d{1}:[0-9]{12}:group/)?[a-zA-Z0-9_\\.-]{1,300}$" + "smithy.api#pattern": "^[a-zA-Z0-9_\\.-]{1,300}|[a-zA-Z0-9_\\.-]{1,150}/[a-z0-9]{26}|arn:aws(-[a-z]+)*:resource-groups:[a-z]{2}(-[a-z]+)+-\\d{1}:[0-9]{12}:group/([a-zA-Z0-9_\\.-]{1,300}|[a-zA-Z0-9_\\.-]{1,150}/[a-z0-9]{26})$" } }, - "com.amazonaws.resourcegroups#InternalServerErrorException": { - "type": "structure", - "members": { - "Message": { - "target": "com.amazonaws.resourcegroups#ErrorMessage" - } - }, + "com.amazonaws.resourcegroups#GroupStringV2": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 1, + "max": 1600 + }, + "smithy.api#pattern": "^[a-zA-Z0-9_\\.-]{1,300}|[a-zA-Z0-9_\\.-]{1,150}/[a-z0-9]{26}|arn:aws(-[a-z]+)*:resource-groups:[a-z]{2}(-[a-z]+)+-\\d{1}:[0-9]{12}:group/([a-zA-Z0-9_\\.-]{1,300}|[a-zA-Z0-9_\\.-]{1,150}/[a-z0-9]{26})$" + } + }, + "com.amazonaws.resourcegroups#GroupingStatus": { + "type": "enum", + "members": { + "SUCCESS": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "SUCCESS" + } + }, + "FAILED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "FAILED" + } + }, + "IN_PROGRESS": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "IN_PROGRESS" + } + }, + "SKIPPED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "SKIPPED" + } + } + } + }, + "com.amazonaws.resourcegroups#GroupingStatusesItem": { + "type": "structure", + "members": { + "ResourceArn": { + "target": "com.amazonaws.resourcegroups#ResourceArn", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of a resource.

      " + } + }, + "Action": { + "target": "com.amazonaws.resourcegroups#GroupingType", + "traits": { + "smithy.api#documentation": "

      Describes the resource grouping action with values of \n GROUP or UNGROUP.

      " + } + }, + "Status": { + "target": "com.amazonaws.resourcegroups#GroupingStatus", + "traits": { + "smithy.api#documentation": "

      Describes the resource grouping status with values of \n SUCCESS, FAILED, IN_PROGRESS, \n or SKIPPED.

      " + } + }, + "ErrorMessage": { + "target": "com.amazonaws.resourcegroups#ErrorMessage", + "traits": { + "smithy.api#documentation": "

      A message that explains the ErrorCode.

      " + } + }, + "ErrorCode": { + "target": "com.amazonaws.resourcegroups#ErrorCode", + "traits": { + "smithy.api#documentation": "

      Specifies the error code that was raised.

      " + } + }, + "UpdatedAt": { + "target": "com.amazonaws.resourcegroups#timestamp", + "traits": { + "smithy.api#documentation": "

      A timestamp of when the status was last updated.

      " + } + } + }, + "traits": { + "smithy.api#documentation": "

      The information about a grouping or ungrouping resource action.

      " + } + }, + "com.amazonaws.resourcegroups#GroupingStatusesList": { + "type": "list", + "member": { + "target": "com.amazonaws.resourcegroups#GroupingStatusesItem" + } + }, + "com.amazonaws.resourcegroups#GroupingType": { + "type": "enum", + "members": { + "GROUP": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "GROUP" + } + }, + "UNGROUP": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "UNGROUP" + } + } + } + }, + "com.amazonaws.resourcegroups#InternalServerErrorException": { + "type": "structure", + "members": { + "Message": { + "target": "com.amazonaws.resourcegroups#ErrorMessage" + } + }, "traits": { "smithy.api#documentation": "

      An internal error occurred while processing the request. Try again later.

      ", "smithy.api#error": "server", @@ -2251,7 +2689,7 @@ } ], "traits": { - "smithy.api#documentation": "

      Returns a list of ARNs of the resources that are members of a specified resource\n group.

      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:ListGroupResources\n

        \n
      • \n
      • \n

        \n cloudformation:DescribeStacks\n

        \n
      • \n
      • \n

        \n cloudformation:ListStackResources\n

        \n
      • \n
      • \n

        \n tag:GetResources\n

        \n
      • \n
      ", + "smithy.api#documentation": "

      Returns a list of Amazon resource names (ARNs) of the resources that are members of a specified resource\n group.

      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:ListGroupResources\n

        \n
      • \n
      • \n

        \n cloudformation:DescribeStacks\n

        \n
      • \n
      • \n

        \n cloudformation:ListStackResources\n

        \n
      • \n
      • \n

        \n tag:GetResources\n

        \n
      • \n
      ", "smithy.api#http": { "method": "POST", "uri": "/list-group-resources", @@ -2278,9 +2716,9 @@ } }, "Group": { - "target": "com.amazonaws.resourcegroups#GroupString", + "target": "com.amazonaws.resourcegroups#GroupStringV2", "traits": { - "smithy.api#documentation": "

      The name or the ARN of the resource group

      " + "smithy.api#documentation": "

      The name or the Amazon resource name (ARN) of the resource group.

      " } }, "Filters": { @@ -2364,6 +2802,168 @@ "smithy.api#output": {} } }, + "com.amazonaws.resourcegroups#ListGroupingStatuses": { + "type": "operation", + "input": { + "target": "com.amazonaws.resourcegroups#ListGroupingStatusesInput" + }, + "output": { + "target": "com.amazonaws.resourcegroups#ListGroupingStatusesOutput" + }, + "errors": [ + { + "target": "com.amazonaws.resourcegroups#BadRequestException" + }, + { + "target": "com.amazonaws.resourcegroups#ForbiddenException" + }, + { + "target": "com.amazonaws.resourcegroups#InternalServerErrorException" + }, + { + "target": "com.amazonaws.resourcegroups#MethodNotAllowedException" + }, + { + "target": "com.amazonaws.resourcegroups#TooManyRequestsException" + } + ], + "traits": { + "smithy.api#documentation": "

      Returns the status of the last grouping or ungrouping action for \n each resource in the specified application group.

      ", + "smithy.api#http": { + "method": "POST", + "uri": "/list-grouping-statuses", + "code": 200 + }, + "smithy.api#paginated": { + "inputToken": "NextToken", + "outputToken": "NextToken", + "items": "GroupingStatuses", + "pageSize": "MaxResults" + } + } + }, + "com.amazonaws.resourcegroups#ListGroupingStatusesFilter": { + "type": "structure", + "members": { + "Name": { + "target": "com.amazonaws.resourcegroups#ListGroupingStatusesFilterName", + "traits": { + "smithy.api#documentation": "

      The name of the filter. Filter names are case-sensitive.

      ", + "smithy.api#required": {} + } + }, + "Values": { + "target": "com.amazonaws.resourcegroups#ListGroupingStatusesFilterValues", + "traits": { + "smithy.api#documentation": "

      One or more filter values. Allowed filter values vary by resource filter name, and are case-sensitive.

      ", + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#documentation": "

      A filter name and value pair that is used to obtain more specific results from the list of grouping statuses.

      " + } + }, + "com.amazonaws.resourcegroups#ListGroupingStatusesFilterList": { + "type": "list", + "member": { + "target": "com.amazonaws.resourcegroups#ListGroupingStatusesFilter" + } + }, + "com.amazonaws.resourcegroups#ListGroupingStatusesFilterName": { + "type": "enum", + "members": { + "Status": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "status" + } + }, + "ResourceArn": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "resource-arn" + } + } + } + }, + "com.amazonaws.resourcegroups#ListGroupingStatusesFilterValue": { + "type": "string", + "traits": { + "smithy.api#pattern": "^SUCCESS|FAILED|IN_PROGRESS|SKIPPED|arn:aws(-[a-z]+)*:[a-z0-9\\-]*:([a-z]{2}(-[a-z]+)+-\\d{1})?:([0-9]{12})?:.+$" + } + }, + "com.amazonaws.resourcegroups#ListGroupingStatusesFilterValues": { + "type": "list", + "member": { + "target": "com.amazonaws.resourcegroups#ListGroupingStatusesFilterValue" + }, + "traits": { + "smithy.api#length": { + "min": 1, + "max": 10 + } + } + }, + "com.amazonaws.resourcegroups#ListGroupingStatusesInput": { + "type": "structure", + "members": { + "Group": { + "target": "com.amazonaws.resourcegroups#GroupStringV2", + "traits": { + "smithy.api#documentation": "

      The application group identifier, expressed as an Amazon resource name (ARN) or the application group name.

      ", + "smithy.api#required": {} + } + }, + "MaxResults": { + "target": "com.amazonaws.resourcegroups#MaxResults", + "traits": { + "smithy.api#documentation": "

      The maximum number of resources and their statuses returned in the \n response.

      " + } + }, + "Filters": { + "target": "com.amazonaws.resourcegroups#ListGroupingStatusesFilterList", + "traits": { + "smithy.api#documentation": "

      The filter name and value pair that is used to return more \n specific results from a list of resources.

      " + } + }, + "NextToken": { + "target": "com.amazonaws.resourcegroups#NextToken", + "traits": { + "smithy.api#documentation": "

      The parameter for receiving additional results if you receive a \n NextToken response in a previous request. A NextToken \n response indicates that more output is available. Set this parameter to the \n value provided by a previous call's NextToken response to indicate \n where the output should continue from.

      " + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.resourcegroups#ListGroupingStatusesOutput": { + "type": "structure", + "members": { + "Group": { + "target": "com.amazonaws.resourcegroups#GroupStringV2", + "traits": { + "smithy.api#documentation": "

      The application group identifier, expressed as an Amazon resource name (ARN) or the application group name.

      " + } + }, + "GroupingStatuses": { + "target": "com.amazonaws.resourcegroups#GroupingStatusesList", + "traits": { + "smithy.api#documentation": "

      Returns details about the grouping or ungrouping status of the \n resources in the specified application group.

      " + } + }, + "NextToken": { + "target": "com.amazonaws.resourcegroups#NextToken", + "traits": { + "smithy.api#documentation": "

      If present, indicates that more output is available than is included in the current response. \n Use this value in the NextToken request parameter in a subsequent call to the operation to get the next part of the output. \n You should repeat this until the NextToken response element comes back as null.

      " + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, "com.amazonaws.resourcegroups#ListGroups": { "type": "operation", "input": { @@ -2410,7 +3010,7 @@ "Filters": { "target": "com.amazonaws.resourcegroups#GroupFilterList", "traits": { - "smithy.api#documentation": "

      Filters, formatted as GroupFilter objects, that you want to apply to\n a ListGroups operation.

      \n
        \n
      • \n

        \n resource-type - Filter the results to include only those resource groups that have the specified\n resource type in their ResourceTypeFilter. For example, AWS::EC2::Instance would\n return any resource group with a ResourceTypeFilter that includes\n AWS::EC2::Instance.

        \n
      • \n
      • \n

        \n configuration-type - Filter the results to include only those\n groups that have the specified configuration types attached. The current\n supported values are:

        \n
          \n
        • \n

          \n AWS::AppRegistry::Application\n

          \n
        • \n
        • \n

          \n AWS::AppRegistry::ApplicationResourceGroups\n

          \n
        • \n
        • \n

          \n AWS::CloudFormation::Stack\n

          \n
        • \n
        • \n

          \n AWS::EC2::CapacityReservationPool\n

          \n
        • \n
        • \n

          \n AWS::EC2::HostManagement\n

          \n
        • \n
        • \n

          \n AWS::NetworkFirewall::RuleGroup\n

          \n
        • \n
        \n
      • \n
      " + "smithy.api#documentation": "

      Filters, formatted as GroupFilter objects, that you want to apply to\n a ListGroups operation.

      \n
        \n
      • \n

        \n resource-type - Filter the results to include only those resource groups that have the specified\n resource type in their ResourceTypeFilter. For example, AWS::EC2::Instance would\n return any resource group with a ResourceTypeFilter that includes\n AWS::EC2::Instance.

        \n
      • \n
      • \n

        \n configuration-type - Filter the results to include only those\n groups that have the specified configuration types attached. The current\n supported values are:

        \n
          \n
        • \n

          \n AWS::ResourceGroups::ApplicationGroup\n

          \n
        • \n
        • \n

          \n AWS::AppRegistry::Application\n

          \n
        • \n
        • \n

          \n AWS::AppRegistry::ApplicationResourceGroups\n

          \n
        • \n
        • \n

          \n AWS::CloudFormation::Stack\n

          \n
        • \n
        • \n

          \n AWS::EC2::CapacityReservationPool\n

          \n
        • \n
        • \n

          \n AWS::EC2::HostManagement\n

          \n
        • \n
        • \n

          \n AWS::NetworkFirewall::RuleGroup\n

          \n
        • \n
        \n
      • \n
      " } }, "MaxResults": { @@ -2461,6 +3061,121 @@ "smithy.api#output": {} } }, + "com.amazonaws.resourcegroups#ListTagSyncTasks": { + "type": "operation", + "input": { + "target": "com.amazonaws.resourcegroups#ListTagSyncTasksInput" + }, + "output": { + "target": "com.amazonaws.resourcegroups#ListTagSyncTasksOutput" + }, + "errors": [ + { + "target": "com.amazonaws.resourcegroups#BadRequestException" + }, + { + "target": "com.amazonaws.resourcegroups#ForbiddenException" + }, + { + "target": "com.amazonaws.resourcegroups#InternalServerErrorException" + }, + { + "target": "com.amazonaws.resourcegroups#MethodNotAllowedException" + }, + { + "target": "com.amazonaws.resourcegroups#TooManyRequestsException" + }, + { + "target": "com.amazonaws.resourcegroups#UnauthorizedException" + } + ], + "traits": { + "smithy.api#documentation": "

      Returns a list of tag-sync tasks.

      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:ListTagSyncTasks with the group passed in the filters as the resource \n or * if using no filters

        \n
      • \n
      ", + "smithy.api#http": { + "method": "POST", + "uri": "/list-tag-sync-tasks", + "code": 200 + }, + "smithy.api#paginated": { + "inputToken": "NextToken", + "outputToken": "NextToken", + "items": "TagSyncTasks", + "pageSize": "MaxResults" + } + } + }, + "com.amazonaws.resourcegroups#ListTagSyncTasksFilter": { + "type": "structure", + "members": { + "GroupArn": { + "target": "com.amazonaws.resourcegroups#GroupArnV2", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the application group.

      " + } + }, + "GroupName": { + "target": "com.amazonaws.resourcegroups#GroupName", + "traits": { + "smithy.api#documentation": "

      The name of the application group.

      " + } + } + }, + "traits": { + "smithy.api#documentation": "

      Returns tag-sync tasks filtered by the Amazon resource name (ARN) or name of a \n specified application group.

      " + } + }, + "com.amazonaws.resourcegroups#ListTagSyncTasksFilterList": { + "type": "list", + "member": { + "target": "com.amazonaws.resourcegroups#ListTagSyncTasksFilter" + } + }, + "com.amazonaws.resourcegroups#ListTagSyncTasksInput": { + "type": "structure", + "members": { + "Filters": { + "target": "com.amazonaws.resourcegroups#ListTagSyncTasksFilterList", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) or name of the application group for which you want to return a \n list of tag-sync tasks.

      " + } + }, + "MaxResults": { + "target": "com.amazonaws.resourcegroups#MaxResults", + "traits": { + "smithy.api#documentation": "

      The maximum number of results to be included in the response.

      " + } + }, + "NextToken": { + "target": "com.amazonaws.resourcegroups#NextToken", + "traits": { + "smithy.api#documentation": "

      The parameter for receiving additional results if you receive a \n NextToken response in a previous request. A NextToken \n response indicates that more output is available. Set this parameter to the \n value provided by a previous call's NextToken response to indicate \n where the output should continue from.

      " + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.resourcegroups#ListTagSyncTasksOutput": { + "type": "structure", + "members": { + "TagSyncTasks": { + "target": "com.amazonaws.resourcegroups#TagSyncTaskList", + "traits": { + "smithy.api#documentation": "

      A list of tag-sync tasks and information about each task.

      " + } + }, + "NextToken": { + "target": "com.amazonaws.resourcegroups#NextToken", + "traits": { + "smithy.api#documentation": "

      If present, indicates that more output is available than is included in the current response. \n Use this value in the NextToken request parameter in a subsequent call to the operation to get the next part of the output. \n You should repeat this until the NextToken response element comes back as null.

      " + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, "com.amazonaws.resourcegroups#MaxResults": { "type": "integer", "traits": { @@ -2506,6 +3221,16 @@ "smithy.api#httpError": 404 } }, + "com.amazonaws.resourcegroups#Owner": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 0, + "max": 300 + }, + "smithy.api#pattern": "^([\\p{L}\\p{Z}\\p{N}_.:/=+\\-@]*)$" + } + }, "com.amazonaws.resourcegroups#PendingResource": { "type": "structure", "members": { @@ -2569,7 +3294,7 @@ "Group": { "target": "com.amazonaws.resourcegroups#GroupString", "traits": { - "smithy.api#documentation": "

      The name or ARN of the resource group with the configuration that you want to\n update.

      " + "smithy.api#documentation": "

      The name or Amazon resource name (ARN) of the resource group with the configuration that you want to\n update.

      " } }, "Configuration": { @@ -2767,7 +3492,7 @@ "ResourceArn": { "target": "com.amazonaws.resourcegroups#ResourceArn", "traits": { - "smithy.api#documentation": "

      The ARN of a resource.

      " + "smithy.api#documentation": "

      The Amazon resource name (ARN) of a resource.

      " } }, "ResourceType": { @@ -2793,7 +3518,7 @@ "Type": { "target": "com.amazonaws.resourcegroups#QueryType", "traits": { - "smithy.api#documentation": "

      The type of the query to perform. This can have one of two values:

      \n
        \n
      • \n

        \n \n CLOUDFORMATION_STACK_1_0:\n Specifies that you\n want the group to contain the members of an CloudFormation stack. The Query\n contains a StackIdentifier element with an ARN for a CloudFormation\n stack.

        \n
      • \n
      • \n

        \n \n TAG_FILTERS_1_0:\n Specifies that you want the\n group to include resource that have tags that match the query.

        \n
      • \n
      ", + "smithy.api#documentation": "

      The type of the query to perform. This can have one of two values:

      \n
        \n
      • \n

        \n \n CLOUDFORMATION_STACK_1_0:\n Specifies that you\n want the group to contain the members of an CloudFormation stack. The Query\n contains a StackIdentifier element with an Amazon resource name (ARN) for a CloudFormation\n stack.

        \n
      • \n
      • \n

        \n \n TAG_FILTERS_1_0:\n Specifies that you want the\n group to include resource that have tags that match the query.

        \n
      • \n
      ", "smithy.api#required": {} } }, @@ -2840,6 +3565,16 @@ "smithy.api#pattern": "^AWS::[a-zA-Z0-9]+::\\w+$" } }, + "com.amazonaws.resourcegroups#RoleArn": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 20, + "max": 2048 + }, + "smithy.api#pattern": "^arn:(aws[a-zA-Z-]*)?:iam::\\d{12}:role/?[a-zA-Z_0-9+=,.@\\-_/]+$" + } + }, "com.amazonaws.resourcegroups#SearchResources": { "type": "operation", "input": { @@ -2936,6 +3671,126 @@ "smithy.api#output": {} } }, + "com.amazonaws.resourcegroups#StartTagSyncTask": { + "type": "operation", + "input": { + "target": "com.amazonaws.resourcegroups#StartTagSyncTaskInput" + }, + "output": { + "target": "com.amazonaws.resourcegroups#StartTagSyncTaskOutput" + }, + "errors": [ + { + "target": "com.amazonaws.resourcegroups#BadRequestException" + }, + { + "target": "com.amazonaws.resourcegroups#ForbiddenException" + }, + { + "target": "com.amazonaws.resourcegroups#InternalServerErrorException" + }, + { + "target": "com.amazonaws.resourcegroups#MethodNotAllowedException" + }, + { + "target": "com.amazonaws.resourcegroups#NotFoundException" + }, + { + "target": "com.amazonaws.resourcegroups#TooManyRequestsException" + }, + { + "target": "com.amazonaws.resourcegroups#UnauthorizedException" + } + ], + "traits": { + "smithy.api#documentation": "

      Creates a new tag-sync task to onboard and sync resources tagged with a specific tag key-value pair to an \n application.

      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:StartTagSyncTask on the application group

        \n
      • \n
      • \n

        \n resource-groups:CreateGroup\n

        \n
      • \n
      • \n

        \n iam:PassRole on the role provided in the request

        \n
      • \n
      ", + "smithy.api#http": { + "method": "POST", + "uri": "/start-tag-sync-task", + "code": 200 + } + } + }, + "com.amazonaws.resourcegroups#StartTagSyncTaskInput": { + "type": "structure", + "members": { + "Group": { + "target": "com.amazonaws.resourcegroups#GroupStringV2", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) or name of the application group for which you want to create a tag-sync task.

      ", + "smithy.api#required": {} + } + }, + "TagKey": { + "target": "com.amazonaws.resourcegroups#TagKey", + "traits": { + "smithy.api#documentation": "

      The tag key. Resources tagged with this tag key-value pair will be added to \n the application. If a resource with this tag is later untagged, the tag-sync task removes\n the resource from the application.

      ", + "smithy.api#required": {} + } + }, + "TagValue": { + "target": "com.amazonaws.resourcegroups#TagValue", + "traits": { + "smithy.api#documentation": "

      The tag value. Resources tagged with this tag key-value pair will be added to \n the application. If a resource with this tag is later untagged, the tag-sync task removes\n the resource from the application.

      ", + "smithy.api#required": {} + } + }, + "RoleArn": { + "target": "com.amazonaws.resourcegroups#RoleArn", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the role assumed by the service to tag and untag resources on your behalf.

      ", + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.resourcegroups#StartTagSyncTaskOutput": { + "type": "structure", + "members": { + "GroupArn": { + "target": "com.amazonaws.resourcegroups#GroupArnV2", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the application group for which you want to add or remove resources.

      " + } + }, + "GroupName": { + "target": "com.amazonaws.resourcegroups#GroupName", + "traits": { + "smithy.api#documentation": "

      The name of the application group to onboard and sync resources.

      " + } + }, + "TaskArn": { + "target": "com.amazonaws.resourcegroups#TagSyncTaskArn", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the new tag-sync task.

      " + } + }, + "TagKey": { + "target": "com.amazonaws.resourcegroups#TagKey", + "traits": { + "smithy.api#documentation": "

      The tag key of the tag-sync task.

      " + } + }, + "TagValue": { + "target": "com.amazonaws.resourcegroups#TagValue", + "traits": { + "smithy.api#documentation": "

      The tag value of the tag-sync task.

      " + } + }, + "RoleArn": { + "target": "com.amazonaws.resourcegroups#RoleArn", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the role assumed by the service to tag and untag resources on your behalf.

      " + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, "com.amazonaws.resourcegroups#Tag": { "type": "operation", "input": { @@ -2965,7 +3820,7 @@ } ], "traits": { - "smithy.api#documentation": "

      Adds tags to a resource group with the specified ARN. Existing tags on a resource\n group are not changed if they are not specified in the request parameters.

      \n \n

      Do not store personally identifiable information (PII) or other confidential or\n sensitive information in tags. We use tags to provide you with billing and\n administration services. Tags are not intended to be used for private or sensitive\n data.

      \n
      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:Tag\n

        \n
      • \n
      ", + "smithy.api#documentation": "

      Adds tags to a resource group with the specified Amazon resource name (ARN). Existing tags on a resource\n group are not changed if they are not specified in the request parameters.

      \n \n

      Do not store personally identifiable information (PII) or other confidential or\n sensitive information in tags. We use tags to provide you with billing and\n administration services. Tags are not intended to be used for private or sensitive\n data.

      \n
      \n

      \n Minimum permissions\n

      \n

      To run this command, you must have the following permissions:

      \n
        \n
      • \n

        \n resource-groups:Tag\n

        \n
      • \n
      ", "smithy.api#http": { "method": "PUT", "uri": "/resources/{Arn}/tags", @@ -2977,9 +3832,9 @@ "type": "structure", "members": { "Arn": { - "target": "com.amazonaws.resourcegroups#GroupArn", + "target": "com.amazonaws.resourcegroups#GroupArnV2", "traits": { - "smithy.api#documentation": "

      The ARN of the resource group to which to add tags.

      ", + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the resource group to which to add tags.

      ", "smithy.api#httpLabel": {}, "smithy.api#required": {} } @@ -3016,9 +3871,9 @@ "type": "structure", "members": { "Arn": { - "target": "com.amazonaws.resourcegroups#GroupArn", + "target": "com.amazonaws.resourcegroups#GroupArnV2", "traits": { - "smithy.api#documentation": "

      The ARN of the tagged resource.

      " + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the tagged resource.

      " } }, "Tags": { @@ -3032,6 +3887,101 @@ "smithy.api#output": {} } }, + "com.amazonaws.resourcegroups#TagSyncTaskArn": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 12, + "max": 1600 + }, + "smithy.api#pattern": "^arn:aws(-[a-z]+)*:resource-groups:[a-z]{2}(-[a-z]+)+-\\d{1}:[0-9]{12}:group/[a-zA-Z0-9_\\.-]{1,150}/[a-z0-9]{26}/tag-sync-task/[a-z0-9]{26}$" + } + }, + "com.amazonaws.resourcegroups#TagSyncTaskItem": { + "type": "structure", + "members": { + "GroupArn": { + "target": "com.amazonaws.resourcegroups#GroupArnV2", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the application group.

      " + } + }, + "GroupName": { + "target": "com.amazonaws.resourcegroups#GroupName", + "traits": { + "smithy.api#documentation": "

      The name of the application group.

      " + } + }, + "TaskArn": { + "target": "com.amazonaws.resourcegroups#TagSyncTaskArn", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the tag-sync task.

      " + } + }, + "TagKey": { + "target": "com.amazonaws.resourcegroups#TagKey", + "traits": { + "smithy.api#documentation": "

      The tag key.

      " + } + }, + "TagValue": { + "target": "com.amazonaws.resourcegroups#TagValue", + "traits": { + "smithy.api#documentation": "

      The tag value.

      " + } + }, + "RoleArn": { + "target": "com.amazonaws.resourcegroups#RoleArn", + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the role assumed by the service to tag and untag resources on your behalf.

      " + } + }, + "Status": { + "target": "com.amazonaws.resourcegroups#TagSyncTaskStatus", + "traits": { + "smithy.api#documentation": "

      The status of the tag-sync task.

      \n

      Valid values include:

      \n
        \n
      • \n

        \n ACTIVE - The tag-sync task is actively managing resources in \n the application by adding or removing the awsApplication tag from resources \n when they are tagged or untagged with the specified tag key-value pair. \n

        \n
      • \n
      • \n

        \n ERROR - The tag-sync task is not actively managing resources \n in the application. Review the ErrorMessage for more information about \n resolving the error. \n

        \n
      • \n
      " + } + }, + "ErrorMessage": { + "target": "com.amazonaws.resourcegroups#ErrorMessage", + "traits": { + "smithy.api#documentation": "

      The specific error message in cases where the tag-sync task status\n is Error.

      " + } + }, + "CreatedAt": { + "target": "com.amazonaws.resourcegroups#timestamp", + "traits": { + "smithy.api#documentation": "

      The timestamp of when the tag-sync task was created.

      " + } + } + }, + "traits": { + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the tag-sync task.

      " + } + }, + "com.amazonaws.resourcegroups#TagSyncTaskList": { + "type": "list", + "member": { + "target": "com.amazonaws.resourcegroups#TagSyncTaskItem" + } + }, + "com.amazonaws.resourcegroups#TagSyncTaskStatus": { + "type": "enum", + "members": { + "ACTIVE": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "ACTIVE" + } + }, + "ERROR": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "ERROR" + } + } + } + }, "com.amazonaws.resourcegroups#TagValue": { "type": "string", "traits": { @@ -3118,16 +4068,16 @@ "type": "structure", "members": { "Group": { - "target": "com.amazonaws.resourcegroups#GroupString", + "target": "com.amazonaws.resourcegroups#GroupStringV2", "traits": { - "smithy.api#documentation": "

      The name or the ARN of the resource group from which to remove the resources.

      ", + "smithy.api#documentation": "

      The name or the Amazon resource name (ARN) of the resource group from which to remove the resources.

      ", "smithy.api#required": {} } }, "ResourceArns": { "target": "com.amazonaws.resourcegroups#ResourceArnList", "traits": { - "smithy.api#documentation": "

      The ARNs of the resources to be removed from the group.

      ", + "smithy.api#documentation": "

      The Amazon resource names (ARNs) of the resources to be removed from the group.

      ", "smithy.api#required": {} } } @@ -3203,9 +4153,9 @@ "type": "structure", "members": { "Arn": { - "target": "com.amazonaws.resourcegroups#GroupArn", + "target": "com.amazonaws.resourcegroups#GroupArnV2", "traits": { - "smithy.api#documentation": "

      The ARN of the resource group from which to remove tags. The command removed both the\n specified keys and any values associated with those keys.

      ", + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the resource group from which to remove tags. The command removed both the\n specified keys and any values associated with those keys.

      ", "smithy.api#httpLabel": {}, "smithy.api#required": {} } @@ -3226,9 +4176,9 @@ "type": "structure", "members": { "Arn": { - "target": "com.amazonaws.resourcegroups#GroupArn", + "target": "com.amazonaws.resourcegroups#GroupArnV2", "traits": { - "smithy.api#documentation": "

      The ARN of the resource group from which tags have been removed.

      " + "smithy.api#documentation": "

      The Amazon resource name (ARN) of the resource group from which tags have been removed.

      " } }, "Keys": { @@ -3282,7 +4232,7 @@ "GroupLifecycleEventsDesiredStatus": { "target": "com.amazonaws.resourcegroups#GroupLifecycleEventsDesiredStatus", "traits": { - "smithy.api#documentation": "

      Specifies whether you want to turn group lifecycle events on or off.

      " + "smithy.api#documentation": "

      Specifies whether you want to turn group lifecycle events on or off.

      \n

      You can't turn on group lifecycle events if your resource groups quota is greater than 2,000.

      " } } }, @@ -3354,9 +4304,9 @@ } }, "Group": { - "target": "com.amazonaws.resourcegroups#GroupString", + "target": "com.amazonaws.resourcegroups#GroupStringV2", "traits": { - "smithy.api#documentation": "

      The name or the ARN of the resource group to modify.

      " + "smithy.api#documentation": "

      The name or the ARN of the resource group to update.

      " } }, "Description": { @@ -3364,6 +4314,24 @@ "traits": { "smithy.api#documentation": "

      The new description that you want to update the resource group with. Descriptions can\n contain letters, numbers, hyphens, underscores, periods, and spaces.

      " } + }, + "Criticality": { + "target": "com.amazonaws.resourcegroups#Criticality", + "traits": { + "smithy.api#documentation": "

      The critical rank of the application group on a scale of 1 to 10, with a \n rank of 1 being the most critical, and a rank of 10 being least critical.

      " + } + }, + "Owner": { + "target": "com.amazonaws.resourcegroups#Owner", + "traits": { + "smithy.api#documentation": "

      A name, email address or other identifier for the person or group \n who is considered as the owner of this application group within your organization.

      " + } + }, + "DisplayName": { + "target": "com.amazonaws.resourcegroups#DisplayName", + "traits": { + "smithy.api#documentation": "

      The name of the application group, which you can change at any time.

      " + } } }, "traits": { @@ -3436,7 +4404,7 @@ "Group": { "target": "com.amazonaws.resourcegroups#GroupString", "traits": { - "smithy.api#documentation": "

      The name or the ARN of the resource group to query.

      " + "smithy.api#documentation": "

      The name or the Amazon resource name (ARN) of the resource group to query.

      " } }, "ResourceQuery": { @@ -3464,6 +4432,9 @@ "traits": { "smithy.api#output": {} } + }, + "com.amazonaws.resourcegroups#timestamp": { + "type": "timestamp" } } }