resourcegroups.d.ts 47 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757
  1. import {Request} from '../lib/request';
  2. import {Response} from '../lib/response';
  3. import {AWSError} from '../lib/error';
  4. import {Service} from '../lib/service';
  5. import {ServiceConfigurationOptions} from '../lib/service';
  6. import {ConfigBase as Config} from '../lib/config-base';
  7. interface Blob {}
  8. declare class ResourceGroups extends Service {
  9. /**
  10. * Constructs a service object. This object has one method for each API operation.
  11. */
  12. constructor(options?: ResourceGroups.Types.ClientConfiguration)
  13. config: Config & ResourceGroups.Types.ClientConfiguration;
  14. /**
  15. * Creates a resource group with the specified name and description. You can optionally include either a resource query or a service configuration. For more information about constructing a resource query, see Build queries and groups in Resource Groups in the Resource Groups User Guide. For more information about service-linked groups and service configurations, see Service configurations for Resource Groups. Minimum permissions To run this command, you must have the following permissions: resource-groups:CreateGroup
  16. */
  17. createGroup(params: ResourceGroups.Types.CreateGroupInput, callback?: (err: AWSError, data: ResourceGroups.Types.CreateGroupOutput) => void): Request<ResourceGroups.Types.CreateGroupOutput, AWSError>;
  18. /**
  19. * Creates a resource group with the specified name and description. You can optionally include either a resource query or a service configuration. For more information about constructing a resource query, see Build queries and groups in Resource Groups in the Resource Groups User Guide. For more information about service-linked groups and service configurations, see Service configurations for Resource Groups. Minimum permissions To run this command, you must have the following permissions: resource-groups:CreateGroup
  20. */
  21. createGroup(callback?: (err: AWSError, data: ResourceGroups.Types.CreateGroupOutput) => void): Request<ResourceGroups.Types.CreateGroupOutput, AWSError>;
  22. /**
  23. * Deletes the specified resource group. Deleting a resource group does not delete any resources that are members of the group; it only deletes the group structure. Minimum permissions To run this command, you must have the following permissions: resource-groups:DeleteGroup
  24. */
  25. deleteGroup(params: ResourceGroups.Types.DeleteGroupInput, callback?: (err: AWSError, data: ResourceGroups.Types.DeleteGroupOutput) => void): Request<ResourceGroups.Types.DeleteGroupOutput, AWSError>;
  26. /**
  27. * Deletes the specified resource group. Deleting a resource group does not delete any resources that are members of the group; it only deletes the group structure. Minimum permissions To run this command, you must have the following permissions: resource-groups:DeleteGroup
  28. */
  29. deleteGroup(callback?: (err: AWSError, data: ResourceGroups.Types.DeleteGroupOutput) => void): Request<ResourceGroups.Types.DeleteGroupOutput, AWSError>;
  30. /**
  31. * Retrieves the current status of optional features in Resource Groups.
  32. */
  33. getAccountSettings(callback?: (err: AWSError, data: ResourceGroups.Types.GetAccountSettingsOutput) => void): Request<ResourceGroups.Types.GetAccountSettingsOutput, AWSError>;
  34. /**
  35. * Returns information about a specified resource group. Minimum permissions To run this command, you must have the following permissions: resource-groups:GetGroup
  36. */
  37. getGroup(params: ResourceGroups.Types.GetGroupInput, callback?: (err: AWSError, data: ResourceGroups.Types.GetGroupOutput) => void): Request<ResourceGroups.Types.GetGroupOutput, AWSError>;
  38. /**
  39. * Returns information about a specified resource group. Minimum permissions To run this command, you must have the following permissions: resource-groups:GetGroup
  40. */
  41. getGroup(callback?: (err: AWSError, data: ResourceGroups.Types.GetGroupOutput) => void): Request<ResourceGroups.Types.GetGroupOutput, AWSError>;
  42. /**
  43. * Retrieves the service configuration associated with the specified resource group. For details about the service configuration syntax, see Service configurations for Resource Groups. Minimum permissions To run this command, you must have the following permissions: resource-groups:GetGroupConfiguration
  44. */
  45. getGroupConfiguration(params: ResourceGroups.Types.GetGroupConfigurationInput, callback?: (err: AWSError, data: ResourceGroups.Types.GetGroupConfigurationOutput) => void): Request<ResourceGroups.Types.GetGroupConfigurationOutput, AWSError>;
  46. /**
  47. * Retrieves the service configuration associated with the specified resource group. For details about the service configuration syntax, see Service configurations for Resource Groups. Minimum permissions To run this command, you must have the following permissions: resource-groups:GetGroupConfiguration
  48. */
  49. getGroupConfiguration(callback?: (err: AWSError, data: ResourceGroups.Types.GetGroupConfigurationOutput) => void): Request<ResourceGroups.Types.GetGroupConfigurationOutput, AWSError>;
  50. /**
  51. * Retrieves the resource query associated with the specified resource group. For more information about resource queries, see Create a tag-based group in Resource Groups. Minimum permissions To run this command, you must have the following permissions: resource-groups:GetGroupQuery
  52. */
  53. getGroupQuery(params: ResourceGroups.Types.GetGroupQueryInput, callback?: (err: AWSError, data: ResourceGroups.Types.GetGroupQueryOutput) => void): Request<ResourceGroups.Types.GetGroupQueryOutput, AWSError>;
  54. /**
  55. * Retrieves the resource query associated with the specified resource group. For more information about resource queries, see Create a tag-based group in Resource Groups. Minimum permissions To run this command, you must have the following permissions: resource-groups:GetGroupQuery
  56. */
  57. getGroupQuery(callback?: (err: AWSError, data: ResourceGroups.Types.GetGroupQueryOutput) => void): Request<ResourceGroups.Types.GetGroupQueryOutput, AWSError>;
  58. /**
  59. * Returns a list of tags that are associated with a resource group, specified by an ARN. Minimum permissions To run this command, you must have the following permissions: resource-groups:GetTags
  60. */
  61. getTags(params: ResourceGroups.Types.GetTagsInput, callback?: (err: AWSError, data: ResourceGroups.Types.GetTagsOutput) => void): Request<ResourceGroups.Types.GetTagsOutput, AWSError>;
  62. /**
  63. * Returns a list of tags that are associated with a resource group, specified by an ARN. Minimum permissions To run this command, you must have the following permissions: resource-groups:GetTags
  64. */
  65. getTags(callback?: (err: AWSError, data: ResourceGroups.Types.GetTagsOutput) => void): Request<ResourceGroups.Types.GetTagsOutput, AWSError>;
  66. /**
  67. * Adds the specified resources to the specified group. You can use this operation with only resource groups that are configured with the following types: AWS::EC2::HostManagement AWS::EC2::CapacityReservationPool Other resource group type and resource types aren't currently supported by this operation. Minimum permissions To run this command, you must have the following permissions: resource-groups:GroupResources
  68. */
  69. groupResources(params: ResourceGroups.Types.GroupResourcesInput, callback?: (err: AWSError, data: ResourceGroups.Types.GroupResourcesOutput) => void): Request<ResourceGroups.Types.GroupResourcesOutput, AWSError>;
  70. /**
  71. * Adds the specified resources to the specified group. You can use this operation with only resource groups that are configured with the following types: AWS::EC2::HostManagement AWS::EC2::CapacityReservationPool Other resource group type and resource types aren't currently supported by this operation. Minimum permissions To run this command, you must have the following permissions: resource-groups:GroupResources
  72. */
  73. groupResources(callback?: (err: AWSError, data: ResourceGroups.Types.GroupResourcesOutput) => void): Request<ResourceGroups.Types.GroupResourcesOutput, AWSError>;
  74. /**
  75. * Returns a list of ARNs of the resources that are members of a specified resource group. Minimum permissions To run this command, you must have the following permissions: resource-groups:ListGroupResources cloudformation:DescribeStacks cloudformation:ListStackResources tag:GetResources
  76. */
  77. listGroupResources(params: ResourceGroups.Types.ListGroupResourcesInput, callback?: (err: AWSError, data: ResourceGroups.Types.ListGroupResourcesOutput) => void): Request<ResourceGroups.Types.ListGroupResourcesOutput, AWSError>;
  78. /**
  79. * Returns a list of ARNs of the resources that are members of a specified resource group. Minimum permissions To run this command, you must have the following permissions: resource-groups:ListGroupResources cloudformation:DescribeStacks cloudformation:ListStackResources tag:GetResources
  80. */
  81. listGroupResources(callback?: (err: AWSError, data: ResourceGroups.Types.ListGroupResourcesOutput) => void): Request<ResourceGroups.Types.ListGroupResourcesOutput, AWSError>;
  82. /**
  83. * Returns a list of existing Resource Groups in your account. Minimum permissions To run this command, you must have the following permissions: resource-groups:ListGroups
  84. */
  85. listGroups(params: ResourceGroups.Types.ListGroupsInput, callback?: (err: AWSError, data: ResourceGroups.Types.ListGroupsOutput) => void): Request<ResourceGroups.Types.ListGroupsOutput, AWSError>;
  86. /**
  87. * Returns a list of existing Resource Groups in your account. Minimum permissions To run this command, you must have the following permissions: resource-groups:ListGroups
  88. */
  89. listGroups(callback?: (err: AWSError, data: ResourceGroups.Types.ListGroupsOutput) => void): Request<ResourceGroups.Types.ListGroupsOutput, AWSError>;
  90. /**
  91. * Attaches a service configuration to the specified group. This occurs asynchronously, and can take time to complete. You can use GetGroupConfiguration to check the status of the update. Minimum permissions To run this command, you must have the following permissions: resource-groups:PutGroupConfiguration
  92. */
  93. putGroupConfiguration(params: ResourceGroups.Types.PutGroupConfigurationInput, callback?: (err: AWSError, data: ResourceGroups.Types.PutGroupConfigurationOutput) => void): Request<ResourceGroups.Types.PutGroupConfigurationOutput, AWSError>;
  94. /**
  95. * Attaches a service configuration to the specified group. This occurs asynchronously, and can take time to complete. You can use GetGroupConfiguration to check the status of the update. Minimum permissions To run this command, you must have the following permissions: resource-groups:PutGroupConfiguration
  96. */
  97. putGroupConfiguration(callback?: (err: AWSError, data: ResourceGroups.Types.PutGroupConfigurationOutput) => void): Request<ResourceGroups.Types.PutGroupConfigurationOutput, AWSError>;
  98. /**
  99. * Returns a list of Amazon Web Services resource identifiers that matches the specified query. The query uses the same format as a resource query in a CreateGroup or UpdateGroupQuery operation. Minimum permissions To run this command, you must have the following permissions: resource-groups:SearchResources cloudformation:DescribeStacks cloudformation:ListStackResources tag:GetResources
  100. */
  101. searchResources(params: ResourceGroups.Types.SearchResourcesInput, callback?: (err: AWSError, data: ResourceGroups.Types.SearchResourcesOutput) => void): Request<ResourceGroups.Types.SearchResourcesOutput, AWSError>;
  102. /**
  103. * Returns a list of Amazon Web Services resource identifiers that matches the specified query. The query uses the same format as a resource query in a CreateGroup or UpdateGroupQuery operation. Minimum permissions To run this command, you must have the following permissions: resource-groups:SearchResources cloudformation:DescribeStacks cloudformation:ListStackResources tag:GetResources
  104. */
  105. searchResources(callback?: (err: AWSError, data: ResourceGroups.Types.SearchResourcesOutput) => void): Request<ResourceGroups.Types.SearchResourcesOutput, AWSError>;
  106. /**
  107. * Adds tags to a resource group with the specified 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 sensitive information in tags. We use tags to provide you with billing and administration services. Tags are not intended to be used for private or sensitive data. Minimum permissions To run this command, you must have the following permissions: resource-groups:Tag
  108. */
  109. tag(params: ResourceGroups.Types.TagInput, callback?: (err: AWSError, data: ResourceGroups.Types.TagOutput) => void): Request<ResourceGroups.Types.TagOutput, AWSError>;
  110. /**
  111. * Adds tags to a resource group with the specified 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 sensitive information in tags. We use tags to provide you with billing and administration services. Tags are not intended to be used for private or sensitive data. Minimum permissions To run this command, you must have the following permissions: resource-groups:Tag
  112. */
  113. tag(callback?: (err: AWSError, data: ResourceGroups.Types.TagOutput) => void): Request<ResourceGroups.Types.TagOutput, AWSError>;
  114. /**
  115. * Removes the specified resources from the specified group. This operation works only with static groups that you populated using the GroupResources operation. It doesn't work with any resource groups that are automatically populated by tag-based or CloudFormation stack-based queries. Minimum permissions To run this command, you must have the following permissions: resource-groups:UngroupResources
  116. */
  117. ungroupResources(params: ResourceGroups.Types.UngroupResourcesInput, callback?: (err: AWSError, data: ResourceGroups.Types.UngroupResourcesOutput) => void): Request<ResourceGroups.Types.UngroupResourcesOutput, AWSError>;
  118. /**
  119. * Removes the specified resources from the specified group. This operation works only with static groups that you populated using the GroupResources operation. It doesn't work with any resource groups that are automatically populated by tag-based or CloudFormation stack-based queries. Minimum permissions To run this command, you must have the following permissions: resource-groups:UngroupResources
  120. */
  121. ungroupResources(callback?: (err: AWSError, data: ResourceGroups.Types.UngroupResourcesOutput) => void): Request<ResourceGroups.Types.UngroupResourcesOutput, AWSError>;
  122. /**
  123. * Deletes tags from a specified resource group. Minimum permissions To run this command, you must have the following permissions: resource-groups:Untag
  124. */
  125. untag(params: ResourceGroups.Types.UntagInput, callback?: (err: AWSError, data: ResourceGroups.Types.UntagOutput) => void): Request<ResourceGroups.Types.UntagOutput, AWSError>;
  126. /**
  127. * Deletes tags from a specified resource group. Minimum permissions To run this command, you must have the following permissions: resource-groups:Untag
  128. */
  129. untag(callback?: (err: AWSError, data: ResourceGroups.Types.UntagOutput) => void): Request<ResourceGroups.Types.UntagOutput, AWSError>;
  130. /**
  131. * Turns on or turns off optional features in Resource Groups. The preceding example shows that the request to turn on group lifecycle events is IN_PROGRESS. You can call the GetAccountSettings operation to check for completion by looking for GroupLifecycleEventsStatus to change to ACTIVE.
  132. */
  133. updateAccountSettings(params: ResourceGroups.Types.UpdateAccountSettingsInput, callback?: (err: AWSError, data: ResourceGroups.Types.UpdateAccountSettingsOutput) => void): Request<ResourceGroups.Types.UpdateAccountSettingsOutput, AWSError>;
  134. /**
  135. * Turns on or turns off optional features in Resource Groups. The preceding example shows that the request to turn on group lifecycle events is IN_PROGRESS. You can call the GetAccountSettings operation to check for completion by looking for GroupLifecycleEventsStatus to change to ACTIVE.
  136. */
  137. updateAccountSettings(callback?: (err: AWSError, data: ResourceGroups.Types.UpdateAccountSettingsOutput) => void): Request<ResourceGroups.Types.UpdateAccountSettingsOutput, AWSError>;
  138. /**
  139. * Updates the description for an existing group. You cannot update the name of a resource group. Minimum permissions To run this command, you must have the following permissions: resource-groups:UpdateGroup
  140. */
  141. updateGroup(params: ResourceGroups.Types.UpdateGroupInput, callback?: (err: AWSError, data: ResourceGroups.Types.UpdateGroupOutput) => void): Request<ResourceGroups.Types.UpdateGroupOutput, AWSError>;
  142. /**
  143. * Updates the description for an existing group. You cannot update the name of a resource group. Minimum permissions To run this command, you must have the following permissions: resource-groups:UpdateGroup
  144. */
  145. updateGroup(callback?: (err: AWSError, data: ResourceGroups.Types.UpdateGroupOutput) => void): Request<ResourceGroups.Types.UpdateGroupOutput, AWSError>;
  146. /**
  147. * Updates the resource query of a group. For more information about resource queries, see Create a tag-based group in Resource Groups. Minimum permissions To run this command, you must have the following permissions: resource-groups:UpdateGroupQuery
  148. */
  149. updateGroupQuery(params: ResourceGroups.Types.UpdateGroupQueryInput, callback?: (err: AWSError, data: ResourceGroups.Types.UpdateGroupQueryOutput) => void): Request<ResourceGroups.Types.UpdateGroupQueryOutput, AWSError>;
  150. /**
  151. * Updates the resource query of a group. For more information about resource queries, see Create a tag-based group in Resource Groups. Minimum permissions To run this command, you must have the following permissions: resource-groups:UpdateGroupQuery
  152. */
  153. updateGroupQuery(callback?: (err: AWSError, data: ResourceGroups.Types.UpdateGroupQueryOutput) => void): Request<ResourceGroups.Types.UpdateGroupQueryOutput, AWSError>;
  154. }
  155. declare namespace ResourceGroups {
  156. export interface AccountSettings {
  157. /**
  158. * The desired target status of the group lifecycle events feature. If
  159. */
  160. GroupLifecycleEventsDesiredStatus?: GroupLifecycleEventsDesiredStatus;
  161. /**
  162. * The current status of the group lifecycle events feature.
  163. */
  164. GroupLifecycleEventsStatus?: GroupLifecycleEventsStatus;
  165. /**
  166. * The text of any error message occurs during an attempt to turn group lifecycle events on or off.
  167. */
  168. GroupLifecycleEventsStatusMessage?: GroupLifecycleEventsStatusMessage;
  169. }
  170. export interface CreateGroupInput {
  171. /**
  172. * The name of the group, which is the identifier of the group in other operations. You can't change the name of a resource group after you create it. A resource group name can consist of letters, numbers, hyphens, periods, and underscores. The name cannot start with AWS, aws, or any other possible capitalization; these are reserved. A resource group name must be unique within each Amazon Web Services Region in your Amazon Web Services account.
  173. */
  174. Name: GroupName;
  175. /**
  176. * The description of the resource group. Descriptions can consist of letters, numbers, hyphens, underscores, periods, and spaces.
  177. */
  178. Description?: Description;
  179. /**
  180. * The resource query that determines which Amazon Web Services resources are members of this group. For more information about resource queries, see Create a tag-based group in Resource Groups. A resource group can contain either a ResourceQuery or a Configuration, but not both.
  181. */
  182. ResourceQuery?: ResourceQuery;
  183. /**
  184. * The tags to add to the group. A tag is key-value pair string.
  185. */
  186. Tags?: Tags;
  187. /**
  188. * A configuration associates the resource group with an Amazon Web Services service and specifies how the service can interact with the resources in the group. A configuration is an array of GroupConfigurationItem elements. For details about the syntax of service configurations, see Service configurations for Resource Groups. A resource group can contain either a Configuration or a ResourceQuery, but not both.
  189. */
  190. Configuration?: GroupConfigurationList;
  191. }
  192. export interface CreateGroupOutput {
  193. /**
  194. * The description of the resource group.
  195. */
  196. Group?: Group;
  197. /**
  198. * The resource query associated with the group. For more information about resource queries, see Create a tag-based group in Resource Groups.
  199. */
  200. ResourceQuery?: ResourceQuery;
  201. /**
  202. * The tags associated with the group.
  203. */
  204. Tags?: Tags;
  205. /**
  206. * The service configuration associated with the resource group. For details about the syntax of a service configuration, see Service configurations for Resource Groups.
  207. */
  208. GroupConfiguration?: GroupConfiguration;
  209. }
  210. export interface DeleteGroupInput {
  211. /**
  212. * Deprecated - don't use this parameter. Use Group instead.
  213. */
  214. GroupName?: GroupName;
  215. /**
  216. * The name or the ARN of the resource group to delete.
  217. */
  218. Group?: GroupString;
  219. }
  220. export interface DeleteGroupOutput {
  221. /**
  222. * A full description of the deleted resource group.
  223. */
  224. Group?: Group;
  225. }
  226. export type Description = string;
  227. export type ErrorCode = string;
  228. export type ErrorMessage = string;
  229. export interface FailedResource {
  230. /**
  231. * The ARN of the resource that failed to be added or removed.
  232. */
  233. ResourceArn?: ResourceArn;
  234. /**
  235. * The error message text associated with the failure.
  236. */
  237. ErrorMessage?: ErrorMessage;
  238. /**
  239. * The error code associated with the failure.
  240. */
  241. ErrorCode?: ErrorCode;
  242. }
  243. export type FailedResourceList = FailedResource[];
  244. export interface GetAccountSettingsOutput {
  245. /**
  246. * The current settings for the optional features in Resource Groups.
  247. */
  248. AccountSettings?: AccountSettings;
  249. }
  250. export interface GetGroupConfigurationInput {
  251. /**
  252. * The name or the ARN of the resource group for which you want to retrive the service configuration.
  253. */
  254. Group?: GroupString;
  255. }
  256. export interface GetGroupConfigurationOutput {
  257. /**
  258. * A structure that describes the service configuration attached with the specified group. For details about the service configuration syntax, see Service configurations for Resource Groups.
  259. */
  260. GroupConfiguration?: GroupConfiguration;
  261. }
  262. export interface GetGroupInput {
  263. /**
  264. * Deprecated - don't use this parameter. Use Group instead.
  265. */
  266. GroupName?: GroupName;
  267. /**
  268. * The name or the ARN of the resource group to retrieve.
  269. */
  270. Group?: GroupString;
  271. }
  272. export interface GetGroupOutput {
  273. /**
  274. * A structure that contains the metadata details for the specified resource group. Use GetGroupQuery and GetGroupConfiguration to get those additional details of the resource group.
  275. */
  276. Group?: Group;
  277. }
  278. export interface GetGroupQueryInput {
  279. /**
  280. * Don't use this parameter. Use Group instead.
  281. */
  282. GroupName?: GroupName;
  283. /**
  284. * The name or the ARN of the resource group to query.
  285. */
  286. Group?: GroupString;
  287. }
  288. export interface GetGroupQueryOutput {
  289. /**
  290. * The resource query associated with the specified group. For more information about resource queries, see Create a tag-based group in Resource Groups.
  291. */
  292. GroupQuery?: GroupQuery;
  293. }
  294. export interface GetTagsInput {
  295. /**
  296. * The ARN of the resource group whose tags you want to retrieve.
  297. */
  298. Arn: GroupArn;
  299. }
  300. export interface GetTagsOutput {
  301. /**
  302. * The ARN of the tagged resource group.
  303. */
  304. Arn?: GroupArn;
  305. /**
  306. * The tags associated with the specified resource group.
  307. */
  308. Tags?: Tags;
  309. }
  310. export interface Group {
  311. /**
  312. * The ARN of the resource group.
  313. */
  314. GroupArn: GroupArn;
  315. /**
  316. * The name of the resource group.
  317. */
  318. Name: GroupName;
  319. /**
  320. * The description of the resource group.
  321. */
  322. Description?: Description;
  323. }
  324. export type GroupArn = string;
  325. export interface GroupConfiguration {
  326. /**
  327. * The configuration currently associated with the group and in effect.
  328. */
  329. Configuration?: GroupConfigurationList;
  330. /**
  331. * If present, the new configuration that is in the process of being applied to the group.
  332. */
  333. ProposedConfiguration?: GroupConfigurationList;
  334. /**
  335. * The current status of an attempt to update the group configuration.
  336. */
  337. Status?: GroupConfigurationStatus;
  338. /**
  339. * If present, the reason why a request to update the group configuration failed.
  340. */
  341. FailureReason?: GroupConfigurationFailureReason;
  342. }
  343. export type GroupConfigurationFailureReason = string;
  344. export interface GroupConfigurationItem {
  345. /**
  346. * Specifies the type of group configuration item. Each item must have a unique value for type. For the list of types that you can specify for a configuration item, see Supported resource types and parameters.
  347. */
  348. Type: GroupConfigurationType;
  349. /**
  350. * A collection of parameters for this group configuration item. For the list of parameters that you can use with each configuration item type, see Supported resource types and parameters.
  351. */
  352. Parameters?: GroupParameterList;
  353. }
  354. export type GroupConfigurationList = GroupConfigurationItem[];
  355. export interface GroupConfigurationParameter {
  356. /**
  357. * The name of the group configuration parameter. For the list of parameters that you can use with each configuration item type, see Supported resource types and parameters.
  358. */
  359. Name: GroupConfigurationParameterName;
  360. /**
  361. * The value or values to be used for the specified parameter. For the list of values you can use with each parameter, see Supported resource types and parameters.
  362. */
  363. Values?: GroupConfigurationParameterValueList;
  364. }
  365. export type GroupConfigurationParameterName = string;
  366. export type GroupConfigurationParameterValue = string;
  367. export type GroupConfigurationParameterValueList = GroupConfigurationParameterValue[];
  368. export type GroupConfigurationStatus = "UPDATING"|"UPDATE_COMPLETE"|"UPDATE_FAILED"|string;
  369. export type GroupConfigurationType = string;
  370. export interface GroupFilter {
  371. /**
  372. * The name of the filter. Filter names are case-sensitive.
  373. */
  374. Name: GroupFilterName;
  375. /**
  376. * One or more filter values. Allowed filter values vary by group filter name, and are case-sensitive.
  377. */
  378. Values: GroupFilterValues;
  379. }
  380. export type GroupFilterList = GroupFilter[];
  381. export type GroupFilterName = "resource-type"|"configuration-type"|string;
  382. export type GroupFilterValue = string;
  383. export type GroupFilterValues = GroupFilterValue[];
  384. export interface GroupIdentifier {
  385. /**
  386. * The name of the resource group.
  387. */
  388. GroupName?: GroupName;
  389. /**
  390. * The ARN of the resource group.
  391. */
  392. GroupArn?: GroupArn;
  393. }
  394. export type GroupIdentifierList = GroupIdentifier[];
  395. export type GroupLifecycleEventsDesiredStatus = "ACTIVE"|"INACTIVE"|string;
  396. export type GroupLifecycleEventsStatus = "ACTIVE"|"INACTIVE"|"IN_PROGRESS"|"ERROR"|string;
  397. export type GroupLifecycleEventsStatusMessage = string;
  398. export type GroupList = Group[];
  399. export type GroupName = string;
  400. export type GroupParameterList = GroupConfigurationParameter[];
  401. export interface GroupQuery {
  402. /**
  403. * The name of the resource group that is associated with the specified resource query.
  404. */
  405. GroupName: GroupName;
  406. /**
  407. * The resource query that determines which Amazon Web Services resources are members of the associated resource group.
  408. */
  409. ResourceQuery: ResourceQuery;
  410. }
  411. export interface GroupResourcesInput {
  412. /**
  413. * The name or the ARN of the resource group to add resources to.
  414. */
  415. Group: GroupString;
  416. /**
  417. * The list of ARNs of the resources to be added to the group.
  418. */
  419. ResourceArns: ResourceArnList;
  420. }
  421. export interface GroupResourcesOutput {
  422. /**
  423. * A list of ARNs of the resources that this operation successfully added to the group.
  424. */
  425. Succeeded?: ResourceArnList;
  426. /**
  427. * A list of ARNs of any resources that this operation failed to add to the group.
  428. */
  429. Failed?: FailedResourceList;
  430. /**
  431. * 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.
  432. */
  433. Pending?: PendingResourceList;
  434. }
  435. export type GroupString = string;
  436. export interface ListGroupResourcesInput {
  437. /**
  438. * Deprecated - don't use this parameter. Use the Group request field instead.
  439. */
  440. GroupName?: GroupName;
  441. /**
  442. * The name or the ARN of the resource group
  443. */
  444. Group?: GroupString;
  445. /**
  446. * Filters, formatted as ResourceFilter objects, that you want to apply to a ListGroupResources operation. Filters the results to include only those of the specified resource types. resource-type - Filter resources by their type. Specify up to five resource types in the format AWS::ServiceCode::ResourceType. For example, AWS::EC2::Instance, or AWS::S3::Bucket. When you specify a resource-type filter for ListGroupResources, Resource Groups validates your filter resource types against the types that are defined in the query associated with the group. For example, if a group contains only S3 buckets because its query specifies only that resource type, but your resource-type filter includes EC2 instances, AWS Resource Groups does not filter for EC2 instances. In this case, a ListGroupResources request returns a BadRequestException error with a message similar to the following: The resource types specified as filters in the request are not valid. The error includes a list of resource types that failed the validation because they are not part of the query associated with the group. This validation doesn't occur when the group query specifies AWS::AllSupported, because a group based on such a query can contain any of the allowed resource types for the query type (tag-based or Amazon CloudFront stack-based queries).
  447. */
  448. Filters?: ResourceFilterList;
  449. /**
  450. * The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the NextToken response element is present and has a value (is not null). Include that value as the NextToken request parameter in the next call to the operation to get the next part of the results. Note that the service might return fewer results than the maximum even when there are more results available. You should check NextToken after every operation to ensure that you receive all of the results.
  451. */
  452. MaxResults?: MaxResults;
  453. /**
  454. * 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.
  455. */
  456. NextToken?: NextToken;
  457. }
  458. export interface ListGroupResourcesItem {
  459. Identifier?: ResourceIdentifier;
  460. /**
  461. * A structure that contains the status of this resource's membership in the group. This field is present in the response only if the group is of type AWS::EC2::HostManagement.
  462. */
  463. Status?: ResourceStatus;
  464. }
  465. export type ListGroupResourcesItemList = ListGroupResourcesItem[];
  466. export interface ListGroupResourcesOutput {
  467. /**
  468. * An array of resources from which you can determine each resource's identity, type, and group membership status.
  469. */
  470. Resources?: ListGroupResourcesItemList;
  471. /**
  472. * Deprecated - don't use this parameter. Use the Resources response field instead.
  473. */
  474. ResourceIdentifiers?: ResourceIdentifierList;
  475. /**
  476. * 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.
  477. */
  478. NextToken?: NextToken;
  479. /**
  480. * A list of QueryError objects. Each error contains an ErrorCode and Message. Possible values for ErrorCode are CLOUDFORMATION_STACK_INACTIVE, CLOUDFORMATION_STACK_NOT_EXISTING, CLOUDFORMATION_STACK_UNASSUMABLE_ROLE and RESOURCE_TYPE_NOT_SUPPORTED.
  481. */
  482. QueryErrors?: QueryErrorList;
  483. }
  484. export interface ListGroupsInput {
  485. /**
  486. * Filters, formatted as GroupFilter objects, that you want to apply to a ListGroups operation. resource-type - Filter the results to include only those resource groups that have the specified resource type in their ResourceTypeFilter. For example, AWS::EC2::Instance would return any resource group with a ResourceTypeFilter that includes AWS::EC2::Instance. configuration-type - Filter the results to include only those groups that have the specified configuration types attached. The current supported values are: AWS::AppRegistry::Application AWS::AppRegistry::ApplicationResourceGroups AWS::CloudFormation::Stack AWS::EC2::CapacityReservationPool AWS::EC2::HostManagement AWS::NetworkFirewall::RuleGroup
  487. */
  488. Filters?: GroupFilterList;
  489. /**
  490. * The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the NextToken response element is present and has a value (is not null). Include that value as the NextToken request parameter in the next call to the operation to get the next part of the results. Note that the service might return fewer results than the maximum even when there are more results available. You should check NextToken after every operation to ensure that you receive all of the results.
  491. */
  492. MaxResults?: MaxResults;
  493. /**
  494. * 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.
  495. */
  496. NextToken?: NextToken;
  497. }
  498. export interface ListGroupsOutput {
  499. /**
  500. * A list of GroupIdentifier objects. Each identifier is an object that contains both the Name and the GroupArn.
  501. */
  502. GroupIdentifiers?: GroupIdentifierList;
  503. /**
  504. * Deprecated - don't use this field. Use the GroupIdentifiers response field instead.
  505. */
  506. Groups?: GroupList;
  507. /**
  508. * 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.
  509. */
  510. NextToken?: NextToken;
  511. }
  512. export type MaxResults = number;
  513. export type NextToken = string;
  514. export interface PendingResource {
  515. /**
  516. * The Amazon resource name (ARN) of the resource that's in a pending state.
  517. */
  518. ResourceArn?: ResourceArn;
  519. }
  520. export type PendingResourceList = PendingResource[];
  521. export interface PutGroupConfigurationInput {
  522. /**
  523. * The name or ARN of the resource group with the configuration that you want to update.
  524. */
  525. Group?: GroupString;
  526. /**
  527. * The new configuration to associate with the specified group. A configuration associates the resource group with an Amazon Web Services service and specifies how the service can interact with the resources in the group. A configuration is an array of GroupConfigurationItem elements. For information about the syntax of a service configuration, see Service configurations for Resource Groups. A resource group can contain either a Configuration or a ResourceQuery, but not both.
  528. */
  529. Configuration?: GroupConfigurationList;
  530. }
  531. export interface PutGroupConfigurationOutput {
  532. }
  533. export type Query = string;
  534. export interface QueryError {
  535. /**
  536. * Specifies the error code that was raised.
  537. */
  538. ErrorCode?: QueryErrorCode;
  539. /**
  540. * A message that explains the ErrorCode.
  541. */
  542. Message?: QueryErrorMessage;
  543. }
  544. export type QueryErrorCode = "CLOUDFORMATION_STACK_INACTIVE"|"CLOUDFORMATION_STACK_NOT_EXISTING"|"CLOUDFORMATION_STACK_UNASSUMABLE_ROLE"|"RESOURCE_TYPE_NOT_SUPPORTED"|string;
  545. export type QueryErrorList = QueryError[];
  546. export type QueryErrorMessage = string;
  547. export type QueryType = "TAG_FILTERS_1_0"|"CLOUDFORMATION_STACK_1_0"|string;
  548. export type ResourceArn = string;
  549. export type ResourceArnList = ResourceArn[];
  550. export interface ResourceFilter {
  551. /**
  552. * The name of the filter. Filter names are case-sensitive.
  553. */
  554. Name: ResourceFilterName;
  555. /**
  556. * One or more filter values. Allowed filter values vary by resource filter name, and are case-sensitive.
  557. */
  558. Values: ResourceFilterValues;
  559. }
  560. export type ResourceFilterList = ResourceFilter[];
  561. export type ResourceFilterName = "resource-type"|string;
  562. export type ResourceFilterValue = string;
  563. export type ResourceFilterValues = ResourceFilterValue[];
  564. export interface ResourceIdentifier {
  565. /**
  566. * The ARN of a resource.
  567. */
  568. ResourceArn?: ResourceArn;
  569. /**
  570. * The resource type of a resource, such as AWS::EC2::Instance.
  571. */
  572. ResourceType?: ResourceType;
  573. }
  574. export type ResourceIdentifierList = ResourceIdentifier[];
  575. export interface ResourceQuery {
  576. /**
  577. * The type of the query to perform. This can have one of two values: 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 stack. TAG_FILTERS_1_0: Specifies that you want the group to include resource that have tags that match the query.
  578. */
  579. Type: QueryType;
  580. /**
  581. * The query that defines a group or a search. The contents depends on the value of the Type element. ResourceTypeFilters – Applies to all ResourceQuery objects of either Type. This element contains one of the following two items: The value AWS::AllSupported. This causes the ResourceQuery to match resources of any resource type that also match the query. A list (a JSON array) of resource type identifiers that limit the query to only resources of the specified types. For the complete list of resource types that you can use in the array value for ResourceTypeFilters, see Resources you can use with Resource Groups and Tag Editor in the Resource Groups User Guide. Example: "ResourceTypeFilters": ["AWS::AllSupported"] or "ResourceTypeFilters": ["AWS::EC2::Instance", "AWS::S3::Bucket"] TagFilters – applicable only if Type = TAG_FILTERS_1_0. The Query contains a JSON string that represents a collection of simple tag filters. The JSON string uses a syntax similar to the GetResources operation, but uses only the ResourceTypeFilters and TagFilters fields. If you specify more than one tag key, only resources that match all tag keys, and at least one value of each specified tag key, are returned in your query. If you specify more than one value for a tag key, a resource matches the filter if it has a tag key value that matches any of the specified values. For example, consider the following sample query for resources that have two tags, Stage and Version, with two values each: [{"Stage":["Test","Deploy"]},{"Version":["1","2"]}] The results of this resource query could include the following. An Amazon EC2 instance that has the following two tags: {"Stage":"Deploy"}, and {"Version":"2"} An S3 bucket that has the following two tags: {"Stage":"Test"}, and {"Version":"1"} The resource query results would not include the following items in the results, however. An Amazon EC2 instance that has only the following tag: {"Stage":"Deploy"}. The instance does not have all of the tag keys specified in the filter, so it is excluded from the results. An RDS database that has the following two tags: {"Stage":"Archived"} and {"Version":"4"} The database has all of the tag keys, but none of those keys has an associated value that matches at least one of the specified values in the filter. Example: "TagFilters": [ { "Key": "Stage", "Values": [ "Gamma", "Beta" ] } StackIdentifier – applicable only if Type = CLOUDFORMATION_STACK_1_0. The value of this parameter is the Amazon Resource Name (ARN) of the CloudFormation stack whose resources you want included in the group.
  582. */
  583. Query: Query;
  584. }
  585. export interface ResourceStatus {
  586. /**
  587. * The current status.
  588. */
  589. Name?: ResourceStatusValue;
  590. }
  591. export type ResourceStatusValue = "PENDING"|string;
  592. export type ResourceType = string;
  593. export interface SearchResourcesInput {
  594. /**
  595. * The search query, using the same formats that are supported for resource group definition. For more information, see CreateGroup.
  596. */
  597. ResourceQuery: ResourceQuery;
  598. /**
  599. * The total number of results that you want included on each page of the response. If you do not include this parameter, it defaults to a value that is specific to the operation. If additional items exist beyond the maximum you specify, the NextToken response element is present and has a value (is not null). Include that value as the NextToken request parameter in the next call to the operation to get the next part of the results. Note that the service might return fewer results than the maximum even when there are more results available. You should check NextToken after every operation to ensure that you receive all of the results.
  600. */
  601. MaxResults?: MaxResults;
  602. /**
  603. * 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.
  604. */
  605. NextToken?: NextToken;
  606. }
  607. export interface SearchResourcesOutput {
  608. /**
  609. * The ARNs and resource types of resources that are members of the group that you specified.
  610. */
  611. ResourceIdentifiers?: ResourceIdentifierList;
  612. /**
  613. * 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.
  614. */
  615. NextToken?: NextToken;
  616. /**
  617. * A list of QueryError objects. Each error contains an ErrorCode and Message. Possible values for ErrorCode: CLOUDFORMATION_STACK_INACTIVE CLOUDFORMATION_STACK_NOT_EXISTING CLOUDFORMATION_STACK_UNASSUMABLE_ROLE
  618. */
  619. QueryErrors?: QueryErrorList;
  620. }
  621. export interface TagInput {
  622. /**
  623. * The ARN of the resource group to which to add tags.
  624. */
  625. Arn: GroupArn;
  626. /**
  627. * The tags to add to the specified resource group. A tag is a string-to-string map of key-value pairs.
  628. */
  629. Tags: Tags;
  630. }
  631. export type TagKey = string;
  632. export type TagKeyList = TagKey[];
  633. export interface TagOutput {
  634. /**
  635. * The ARN of the tagged resource.
  636. */
  637. Arn?: GroupArn;
  638. /**
  639. * The tags that have been added to the specified resource group.
  640. */
  641. Tags?: Tags;
  642. }
  643. export type TagValue = string;
  644. export type Tags = {[key: string]: TagValue};
  645. export interface UngroupResourcesInput {
  646. /**
  647. * The name or the ARN of the resource group from which to remove the resources.
  648. */
  649. Group: GroupString;
  650. /**
  651. * The ARNs of the resources to be removed from the group.
  652. */
  653. ResourceArns: ResourceArnList;
  654. }
  655. export interface UngroupResourcesOutput {
  656. /**
  657. * A list of resources that were successfully removed from the group by this operation.
  658. */
  659. Succeeded?: ResourceArnList;
  660. /**
  661. * A list of any resources that failed to be removed from the group by this operation.
  662. */
  663. Failed?: FailedResourceList;
  664. /**
  665. * A list of any resources that are still in the process of being removed from the group by this operation. These pending removals continue asynchronously. You can check the status of pending removals by using the ListGroupResources operation. After the resource is successfully removed, it no longer appears in the response.
  666. */
  667. Pending?: PendingResourceList;
  668. }
  669. export interface UntagInput {
  670. /**
  671. * The ARN of the resource group from which to remove tags. The command removed both the specified keys and any values associated with those keys.
  672. */
  673. Arn: GroupArn;
  674. /**
  675. * The keys of the tags to be removed.
  676. */
  677. Keys: TagKeyList;
  678. }
  679. export interface UntagOutput {
  680. /**
  681. * The ARN of the resource group from which tags have been removed.
  682. */
  683. Arn?: GroupArn;
  684. /**
  685. * The keys of the tags that were removed.
  686. */
  687. Keys?: TagKeyList;
  688. }
  689. export interface UpdateAccountSettingsInput {
  690. /**
  691. * Specifies whether you want to turn group lifecycle events on or off.
  692. */
  693. GroupLifecycleEventsDesiredStatus?: GroupLifecycleEventsDesiredStatus;
  694. }
  695. export interface UpdateAccountSettingsOutput {
  696. /**
  697. * A structure that displays the status of the optional features in the account.
  698. */
  699. AccountSettings?: AccountSettings;
  700. }
  701. export interface UpdateGroupInput {
  702. /**
  703. * Don't use this parameter. Use Group instead.
  704. */
  705. GroupName?: GroupName;
  706. /**
  707. * The name or the ARN of the resource group to modify.
  708. */
  709. Group?: GroupString;
  710. /**
  711. * The new description that you want to update the resource group with. Descriptions can contain letters, numbers, hyphens, underscores, periods, and spaces.
  712. */
  713. Description?: Description;
  714. }
  715. export interface UpdateGroupOutput {
  716. /**
  717. * The update description of the resource group.
  718. */
  719. Group?: Group;
  720. }
  721. export interface UpdateGroupQueryInput {
  722. /**
  723. * Don't use this parameter. Use Group instead.
  724. */
  725. GroupName?: GroupName;
  726. /**
  727. * The name or the ARN of the resource group to query.
  728. */
  729. Group?: GroupString;
  730. /**
  731. * The resource query to determine which Amazon Web Services resources are members of this resource group. A resource group can contain either a Configuration or a ResourceQuery, but not both.
  732. */
  733. ResourceQuery: ResourceQuery;
  734. }
  735. export interface UpdateGroupQueryOutput {
  736. /**
  737. * The updated resource query associated with the resource group after the update.
  738. */
  739. GroupQuery?: GroupQuery;
  740. }
  741. /**
  742. * A string in YYYY-MM-DD format that represents the latest possible API version that can be used in this service. Specify 'latest' to use the latest possible version.
  743. */
  744. export type apiVersion = "2017-11-27"|"latest"|string;
  745. export interface ClientApiVersions {
  746. /**
  747. * A string in YYYY-MM-DD format that represents the latest possible API version that can be used in this service. Specify 'latest' to use the latest possible version.
  748. */
  749. apiVersion?: apiVersion;
  750. }
  751. export type ClientConfiguration = ServiceConfigurationOptions & ClientApiVersions;
  752. /**
  753. * Contains interfaces for use with the ResourceGroups client.
  754. */
  755. export import Types = ResourceGroups;
  756. }
  757. export = ResourceGroups;