From d9ef47c00dcaad7cc4f2d2d0f594543b57e8fe1f Mon Sep 17 00:00:00 2001 From: awstools Date: Tue, 17 Dec 2024 19:11:28 +0000 Subject: [PATCH] feat(client-backupsearch): Add support for searching backups --- clients/client-backupsearch/.gitignore | 9 + clients/client-backupsearch/LICENSE | 201 ++ clients/client-backupsearch/README.md | 317 ++ .../client-backupsearch/api-extractor.json | 4 + clients/client-backupsearch/package.json | 101 + .../client-backupsearch/src/BackupSearch.ts | 276 ++ .../src/BackupSearchClient.ts | 389 +++ .../auth/httpAuthExtensionConfiguration.ts | 72 + .../src/auth/httpAuthSchemeProvider.ts | 138 + .../src/commands/GetSearchJobCommand.ts | 208 ++ .../GetSearchResultExportJobCommand.ts | 126 + .../commands/ListSearchJobBackupsCommand.ts | 134 + .../commands/ListSearchJobResultsCommand.ts | 139 + .../src/commands/ListSearchJobsCommand.ts | 122 + .../ListSearchResultExportJobsCommand.ts | 127 + .../commands/ListTagsForResourceCommand.ts | 111 + .../src/commands/StartSearchJobCommand.ts | 208 ++ .../StartSearchResultExportJobCommand.ts | 133 + .../src/commands/StopSearchJobCommand.ts | 117 + .../src/commands/TagResourceCommand.ts | 110 + .../src/commands/UntagResourceCommand.ts | 110 + .../client-backupsearch/src/commands/index.ts | 13 + .../src/endpoint/EndpointParameters.ts | 37 + .../src/endpoint/endpointResolver.ts | 26 + .../src/endpoint/ruleset.ts | 22 + .../src/extensionConfiguration.ts | 15 + clients/client-backupsearch/src/index.ts | 32 + .../models/BackupSearchServiceException.ts | 24 + .../client-backupsearch/src/models/index.ts | 2 + .../src/models/models_0.ts | 1799 +++++++++++ .../src/pagination/Interfaces.ts | 11 + .../ListSearchJobBackupsPaginator.ts | 24 + .../ListSearchJobResultsPaginator.ts | 24 + .../src/pagination/ListSearchJobsPaginator.ts | 24 + .../ListSearchResultExportJobsPaginator.ts | 24 + .../src/pagination/index.ts | 6 + .../src/protocols/Aws_restJson1.ts | 1221 +++++++ .../src/runtimeConfig.browser.ts | 44 + .../src/runtimeConfig.native.ts | 18 + .../src/runtimeConfig.shared.ts | 38 + .../client-backupsearch/src/runtimeConfig.ts | 67 + .../src/runtimeExtensions.ts | 48 + clients/client-backupsearch/tsconfig.cjs.json | 6 + clients/client-backupsearch/tsconfig.es.json | 8 + clients/client-backupsearch/tsconfig.json | 13 + .../client-backupsearch/tsconfig.types.json | 10 + .../sdk-codegen/aws-models/backupsearch.json | 2820 +++++++++++++++++ 47 files changed, 9528 insertions(+) create mode 100644 clients/client-backupsearch/.gitignore create mode 100644 clients/client-backupsearch/LICENSE create mode 100644 clients/client-backupsearch/README.md create mode 100644 clients/client-backupsearch/api-extractor.json create mode 100644 clients/client-backupsearch/package.json create mode 100644 clients/client-backupsearch/src/BackupSearch.ts create mode 100644 clients/client-backupsearch/src/BackupSearchClient.ts create mode 100644 clients/client-backupsearch/src/auth/httpAuthExtensionConfiguration.ts create mode 100644 clients/client-backupsearch/src/auth/httpAuthSchemeProvider.ts create mode 100644 clients/client-backupsearch/src/commands/GetSearchJobCommand.ts create mode 100644 clients/client-backupsearch/src/commands/GetSearchResultExportJobCommand.ts create mode 100644 clients/client-backupsearch/src/commands/ListSearchJobBackupsCommand.ts create mode 100644 clients/client-backupsearch/src/commands/ListSearchJobResultsCommand.ts create mode 100644 clients/client-backupsearch/src/commands/ListSearchJobsCommand.ts create mode 100644 clients/client-backupsearch/src/commands/ListSearchResultExportJobsCommand.ts create mode 100644 clients/client-backupsearch/src/commands/ListTagsForResourceCommand.ts create mode 100644 clients/client-backupsearch/src/commands/StartSearchJobCommand.ts create mode 100644 clients/client-backupsearch/src/commands/StartSearchResultExportJobCommand.ts create mode 100644 clients/client-backupsearch/src/commands/StopSearchJobCommand.ts create mode 100644 clients/client-backupsearch/src/commands/TagResourceCommand.ts create mode 100644 clients/client-backupsearch/src/commands/UntagResourceCommand.ts create mode 100644 clients/client-backupsearch/src/commands/index.ts create mode 100644 clients/client-backupsearch/src/endpoint/EndpointParameters.ts create mode 100644 clients/client-backupsearch/src/endpoint/endpointResolver.ts create mode 100644 clients/client-backupsearch/src/endpoint/ruleset.ts create mode 100644 clients/client-backupsearch/src/extensionConfiguration.ts create mode 100644 clients/client-backupsearch/src/index.ts create mode 100644 clients/client-backupsearch/src/models/BackupSearchServiceException.ts create mode 100644 clients/client-backupsearch/src/models/index.ts create mode 100644 clients/client-backupsearch/src/models/models_0.ts create mode 100644 clients/client-backupsearch/src/pagination/Interfaces.ts create mode 100644 clients/client-backupsearch/src/pagination/ListSearchJobBackupsPaginator.ts create mode 100644 clients/client-backupsearch/src/pagination/ListSearchJobResultsPaginator.ts create mode 100644 clients/client-backupsearch/src/pagination/ListSearchJobsPaginator.ts create mode 100644 clients/client-backupsearch/src/pagination/ListSearchResultExportJobsPaginator.ts create mode 100644 clients/client-backupsearch/src/pagination/index.ts create mode 100644 clients/client-backupsearch/src/protocols/Aws_restJson1.ts create mode 100644 clients/client-backupsearch/src/runtimeConfig.browser.ts create mode 100644 clients/client-backupsearch/src/runtimeConfig.native.ts create mode 100644 clients/client-backupsearch/src/runtimeConfig.shared.ts create mode 100644 clients/client-backupsearch/src/runtimeConfig.ts create mode 100644 clients/client-backupsearch/src/runtimeExtensions.ts create mode 100644 clients/client-backupsearch/tsconfig.cjs.json create mode 100644 clients/client-backupsearch/tsconfig.es.json create mode 100644 clients/client-backupsearch/tsconfig.json create mode 100644 clients/client-backupsearch/tsconfig.types.json create mode 100644 codegen/sdk-codegen/aws-models/backupsearch.json diff --git a/clients/client-backupsearch/.gitignore b/clients/client-backupsearch/.gitignore new file mode 100644 index 000000000000..54f14c9aef25 --- /dev/null +++ b/clients/client-backupsearch/.gitignore @@ -0,0 +1,9 @@ +/node_modules/ +/build/ +/coverage/ +/docs/ +/dist-* +*.tsbuildinfo +*.tgz +*.log +package-lock.json diff --git a/clients/client-backupsearch/LICENSE b/clients/client-backupsearch/LICENSE new file mode 100644 index 000000000000..1349aa7c9923 --- /dev/null +++ b/clients/client-backupsearch/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "{}" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright 2018-2024 Amazon.com, Inc. or its affiliates. All Rights Reserved. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/clients/client-backupsearch/README.md b/clients/client-backupsearch/README.md new file mode 100644 index 000000000000..0ff3caffe746 --- /dev/null +++ b/clients/client-backupsearch/README.md @@ -0,0 +1,317 @@ + + +# @aws-sdk/client-backupsearch + +## Description + +AWS SDK for JavaScript BackupSearch Client for Node.js, Browser and React Native. + +Backup Search + +

Backup Search is the recovery point and item level search for Backup.

+

For additional information, see:

+ + +## Installing + +To install this package, simply type add or install @aws-sdk/client-backupsearch +using your favorite package manager: + +- `npm install @aws-sdk/client-backupsearch` +- `yarn add @aws-sdk/client-backupsearch` +- `pnpm add @aws-sdk/client-backupsearch` + +## Getting Started + +### Import + +The AWS SDK is modulized by clients and commands. +To send a request, you only need to import the `BackupSearchClient` and +the commands you need, for example `ListSearchJobsCommand`: + +```js +// ES5 example +const { BackupSearchClient, ListSearchJobsCommand } = require("@aws-sdk/client-backupsearch"); +``` + +```ts +// ES6+ example +import { BackupSearchClient, ListSearchJobsCommand } from "@aws-sdk/client-backupsearch"; +``` + +### Usage + +To send a request, you: + +- Initiate client with configuration (e.g. credentials, region). +- Initiate command with input parameters. +- Call `send` operation on client with command object as input. +- If you are using a custom http handler, you may call `destroy()` to close open connections. + +```js +// a client can be shared by different commands. +const client = new BackupSearchClient({ region: "REGION" }); + +const params = { + /** input parameters */ +}; +const command = new ListSearchJobsCommand(params); +``` + +#### Async/await + +We recommend using [await](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/await) +operator to wait for the promise returned by send operation as follows: + +```js +// async/await. +try { + const data = await client.send(command); + // process data. +} catch (error) { + // error handling. +} finally { + // finally. +} +``` + +Async-await is clean, concise, intuitive, easy to debug and has better error handling +as compared to using Promise chains or callbacks. + +#### Promises + +You can also use [Promise chaining](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Using_promises#chaining) +to execute send operation. + +```js +client.send(command).then( + (data) => { + // process data. + }, + (error) => { + // error handling. + } +); +``` + +Promises can also be called using `.catch()` and `.finally()` as follows: + +```js +client + .send(command) + .then((data) => { + // process data. + }) + .catch((error) => { + // error handling. + }) + .finally(() => { + // finally. + }); +``` + +#### Callbacks + +We do not recommend using callbacks because of [callback hell](http://callbackhell.com/), +but they are supported by the send operation. + +```js +// callbacks. +client.send(command, (err, data) => { + // process err and data. +}); +``` + +#### v2 compatible style + +The client can also send requests using v2 compatible style. +However, it results in a bigger bundle size and may be dropped in next major version. More details in the blog post +on [modular packages in AWS SDK for JavaScript](https://aws.amazon.com/blogs/developer/modular-packages-in-aws-sdk-for-javascript/) + +```ts +import * as AWS from "@aws-sdk/client-backupsearch"; +const client = new AWS.BackupSearch({ region: "REGION" }); + +// async/await. +try { + const data = await client.listSearchJobs(params); + // process data. +} catch (error) { + // error handling. +} + +// Promises. +client + .listSearchJobs(params) + .then((data) => { + // process data. + }) + .catch((error) => { + // error handling. + }); + +// callbacks. +client.listSearchJobs(params, (err, data) => { + // process err and data. +}); +``` + +### Troubleshooting + +When the service returns an exception, the error will include the exception information, +as well as response metadata (e.g. request id). + +```js +try { + const data = await client.send(command); + // process data. +} catch (error) { + const { requestId, cfId, extendedRequestId } = error.$metadata; + console.log({ requestId, cfId, extendedRequestId }); + /** + * The keys within exceptions are also parsed. + * You can access them by specifying exception names: + * if (error.name === 'SomeServiceException') { + * const value = error.specialKeyInException; + * } + */ +} +``` + +## Getting Help + +Please use these community resources for getting help. +We use the GitHub issues for tracking bugs and feature requests, but have limited bandwidth to address them. + +- Visit [Developer Guide](https://docs.aws.amazon.com/sdk-for-javascript/v3/developer-guide/welcome.html) + or [API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/index.html). +- Check out the blog posts tagged with [`aws-sdk-js`](https://aws.amazon.com/blogs/developer/tag/aws-sdk-js/) + on AWS Developer Blog. +- Ask a question on [StackOverflow](https://stackoverflow.com/questions/tagged/aws-sdk-js) and tag it with `aws-sdk-js`. +- Join the AWS JavaScript community on [gitter](https://gitter.im/aws/aws-sdk-js-v3). +- If it turns out that you may have found a bug, please [open an issue](https://github.com/aws/aws-sdk-js-v3/issues/new/choose). + +To test your universal JavaScript code in Node.js, browser and react-native environments, +visit our [code samples repo](https://github.com/aws-samples/aws-sdk-js-tests). + +## Contributing + +This client code is generated automatically. Any modifications will be overwritten the next time the `@aws-sdk/client-backupsearch` package is updated. +To contribute to client you can check our [generate clients scripts](https://github.com/aws/aws-sdk-js-v3/tree/main/scripts/generate-clients). + +## License + +This SDK is distributed under the +[Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0), +see LICENSE for more information. + +## Client Commands (Operations List) + +
+ +GetSearchJob + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/GetSearchJobCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/GetSearchJobCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/GetSearchJobCommandOutput/) + +
+
+ +GetSearchResultExportJob + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/GetSearchResultExportJobCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/GetSearchResultExportJobCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/GetSearchResultExportJobCommandOutput/) + +
+
+ +ListSearchJobBackups + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/ListSearchJobBackupsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/ListSearchJobBackupsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/ListSearchJobBackupsCommandOutput/) + +
+
+ +ListSearchJobResults + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/ListSearchJobResultsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/ListSearchJobResultsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/ListSearchJobResultsCommandOutput/) + +
+
+ +ListSearchJobs + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/ListSearchJobsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/ListSearchJobsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/ListSearchJobsCommandOutput/) + +
+
+ +ListSearchResultExportJobs + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/ListSearchResultExportJobsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/ListSearchResultExportJobsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/ListSearchResultExportJobsCommandOutput/) + +
+
+ +ListTagsForResource + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/ListTagsForResourceCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/ListTagsForResourceCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/ListTagsForResourceCommandOutput/) + +
+
+ +StartSearchJob + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/StartSearchJobCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/StartSearchJobCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/StartSearchJobCommandOutput/) + +
+
+ +StartSearchResultExportJob + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/StartSearchResultExportJobCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/StartSearchResultExportJobCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/StartSearchResultExportJobCommandOutput/) + +
+
+ +StopSearchJob + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/StopSearchJobCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/StopSearchJobCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/StopSearchJobCommandOutput/) + +
+
+ +TagResource + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/TagResourceCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/TagResourceCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/TagResourceCommandOutput/) + +
+
+ +UntagResource + + +[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/backupsearch/command/UntagResourceCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/UntagResourceCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-backupsearch/Interface/UntagResourceCommandOutput/) + +
diff --git a/clients/client-backupsearch/api-extractor.json b/clients/client-backupsearch/api-extractor.json new file mode 100644 index 000000000000..d5bf5ffeee85 --- /dev/null +++ b/clients/client-backupsearch/api-extractor.json @@ -0,0 +1,4 @@ +{ + "extends": "../../api-extractor.json", + "mainEntryPointFilePath": "/dist-types/index.d.ts" +} diff --git a/clients/client-backupsearch/package.json b/clients/client-backupsearch/package.json new file mode 100644 index 000000000000..c58b63f7566d --- /dev/null +++ b/clients/client-backupsearch/package.json @@ -0,0 +1,101 @@ +{ + "name": "@aws-sdk/client-backupsearch", + "description": "AWS SDK for JavaScript Backupsearch Client for Node.js, Browser and React Native", + "version": "3.0.0", + "scripts": { + "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'", + "build:cjs": "tsc -p tsconfig.cjs.json", + "build:es": "tsc -p tsconfig.es.json", + "build:include:deps": "lerna run --scope $npm_package_name --include-dependencies build", + "build:types": "tsc -p tsconfig.types.json", + "build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4", + "clean": "rimraf ./dist-* && rimraf *.tsbuildinfo || exit 0", + "extract:docs": "api-extractor run --local", + "generate:client": "node ../../scripts/generate-clients/single-service --solo backupsearch" + }, + "main": "./dist-cjs/index.js", + "types": "./dist-types/index.d.ts", + "module": "./dist-es/index.js", + "sideEffects": false, + "dependencies": { + "@aws-crypto/sha256-browser": "5.2.0", + "@aws-crypto/sha256-js": "5.2.0", + "@aws-sdk/client-sso-oidc": "*", + "@aws-sdk/client-sts": "*", + "@aws-sdk/core": "*", + "@aws-sdk/credential-provider-node": "*", + "@aws-sdk/middleware-host-header": "*", + "@aws-sdk/middleware-logger": "*", + "@aws-sdk/middleware-recursion-detection": "*", + "@aws-sdk/middleware-user-agent": "*", + "@aws-sdk/region-config-resolver": "*", + "@aws-sdk/types": "*", + "@aws-sdk/util-endpoints": "*", + "@aws-sdk/util-user-agent-browser": "*", + "@aws-sdk/util-user-agent-node": "*", + "@smithy/config-resolver": "^3.0.13", + "@smithy/core": "^2.5.5", + "@smithy/fetch-http-handler": "^4.1.2", + "@smithy/hash-node": "^3.0.11", + "@smithy/invalid-dependency": "^3.0.11", + "@smithy/middleware-content-length": "^3.0.13", + "@smithy/middleware-endpoint": "^3.2.5", + "@smithy/middleware-retry": "^3.0.30", + "@smithy/middleware-serde": "^3.0.11", + "@smithy/middleware-stack": "^3.0.11", + "@smithy/node-config-provider": "^3.1.12", + "@smithy/node-http-handler": "^3.3.2", + "@smithy/protocol-http": "^4.1.8", + "@smithy/smithy-client": "^3.5.0", + "@smithy/types": "^3.7.2", + "@smithy/url-parser": "^3.0.11", + "@smithy/util-base64": "^3.0.0", + "@smithy/util-body-length-browser": "^3.0.0", + "@smithy/util-body-length-node": "^3.0.0", + "@smithy/util-defaults-mode-browser": "^3.0.30", + "@smithy/util-defaults-mode-node": "^3.0.30", + "@smithy/util-endpoints": "^2.1.7", + "@smithy/util-middleware": "^3.0.11", + "@smithy/util-retry": "^3.0.11", + "@smithy/util-utf8": "^3.0.0", + "tslib": "^2.6.2" + }, + "devDependencies": { + "@tsconfig/node16": "16.1.3", + "@types/node": "^16.18.96", + "concurrently": "7.0.0", + "downlevel-dts": "0.10.1", + "rimraf": "3.0.2", + "typescript": "~4.9.5" + }, + "engines": { + "node": ">=16.0.0" + }, + "typesVersions": { + "<4.0": { + "dist-types/*": [ + "dist-types/ts3.4/*" + ] + } + }, + "files": [ + "dist-*/**" + ], + "author": { + "name": "AWS SDK for JavaScript Team", + "url": "https://aws.amazon.com/javascript/" + }, + "license": "Apache-2.0", + "browser": { + "./dist-es/runtimeConfig": "./dist-es/runtimeConfig.browser" + }, + "react-native": { + "./dist-es/runtimeConfig": "./dist-es/runtimeConfig.native" + }, + "homepage": "https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-backupsearch", + "repository": { + "type": "git", + "url": "https://github.com/aws/aws-sdk-js-v3.git", + "directory": "clients/client-backupsearch" + } +} diff --git a/clients/client-backupsearch/src/BackupSearch.ts b/clients/client-backupsearch/src/BackupSearch.ts new file mode 100644 index 000000000000..abe5c30e1adf --- /dev/null +++ b/clients/client-backupsearch/src/BackupSearch.ts @@ -0,0 +1,276 @@ +// smithy-typescript generated code +import { createAggregatedClient } from "@smithy/smithy-client"; +import { HttpHandlerOptions as __HttpHandlerOptions } from "@smithy/types"; + +import { BackupSearchClient, BackupSearchClientConfig } from "./BackupSearchClient"; +import { + GetSearchJobCommand, + GetSearchJobCommandInput, + GetSearchJobCommandOutput, +} from "./commands/GetSearchJobCommand"; +import { + GetSearchResultExportJobCommand, + GetSearchResultExportJobCommandInput, + GetSearchResultExportJobCommandOutput, +} from "./commands/GetSearchResultExportJobCommand"; +import { + ListSearchJobBackupsCommand, + ListSearchJobBackupsCommandInput, + ListSearchJobBackupsCommandOutput, +} from "./commands/ListSearchJobBackupsCommand"; +import { + ListSearchJobResultsCommand, + ListSearchJobResultsCommandInput, + ListSearchJobResultsCommandOutput, +} from "./commands/ListSearchJobResultsCommand"; +import { + ListSearchJobsCommand, + ListSearchJobsCommandInput, + ListSearchJobsCommandOutput, +} from "./commands/ListSearchJobsCommand"; +import { + ListSearchResultExportJobsCommand, + ListSearchResultExportJobsCommandInput, + ListSearchResultExportJobsCommandOutput, +} from "./commands/ListSearchResultExportJobsCommand"; +import { + ListTagsForResourceCommand, + ListTagsForResourceCommandInput, + ListTagsForResourceCommandOutput, +} from "./commands/ListTagsForResourceCommand"; +import { + StartSearchJobCommand, + StartSearchJobCommandInput, + StartSearchJobCommandOutput, +} from "./commands/StartSearchJobCommand"; +import { + StartSearchResultExportJobCommand, + StartSearchResultExportJobCommandInput, + StartSearchResultExportJobCommandOutput, +} from "./commands/StartSearchResultExportJobCommand"; +import { + StopSearchJobCommand, + StopSearchJobCommandInput, + StopSearchJobCommandOutput, +} from "./commands/StopSearchJobCommand"; +import { TagResourceCommand, TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand"; +import { + UntagResourceCommand, + UntagResourceCommandInput, + UntagResourceCommandOutput, +} from "./commands/UntagResourceCommand"; + +const commands = { + GetSearchJobCommand, + GetSearchResultExportJobCommand, + ListSearchJobBackupsCommand, + ListSearchJobResultsCommand, + ListSearchJobsCommand, + ListSearchResultExportJobsCommand, + ListTagsForResourceCommand, + StartSearchJobCommand, + StartSearchResultExportJobCommand, + StopSearchJobCommand, + TagResourceCommand, + UntagResourceCommand, +}; + +export interface BackupSearch { + /** + * @see {@link GetSearchJobCommand} + */ + getSearchJob(args: GetSearchJobCommandInput, options?: __HttpHandlerOptions): Promise; + getSearchJob(args: GetSearchJobCommandInput, cb: (err: any, data?: GetSearchJobCommandOutput) => void): void; + getSearchJob( + args: GetSearchJobCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: GetSearchJobCommandOutput) => void + ): void; + + /** + * @see {@link GetSearchResultExportJobCommand} + */ + getSearchResultExportJob( + args: GetSearchResultExportJobCommandInput, + options?: __HttpHandlerOptions + ): Promise; + getSearchResultExportJob( + args: GetSearchResultExportJobCommandInput, + cb: (err: any, data?: GetSearchResultExportJobCommandOutput) => void + ): void; + getSearchResultExportJob( + args: GetSearchResultExportJobCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: GetSearchResultExportJobCommandOutput) => void + ): void; + + /** + * @see {@link ListSearchJobBackupsCommand} + */ + listSearchJobBackups( + args: ListSearchJobBackupsCommandInput, + options?: __HttpHandlerOptions + ): Promise; + listSearchJobBackups( + args: ListSearchJobBackupsCommandInput, + cb: (err: any, data?: ListSearchJobBackupsCommandOutput) => void + ): void; + listSearchJobBackups( + args: ListSearchJobBackupsCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: ListSearchJobBackupsCommandOutput) => void + ): void; + + /** + * @see {@link ListSearchJobResultsCommand} + */ + listSearchJobResults( + args: ListSearchJobResultsCommandInput, + options?: __HttpHandlerOptions + ): Promise; + listSearchJobResults( + args: ListSearchJobResultsCommandInput, + cb: (err: any, data?: ListSearchJobResultsCommandOutput) => void + ): void; + listSearchJobResults( + args: ListSearchJobResultsCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: ListSearchJobResultsCommandOutput) => void + ): void; + + /** + * @see {@link ListSearchJobsCommand} + */ + listSearchJobs(): Promise; + listSearchJobs( + args: ListSearchJobsCommandInput, + options?: __HttpHandlerOptions + ): Promise; + listSearchJobs(args: ListSearchJobsCommandInput, cb: (err: any, data?: ListSearchJobsCommandOutput) => void): void; + listSearchJobs( + args: ListSearchJobsCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: ListSearchJobsCommandOutput) => void + ): void; + + /** + * @see {@link ListSearchResultExportJobsCommand} + */ + listSearchResultExportJobs(): Promise; + listSearchResultExportJobs( + args: ListSearchResultExportJobsCommandInput, + options?: __HttpHandlerOptions + ): Promise; + listSearchResultExportJobs( + args: ListSearchResultExportJobsCommandInput, + cb: (err: any, data?: ListSearchResultExportJobsCommandOutput) => void + ): void; + listSearchResultExportJobs( + args: ListSearchResultExportJobsCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: ListSearchResultExportJobsCommandOutput) => void + ): void; + + /** + * @see {@link ListTagsForResourceCommand} + */ + listTagsForResource( + args: ListTagsForResourceCommandInput, + options?: __HttpHandlerOptions + ): Promise; + listTagsForResource( + args: ListTagsForResourceCommandInput, + cb: (err: any, data?: ListTagsForResourceCommandOutput) => void + ): void; + listTagsForResource( + args: ListTagsForResourceCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: ListTagsForResourceCommandOutput) => void + ): void; + + /** + * @see {@link StartSearchJobCommand} + */ + startSearchJob( + args: StartSearchJobCommandInput, + options?: __HttpHandlerOptions + ): Promise; + startSearchJob(args: StartSearchJobCommandInput, cb: (err: any, data?: StartSearchJobCommandOutput) => void): void; + startSearchJob( + args: StartSearchJobCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: StartSearchJobCommandOutput) => void + ): void; + + /** + * @see {@link StartSearchResultExportJobCommand} + */ + startSearchResultExportJob( + args: StartSearchResultExportJobCommandInput, + options?: __HttpHandlerOptions + ): Promise; + startSearchResultExportJob( + args: StartSearchResultExportJobCommandInput, + cb: (err: any, data?: StartSearchResultExportJobCommandOutput) => void + ): void; + startSearchResultExportJob( + args: StartSearchResultExportJobCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: StartSearchResultExportJobCommandOutput) => void + ): void; + + /** + * @see {@link StopSearchJobCommand} + */ + stopSearchJob(args: StopSearchJobCommandInput, options?: __HttpHandlerOptions): Promise; + stopSearchJob(args: StopSearchJobCommandInput, cb: (err: any, data?: StopSearchJobCommandOutput) => void): void; + stopSearchJob( + args: StopSearchJobCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: StopSearchJobCommandOutput) => void + ): void; + + /** + * @see {@link TagResourceCommand} + */ + tagResource(args: TagResourceCommandInput, options?: __HttpHandlerOptions): Promise; + tagResource(args: TagResourceCommandInput, cb: (err: any, data?: TagResourceCommandOutput) => void): void; + tagResource( + args: TagResourceCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: TagResourceCommandOutput) => void + ): void; + + /** + * @see {@link UntagResourceCommand} + */ + untagResource(args: UntagResourceCommandInput, options?: __HttpHandlerOptions): Promise; + untagResource(args: UntagResourceCommandInput, cb: (err: any, data?: UntagResourceCommandOutput) => void): void; + untagResource( + args: UntagResourceCommandInput, + options: __HttpHandlerOptions, + cb: (err: any, data?: UntagResourceCommandOutput) => void + ): void; +} + +/** + * Backup Search + *

Backup Search is the recovery point and item level search for Backup.

+ *

For additional information, see:

+ * + * @public + */ +export class BackupSearch extends BackupSearchClient implements BackupSearch {} +createAggregatedClient(commands, BackupSearch); diff --git a/clients/client-backupsearch/src/BackupSearchClient.ts b/clients/client-backupsearch/src/BackupSearchClient.ts new file mode 100644 index 000000000000..2963177f24ab --- /dev/null +++ b/clients/client-backupsearch/src/BackupSearchClient.ts @@ -0,0 +1,389 @@ +// smithy-typescript generated code +import { + getHostHeaderPlugin, + HostHeaderInputConfig, + HostHeaderResolvedConfig, + resolveHostHeaderConfig, +} from "@aws-sdk/middleware-host-header"; +import { getLoggerPlugin } from "@aws-sdk/middleware-logger"; +import { getRecursionDetectionPlugin } from "@aws-sdk/middleware-recursion-detection"; +import { + getUserAgentPlugin, + resolveUserAgentConfig, + UserAgentInputConfig, + UserAgentResolvedConfig, +} from "@aws-sdk/middleware-user-agent"; +import { RegionInputConfig, RegionResolvedConfig, resolveRegionConfig } from "@smithy/config-resolver"; +import { + DefaultIdentityProviderConfig, + getHttpAuthSchemeEndpointRuleSetPlugin, + getHttpSigningPlugin, +} from "@smithy/core"; +import { getContentLengthPlugin } from "@smithy/middleware-content-length"; +import { EndpointInputConfig, EndpointResolvedConfig, resolveEndpointConfig } from "@smithy/middleware-endpoint"; +import { getRetryPlugin, resolveRetryConfig, RetryInputConfig, RetryResolvedConfig } from "@smithy/middleware-retry"; +import { HttpHandlerUserInput as __HttpHandlerUserInput } from "@smithy/protocol-http"; +import { + Client as __Client, + DefaultsMode as __DefaultsMode, + SmithyConfiguration as __SmithyConfiguration, + SmithyResolvedConfiguration as __SmithyResolvedConfiguration, +} from "@smithy/smithy-client"; +import { + AwsCredentialIdentityProvider, + BodyLengthCalculator as __BodyLengthCalculator, + CheckOptionalClientConfig as __CheckOptionalClientConfig, + ChecksumConstructor as __ChecksumConstructor, + Decoder as __Decoder, + Encoder as __Encoder, + EndpointV2 as __EndpointV2, + HashConstructor as __HashConstructor, + HttpHandlerOptions as __HttpHandlerOptions, + Logger as __Logger, + Provider as __Provider, + Provider, + StreamCollector as __StreamCollector, + UrlParser as __UrlParser, + UserAgent as __UserAgent, +} from "@smithy/types"; + +import { + defaultBackupSearchHttpAuthSchemeParametersProvider, + HttpAuthSchemeInputConfig, + HttpAuthSchemeResolvedConfig, + resolveHttpAuthSchemeConfig, +} from "./auth/httpAuthSchemeProvider"; +import { GetSearchJobCommandInput, GetSearchJobCommandOutput } from "./commands/GetSearchJobCommand"; +import { + GetSearchResultExportJobCommandInput, + GetSearchResultExportJobCommandOutput, +} from "./commands/GetSearchResultExportJobCommand"; +import { + ListSearchJobBackupsCommandInput, + ListSearchJobBackupsCommandOutput, +} from "./commands/ListSearchJobBackupsCommand"; +import { + ListSearchJobResultsCommandInput, + ListSearchJobResultsCommandOutput, +} from "./commands/ListSearchJobResultsCommand"; +import { ListSearchJobsCommandInput, ListSearchJobsCommandOutput } from "./commands/ListSearchJobsCommand"; +import { + ListSearchResultExportJobsCommandInput, + ListSearchResultExportJobsCommandOutput, +} from "./commands/ListSearchResultExportJobsCommand"; +import { + ListTagsForResourceCommandInput, + ListTagsForResourceCommandOutput, +} from "./commands/ListTagsForResourceCommand"; +import { StartSearchJobCommandInput, StartSearchJobCommandOutput } from "./commands/StartSearchJobCommand"; +import { + StartSearchResultExportJobCommandInput, + StartSearchResultExportJobCommandOutput, +} from "./commands/StartSearchResultExportJobCommand"; +import { StopSearchJobCommandInput, StopSearchJobCommandOutput } from "./commands/StopSearchJobCommand"; +import { TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand"; +import { UntagResourceCommandInput, UntagResourceCommandOutput } from "./commands/UntagResourceCommand"; +import { + ClientInputEndpointParameters, + ClientResolvedEndpointParameters, + EndpointParameters, + resolveClientEndpointParameters, +} from "./endpoint/EndpointParameters"; +import { getRuntimeConfig as __getRuntimeConfig } from "./runtimeConfig"; +import { resolveRuntimeExtensions, RuntimeExtension, RuntimeExtensionsConfig } from "./runtimeExtensions"; + +export { __Client }; + +/** + * @public + */ +export type ServiceInputTypes = + | GetSearchJobCommandInput + | GetSearchResultExportJobCommandInput + | ListSearchJobBackupsCommandInput + | ListSearchJobResultsCommandInput + | ListSearchJobsCommandInput + | ListSearchResultExportJobsCommandInput + | ListTagsForResourceCommandInput + | StartSearchJobCommandInput + | StartSearchResultExportJobCommandInput + | StopSearchJobCommandInput + | TagResourceCommandInput + | UntagResourceCommandInput; + +/** + * @public + */ +export type ServiceOutputTypes = + | GetSearchJobCommandOutput + | GetSearchResultExportJobCommandOutput + | ListSearchJobBackupsCommandOutput + | ListSearchJobResultsCommandOutput + | ListSearchJobsCommandOutput + | ListSearchResultExportJobsCommandOutput + | ListTagsForResourceCommandOutput + | StartSearchJobCommandOutput + | StartSearchResultExportJobCommandOutput + | StopSearchJobCommandOutput + | TagResourceCommandOutput + | UntagResourceCommandOutput; + +/** + * @public + */ +export interface ClientDefaults extends Partial<__SmithyConfiguration<__HttpHandlerOptions>> { + /** + * The HTTP handler to use or its constructor options. Fetch in browser and Https in Nodejs. + */ + requestHandler?: __HttpHandlerUserInput; + + /** + * A constructor for a class implementing the {@link @smithy/types#ChecksumConstructor} interface + * that computes the SHA-256 HMAC or checksum of a string or binary buffer. + * @internal + */ + sha256?: __ChecksumConstructor | __HashConstructor; + + /** + * The function that will be used to convert strings into HTTP endpoints. + * @internal + */ + urlParser?: __UrlParser; + + /** + * A function that can calculate the length of a request body. + * @internal + */ + bodyLengthChecker?: __BodyLengthCalculator; + + /** + * A function that converts a stream into an array of bytes. + * @internal + */ + streamCollector?: __StreamCollector; + + /** + * The function that will be used to convert a base64-encoded string to a byte array. + * @internal + */ + base64Decoder?: __Decoder; + + /** + * The function that will be used to convert binary data to a base64-encoded string. + * @internal + */ + base64Encoder?: __Encoder; + + /** + * The function that will be used to convert a UTF8-encoded string to a byte array. + * @internal + */ + utf8Decoder?: __Decoder; + + /** + * The function that will be used to convert binary data to a UTF-8 encoded string. + * @internal + */ + utf8Encoder?: __Encoder; + + /** + * The runtime environment. + * @internal + */ + runtime?: string; + + /** + * Disable dynamically changing the endpoint of the client based on the hostPrefix + * trait of an operation. + */ + disableHostPrefix?: boolean; + + /** + * Unique service identifier. + * @internal + */ + serviceId?: string; + + /** + * Enables IPv6/IPv4 dualstack endpoint. + */ + useDualstackEndpoint?: boolean | __Provider; + + /** + * Enables FIPS compatible endpoints. + */ + useFipsEndpoint?: boolean | __Provider; + + /** + * The AWS region to which this client will send requests + */ + region?: string | __Provider; + + /** + * Setting a client profile is similar to setting a value for the + * AWS_PROFILE environment variable. Setting a profile on a client + * in code only affects the single client instance, unlike AWS_PROFILE. + * + * When set, and only for environments where an AWS configuration + * file exists, fields configurable by this file will be retrieved + * from the specified profile within that file. + * Conflicting code configuration and environment variables will + * still have higher priority. + * + * For client credential resolution that involves checking the AWS + * configuration file, the client's profile (this value) will be + * used unless a different profile is set in the credential + * provider options. + * + */ + profile?: string; + + /** + * The provider populating default tracking information to be sent with `user-agent`, `x-amz-user-agent` header + * @internal + */ + defaultUserAgentProvider?: Provider<__UserAgent>; + + /** + * Default credentials provider; Not available in browser runtime. + * @deprecated + * @internal + */ + credentialDefaultProvider?: (input: any) => AwsCredentialIdentityProvider; + + /** + * Value for how many times a request will be made at most in case of retry. + */ + maxAttempts?: number | __Provider; + + /** + * Specifies which retry algorithm to use. + * @see https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-smithy-util-retry/Enum/RETRY_MODES/ + * + */ + retryMode?: string | __Provider; + + /** + * Optional logger for logging debug/info/warn/error. + */ + logger?: __Logger; + + /** + * Optional extensions + */ + extensions?: RuntimeExtension[]; + + /** + * The {@link @smithy/smithy-client#DefaultsMode} that will be used to determine how certain default configuration options are resolved in the SDK. + */ + defaultsMode?: __DefaultsMode | __Provider<__DefaultsMode>; +} + +/** + * @public + */ +export type BackupSearchClientConfigType = Partial<__SmithyConfiguration<__HttpHandlerOptions>> & + ClientDefaults & + UserAgentInputConfig & + RetryInputConfig & + RegionInputConfig & + HostHeaderInputConfig & + EndpointInputConfig & + HttpAuthSchemeInputConfig & + ClientInputEndpointParameters; +/** + * @public + * + * The configuration interface of BackupSearchClient class constructor that set the region, credentials and other options. + */ +export interface BackupSearchClientConfig extends BackupSearchClientConfigType {} + +/** + * @public + */ +export type BackupSearchClientResolvedConfigType = __SmithyResolvedConfiguration<__HttpHandlerOptions> & + Required & + RuntimeExtensionsConfig & + UserAgentResolvedConfig & + RetryResolvedConfig & + RegionResolvedConfig & + HostHeaderResolvedConfig & + EndpointResolvedConfig & + HttpAuthSchemeResolvedConfig & + ClientResolvedEndpointParameters; +/** + * @public + * + * The resolved configuration interface of BackupSearchClient class. This is resolved and normalized from the {@link BackupSearchClientConfig | constructor configuration interface}. + */ +export interface BackupSearchClientResolvedConfig extends BackupSearchClientResolvedConfigType {} + +/** + * Backup Search + *

Backup Search is the recovery point and item level search for Backup.

+ *

For additional information, see:

+ * + * @public + */ +export class BackupSearchClient extends __Client< + __HttpHandlerOptions, + ServiceInputTypes, + ServiceOutputTypes, + BackupSearchClientResolvedConfig +> { + /** + * The resolved configuration of BackupSearchClient class. This is resolved and normalized from the {@link BackupSearchClientConfig | constructor configuration interface}. + */ + readonly config: BackupSearchClientResolvedConfig; + + constructor(...[configuration]: __CheckOptionalClientConfig) { + const _config_0 = __getRuntimeConfig(configuration || {}); + const _config_1 = resolveClientEndpointParameters(_config_0); + const _config_2 = resolveUserAgentConfig(_config_1); + const _config_3 = resolveRetryConfig(_config_2); + const _config_4 = resolveRegionConfig(_config_3); + const _config_5 = resolveHostHeaderConfig(_config_4); + const _config_6 = resolveEndpointConfig(_config_5); + const _config_7 = resolveHttpAuthSchemeConfig(_config_6); + const _config_8 = resolveRuntimeExtensions(_config_7, configuration?.extensions || []); + super(_config_8); + this.config = _config_8; + this.middlewareStack.use(getUserAgentPlugin(this.config)); + this.middlewareStack.use(getRetryPlugin(this.config)); + this.middlewareStack.use(getContentLengthPlugin(this.config)); + this.middlewareStack.use(getHostHeaderPlugin(this.config)); + this.middlewareStack.use(getLoggerPlugin(this.config)); + this.middlewareStack.use(getRecursionDetectionPlugin(this.config)); + this.middlewareStack.use( + getHttpAuthSchemeEndpointRuleSetPlugin(this.config, { + httpAuthSchemeParametersProvider: defaultBackupSearchHttpAuthSchemeParametersProvider, + identityProviderConfigProvider: async (config: BackupSearchClientResolvedConfig) => + new DefaultIdentityProviderConfig({ + "aws.auth#sigv4": config.credentials, + }), + }) + ); + this.middlewareStack.use(getHttpSigningPlugin(this.config)); + } + + /** + * Destroy underlying resources, like sockets. It's usually not necessary to do this. + * However in Node.js, it's best to explicitly shut down the client's agent when it is no longer needed. + * Otherwise, sockets might stay open for quite a long time before the server terminates them. + */ + destroy(): void { + super.destroy(); + } +} diff --git a/clients/client-backupsearch/src/auth/httpAuthExtensionConfiguration.ts b/clients/client-backupsearch/src/auth/httpAuthExtensionConfiguration.ts new file mode 100644 index 000000000000..885ce37eb9d2 --- /dev/null +++ b/clients/client-backupsearch/src/auth/httpAuthExtensionConfiguration.ts @@ -0,0 +1,72 @@ +// smithy-typescript generated code +import { AwsCredentialIdentity, AwsCredentialIdentityProvider, HttpAuthScheme } from "@smithy/types"; + +import { BackupSearchHttpAuthSchemeProvider } from "./httpAuthSchemeProvider"; + +/** + * @internal + */ +export interface HttpAuthExtensionConfiguration { + setHttpAuthScheme(httpAuthScheme: HttpAuthScheme): void; + httpAuthSchemes(): HttpAuthScheme[]; + setHttpAuthSchemeProvider(httpAuthSchemeProvider: BackupSearchHttpAuthSchemeProvider): void; + httpAuthSchemeProvider(): BackupSearchHttpAuthSchemeProvider; + setCredentials(credentials: AwsCredentialIdentity | AwsCredentialIdentityProvider): void; + credentials(): AwsCredentialIdentity | AwsCredentialIdentityProvider | undefined; +} + +/** + * @internal + */ +export type HttpAuthRuntimeConfig = Partial<{ + httpAuthSchemes: HttpAuthScheme[]; + httpAuthSchemeProvider: BackupSearchHttpAuthSchemeProvider; + credentials: AwsCredentialIdentity | AwsCredentialIdentityProvider; +}>; + +/** + * @internal + */ +export const getHttpAuthExtensionConfiguration = ( + runtimeConfig: HttpAuthRuntimeConfig +): HttpAuthExtensionConfiguration => { + const _httpAuthSchemes = runtimeConfig.httpAuthSchemes!; + let _httpAuthSchemeProvider = runtimeConfig.httpAuthSchemeProvider!; + let _credentials = runtimeConfig.credentials; + return { + setHttpAuthScheme(httpAuthScheme: HttpAuthScheme): void { + const index = _httpAuthSchemes.findIndex((scheme) => scheme.schemeId === httpAuthScheme.schemeId); + if (index === -1) { + _httpAuthSchemes.push(httpAuthScheme); + } else { + _httpAuthSchemes.splice(index, 1, httpAuthScheme); + } + }, + httpAuthSchemes(): HttpAuthScheme[] { + return _httpAuthSchemes; + }, + setHttpAuthSchemeProvider(httpAuthSchemeProvider: BackupSearchHttpAuthSchemeProvider): void { + _httpAuthSchemeProvider = httpAuthSchemeProvider; + }, + httpAuthSchemeProvider(): BackupSearchHttpAuthSchemeProvider { + return _httpAuthSchemeProvider; + }, + setCredentials(credentials: AwsCredentialIdentity | AwsCredentialIdentityProvider): void { + _credentials = credentials; + }, + credentials(): AwsCredentialIdentity | AwsCredentialIdentityProvider | undefined { + return _credentials; + }, + }; +}; + +/** + * @internal + */ +export const resolveHttpAuthRuntimeConfig = (config: HttpAuthExtensionConfiguration): HttpAuthRuntimeConfig => { + return { + httpAuthSchemes: config.httpAuthSchemes(), + httpAuthSchemeProvider: config.httpAuthSchemeProvider(), + credentials: config.credentials(), + }; +}; diff --git a/clients/client-backupsearch/src/auth/httpAuthSchemeProvider.ts b/clients/client-backupsearch/src/auth/httpAuthSchemeProvider.ts new file mode 100644 index 000000000000..bef4973e6c4d --- /dev/null +++ b/clients/client-backupsearch/src/auth/httpAuthSchemeProvider.ts @@ -0,0 +1,138 @@ +// smithy-typescript generated code +import { + AwsSdkSigV4AuthInputConfig, + AwsSdkSigV4AuthResolvedConfig, + AwsSdkSigV4PreviouslyResolved, + resolveAwsSdkSigV4Config, +} from "@aws-sdk/core"; +import { + HandlerExecutionContext, + HttpAuthOption, + HttpAuthScheme, + HttpAuthSchemeParameters, + HttpAuthSchemeParametersProvider, + HttpAuthSchemeProvider, +} from "@smithy/types"; +import { getSmithyContext, normalizeProvider } from "@smithy/util-middleware"; + +import { BackupSearchClientConfig, BackupSearchClientResolvedConfig } from "../BackupSearchClient"; + +/** + * @internal + */ +export interface BackupSearchHttpAuthSchemeParameters extends HttpAuthSchemeParameters { + region?: string; +} + +/** + * @internal + */ +export interface BackupSearchHttpAuthSchemeParametersProvider + extends HttpAuthSchemeParametersProvider< + BackupSearchClientResolvedConfig, + HandlerExecutionContext, + BackupSearchHttpAuthSchemeParameters, + object + > {} + +/** + * @internal + */ +export const defaultBackupSearchHttpAuthSchemeParametersProvider = async ( + config: BackupSearchClientResolvedConfig, + context: HandlerExecutionContext, + input: object +): Promise => { + return { + operation: getSmithyContext(context).operation as string, + region: + (await normalizeProvider(config.region)()) || + (() => { + throw new Error("expected `region` to be configured for `aws.auth#sigv4`"); + })(), + }; +}; + +function createAwsAuthSigv4HttpAuthOption(authParameters: BackupSearchHttpAuthSchemeParameters): HttpAuthOption { + return { + schemeId: "aws.auth#sigv4", + signingProperties: { + name: "backup-search", + region: authParameters.region, + }, + propertiesExtractor: (config: Partial, context) => ({ + /** + * @internal + */ + signingProperties: { + config, + context, + }, + }), + }; +} + +/** + * @internal + */ +export interface BackupSearchHttpAuthSchemeProvider + extends HttpAuthSchemeProvider {} + +/** + * @internal + */ +export const defaultBackupSearchHttpAuthSchemeProvider: BackupSearchHttpAuthSchemeProvider = (authParameters) => { + const options: HttpAuthOption[] = []; + switch (authParameters.operation) { + default: { + options.push(createAwsAuthSigv4HttpAuthOption(authParameters)); + } + } + return options; +}; + +/** + * @internal + */ +export interface HttpAuthSchemeInputConfig extends AwsSdkSigV4AuthInputConfig { + /** + * Configuration of HttpAuthSchemes for a client which provides default identity providers and signers per auth scheme. + * @internal + */ + httpAuthSchemes?: HttpAuthScheme[]; + + /** + * Configuration of an HttpAuthSchemeProvider for a client which resolves which HttpAuthScheme to use. + * @internal + */ + httpAuthSchemeProvider?: BackupSearchHttpAuthSchemeProvider; +} + +/** + * @internal + */ +export interface HttpAuthSchemeResolvedConfig extends AwsSdkSigV4AuthResolvedConfig { + /** + * Configuration of HttpAuthSchemes for a client which provides default identity providers and signers per auth scheme. + * @internal + */ + readonly httpAuthSchemes: HttpAuthScheme[]; + + /** + * Configuration of an HttpAuthSchemeProvider for a client which resolves which HttpAuthScheme to use. + * @internal + */ + readonly httpAuthSchemeProvider: BackupSearchHttpAuthSchemeProvider; +} + +/** + * @internal + */ +export const resolveHttpAuthSchemeConfig = ( + config: T & HttpAuthSchemeInputConfig & AwsSdkSigV4PreviouslyResolved +): T & HttpAuthSchemeResolvedConfig => { + const config_0 = resolveAwsSdkSigV4Config(config); + return { + ...config_0, + } as T & HttpAuthSchemeResolvedConfig; +}; diff --git a/clients/client-backupsearch/src/commands/GetSearchJobCommand.ts b/clients/client-backupsearch/src/commands/GetSearchJobCommand.ts new file mode 100644 index 000000000000..0e71463a091d --- /dev/null +++ b/clients/client-backupsearch/src/commands/GetSearchJobCommand.ts @@ -0,0 +1,208 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { GetSearchJobInput, GetSearchJobOutput } from "../models/models_0"; +import { de_GetSearchJobCommand, se_GetSearchJobCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link GetSearchJobCommand}. + */ +export interface GetSearchJobCommandInput extends GetSearchJobInput {} +/** + * @public + * + * The output of {@link GetSearchJobCommand}. + */ +export interface GetSearchJobCommandOutput extends GetSearchJobOutput, __MetadataBearer {} + +/** + *

This operation retrieves metadata of a search job, + * including its progress.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, GetSearchJobCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, GetSearchJobCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // GetSearchJobInput + * SearchJobIdentifier: "STRING_VALUE", // required + * }; + * const command = new GetSearchJobCommand(input); + * const response = await client.send(command); + * // { // GetSearchJobOutput + * // Name: "STRING_VALUE", + * // SearchScopeSummary: { // SearchScopeSummary + * // TotalRecoveryPointsToScanCount: Number("int"), + * // TotalItemsToScanCount: Number("long"), + * // }, + * // CurrentSearchProgress: { // CurrentSearchProgress + * // RecoveryPointsScannedCount: Number("int"), + * // ItemsScannedCount: Number("long"), + * // ItemsMatchedCount: Number("long"), + * // }, + * // StatusMessage: "STRING_VALUE", + * // EncryptionKeyArn: "STRING_VALUE", + * // CompletionTime: new Date("TIMESTAMP"), + * // Status: "RUNNING" || "COMPLETED" || "STOPPING" || "STOPPED" || "FAILED", // required + * // SearchScope: { // SearchScope + * // BackupResourceTypes: [ // ResourceTypeList // required + * // "S3" || "EBS", + * // ], + * // BackupResourceCreationTime: { // BackupCreationTimeFilter + * // CreatedAfter: new Date("TIMESTAMP"), + * // CreatedBefore: new Date("TIMESTAMP"), + * // }, + * // SourceResourceArns: [ // ResourceArnList + * // "STRING_VALUE", + * // ], + * // BackupResourceArns: [ // RecoveryPointArnList + * // "STRING_VALUE", + * // ], + * // BackupResourceTags: { // TagMap + * // "": "STRING_VALUE", + * // }, + * // }, + * // ItemFilters: { // ItemFilters + * // S3ItemFilters: [ // S3ItemFilters + * // { // S3ItemFilter + * // ObjectKeys: [ // StringConditionList + * // { // StringCondition + * // Value: "STRING_VALUE", // required + * // Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "CONTAINS" || "DOES_NOT_CONTAIN" || "BEGINS_WITH" || "ENDS_WITH" || "DOES_NOT_BEGIN_WITH" || "DOES_NOT_END_WITH", + * // }, + * // ], + * // Sizes: [ // LongConditionList + * // { // LongCondition + * // Value: Number("long"), // required + * // Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "LESS_THAN_EQUAL_TO" || "GREATER_THAN_EQUAL_TO", + * // }, + * // ], + * // CreationTimes: [ // TimeConditionList + * // { // TimeCondition + * // Value: new Date("TIMESTAMP"), // required + * // Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "LESS_THAN_EQUAL_TO" || "GREATER_THAN_EQUAL_TO", + * // }, + * // ], + * // VersionIds: [ + * // { + * // Value: "STRING_VALUE", // required + * // Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "CONTAINS" || "DOES_NOT_CONTAIN" || "BEGINS_WITH" || "ENDS_WITH" || "DOES_NOT_BEGIN_WITH" || "DOES_NOT_END_WITH", + * // }, + * // ], + * // ETags: [ + * // { + * // Value: "STRING_VALUE", // required + * // Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "CONTAINS" || "DOES_NOT_CONTAIN" || "BEGINS_WITH" || "ENDS_WITH" || "DOES_NOT_BEGIN_WITH" || "DOES_NOT_END_WITH", + * // }, + * // ], + * // }, + * // ], + * // EBSItemFilters: [ // EBSItemFilters + * // { // EBSItemFilter + * // FilePaths: [ + * // { + * // Value: "STRING_VALUE", // required + * // Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "CONTAINS" || "DOES_NOT_CONTAIN" || "BEGINS_WITH" || "ENDS_WITH" || "DOES_NOT_BEGIN_WITH" || "DOES_NOT_END_WITH", + * // }, + * // ], + * // Sizes: [ + * // { + * // Value: Number("long"), // required + * // Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "LESS_THAN_EQUAL_TO" || "GREATER_THAN_EQUAL_TO", + * // }, + * // ], + * // CreationTimes: [ + * // { + * // Value: new Date("TIMESTAMP"), // required + * // Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "LESS_THAN_EQUAL_TO" || "GREATER_THAN_EQUAL_TO", + * // }, + * // ], + * // LastModificationTimes: [ + * // { + * // Value: new Date("TIMESTAMP"), // required + * // Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "LESS_THAN_EQUAL_TO" || "GREATER_THAN_EQUAL_TO", + * // }, + * // ], + * // }, + * // ], + * // }, + * // CreationTime: new Date("TIMESTAMP"), // required + * // SearchJobIdentifier: "STRING_VALUE", // required + * // SearchJobArn: "STRING_VALUE", // required + * // }; + * + * ``` + * + * @param GetSearchJobCommandInput - {@link GetSearchJobCommandInput} + * @returns {@link GetSearchJobCommandOutput} + * @see {@link GetSearchJobCommandInput} for command's `input` shape. + * @see {@link GetSearchJobCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ResourceNotFoundException} (client fault) + *

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class GetSearchJobCommand extends $Command + .classBuilder< + GetSearchJobCommandInput, + GetSearchJobCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "GetSearchJob", {}) + .n("BackupSearchClient", "GetSearchJobCommand") + .f(void 0, void 0) + .ser(se_GetSearchJobCommand) + .de(de_GetSearchJobCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: GetSearchJobInput; + output: GetSearchJobOutput; + }; + sdk: { + input: GetSearchJobCommandInput; + output: GetSearchJobCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/GetSearchResultExportJobCommand.ts b/clients/client-backupsearch/src/commands/GetSearchResultExportJobCommand.ts new file mode 100644 index 000000000000..7c44830c84ae --- /dev/null +++ b/clients/client-backupsearch/src/commands/GetSearchResultExportJobCommand.ts @@ -0,0 +1,126 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { GetSearchResultExportJobInput, GetSearchResultExportJobOutput } from "../models/models_0"; +import { de_GetSearchResultExportJobCommand, se_GetSearchResultExportJobCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link GetSearchResultExportJobCommand}. + */ +export interface GetSearchResultExportJobCommandInput extends GetSearchResultExportJobInput {} +/** + * @public + * + * The output of {@link GetSearchResultExportJobCommand}. + */ +export interface GetSearchResultExportJobCommandOutput extends GetSearchResultExportJobOutput, __MetadataBearer {} + +/** + *

This operation retrieves the metadata of an export job.

+ *

An export job is an operation that transmits the results + * of a search job to a specified S3 bucket in a + * .csv file.

+ *

An export job allows you to retain results of a search + * beyond the search job's scheduled retention of 7 days.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, GetSearchResultExportJobCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, GetSearchResultExportJobCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // GetSearchResultExportJobInput + * ExportJobIdentifier: "STRING_VALUE", // required + * }; + * const command = new GetSearchResultExportJobCommand(input); + * const response = await client.send(command); + * // { // GetSearchResultExportJobOutput + * // ExportJobIdentifier: "STRING_VALUE", // required + * // ExportJobArn: "STRING_VALUE", + * // Status: "RUNNING" || "FAILED" || "COMPLETED", + * // CreationTime: new Date("TIMESTAMP"), + * // CompletionTime: new Date("TIMESTAMP"), + * // StatusMessage: "STRING_VALUE", + * // ExportSpecification: { // ExportSpecification Union: only one key present + * // s3ExportSpecification: { // S3ExportSpecification + * // DestinationBucket: "STRING_VALUE", // required + * // DestinationPrefix: "STRING_VALUE", + * // }, + * // }, + * // SearchJobArn: "STRING_VALUE", + * // }; + * + * ``` + * + * @param GetSearchResultExportJobCommandInput - {@link GetSearchResultExportJobCommandInput} + * @returns {@link GetSearchResultExportJobCommandOutput} + * @see {@link GetSearchResultExportJobCommandInput} for command's `input` shape. + * @see {@link GetSearchResultExportJobCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ResourceNotFoundException} (client fault) + *

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class GetSearchResultExportJobCommand extends $Command + .classBuilder< + GetSearchResultExportJobCommandInput, + GetSearchResultExportJobCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "GetSearchResultExportJob", {}) + .n("BackupSearchClient", "GetSearchResultExportJobCommand") + .f(void 0, void 0) + .ser(se_GetSearchResultExportJobCommand) + .de(de_GetSearchResultExportJobCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: GetSearchResultExportJobInput; + output: GetSearchResultExportJobOutput; + }; + sdk: { + input: GetSearchResultExportJobCommandInput; + output: GetSearchResultExportJobCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/ListSearchJobBackupsCommand.ts b/clients/client-backupsearch/src/commands/ListSearchJobBackupsCommand.ts new file mode 100644 index 000000000000..5710d2a03c09 --- /dev/null +++ b/clients/client-backupsearch/src/commands/ListSearchJobBackupsCommand.ts @@ -0,0 +1,134 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { ListSearchJobBackupsInput, ListSearchJobBackupsOutput } from "../models/models_0"; +import { de_ListSearchJobBackupsCommand, se_ListSearchJobBackupsCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link ListSearchJobBackupsCommand}. + */ +export interface ListSearchJobBackupsCommandInput extends ListSearchJobBackupsInput {} +/** + * @public + * + * The output of {@link ListSearchJobBackupsCommand}. + */ +export interface ListSearchJobBackupsCommandOutput extends ListSearchJobBackupsOutput, __MetadataBearer {} + +/** + *

This operation returns a list of all backups (recovery + * points) in a paginated format that were included in + * the search job.

+ *

If a search does not display an expected backup in + * the results, you can call this operation to display each + * backup included in the search. Any backups that were not + * included because they have a FAILED status + * from a permissions issue will be displayed, along with a + * status message.

+ *

Only recovery points with a backup index that has + * a status of ACTIVE will be included in search results. + * If the index has any other status, its status will be + * displayed along with a status message.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, ListSearchJobBackupsCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, ListSearchJobBackupsCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // ListSearchJobBackupsInput + * SearchJobIdentifier: "STRING_VALUE", // required + * NextToken: "STRING_VALUE", + * MaxResults: Number("int"), + * }; + * const command = new ListSearchJobBackupsCommand(input); + * const response = await client.send(command); + * // { // ListSearchJobBackupsOutput + * // Results: [ // SearchJobBackupsResults // required + * // { // SearchJobBackupsResult + * // Status: "RUNNING" || "COMPLETED" || "STOPPING" || "STOPPED" || "FAILED", + * // StatusMessage: "STRING_VALUE", + * // ResourceType: "S3" || "EBS", + * // BackupResourceArn: "STRING_VALUE", + * // SourceResourceArn: "STRING_VALUE", + * // IndexCreationTime: new Date("TIMESTAMP"), + * // BackupCreationTime: new Date("TIMESTAMP"), + * // }, + * // ], + * // NextToken: "STRING_VALUE", + * // }; + * + * ``` + * + * @param ListSearchJobBackupsCommandInput - {@link ListSearchJobBackupsCommandInput} + * @returns {@link ListSearchJobBackupsCommandOutput} + * @see {@link ListSearchJobBackupsCommandInput} for command's `input` shape. + * @see {@link ListSearchJobBackupsCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ResourceNotFoundException} (client fault) + *

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class ListSearchJobBackupsCommand extends $Command + .classBuilder< + ListSearchJobBackupsCommandInput, + ListSearchJobBackupsCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "ListSearchJobBackups", {}) + .n("BackupSearchClient", "ListSearchJobBackupsCommand") + .f(void 0, void 0) + .ser(se_ListSearchJobBackupsCommand) + .de(de_ListSearchJobBackupsCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: ListSearchJobBackupsInput; + output: ListSearchJobBackupsOutput; + }; + sdk: { + input: ListSearchJobBackupsCommandInput; + output: ListSearchJobBackupsCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/ListSearchJobResultsCommand.ts b/clients/client-backupsearch/src/commands/ListSearchJobResultsCommand.ts new file mode 100644 index 000000000000..deb4d83e81b1 --- /dev/null +++ b/clients/client-backupsearch/src/commands/ListSearchJobResultsCommand.ts @@ -0,0 +1,139 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { + ListSearchJobResultsInput, + ListSearchJobResultsOutput, + ListSearchJobResultsOutputFilterSensitiveLog, +} from "../models/models_0"; +import { de_ListSearchJobResultsCommand, se_ListSearchJobResultsCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link ListSearchJobResultsCommand}. + */ +export interface ListSearchJobResultsCommandInput extends ListSearchJobResultsInput {} +/** + * @public + * + * The output of {@link ListSearchJobResultsCommand}. + */ +export interface ListSearchJobResultsCommandOutput extends ListSearchJobResultsOutput, __MetadataBearer {} + +/** + *

This operation returns a list of a specified search job.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, ListSearchJobResultsCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, ListSearchJobResultsCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // ListSearchJobResultsInput + * SearchJobIdentifier: "STRING_VALUE", // required + * NextToken: "STRING_VALUE", + * MaxResults: Number("int"), + * }; + * const command = new ListSearchJobResultsCommand(input); + * const response = await client.send(command); + * // { // ListSearchJobResultsOutput + * // Results: [ // Results // required + * // { // ResultItem Union: only one key present + * // S3ResultItem: { // S3ResultItem + * // BackupResourceArn: "STRING_VALUE", + * // SourceResourceArn: "STRING_VALUE", + * // BackupVaultName: "STRING_VALUE", + * // ObjectKey: "STRING_VALUE", + * // ObjectSize: Number("long"), + * // CreationTime: new Date("TIMESTAMP"), + * // ETag: "STRING_VALUE", + * // VersionId: "STRING_VALUE", + * // }, + * // EBSResultItem: { // EBSResultItem + * // BackupResourceArn: "STRING_VALUE", + * // SourceResourceArn: "STRING_VALUE", + * // BackupVaultName: "STRING_VALUE", + * // FileSystemIdentifier: "STRING_VALUE", + * // FilePath: "STRING_VALUE", + * // FileSize: Number("long"), + * // CreationTime: new Date("TIMESTAMP"), + * // LastModifiedTime: new Date("TIMESTAMP"), + * // }, + * // }, + * // ], + * // NextToken: "STRING_VALUE", + * // }; + * + * ``` + * + * @param ListSearchJobResultsCommandInput - {@link ListSearchJobResultsCommandInput} + * @returns {@link ListSearchJobResultsCommandOutput} + * @see {@link ListSearchJobResultsCommandInput} for command's `input` shape. + * @see {@link ListSearchJobResultsCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ResourceNotFoundException} (client fault) + *

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class ListSearchJobResultsCommand extends $Command + .classBuilder< + ListSearchJobResultsCommandInput, + ListSearchJobResultsCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "ListSearchJobResults", {}) + .n("BackupSearchClient", "ListSearchJobResultsCommand") + .f(void 0, ListSearchJobResultsOutputFilterSensitiveLog) + .ser(se_ListSearchJobResultsCommand) + .de(de_ListSearchJobResultsCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: ListSearchJobResultsInput; + output: ListSearchJobResultsOutput; + }; + sdk: { + input: ListSearchJobResultsCommandInput; + output: ListSearchJobResultsCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/ListSearchJobsCommand.ts b/clients/client-backupsearch/src/commands/ListSearchJobsCommand.ts new file mode 100644 index 000000000000..9c672996afde --- /dev/null +++ b/clients/client-backupsearch/src/commands/ListSearchJobsCommand.ts @@ -0,0 +1,122 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { ListSearchJobsInput, ListSearchJobsOutput } from "../models/models_0"; +import { de_ListSearchJobsCommand, se_ListSearchJobsCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link ListSearchJobsCommand}. + */ +export interface ListSearchJobsCommandInput extends ListSearchJobsInput {} +/** + * @public + * + * The output of {@link ListSearchJobsCommand}. + */ +export interface ListSearchJobsCommandOutput extends ListSearchJobsOutput, __MetadataBearer {} + +/** + *

This operation returns a list of search jobs belonging + * to an account.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, ListSearchJobsCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, ListSearchJobsCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // ListSearchJobsInput + * ByStatus: "RUNNING" || "COMPLETED" || "STOPPING" || "STOPPED" || "FAILED", + * NextToken: "STRING_VALUE", + * MaxResults: Number("int"), + * }; + * const command = new ListSearchJobsCommand(input); + * const response = await client.send(command); + * // { // ListSearchJobsOutput + * // SearchJobs: [ // SearchJobs // required + * // { // SearchJobSummary + * // SearchJobIdentifier: "STRING_VALUE", + * // SearchJobArn: "STRING_VALUE", + * // Name: "STRING_VALUE", + * // Status: "RUNNING" || "COMPLETED" || "STOPPING" || "STOPPED" || "FAILED", + * // CreationTime: new Date("TIMESTAMP"), + * // CompletionTime: new Date("TIMESTAMP"), + * // SearchScopeSummary: { // SearchScopeSummary + * // TotalRecoveryPointsToScanCount: Number("int"), + * // TotalItemsToScanCount: Number("long"), + * // }, + * // StatusMessage: "STRING_VALUE", + * // }, + * // ], + * // NextToken: "STRING_VALUE", + * // }; + * + * ``` + * + * @param ListSearchJobsCommandInput - {@link ListSearchJobsCommandInput} + * @returns {@link ListSearchJobsCommandOutput} + * @see {@link ListSearchJobsCommandInput} for command's `input` shape. + * @see {@link ListSearchJobsCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link AccessDeniedException} (client fault) + *

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class ListSearchJobsCommand extends $Command + .classBuilder< + ListSearchJobsCommandInput, + ListSearchJobsCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "ListSearchJobs", {}) + .n("BackupSearchClient", "ListSearchJobsCommand") + .f(void 0, void 0) + .ser(se_ListSearchJobsCommand) + .de(de_ListSearchJobsCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: ListSearchJobsInput; + output: ListSearchJobsOutput; + }; + sdk: { + input: ListSearchJobsCommandInput; + output: ListSearchJobsCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/ListSearchResultExportJobsCommand.ts b/clients/client-backupsearch/src/commands/ListSearchResultExportJobsCommand.ts new file mode 100644 index 000000000000..30df4619642c --- /dev/null +++ b/clients/client-backupsearch/src/commands/ListSearchResultExportJobsCommand.ts @@ -0,0 +1,127 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { ListSearchResultExportJobsInput, ListSearchResultExportJobsOutput } from "../models/models_0"; +import { de_ListSearchResultExportJobsCommand, se_ListSearchResultExportJobsCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link ListSearchResultExportJobsCommand}. + */ +export interface ListSearchResultExportJobsCommandInput extends ListSearchResultExportJobsInput {} +/** + * @public + * + * The output of {@link ListSearchResultExportJobsCommand}. + */ +export interface ListSearchResultExportJobsCommandOutput extends ListSearchResultExportJobsOutput, __MetadataBearer {} + +/** + *

This operation exports search results of a search job + * to a specified destination S3 bucket.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, ListSearchResultExportJobsCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, ListSearchResultExportJobsCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // ListSearchResultExportJobsInput + * Status: "RUNNING" || "FAILED" || "COMPLETED", + * SearchJobIdentifier: "STRING_VALUE", + * NextToken: "STRING_VALUE", + * MaxResults: Number("int"), + * }; + * const command = new ListSearchResultExportJobsCommand(input); + * const response = await client.send(command); + * // { // ListSearchResultExportJobsOutput + * // ExportJobs: [ // ExportJobSummaries // required + * // { // ExportJobSummary + * // ExportJobIdentifier: "STRING_VALUE", // required + * // ExportJobArn: "STRING_VALUE", + * // Status: "RUNNING" || "FAILED" || "COMPLETED", + * // CreationTime: new Date("TIMESTAMP"), + * // CompletionTime: new Date("TIMESTAMP"), + * // StatusMessage: "STRING_VALUE", + * // SearchJobArn: "STRING_VALUE", + * // }, + * // ], + * // NextToken: "STRING_VALUE", + * // }; + * + * ``` + * + * @param ListSearchResultExportJobsCommandInput - {@link ListSearchResultExportJobsCommandInput} + * @returns {@link ListSearchResultExportJobsCommandOutput} + * @see {@link ListSearchResultExportJobsCommandInput} for command's `input` shape. + * @see {@link ListSearchResultExportJobsCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ResourceNotFoundException} (client fault) + *

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

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

The request denied due to exceeding the quota limits permitted.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class ListSearchResultExportJobsCommand extends $Command + .classBuilder< + ListSearchResultExportJobsCommandInput, + ListSearchResultExportJobsCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "ListSearchResultExportJobs", {}) + .n("BackupSearchClient", "ListSearchResultExportJobsCommand") + .f(void 0, void 0) + .ser(se_ListSearchResultExportJobsCommand) + .de(de_ListSearchResultExportJobsCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: ListSearchResultExportJobsInput; + output: ListSearchResultExportJobsOutput; + }; + sdk: { + input: ListSearchResultExportJobsCommandInput; + output: ListSearchResultExportJobsCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/ListTagsForResourceCommand.ts b/clients/client-backupsearch/src/commands/ListTagsForResourceCommand.ts new file mode 100644 index 000000000000..b98ef69f73b8 --- /dev/null +++ b/clients/client-backupsearch/src/commands/ListTagsForResourceCommand.ts @@ -0,0 +1,111 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { ListTagsForResourceRequest, ListTagsForResourceResponse } from "../models/models_0"; +import { de_ListTagsForResourceCommand, se_ListTagsForResourceCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link ListTagsForResourceCommand}. + */ +export interface ListTagsForResourceCommandInput extends ListTagsForResourceRequest {} +/** + * @public + * + * The output of {@link ListTagsForResourceCommand}. + */ +export interface ListTagsForResourceCommandOutput extends ListTagsForResourceResponse, __MetadataBearer {} + +/** + *

This operation returns the tags for a resource type.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, ListTagsForResourceCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, ListTagsForResourceCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // ListTagsForResourceRequest + * ResourceArn: "STRING_VALUE", // required + * }; + * const command = new ListTagsForResourceCommand(input); + * const response = await client.send(command); + * // { // ListTagsForResourceResponse + * // Tags: { // TagMap + * // "": "STRING_VALUE", + * // }, + * // }; + * + * ``` + * + * @param ListTagsForResourceCommandInput - {@link ListTagsForResourceCommandInput} + * @returns {@link ListTagsForResourceCommandOutput} + * @see {@link ListTagsForResourceCommandInput} for command's `input` shape. + * @see {@link ListTagsForResourceCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ResourceNotFoundException} (client fault) + *

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class ListTagsForResourceCommand extends $Command + .classBuilder< + ListTagsForResourceCommandInput, + ListTagsForResourceCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "ListTagsForResource", {}) + .n("BackupSearchClient", "ListTagsForResourceCommand") + .f(void 0, void 0) + .ser(se_ListTagsForResourceCommand) + .de(de_ListTagsForResourceCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: ListTagsForResourceRequest; + output: ListTagsForResourceResponse; + }; + sdk: { + input: ListTagsForResourceCommandInput; + output: ListTagsForResourceCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/StartSearchJobCommand.ts b/clients/client-backupsearch/src/commands/StartSearchJobCommand.ts new file mode 100644 index 000000000000..128ffbca7229 --- /dev/null +++ b/clients/client-backupsearch/src/commands/StartSearchJobCommand.ts @@ -0,0 +1,208 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { StartSearchJobInput, StartSearchJobOutput } from "../models/models_0"; +import { de_StartSearchJobCommand, se_StartSearchJobCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link StartSearchJobCommand}. + */ +export interface StartSearchJobCommandInput extends StartSearchJobInput {} +/** + * @public + * + * The output of {@link StartSearchJobCommand}. + */ +export interface StartSearchJobCommandOutput extends StartSearchJobOutput, __MetadataBearer {} + +/** + *

This operation creates a search job which returns + * recovery points filtered by SearchScope and items + * filtered by ItemFilters.

+ *

You can optionally include ClientToken, + * EncryptionKeyArn, Name, and/or Tags.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, StartSearchJobCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, StartSearchJobCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // StartSearchJobInput + * Tags: { // TagMap + * "": "STRING_VALUE", + * }, + * Name: "STRING_VALUE", + * EncryptionKeyArn: "STRING_VALUE", + * ClientToken: "STRING_VALUE", + * SearchScope: { // SearchScope + * BackupResourceTypes: [ // ResourceTypeList // required + * "S3" || "EBS", + * ], + * BackupResourceCreationTime: { // BackupCreationTimeFilter + * CreatedAfter: new Date("TIMESTAMP"), + * CreatedBefore: new Date("TIMESTAMP"), + * }, + * SourceResourceArns: [ // ResourceArnList + * "STRING_VALUE", + * ], + * BackupResourceArns: [ // RecoveryPointArnList + * "STRING_VALUE", + * ], + * BackupResourceTags: { + * "": "STRING_VALUE", + * }, + * }, + * ItemFilters: { // ItemFilters + * S3ItemFilters: [ // S3ItemFilters + * { // S3ItemFilter + * ObjectKeys: [ // StringConditionList + * { // StringCondition + * Value: "STRING_VALUE", // required + * Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "CONTAINS" || "DOES_NOT_CONTAIN" || "BEGINS_WITH" || "ENDS_WITH" || "DOES_NOT_BEGIN_WITH" || "DOES_NOT_END_WITH", + * }, + * ], + * Sizes: [ // LongConditionList + * { // LongCondition + * Value: Number("long"), // required + * Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "LESS_THAN_EQUAL_TO" || "GREATER_THAN_EQUAL_TO", + * }, + * ], + * CreationTimes: [ // TimeConditionList + * { // TimeCondition + * Value: new Date("TIMESTAMP"), // required + * Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "LESS_THAN_EQUAL_TO" || "GREATER_THAN_EQUAL_TO", + * }, + * ], + * VersionIds: [ + * { + * Value: "STRING_VALUE", // required + * Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "CONTAINS" || "DOES_NOT_CONTAIN" || "BEGINS_WITH" || "ENDS_WITH" || "DOES_NOT_BEGIN_WITH" || "DOES_NOT_END_WITH", + * }, + * ], + * ETags: [ + * { + * Value: "STRING_VALUE", // required + * Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "CONTAINS" || "DOES_NOT_CONTAIN" || "BEGINS_WITH" || "ENDS_WITH" || "DOES_NOT_BEGIN_WITH" || "DOES_NOT_END_WITH", + * }, + * ], + * }, + * ], + * EBSItemFilters: [ // EBSItemFilters + * { // EBSItemFilter + * FilePaths: [ + * { + * Value: "STRING_VALUE", // required + * Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "CONTAINS" || "DOES_NOT_CONTAIN" || "BEGINS_WITH" || "ENDS_WITH" || "DOES_NOT_BEGIN_WITH" || "DOES_NOT_END_WITH", + * }, + * ], + * Sizes: [ + * { + * Value: Number("long"), // required + * Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "LESS_THAN_EQUAL_TO" || "GREATER_THAN_EQUAL_TO", + * }, + * ], + * CreationTimes: [ + * { + * Value: new Date("TIMESTAMP"), // required + * Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "LESS_THAN_EQUAL_TO" || "GREATER_THAN_EQUAL_TO", + * }, + * ], + * LastModificationTimes: [ + * { + * Value: new Date("TIMESTAMP"), // required + * Operator: "EQUALS_TO" || "NOT_EQUALS_TO" || "LESS_THAN_EQUAL_TO" || "GREATER_THAN_EQUAL_TO", + * }, + * ], + * }, + * ], + * }, + * }; + * const command = new StartSearchJobCommand(input); + * const response = await client.send(command); + * // { // StartSearchJobOutput + * // SearchJobArn: "STRING_VALUE", + * // CreationTime: new Date("TIMESTAMP"), + * // SearchJobIdentifier: "STRING_VALUE", + * // }; + * + * ``` + * + * @param StartSearchJobCommandInput - {@link StartSearchJobCommandInput} + * @returns {@link StartSearchJobCommandOutput} + * @see {@link StartSearchJobCommandInput} for command's `input` shape. + * @see {@link StartSearchJobCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ConflictException} (client fault) + *

This exception occurs when a conflict with a previous successful + * operation is detected. This generally occurs when the previous + * operation did not have time to propagate to the host serving the + * current request.

+ *

A retry (with appropriate backoff logic) is the recommended + * response to this exception.

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

The request denied due to exceeding the quota limits permitted.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class StartSearchJobCommand extends $Command + .classBuilder< + StartSearchJobCommandInput, + StartSearchJobCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "StartSearchJob", {}) + .n("BackupSearchClient", "StartSearchJobCommand") + .f(void 0, void 0) + .ser(se_StartSearchJobCommand) + .de(de_StartSearchJobCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: StartSearchJobInput; + output: StartSearchJobOutput; + }; + sdk: { + input: StartSearchJobCommandInput; + output: StartSearchJobCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/StartSearchResultExportJobCommand.ts b/clients/client-backupsearch/src/commands/StartSearchResultExportJobCommand.ts new file mode 100644 index 000000000000..43e0a665e9d9 --- /dev/null +++ b/clients/client-backupsearch/src/commands/StartSearchResultExportJobCommand.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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { StartSearchResultExportJobInput, StartSearchResultExportJobOutput } from "../models/models_0"; +import { de_StartSearchResultExportJobCommand, se_StartSearchResultExportJobCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link StartSearchResultExportJobCommand}. + */ +export interface StartSearchResultExportJobCommandInput extends StartSearchResultExportJobInput {} +/** + * @public + * + * The output of {@link StartSearchResultExportJobCommand}. + */ +export interface StartSearchResultExportJobCommandOutput extends StartSearchResultExportJobOutput, __MetadataBearer {} + +/** + *

This operations starts a job to export the results + * of search job to a designated S3 bucket.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, StartSearchResultExportJobCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, StartSearchResultExportJobCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // StartSearchResultExportJobInput + * SearchJobIdentifier: "STRING_VALUE", // required + * ExportSpecification: { // ExportSpecification Union: only one key present + * s3ExportSpecification: { // S3ExportSpecification + * DestinationBucket: "STRING_VALUE", // required + * DestinationPrefix: "STRING_VALUE", + * }, + * }, + * ClientToken: "STRING_VALUE", + * Tags: { // TagMap + * "": "STRING_VALUE", + * }, + * RoleArn: "STRING_VALUE", + * }; + * const command = new StartSearchResultExportJobCommand(input); + * const response = await client.send(command); + * // { // StartSearchResultExportJobOutput + * // ExportJobArn: "STRING_VALUE", + * // ExportJobIdentifier: "STRING_VALUE", // required + * // }; + * + * ``` + * + * @param StartSearchResultExportJobCommandInput - {@link StartSearchResultExportJobCommandInput} + * @returns {@link StartSearchResultExportJobCommandOutput} + * @see {@link StartSearchResultExportJobCommandInput} for command's `input` shape. + * @see {@link StartSearchResultExportJobCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ConflictException} (client fault) + *

This exception occurs when a conflict with a previous successful + * operation is detected. This generally occurs when the previous + * operation did not have time to propagate to the host serving the + * current request.

+ *

A retry (with appropriate backoff logic) is the recommended + * response to this exception.

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

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

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

The request denied due to exceeding the quota limits permitted.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class StartSearchResultExportJobCommand extends $Command + .classBuilder< + StartSearchResultExportJobCommandInput, + StartSearchResultExportJobCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "StartSearchResultExportJob", {}) + .n("BackupSearchClient", "StartSearchResultExportJobCommand") + .f(void 0, void 0) + .ser(se_StartSearchResultExportJobCommand) + .de(de_StartSearchResultExportJobCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: StartSearchResultExportJobInput; + output: StartSearchResultExportJobOutput; + }; + sdk: { + input: StartSearchResultExportJobCommandInput; + output: StartSearchResultExportJobCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/StopSearchJobCommand.ts b/clients/client-backupsearch/src/commands/StopSearchJobCommand.ts new file mode 100644 index 000000000000..118cf92418ec --- /dev/null +++ b/clients/client-backupsearch/src/commands/StopSearchJobCommand.ts @@ -0,0 +1,117 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { StopSearchJobInput, StopSearchJobOutput } from "../models/models_0"; +import { de_StopSearchJobCommand, se_StopSearchJobCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link StopSearchJobCommand}. + */ +export interface StopSearchJobCommandInput extends StopSearchJobInput {} +/** + * @public + * + * The output of {@link StopSearchJobCommand}. + */ +export interface StopSearchJobCommandOutput extends StopSearchJobOutput, __MetadataBearer {} + +/** + *

This operations ends a search job.

+ *

Only a search job with a status of RUNNING + * can be stopped.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, StopSearchJobCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, StopSearchJobCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // StopSearchJobInput + * SearchJobIdentifier: "STRING_VALUE", // required + * }; + * const command = new StopSearchJobCommand(input); + * const response = await client.send(command); + * // {}; + * + * ``` + * + * @param StopSearchJobCommandInput - {@link StopSearchJobCommandInput} + * @returns {@link StopSearchJobCommandOutput} + * @see {@link StopSearchJobCommandInput} for command's `input` shape. + * @see {@link StopSearchJobCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ConflictException} (client fault) + *

This exception occurs when a conflict with a previous successful + * operation is detected. This generally occurs when the previous + * operation did not have time to propagate to the host serving the + * current request.

+ *

A retry (with appropriate backoff logic) is the recommended + * response to this exception.

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

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class StopSearchJobCommand extends $Command + .classBuilder< + StopSearchJobCommandInput, + StopSearchJobCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "StopSearchJob", {}) + .n("BackupSearchClient", "StopSearchJobCommand") + .f(void 0, void 0) + .ser(se_StopSearchJobCommand) + .de(de_StopSearchJobCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: StopSearchJobInput; + output: {}; + }; + sdk: { + input: StopSearchJobCommandInput; + output: StopSearchJobCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/TagResourceCommand.ts b/clients/client-backupsearch/src/commands/TagResourceCommand.ts new file mode 100644 index 000000000000..bb52676c435b --- /dev/null +++ b/clients/client-backupsearch/src/commands/TagResourceCommand.ts @@ -0,0 +1,110 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { TagResourceRequest, TagResourceResponse } from "../models/models_0"; +import { de_TagResourceCommand, se_TagResourceCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link TagResourceCommand}. + */ +export interface TagResourceCommandInput extends TagResourceRequest {} +/** + * @public + * + * The output of {@link TagResourceCommand}. + */ +export interface TagResourceCommandOutput extends TagResourceResponse, __MetadataBearer {} + +/** + *

This operation puts tags on the resource you indicate.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, TagResourceCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, TagResourceCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // TagResourceRequest + * ResourceArn: "STRING_VALUE", // required + * Tags: { // TagMap // required + * "": "STRING_VALUE", + * }, + * }; + * const command = new TagResourceCommand(input); + * const response = await client.send(command); + * // {}; + * + * ``` + * + * @param TagResourceCommandInput - {@link TagResourceCommandInput} + * @returns {@link TagResourceCommandOutput} + * @see {@link TagResourceCommandInput} for command's `input` shape. + * @see {@link TagResourceCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ResourceNotFoundException} (client fault) + *

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class TagResourceCommand extends $Command + .classBuilder< + TagResourceCommandInput, + TagResourceCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "TagResource", {}) + .n("BackupSearchClient", "TagResourceCommand") + .f(void 0, void 0) + .ser(se_TagResourceCommand) + .de(de_TagResourceCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: TagResourceRequest; + output: {}; + }; + sdk: { + input: TagResourceCommandInput; + output: TagResourceCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/UntagResourceCommand.ts b/clients/client-backupsearch/src/commands/UntagResourceCommand.ts new file mode 100644 index 000000000000..7e190d48638f --- /dev/null +++ b/clients/client-backupsearch/src/commands/UntagResourceCommand.ts @@ -0,0 +1,110 @@ +// 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 { BackupSearchClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../BackupSearchClient"; +import { commonParams } from "../endpoint/EndpointParameters"; +import { UntagResourceRequest, UntagResourceResponse } from "../models/models_0"; +import { de_UntagResourceCommand, se_UntagResourceCommand } from "../protocols/Aws_restJson1"; + +/** + * @public + */ +export type { __MetadataBearer }; +export { $Command }; +/** + * @public + * + * The input for {@link UntagResourceCommand}. + */ +export interface UntagResourceCommandInput extends UntagResourceRequest {} +/** + * @public + * + * The output of {@link UntagResourceCommand}. + */ +export interface UntagResourceCommandOutput extends UntagResourceResponse, __MetadataBearer {} + +/** + *

This operation removes tags from the specified resource.

+ * @example + * Use a bare-bones client and the command you need to make an API call. + * ```javascript + * import { BackupSearchClient, UntagResourceCommand } from "@aws-sdk/client-backupsearch"; // ES Modules import + * // const { BackupSearchClient, UntagResourceCommand } = require("@aws-sdk/client-backupsearch"); // CommonJS import + * const client = new BackupSearchClient(config); + * const input = { // UntagResourceRequest + * ResourceArn: "STRING_VALUE", // required + * TagKeys: [ // TagKeys // required + * "STRING_VALUE", + * ], + * }; + * const command = new UntagResourceCommand(input); + * const response = await client.send(command); + * // {}; + * + * ``` + * + * @param UntagResourceCommandInput - {@link UntagResourceCommandInput} + * @returns {@link UntagResourceCommandOutput} + * @see {@link UntagResourceCommandInput} for command's `input` shape. + * @see {@link UntagResourceCommandOutput} for command's `response` shape. + * @see {@link BackupSearchClientResolvedConfig | config} for BackupSearchClient's `config` shape. + * + * @throws {@link ResourceNotFoundException} (client fault) + *

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

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

You do not have sufficient access to perform this action.

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

An internal server error occurred. Retry your request.

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

The request was denied due to request throttling.

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

The input fails to satisfy the constraints specified by a service.

+ * + * @throws {@link BackupSearchServiceException} + *

Base exception class for all service exceptions from BackupSearch service.

+ * + * @public + */ +export class UntagResourceCommand extends $Command + .classBuilder< + UntagResourceCommandInput, + UntagResourceCommandOutput, + BackupSearchClientResolvedConfig, + ServiceInputTypes, + ServiceOutputTypes + >() + .ep(commonParams) + .m(function (this: any, Command: any, cs: any, config: BackupSearchClientResolvedConfig, o: any) { + return [ + getSerdePlugin(config, this.serialize, this.deserialize), + getEndpointPlugin(config, Command.getEndpointParameterInstructions()), + ]; + }) + .s("CryoBackupSearchService", "UntagResource", {}) + .n("BackupSearchClient", "UntagResourceCommand") + .f(void 0, void 0) + .ser(se_UntagResourceCommand) + .de(de_UntagResourceCommand) + .build() { + /** @internal type navigation helper, not in runtime. */ + protected declare static __types: { + api: { + input: UntagResourceRequest; + output: {}; + }; + sdk: { + input: UntagResourceCommandInput; + output: UntagResourceCommandOutput; + }; + }; +} diff --git a/clients/client-backupsearch/src/commands/index.ts b/clients/client-backupsearch/src/commands/index.ts new file mode 100644 index 000000000000..822ca911aec9 --- /dev/null +++ b/clients/client-backupsearch/src/commands/index.ts @@ -0,0 +1,13 @@ +// smithy-typescript generated code +export * from "./GetSearchJobCommand"; +export * from "./GetSearchResultExportJobCommand"; +export * from "./ListSearchJobBackupsCommand"; +export * from "./ListSearchJobResultsCommand"; +export * from "./ListSearchJobsCommand"; +export * from "./ListSearchResultExportJobsCommand"; +export * from "./ListTagsForResourceCommand"; +export * from "./StartSearchJobCommand"; +export * from "./StartSearchResultExportJobCommand"; +export * from "./StopSearchJobCommand"; +export * from "./TagResourceCommand"; +export * from "./UntagResourceCommand"; diff --git a/clients/client-backupsearch/src/endpoint/EndpointParameters.ts b/clients/client-backupsearch/src/endpoint/EndpointParameters.ts new file mode 100644 index 000000000000..50e5719a838a --- /dev/null +++ b/clients/client-backupsearch/src/endpoint/EndpointParameters.ts @@ -0,0 +1,37 @@ +// smithy-typescript generated code +import { Endpoint, EndpointParameters as __EndpointParameters, EndpointV2, Provider } from "@smithy/types"; + +/** + * @public + */ +export interface ClientInputEndpointParameters { + useFipsEndpoint?: boolean | Provider; + endpoint?: string | Provider | Endpoint | Provider | EndpointV2 | Provider; + region?: string | Provider; +} + +export type ClientResolvedEndpointParameters = ClientInputEndpointParameters & { + defaultSigningName: string; +}; + +export const resolveClientEndpointParameters = ( + options: T & ClientInputEndpointParameters +): T & ClientResolvedEndpointParameters => { + return { + ...options, + useFipsEndpoint: options.useFipsEndpoint ?? false, + defaultSigningName: "backup-search", + }; +}; + +export const commonParams = { + UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" }, + Endpoint: { type: "builtInParams", name: "endpoint" }, + Region: { type: "builtInParams", name: "region" }, +} as const; + +export interface EndpointParameters extends __EndpointParameters { + UseFIPS?: boolean; + Endpoint?: string; + Region?: string; +} diff --git a/clients/client-backupsearch/src/endpoint/endpointResolver.ts b/clients/client-backupsearch/src/endpoint/endpointResolver.ts new file mode 100644 index 000000000000..b08a72482ca0 --- /dev/null +++ b/clients/client-backupsearch/src/endpoint/endpointResolver.ts @@ -0,0 +1,26 @@ +// smithy-typescript generated code +import { awsEndpointFunctions } from "@aws-sdk/util-endpoints"; +import { EndpointV2, Logger } from "@smithy/types"; +import { customEndpointFunctions, EndpointCache, EndpointParams, resolveEndpoint } from "@smithy/util-endpoints"; + +import { EndpointParameters } from "./EndpointParameters"; +import { ruleSet } from "./ruleset"; + +const cache = new EndpointCache({ + size: 50, + params: ["Endpoint", "Region", "UseFIPS"], +}); + +export const defaultEndpointResolver = ( + endpointParams: EndpointParameters, + context: { logger?: Logger } = {} +): EndpointV2 => { + return cache.get(endpointParams as EndpointParams, () => + resolveEndpoint(ruleSet, { + endpointParams: endpointParams as EndpointParams, + logger: context.logger, + }) + ); +}; + +customEndpointFunctions.aws = awsEndpointFunctions; diff --git a/clients/client-backupsearch/src/endpoint/ruleset.ts b/clients/client-backupsearch/src/endpoint/ruleset.ts new file mode 100644 index 000000000000..fbc65965754d --- /dev/null +++ b/clients/client-backupsearch/src/endpoint/ruleset.ts @@ -0,0 +1,22 @@ +// @ts-nocheck +// generated code, do not edit +import { RuleSetObject } from "@smithy/types"; + +/* This file is compressed. Log this object + or see "smithy.rules#endpointRuleSet" + in codegen/sdk-codegen/aws-models/backupsearch.json */ + +const l="ref"; +const a=true, +b=false, +c="isSet", +d="error", +e="endpoint", +f="tree", +g={"required":false,"type":"String"}, +h={[l]:"Endpoint"}, +i={"authSchemes":[{"name":"sigv4","signingRegion":"{PartitionResult#implicitGlobalRegion}"}]}, +j=[{"fn":"booleanEquals","argv":[{[l]:"UseFIPS"},true]}], +k=[{[l]:"Region"}]; +const _data={version:"1.0",parameters:{UseFIPS:{required:a,default:b,type:"Boolean"},Endpoint:g,Region:g},rules:[{conditions:[{fn:c,argv:[h]}],rules:[{conditions:j,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:d},{endpoint:{url:h,properties:{},headers:{}},type:e}],type:f},{rules:[{conditions:[{fn:c,argv:k}],rules:[{conditions:[{fn:"aws.partition",argv:k,assign:"PartitionResult"}],rules:[{conditions:j,endpoint:{url:"https://backup-search-fips.{PartitionResult#implicitGlobalRegion}.{PartitionResult#dualStackDnsSuffix}",properties:i,headers:{}},type:e},{endpoint:{url:"https://backup-search.{PartitionResult#implicitGlobalRegion}.{PartitionResult#dualStackDnsSuffix}",properties:i,headers:{}},type:e}],type:f}],type:f},{error:"Invalid Configuration: Missing Region",type:d}],type:f}]}; +export const ruleSet: RuleSetObject = _data; diff --git a/clients/client-backupsearch/src/extensionConfiguration.ts b/clients/client-backupsearch/src/extensionConfiguration.ts new file mode 100644 index 000000000000..cb328cb4cdf7 --- /dev/null +++ b/clients/client-backupsearch/src/extensionConfiguration.ts @@ -0,0 +1,15 @@ +// smithy-typescript generated code +import { AwsRegionExtensionConfiguration } from "@aws-sdk/types"; +import { HttpHandlerExtensionConfiguration } from "@smithy/protocol-http"; +import { DefaultExtensionConfiguration } from "@smithy/types"; + +import { HttpAuthExtensionConfiguration } from "./auth/httpAuthExtensionConfiguration"; + +/** + * @internal + */ +export interface BackupSearchExtensionConfiguration + extends HttpHandlerExtensionConfiguration, + DefaultExtensionConfiguration, + AwsRegionExtensionConfiguration, + HttpAuthExtensionConfiguration {} diff --git a/clients/client-backupsearch/src/index.ts b/clients/client-backupsearch/src/index.ts new file mode 100644 index 000000000000..711f6f419cbb --- /dev/null +++ b/clients/client-backupsearch/src/index.ts @@ -0,0 +1,32 @@ +// smithy-typescript generated code +/* eslint-disable */ +/** + * Backup Search + *

Backup Search is the recovery point and item level search for Backup.

+ *

For additional information, see:

+ * + * + * @packageDocumentation + */ +export * from "./BackupSearchClient"; +export * from "./BackupSearch"; +export { ClientInputEndpointParameters } from "./endpoint/EndpointParameters"; +export type { RuntimeExtension } from "./runtimeExtensions"; +export type { BackupSearchExtensionConfiguration } from "./extensionConfiguration"; +export * from "./commands"; +export * from "./pagination"; +export * from "./models"; + +export { BackupSearchServiceException } from "./models/BackupSearchServiceException"; diff --git a/clients/client-backupsearch/src/models/BackupSearchServiceException.ts b/clients/client-backupsearch/src/models/BackupSearchServiceException.ts new file mode 100644 index 000000000000..708c008e8462 --- /dev/null +++ b/clients/client-backupsearch/src/models/BackupSearchServiceException.ts @@ -0,0 +1,24 @@ +// smithy-typescript generated code +import { + ServiceException as __ServiceException, + ServiceExceptionOptions as __ServiceExceptionOptions, +} from "@smithy/smithy-client"; + +export type { __ServiceExceptionOptions }; + +export { __ServiceException }; + +/** + * @public + * + * Base exception class for all service exceptions from BackupSearch service. + */ +export class BackupSearchServiceException extends __ServiceException { + /** + * @internal + */ + constructor(options: __ServiceExceptionOptions) { + super(options); + Object.setPrototypeOf(this, BackupSearchServiceException.prototype); + } +} diff --git a/clients/client-backupsearch/src/models/index.ts b/clients/client-backupsearch/src/models/index.ts new file mode 100644 index 000000000000..9eaceb12865f --- /dev/null +++ b/clients/client-backupsearch/src/models/index.ts @@ -0,0 +1,2 @@ +// smithy-typescript generated code +export * from "./models_0"; diff --git a/clients/client-backupsearch/src/models/models_0.ts b/clients/client-backupsearch/src/models/models_0.ts new file mode 100644 index 000000000000..c24ff760637b --- /dev/null +++ b/clients/client-backupsearch/src/models/models_0.ts @@ -0,0 +1,1799 @@ +// smithy-typescript generated code +import { ExceptionOptionType as __ExceptionOptionType, SENSITIVE_STRING } from "@smithy/smithy-client"; + +import { BackupSearchServiceException as __BaseException } from "./BackupSearchServiceException"; + +/** + *

You do not have sufficient access to perform this action.

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

This filters by recovery points within the CreatedAfter + * and CreatedBefore timestamps.

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

This timestamp includes recovery points only + * created after the specified time.

+ * @public + */ + CreatedAfter?: Date | undefined; + + /** + *

This timestamp includes recovery points only + * created before the specified time.

+ * @public + */ + CreatedBefore?: Date | undefined; +} + +/** + *

This exception occurs when a conflict with a previous successful + * operation is detected. This generally occurs when the previous + * operation did not have time to propagate to the host serving the + * current request.

+ *

A retry (with appropriate backoff logic) is the recommended + * response to this exception.

+ * @public + */ +export class ConflictException extends __BaseException { + readonly name: "ConflictException" = "ConflictException"; + readonly $fault: "client" = "client"; + /** + *

Identifier of the resource affected.

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

Type of the resource affected.

+ * @public + */ + resourceType: string | undefined; + + /** + * @internal + */ + constructor(opts: __ExceptionOptionType) { + super({ + name: "ConflictException", + $fault: "client", + ...opts, + }); + Object.setPrototypeOf(this, ConflictException.prototype); + this.resourceId = opts.resourceId; + this.resourceType = opts.resourceType; + } +} + +/** + *

An internal server error occurred. Retry your request.

+ * @public + */ +export class InternalServerException extends __BaseException { + readonly name: "InternalServerException" = "InternalServerException"; + readonly $fault: "server" = "server"; + $retryable = {}; + /** + *

Retry the call after number of seconds.

+ * @public + */ + retryAfterSeconds?: number | undefined; + + /** + * @internal + */ + constructor(opts: __ExceptionOptionType) { + super({ + name: "InternalServerException", + $fault: "server", + ...opts, + }); + Object.setPrototypeOf(this, InternalServerException.prototype); + this.retryAfterSeconds = opts.retryAfterSeconds; + } +} + +/** + * @public + */ +export interface ListSearchJobBackupsInput { + /** + *

The unique string that specifies the search job.

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

The next item following a partial list of returned backups + * included in a search job.

+ *

For example, if a request + * is made to return MaxResults number of backups, NextToken + * allows you to return more items in your list starting at the location pointed to by the + * next token.

+ * @public + */ + NextToken?: string | undefined; + + /** + *

The maximum number of resource list items to be returned.

+ * @public + */ + MaxResults?: number | undefined; +} + +/** + * @public + * @enum + */ +export const ResourceType = { + EBS: "EBS", + S3: "S3", +} as const; + +/** + * @public + */ +export type ResourceType = (typeof ResourceType)[keyof typeof ResourceType]; + +/** + * @public + * @enum + */ +export const SearchJobState = { + COMPLETED: "COMPLETED", + FAILED: "FAILED", + RUNNING: "RUNNING", + STOPPED: "STOPPED", + STOPPING: "STOPPING", +} as const; + +/** + * @public + */ +export type SearchJobState = (typeof SearchJobState)[keyof typeof SearchJobState]; + +/** + *

This contains the information about recovery + * points returned in results of a search job.

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

This is the status of the search job backup result.

+ * @public + */ + Status?: SearchJobState | undefined; + + /** + *

This is the status message included with the results.

+ * @public + */ + StatusMessage?: string | undefined; + + /** + *

This is the resource type of the search.

+ * @public + */ + ResourceType?: ResourceType | undefined; + + /** + *

The Amazon Resource Name (ARN) that uniquely identifies + * the backup resources.

+ * @public + */ + BackupResourceArn?: string | undefined; + + /** + *

The Amazon Resource Name (ARN) that uniquely identifies + * the source resources.

+ * @public + */ + SourceResourceArn?: string | undefined; + + /** + *

This is the creation time of the backup index.

+ * @public + */ + IndexCreationTime?: Date | undefined; + + /** + *

This is the creation time of the backup (recovery point).

+ * @public + */ + BackupCreationTime?: Date | undefined; +} + +/** + * @public + */ +export interface ListSearchJobBackupsOutput { + /** + *

The recovery points returned the results of a + * search job

+ * @public + */ + Results: SearchJobBackupsResult[] | undefined; + + /** + *

The next item following a partial list of returned backups + * included in a search job.

+ *

For example, if a request + * is made to return MaxResults number of backups, NextToken + * allows you to return more items in your list starting at the location pointed to by the + * next token.

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

The resource was not found for this request.

+ *

Confirm the resource information, such as the ARN or type is correct + * and exists, then retry the request.

+ * @public + */ +export class ResourceNotFoundException extends __BaseException { + readonly name: "ResourceNotFoundException" = "ResourceNotFoundException"; + readonly $fault: "client" = "client"; + /** + *

Hypothetical identifier of the resource affected.

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

Hypothetical type of the resource affected.

+ * @public + */ + resourceType: string | undefined; + + /** + * @internal + */ + constructor(opts: __ExceptionOptionType) { + super({ + name: "ResourceNotFoundException", + $fault: "client", + ...opts, + }); + Object.setPrototypeOf(this, ResourceNotFoundException.prototype); + this.resourceId = opts.resourceId; + this.resourceType = opts.resourceType; + } +} + +/** + *

The request was denied due to request throttling.

+ * @public + */ +export class ThrottlingException extends __BaseException { + readonly name: "ThrottlingException" = "ThrottlingException"; + readonly $fault: "client" = "client"; + $retryable = { + throttling: true, + }; + /** + *

This is the code unique to the originating service.

+ * @public + */ + serviceCode?: string | undefined; + + /** + *

This is the code unique to the originating service with the quota.

+ * @public + */ + quotaCode?: string | undefined; + + /** + *

Retry the call after number of seconds.

+ * @public + */ + retryAfterSeconds?: number | undefined; + + /** + * @internal + */ + constructor(opts: __ExceptionOptionType) { + super({ + name: "ThrottlingException", + $fault: "client", + ...opts, + }); + Object.setPrototypeOf(this, ThrottlingException.prototype); + this.serviceCode = opts.serviceCode; + this.quotaCode = opts.quotaCode; + this.retryAfterSeconds = opts.retryAfterSeconds; + } +} + +/** + *

The input fails to satisfy the constraints specified by a service.

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

The unique string that specifies the search job.

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

The next item following a partial list of returned + * search job results.

+ *

For example, if a request + * is made to return MaxResults number of + * search job results, NextToken + * allows you to return more items in your list starting at the location pointed to by the + * next token.

+ * @public + */ + NextToken?: string | undefined; + + /** + *

The maximum number of resource list items to be returned.

+ * @public + */ + MaxResults?: number | undefined; +} + +/** + *

These are the items returned in the results of + * a search of Amazon EBS backup metadata.

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

These are one or more items in the + * results that match values for the Amazon Resource + * Name (ARN) of recovery points returned in a search + * of Amazon EBS backup metadata.

+ * @public + */ + BackupResourceArn?: string | undefined; + + /** + *

These are one or more items in the + * results that match values for the Amazon Resource + * Name (ARN) of source resources returned in a search + * of Amazon EBS backup metadata.

+ * @public + */ + SourceResourceArn?: string | undefined; + + /** + *

The name of the backup vault.

+ * @public + */ + BackupVaultName?: string | undefined; + + /** + *

These are one or more items in the + * results that match values for file systems returned + * in a search of Amazon EBS backup metadata.

+ * @public + */ + FileSystemIdentifier?: string | undefined; + + /** + *

These are one or more items in the + * results that match values for file paths returned + * in a search of Amazon EBS backup metadata.

+ * @public + */ + FilePath?: string | undefined; + + /** + *

These are one or more items in the + * results that match values for file sizes returned + * in a search of Amazon EBS backup metadata.

+ * @public + */ + FileSize?: number | undefined; + + /** + *

These are one or more items in the + * results that match values for creation times returned + * in a search of Amazon EBS backup metadata.

+ * @public + */ + CreationTime?: Date | undefined; + + /** + *

These are one or more items in the + * results that match values for Last Modified Time returned + * in a search of Amazon EBS backup metadata.

+ * @public + */ + LastModifiedTime?: Date | undefined; +} + +/** + *

These are the items returned in the results of + * a search of Amazon S3 backup metadata.

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

These are items in the returned results that match + * recovery point Amazon Resource Names (ARN) input during + * a search of Amazon S3 backup metadata.

+ * @public + */ + BackupResourceArn?: string | undefined; + + /** + *

These are items in the returned results that match + * source Amazon Resource Names (ARN) input during + * a search of Amazon S3 backup metadata.

+ * @public + */ + SourceResourceArn?: string | undefined; + + /** + *

The name of the backup vault.

+ * @public + */ + BackupVaultName?: string | undefined; + + /** + *

This is one or more items + * returned in the results of a search of Amazon S3 + * backup metadata that match the values input for + * object key.

+ * @public + */ + ObjectKey?: string | undefined; + + /** + *

These are items in the returned results that match + * values for object size(s) input during a search of + * Amazon S3 backup metadata.

+ * @public + */ + ObjectSize?: number | undefined; + + /** + *

These are one or more items in the returned results + * that match values for item creation time input during + * a search of Amazon S3 backup metadata.

+ * @public + */ + CreationTime?: Date | undefined; + + /** + *

These are one or more items in the returned results + * that match values for ETags input during + * a search of Amazon S3 backup metadata.

+ * @public + */ + ETag?: string | undefined; + + /** + *

These are one or more items in the returned results + * that match values for version IDs input during + * a search of Amazon S3 backup metadata.

+ * @public + */ + VersionId?: string | undefined; +} + +/** + *

This is an object representing the item + * returned in the results of a search for a specific + * resource type.

+ * @public + */ +export type ResultItem = ResultItem.EBSResultItemMember | ResultItem.S3ResultItemMember | ResultItem.$UnknownMember; + +/** + * @public + */ +export namespace ResultItem { + /** + *

These are items returned in the search results + * of an Amazon S3 search.

+ * @public + */ + export interface S3ResultItemMember { + S3ResultItem: S3ResultItem; + EBSResultItem?: never; + $unknown?: never; + } + + /** + *

These are items returned in the search results + * of an Amazon EBS search.

+ * @public + */ + export interface EBSResultItemMember { + S3ResultItem?: never; + EBSResultItem: EBSResultItem; + $unknown?: never; + } + + /** + * @public + */ + export interface $UnknownMember { + S3ResultItem?: never; + EBSResultItem?: never; + $unknown: [string, any]; + } + + export interface Visitor { + S3ResultItem: (value: S3ResultItem) => T; + EBSResultItem: (value: EBSResultItem) => T; + _: (name: string, value: any) => T; + } + + export const visit = (value: ResultItem, visitor: Visitor): T => { + if (value.S3ResultItem !== undefined) return visitor.S3ResultItem(value.S3ResultItem); + if (value.EBSResultItem !== undefined) return visitor.EBSResultItem(value.EBSResultItem); + return visitor._(value.$unknown[0], value.$unknown[1]); + }; +} + +/** + * @public + */ +export interface ListSearchJobResultsOutput { + /** + *

The results consist of either EBSResultItem or S3ResultItem.

+ * @public + */ + Results: ResultItem[] | undefined; + + /** + *

The next item following a partial list of + * search job results.

+ *

For example, if a request + * is made to return MaxResults number of backups, NextToken + * allows you to return more items in your list starting at the location pointed to by the + * next token.

+ * @public + */ + NextToken?: string | undefined; +} + +/** + * @public + */ +export interface ListTagsForResourceRequest { + /** + *

The Amazon Resource Name (ARN) that uniquely identifies + * the resource.>

+ * @public + */ + ResourceArn: string | undefined; +} + +/** + * @public + */ +export interface ListTagsForResourceResponse { + /** + *

List of tags returned by the operation.

+ * @public + */ + Tags?: Record | undefined; +} + +/** + *

This contains information results retrieved from + * a search job that may not have completed.

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

This number is the sum of all backups that + * have been scanned so far during a search job.

+ * @public + */ + RecoveryPointsScannedCount?: number | undefined; + + /** + *

This number is the sum of all items that + * have been scanned so far during a search job.

+ * @public + */ + ItemsScannedCount?: number | undefined; + + /** + *

This number is the sum of all items that match + * the item filters in a search job in progress.

+ * @public + */ + ItemsMatchedCount?: number | undefined; +} + +/** + * @public + */ +export interface GetSearchJobInput { + /** + *

Required unique string that specifies the + * search job.

+ * @public + */ + SearchJobIdentifier: string | undefined; +} + +/** + * @public + * @enum + */ +export const TimeConditionOperator = { + EQUALS_TO: "EQUALS_TO", + GREATER_THAN_EQUAL_TO: "GREATER_THAN_EQUAL_TO", + LESS_THAN_EQUAL_TO: "LESS_THAN_EQUAL_TO", + NOT_EQUALS_TO: "NOT_EQUALS_TO", +} as const; + +/** + * @public + */ +export type TimeConditionOperator = (typeof TimeConditionOperator)[keyof typeof TimeConditionOperator]; + +/** + *

A time condition denotes a creation time, last modification time, + * or other time.

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

This is the timestamp value of the time condition.

+ * @public + */ + Value: Date | undefined; + + /** + *

A string that defines what values will be + * returned.

+ *

If this is included, avoid combinations of + * operators that will return all possible values. + * For example, including both EQUALS_TO + * and NOT_EQUALS_TO with a value of 4 + * will return all values.

+ * @public + */ + Operator?: TimeConditionOperator | undefined; +} + +/** + * @public + * @enum + */ +export const StringConditionOperator = { + BEGINS_WITH: "BEGINS_WITH", + CONTAINS: "CONTAINS", + DOES_NOT_BEGIN_WITH: "DOES_NOT_BEGIN_WITH", + DOES_NOT_CONTAIN: "DOES_NOT_CONTAIN", + DOES_NOT_END_WITH: "DOES_NOT_END_WITH", + ENDS_WITH: "ENDS_WITH", + EQUALS_TO: "EQUALS_TO", + NOT_EQUALS_TO: "NOT_EQUALS_TO", +} as const; + +/** + * @public + */ +export type StringConditionOperator = (typeof StringConditionOperator)[keyof typeof StringConditionOperator]; + +/** + *

This contains the value of the string and can contain + * one or more operators.

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

The value of the string.

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

A string that defines what values will be + * returned.

+ *

If this is included, avoid combinations of + * operators that will return all possible values. + * For example, including both EQUALS_TO + * and NOT_EQUALS_TO with a value of 4 + * will return all values.

+ * @public + */ + Operator?: StringConditionOperator | undefined; +} + +/** + * @public + * @enum + */ +export const LongConditionOperator = { + EQUALS_TO: "EQUALS_TO", + GREATER_THAN_EQUAL_TO: "GREATER_THAN_EQUAL_TO", + LESS_THAN_EQUAL_TO: "LESS_THAN_EQUAL_TO", + NOT_EQUALS_TO: "NOT_EQUALS_TO", +} as const; + +/** + * @public + */ +export type LongConditionOperator = (typeof LongConditionOperator)[keyof typeof LongConditionOperator]; + +/** + *

The long condition contains a Value + * and can optionally contain an Operator.

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

The value of an item included in one of the search + * item filters.

+ * @public + */ + Value: number | undefined; + + /** + *

A string that defines what values will be + * returned.

+ *

If this is included, avoid combinations of + * operators that will return all possible values. + * For example, including both EQUALS_TO + * and NOT_EQUALS_TO with a value of 4 + * will return all values.

+ * @public + */ + Operator?: LongConditionOperator | undefined; +} + +/** + *

This contains arrays of objects, which may include + * CreationTimes time condition objects, FilePaths + * string objects, LastModificationTimes time + * condition objects,

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

You can include 1 to 10 values.

+ *

If one file path is included, the results will + * return only items that match the file path.

+ *

If more than one file path is included, the + * results will return all items that match any of the + * file paths.

+ * @public + */ + FilePaths?: StringCondition[] | undefined; + + /** + *

You can include 1 to 10 values.

+ *

If one is included, the results will + * return only items that match.

+ *

If more than one is included, the + * results will return all items that match any of + * the included values.

+ * @public + */ + Sizes?: LongCondition[] | undefined; + + /** + *

You can include 1 to 10 values.

+ *

If one is included, the results will + * return only items that match.

+ *

If more than one is included, the + * results will return all items that match any of + * the included values.

+ * @public + */ + CreationTimes?: TimeCondition[] | undefined; + + /** + *

You can include 1 to 10 values.

+ *

If one is included, the results will + * return only items that match.

+ *

If more than one is included, the + * results will return all items that match any of + * the included values.

+ * @public + */ + LastModificationTimes?: TimeCondition[] | undefined; +} + +/** + *

This contains arrays of objects, which may include + * ObjectKeys, Sizes, CreationTimes, VersionIds, and/or + * Etags.

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

You can include 1 to 10 values.

+ *

If one value is included, the results will + * return only items that match the value.

+ *

If more than one value is included, the + * results will return all items that match any of the + * values.

+ * @public + */ + ObjectKeys?: StringCondition[] | undefined; + + /** + *

You can include 1 to 10 values.

+ *

If one value is included, the results will + * return only items that match the value.

+ *

If more than one value is included, the + * results will return all items that match any of the + * values.

+ * @public + */ + Sizes?: LongCondition[] | undefined; + + /** + *

You can include 1 to 10 values.

+ *

If one value is included, the results will + * return only items that match the value.

+ *

If more than one value is included, the + * results will return all items that match any of the + * values.

+ * @public + */ + CreationTimes?: TimeCondition[] | undefined; + + /** + *

You can include 1 to 10 values.

+ *

If one value is included, the results will + * return only items that match the value.

+ *

If more than one value is included, the + * results will return all items that match any of the + * values.

+ * @public + */ + VersionIds?: StringCondition[] | undefined; + + /** + *

You can include 1 to 10 values.

+ *

If one value is included, the results will + * return only items that match the value.

+ *

If more than one value is included, the + * results will return all items that match any of the + * values.

+ * @public + */ + ETags?: StringCondition[] | undefined; +} + +/** + *

Item Filters represent all input item + * properties specified when the search was + * created.

+ *

Contains either EBSItemFilters or + * S3ItemFilters

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

This array can contain CreationTimes, ETags, + * ObjectKeys, Sizes, or VersionIds objects.

+ * @public + */ + S3ItemFilters?: S3ItemFilter[] | undefined; + + /** + *

This array can contain CreationTimes, + * FilePaths, LastModificationTimes, or Sizes objects.

+ * @public + */ + EBSItemFilters?: EBSItemFilter[] | undefined; +} + +/** + *

The search scope is all backup + * properties input into a search.

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

The resource types included in a search.

+ *

Eligible resource types include S3 and EBS.

+ * @public + */ + BackupResourceTypes: ResourceType[] | undefined; + + /** + *

This is the time a backup resource was created.

+ * @public + */ + BackupResourceCreationTime?: BackupCreationTimeFilter | undefined; + + /** + *

The Amazon Resource Name (ARN) that uniquely identifies + * the source resources.

+ * @public + */ + SourceResourceArns?: string[] | undefined; + + /** + *

The Amazon Resource Name (ARN) that uniquely identifies + * the backup resources.

+ * @public + */ + BackupResourceArns?: string[] | undefined; + + /** + *

These are one or more tags on the backup (recovery + * point).

+ * @public + */ + BackupResourceTags?: Record | undefined; +} + +/** + *

The summary of the specified search job scope, + * including: + *

+ *
    + *
  • + *

    TotalBackupsToScanCount, the number of + * recovery points returned by the search.

    + *
  • + *
  • + *

    TotalItemsToScanCount, the number of + * items returned by the search.

    + *
  • + *
+ * @public + */ +export interface SearchScopeSummary { + /** + *

This is the count of the total number of backups + * that will be scanned in a search.

+ * @public + */ + TotalRecoveryPointsToScanCount?: number | undefined; + + /** + *

This is the count of the total number of items + * that will be scanned in a search.

+ * @public + */ + TotalItemsToScanCount?: number | undefined; +} + +/** + * @public + */ +export interface GetSearchJobOutput { + /** + *

Returned name of the specified search job.

+ * @public + */ + Name?: string | undefined; + + /** + *

Returned summary of the specified search job scope, + * including: + *

+ *
    + *
  • + *

    TotalBackupsToScanCount, the number of + * recovery points returned by the search.

    + *
  • + *
  • + *

    TotalItemsToScanCount, the number of + * items returned by the search.

    + *
  • + *
+ * @public + */ + SearchScopeSummary?: SearchScopeSummary | undefined; + + /** + *

Returns numbers representing BackupsScannedCount, + * ItemsScanned, and ItemsMatched.

+ * @public + */ + CurrentSearchProgress?: CurrentSearchProgress | undefined; + + /** + *

A status message will be returned for either a + * earch job with a status of ERRORED or a status of + * COMPLETED jobs with issues.

+ *

For example, a message may say that a search + * contained recovery points unable to be scanned because + * of a permissions issue.

+ * @public + */ + StatusMessage?: string | undefined; + + /** + *

The encryption key for the specified + * search job.

+ *

Example: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab.

+ * @public + */ + EncryptionKeyArn?: string | undefined; + + /** + *

The date and time that a search job completed, in Unix format and Coordinated + * Universal Time (UTC). The value of CompletionTime is accurate to milliseconds. + * For example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 + * AM.

+ * @public + */ + CompletionTime?: Date | undefined; + + /** + *

The current status of the specified search job.

+ *

A search job may have one of the following statuses: + * RUNNING; COMPLETED; STOPPED; + * FAILED; TIMED_OUT; or EXPIRED + * .

+ * @public + */ + Status: SearchJobState | undefined; + + /** + *

The search scope is all backup + * properties input into a search.

+ * @public + */ + SearchScope: SearchScope | undefined; + + /** + *

Item Filters represent all input item + * properties specified when the search was + * created.

+ * @public + */ + ItemFilters: ItemFilters | undefined; + + /** + *

The date and time that a search job was created, in Unix format and Coordinated + * Universal Time (UTC). The value of CompletionTime is accurate to milliseconds. + * For example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 + * AM.

+ * @public + */ + CreationTime: Date | undefined; + + /** + *

The unique string that identifies the specified search job.

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

The unique string that identifies the Amazon Resource + * Name (ARN) of the specified search job.

+ * @public + */ + SearchJobArn: string | undefined; +} + +/** + * @public + */ +export interface ListSearchJobsInput { + /** + *

Include this parameter to filter list by search + * job status.

+ * @public + */ + ByStatus?: SearchJobState | undefined; + + /** + *

The next item following a partial list of returned + * search jobs.

+ *

For example, if a request + * is made to return MaxResults number of backups, NextToken + * allows you to return more items in your list starting at the location pointed to by the + * next token.

+ * @public + */ + NextToken?: string | undefined; + + /** + *

The maximum number of resource list items to be returned.

+ * @public + */ + MaxResults?: number | undefined; +} + +/** + *

This is information pertaining to a search job.

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

The unique string that specifies the search job.

+ * @public + */ + SearchJobIdentifier?: string | undefined; + + /** + *

The unique string that identifies the Amazon Resource + * Name (ARN) of the specified search job.

+ * @public + */ + SearchJobArn?: string | undefined; + + /** + *

This is the name of the search job.

+ * @public + */ + Name?: string | undefined; + + /** + *

This is the status of the search job.

+ * @public + */ + Status?: SearchJobState | undefined; + + /** + *

This is the creation time of the search job.

+ * @public + */ + CreationTime?: Date | undefined; + + /** + *

This is the completion time of the search job.

+ * @public + */ + CompletionTime?: Date | undefined; + + /** + *

Returned summary of the specified search job scope, + * including: + *

+ *
    + *
  • + *

    TotalBackupsToScanCount, the number of + * recovery points returned by the search.

    + *
  • + *
  • + *

    TotalItemsToScanCount, the number of + * items returned by the search.

    + *
  • + *
+ * @public + */ + SearchScopeSummary?: SearchScopeSummary | undefined; + + /** + *

A status message will be returned for either a + * earch job with a status of ERRORED or a status of + * COMPLETED jobs with issues.

+ *

For example, a message may say that a search + * contained recovery points unable to be scanned because + * of a permissions issue.

+ * @public + */ + StatusMessage?: string | undefined; +} + +/** + * @public + */ +export interface ListSearchJobsOutput { + /** + *

The search jobs among the list, with details of + * the returned search jobs.

+ * @public + */ + SearchJobs: SearchJobSummary[] | undefined; + + /** + *

The next item following a partial list of returned backups + * included in a search job.

+ *

For example, if a request + * is made to return MaxResults number of backups, NextToken + * allows you to return more items in your list starting at the location pointed to by the + * next token.

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

The request denied due to exceeding the quota limits permitted.

+ * @public + */ +export class ServiceQuotaExceededException extends __BaseException { + readonly name: "ServiceQuotaExceededException" = "ServiceQuotaExceededException"; + readonly $fault: "client" = "client"; + /** + *

Identifier of the resource.

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

Type of resource.

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

This is the code unique to the originating service with the quota.

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

This is the code specific to the quota type.

+ * @public + */ + quotaCode: string | undefined; + + /** + * @internal + */ + constructor(opts: __ExceptionOptionType) { + super({ + name: "ServiceQuotaExceededException", + $fault: "client", + ...opts, + }); + Object.setPrototypeOf(this, ServiceQuotaExceededException.prototype); + this.resourceId = opts.resourceId; + this.resourceType = opts.resourceType; + this.serviceCode = opts.serviceCode; + this.quotaCode = opts.quotaCode; + } +} + +/** + * @public + */ +export interface StartSearchJobInput { + /** + *

List of tags returned by the operation.

+ * @public + */ + Tags?: Record | undefined; + + /** + *

Include alphanumeric characters to create a + * name for this search job.

+ * @public + */ + Name?: string | undefined; + + /** + *

The encryption key for the specified + * search job.

+ * @public + */ + EncryptionKeyArn?: string | undefined; + + /** + *

Include this parameter to allow multiple identical + * calls for idempotency.

+ *

A client token is valid for 8 hours after the first + * request that uses it is completed. After this time, + * any request with the same token is treated as a + * new request.

+ * @public + */ + ClientToken?: string | undefined; + + /** + *

This object can contain BackupResourceTypes, + * BackupResourceArns, BackupResourceCreationTime, + * BackupResourceTags, and SourceResourceArns to + * filter the recovery points returned by the search + * job.

+ * @public + */ + SearchScope: SearchScope | undefined; + + /** + *

Item Filters represent all input item + * properties specified when the search was + * created.

+ *

Contains either EBSItemFilters or + * S3ItemFilters

+ * @public + */ + ItemFilters?: ItemFilters | undefined; +} + +/** + * @public + */ +export interface StartSearchJobOutput { + /** + *

The unique string that identifies the Amazon Resource + * Name (ARN) of the specified search job.

+ * @public + */ + SearchJobArn?: string | undefined; + + /** + *

The date and time that a job was created, in Unix format and Coordinated + * Universal Time (UTC). The value of CompletionTime is accurate to milliseconds. + * For example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 + * AM.

+ * @public + */ + CreationTime?: Date | undefined; + + /** + *

The unique string that specifies the search job.

+ * @public + */ + SearchJobIdentifier?: string | undefined; +} + +/** + * @public + */ +export interface StopSearchJobInput { + /** + *

The unique string that specifies the search job.

+ * @public + */ + SearchJobIdentifier: string | undefined; +} + +/** + * @public + */ +export interface StopSearchJobOutput {} + +/** + * @public + * @enum + */ +export const ExportJobStatus = { + COMPLETED: "COMPLETED", + FAILED: "FAILED", + RUNNING: "RUNNING", +} as const; + +/** + * @public + */ +export type ExportJobStatus = (typeof ExportJobStatus)[keyof typeof ExportJobStatus]; + +/** + *

This specification contains a required string of the + * destination bucket; optionally, you can include the + * destination prefix.

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

This specifies the destination Amazon S3 + * bucket for the export job.

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

This specifies the prefix for the destination + * Amazon S3 bucket for the export job.

+ * @public + */ + DestinationPrefix?: string | undefined; +} + +/** + *

This contains the export specification object.

+ * @public + */ +export type ExportSpecification = ExportSpecification.S3ExportSpecificationMember | ExportSpecification.$UnknownMember; + +/** + * @public + */ +export namespace ExportSpecification { + /** + *

This specifies the destination Amazon S3 + * bucket for the export job. And, if included, it also + * specifies the destination prefix.

+ * @public + */ + export interface S3ExportSpecificationMember { + s3ExportSpecification: S3ExportSpecification; + $unknown?: never; + } + + /** + * @public + */ + export interface $UnknownMember { + s3ExportSpecification?: never; + $unknown: [string, any]; + } + + export interface Visitor { + s3ExportSpecification: (value: S3ExportSpecification) => T; + _: (name: string, value: any) => T; + } + + export const visit = (value: ExportSpecification, visitor: Visitor): T => { + if (value.s3ExportSpecification !== undefined) return visitor.s3ExportSpecification(value.s3ExportSpecification); + return visitor._(value.$unknown[0], value.$unknown[1]); + }; +} + +/** + * @public + */ +export interface GetSearchResultExportJobInput { + /** + *

This is the unique string that identifies a + * specific export job.

+ *

Required for this operation.

+ * @public + */ + ExportJobIdentifier: string | undefined; +} + +/** + * @public + */ +export interface GetSearchResultExportJobOutput { + /** + *

This is the unique string that identifies the + * specified export job.

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

The unique Amazon Resource Name (ARN) that uniquely identifies + * the export job.

+ * @public + */ + ExportJobArn?: string | undefined; + + /** + *

This is the current status of the export job.

+ * @public + */ + Status?: ExportJobStatus | undefined; + + /** + *

The date and time that an export job was created, in Unix format and Coordinated Universal + * Time (UTC). The value of CreationTime is accurate to milliseconds. For + * example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 + * AM.

+ * @public + */ + CreationTime?: Date | undefined; + + /** + *

The date and time that an export job completed, in Unix format and Coordinated Universal + * Time (UTC). The value of CreationTime is accurate to milliseconds. For + * example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 + * AM.

+ * @public + */ + CompletionTime?: Date | undefined; + + /** + *

A status message is a string that is returned for search job + * with a status of FAILED, along with steps to remedy + * and retry the operation.

+ * @public + */ + StatusMessage?: string | undefined; + + /** + *

The export specification consists of the destination + * S3 bucket to which the search results were exported, along + * with the destination prefix.

+ * @public + */ + ExportSpecification?: ExportSpecification | undefined; + + /** + *

The unique string that identifies the Amazon Resource + * Name (ARN) of the specified search job.

+ * @public + */ + SearchJobArn?: string | undefined; +} + +/** + * @public + */ +export interface ListSearchResultExportJobsInput { + /** + *

The search jobs to be included in the export job + * can be filtered by including this parameter.

+ * @public + */ + Status?: ExportJobStatus | undefined; + + /** + *

The unique string that specifies the search job.

+ * @public + */ + SearchJobIdentifier?: string | undefined; + + /** + *

The next item following a partial list of returned backups + * included in a search job.

+ *

For example, if a request + * is made to return MaxResults number of backups, NextToken + * allows you to return more items in your list starting at the location pointed to by the + * next token.

+ * @public + */ + NextToken?: string | undefined; + + /** + *

The maximum number of resource list items to be returned.

+ * @public + */ + MaxResults?: number | undefined; +} + +/** + *

This is the summary of an export job.

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

This is the unique string that identifies a + * specific export job.

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

This is the unique ARN (Amazon Resource Name) that + * belongs to the new export job.

+ * @public + */ + ExportJobArn?: string | undefined; + + /** + *

The status of the export job is one of the + * following:

+ *

+ * CREATED; RUNNING; + * FAILED; or COMPLETED.

+ * @public + */ + Status?: ExportJobStatus | undefined; + + /** + *

This is a timestamp of the time the export job + * was created.

+ * @public + */ + CreationTime?: Date | undefined; + + /** + *

This is a timestamp of the time the export job + * compeleted.

+ * @public + */ + CompletionTime?: Date | undefined; + + /** + *

A status message is a string that is returned for an export + * job.

+ *

A status message is included for any status other + * than COMPLETED without issues.

+ * @public + */ + StatusMessage?: string | undefined; + + /** + *

The unique string that identifies the Amazon Resource + * Name (ARN) of the specified search job.

+ * @public + */ + SearchJobArn?: string | undefined; +} + +/** + * @public + */ +export interface ListSearchResultExportJobsOutput { + /** + *

The operation returns the included export jobs.

+ * @public + */ + ExportJobs: ExportJobSummary[] | undefined; + + /** + *

The next item following a partial list of returned backups + * included in a search job.

+ *

For example, if a request + * is made to return MaxResults number of backups, NextToken + * allows you to return more items in your list starting at the location pointed to by the + * next token.

+ * @public + */ + NextToken?: string | undefined; +} + +/** + * @public + */ +export interface StartSearchResultExportJobInput { + /** + *

The unique string that specifies the search job.

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

This specification contains a required string of the + * destination bucket; optionally, you can include the + * destination prefix.

+ * @public + */ + ExportSpecification: ExportSpecification | undefined; + + /** + *

Include this parameter to allow multiple identical + * calls for idempotency.

+ *

A client token is valid for 8 hours after the first + * request that uses it is completed. After this time, + * any request with the same token is treated as a + * new request.

+ * @public + */ + ClientToken?: string | undefined; + + /** + *

Optional tags to include. A tag is a key-value pair you can use to manage, + * filter, and search for your resources. Allowed characters include UTF-8 letters, + * numbers, spaces, and the following characters: + - = . _ : /.

+ * @public + */ + Tags?: Record | undefined; + + /** + *

This parameter specifies the role ARN used to start + * the search results export jobs.

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

This is the unique ARN (Amazon Resource Name) that + * belongs to the new export job.

+ * @public + */ + ExportJobArn?: string | undefined; + + /** + *

This is the unique identifier that + * specifies the new export job.

+ * @public + */ + ExportJobIdentifier: string | undefined; +} + +/** + * @public + */ +export interface TagResourceRequest { + /** + *

The Amazon Resource Name (ARN) that uniquely identifies + * the resource.

+ *

This is the resource that will have the indicated tags.

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

Required tags to include. A tag is a key-value pair you can use to manage, + * filter, and search for your resources. Allowed characters include UTF-8 letters, + * numbers, spaces, and the following characters: + - = . _ : /.

+ * @public + */ + Tags: Record | undefined; +} + +/** + * @public + */ +export interface TagResourceResponse {} + +/** + * @public + */ +export interface UntagResourceRequest { + /** + *

The Amazon Resource Name (ARN) that uniquely identifies + * the resource where you want to remove tags.

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

This required parameter contains the tag keys you + * want to remove from the source.

+ * @public + */ + TagKeys: string[] | undefined; +} + +/** + * @public + */ +export interface UntagResourceResponse {} + +/** + * @internal + */ +export const EBSResultItemFilterSensitiveLog = (obj: EBSResultItem): any => ({ + ...obj, + ...(obj.FilePath && { FilePath: SENSITIVE_STRING }), +}); + +/** + * @internal + */ +export const S3ResultItemFilterSensitiveLog = (obj: S3ResultItem): any => ({ + ...obj, + ...(obj.ObjectKey && { ObjectKey: SENSITIVE_STRING }), +}); + +/** + * @internal + */ +export const ResultItemFilterSensitiveLog = (obj: ResultItem): any => { + if (obj.S3ResultItem !== undefined) return { S3ResultItem: S3ResultItemFilterSensitiveLog(obj.S3ResultItem) }; + if (obj.EBSResultItem !== undefined) return { EBSResultItem: EBSResultItemFilterSensitiveLog(obj.EBSResultItem) }; + if (obj.$unknown !== undefined) return { [obj.$unknown[0]]: "UNKNOWN" }; +}; + +/** + * @internal + */ +export const ListSearchJobResultsOutputFilterSensitiveLog = (obj: ListSearchJobResultsOutput): any => ({ + ...obj, + ...(obj.Results && { Results: obj.Results.map((item) => ResultItemFilterSensitiveLog(item)) }), +}); diff --git a/clients/client-backupsearch/src/pagination/Interfaces.ts b/clients/client-backupsearch/src/pagination/Interfaces.ts new file mode 100644 index 000000000000..cb351c831d0d --- /dev/null +++ b/clients/client-backupsearch/src/pagination/Interfaces.ts @@ -0,0 +1,11 @@ +// smithy-typescript generated code +import { PaginationConfiguration } from "@smithy/types"; + +import { BackupSearchClient } from "../BackupSearchClient"; + +/** + * @public + */ +export interface BackupSearchPaginationConfiguration extends PaginationConfiguration { + client: BackupSearchClient; +} diff --git a/clients/client-backupsearch/src/pagination/ListSearchJobBackupsPaginator.ts b/clients/client-backupsearch/src/pagination/ListSearchJobBackupsPaginator.ts new file mode 100644 index 000000000000..21beeb203463 --- /dev/null +++ b/clients/client-backupsearch/src/pagination/ListSearchJobBackupsPaginator.ts @@ -0,0 +1,24 @@ +// smithy-typescript generated code +import { createPaginator } from "@smithy/core"; +import { Paginator } from "@smithy/types"; + +import { BackupSearchClient } from "../BackupSearchClient"; +import { + ListSearchJobBackupsCommand, + ListSearchJobBackupsCommandInput, + ListSearchJobBackupsCommandOutput, +} from "../commands/ListSearchJobBackupsCommand"; +import { BackupSearchPaginationConfiguration } from "./Interfaces"; + +/** + * @public + */ +export const paginateListSearchJobBackups: ( + config: BackupSearchPaginationConfiguration, + input: ListSearchJobBackupsCommandInput, + ...rest: any[] +) => Paginator = createPaginator< + BackupSearchPaginationConfiguration, + ListSearchJobBackupsCommandInput, + ListSearchJobBackupsCommandOutput +>(BackupSearchClient, ListSearchJobBackupsCommand, "NextToken", "NextToken", "MaxResults"); diff --git a/clients/client-backupsearch/src/pagination/ListSearchJobResultsPaginator.ts b/clients/client-backupsearch/src/pagination/ListSearchJobResultsPaginator.ts new file mode 100644 index 000000000000..55a26bc38ce8 --- /dev/null +++ b/clients/client-backupsearch/src/pagination/ListSearchJobResultsPaginator.ts @@ -0,0 +1,24 @@ +// smithy-typescript generated code +import { createPaginator } from "@smithy/core"; +import { Paginator } from "@smithy/types"; + +import { BackupSearchClient } from "../BackupSearchClient"; +import { + ListSearchJobResultsCommand, + ListSearchJobResultsCommandInput, + ListSearchJobResultsCommandOutput, +} from "../commands/ListSearchJobResultsCommand"; +import { BackupSearchPaginationConfiguration } from "./Interfaces"; + +/** + * @public + */ +export const paginateListSearchJobResults: ( + config: BackupSearchPaginationConfiguration, + input: ListSearchJobResultsCommandInput, + ...rest: any[] +) => Paginator = createPaginator< + BackupSearchPaginationConfiguration, + ListSearchJobResultsCommandInput, + ListSearchJobResultsCommandOutput +>(BackupSearchClient, ListSearchJobResultsCommand, "NextToken", "NextToken", "MaxResults"); diff --git a/clients/client-backupsearch/src/pagination/ListSearchJobsPaginator.ts b/clients/client-backupsearch/src/pagination/ListSearchJobsPaginator.ts new file mode 100644 index 000000000000..81ce66888fd6 --- /dev/null +++ b/clients/client-backupsearch/src/pagination/ListSearchJobsPaginator.ts @@ -0,0 +1,24 @@ +// smithy-typescript generated code +import { createPaginator } from "@smithy/core"; +import { Paginator } from "@smithy/types"; + +import { BackupSearchClient } from "../BackupSearchClient"; +import { + ListSearchJobsCommand, + ListSearchJobsCommandInput, + ListSearchJobsCommandOutput, +} from "../commands/ListSearchJobsCommand"; +import { BackupSearchPaginationConfiguration } from "./Interfaces"; + +/** + * @public + */ +export const paginateListSearchJobs: ( + config: BackupSearchPaginationConfiguration, + input: ListSearchJobsCommandInput, + ...rest: any[] +) => Paginator = createPaginator< + BackupSearchPaginationConfiguration, + ListSearchJobsCommandInput, + ListSearchJobsCommandOutput +>(BackupSearchClient, ListSearchJobsCommand, "NextToken", "NextToken", "MaxResults"); diff --git a/clients/client-backupsearch/src/pagination/ListSearchResultExportJobsPaginator.ts b/clients/client-backupsearch/src/pagination/ListSearchResultExportJobsPaginator.ts new file mode 100644 index 000000000000..6f5657e38e3f --- /dev/null +++ b/clients/client-backupsearch/src/pagination/ListSearchResultExportJobsPaginator.ts @@ -0,0 +1,24 @@ +// smithy-typescript generated code +import { createPaginator } from "@smithy/core"; +import { Paginator } from "@smithy/types"; + +import { BackupSearchClient } from "../BackupSearchClient"; +import { + ListSearchResultExportJobsCommand, + ListSearchResultExportJobsCommandInput, + ListSearchResultExportJobsCommandOutput, +} from "../commands/ListSearchResultExportJobsCommand"; +import { BackupSearchPaginationConfiguration } from "./Interfaces"; + +/** + * @public + */ +export const paginateListSearchResultExportJobs: ( + config: BackupSearchPaginationConfiguration, + input: ListSearchResultExportJobsCommandInput, + ...rest: any[] +) => Paginator = createPaginator< + BackupSearchPaginationConfiguration, + ListSearchResultExportJobsCommandInput, + ListSearchResultExportJobsCommandOutput +>(BackupSearchClient, ListSearchResultExportJobsCommand, "NextToken", "NextToken", "MaxResults"); diff --git a/clients/client-backupsearch/src/pagination/index.ts b/clients/client-backupsearch/src/pagination/index.ts new file mode 100644 index 000000000000..ef0e7a68751f --- /dev/null +++ b/clients/client-backupsearch/src/pagination/index.ts @@ -0,0 +1,6 @@ +// smithy-typescript generated code +export * from "./Interfaces"; +export * from "./ListSearchJobBackupsPaginator"; +export * from "./ListSearchJobResultsPaginator"; +export * from "./ListSearchJobsPaginator"; +export * from "./ListSearchResultExportJobsPaginator"; diff --git a/clients/client-backupsearch/src/protocols/Aws_restJson1.ts b/clients/client-backupsearch/src/protocols/Aws_restJson1.ts new file mode 100644 index 000000000000..f3c1380af8c9 --- /dev/null +++ b/clients/client-backupsearch/src/protocols/Aws_restJson1.ts @@ -0,0 +1,1221 @@ +// smithy-typescript generated code +import { + awsExpectUnion as __expectUnion, + loadRestJsonErrorCode, + parseJsonBody as parseBody, + parseJsonErrorBody as parseErrorBody, +} from "@aws-sdk/core"; +import { requestBuilder as rb } from "@smithy/core"; +import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@smithy/protocol-http"; +import { + _json, + collectBody, + decorateServiceException as __decorateServiceException, + expectLong as __expectLong, + expectNonNull as __expectNonNull, + expectNumber as __expectNumber, + expectObject as __expectObject, + expectString as __expectString, + extendedEncodeURIComponent as __extendedEncodeURIComponent, + map, + parseEpochTimestamp as __parseEpochTimestamp, + resolvedPath as __resolvedPath, + strictParseInt32 as __strictParseInt32, + take, + withBaseException, +} from "@smithy/smithy-client"; +import { + Endpoint as __Endpoint, + ResponseMetadata as __ResponseMetadata, + SerdeContext as __SerdeContext, +} from "@smithy/types"; + +import { GetSearchJobCommandInput, GetSearchJobCommandOutput } from "../commands/GetSearchJobCommand"; +import { + GetSearchResultExportJobCommandInput, + GetSearchResultExportJobCommandOutput, +} from "../commands/GetSearchResultExportJobCommand"; +import { + ListSearchJobBackupsCommandInput, + ListSearchJobBackupsCommandOutput, +} from "../commands/ListSearchJobBackupsCommand"; +import { + ListSearchJobResultsCommandInput, + ListSearchJobResultsCommandOutput, +} from "../commands/ListSearchJobResultsCommand"; +import { ListSearchJobsCommandInput, ListSearchJobsCommandOutput } from "../commands/ListSearchJobsCommand"; +import { + ListSearchResultExportJobsCommandInput, + ListSearchResultExportJobsCommandOutput, +} from "../commands/ListSearchResultExportJobsCommand"; +import { + ListTagsForResourceCommandInput, + ListTagsForResourceCommandOutput, +} from "../commands/ListTagsForResourceCommand"; +import { StartSearchJobCommandInput, StartSearchJobCommandOutput } from "../commands/StartSearchJobCommand"; +import { + StartSearchResultExportJobCommandInput, + StartSearchResultExportJobCommandOutput, +} from "../commands/StartSearchResultExportJobCommand"; +import { StopSearchJobCommandInput, StopSearchJobCommandOutput } from "../commands/StopSearchJobCommand"; +import { TagResourceCommandInput, TagResourceCommandOutput } from "../commands/TagResourceCommand"; +import { UntagResourceCommandInput, UntagResourceCommandOutput } from "../commands/UntagResourceCommand"; +import { BackupSearchServiceException as __BaseException } from "../models/BackupSearchServiceException"; +import { + AccessDeniedException, + BackupCreationTimeFilter, + ConflictException, + EBSItemFilter, + EBSResultItem, + ExportJobSummary, + ExportSpecification, + InternalServerException, + ItemFilters, + LongCondition, + ResourceNotFoundException, + ResourceType, + ResultItem, + S3ExportSpecification, + S3ItemFilter, + S3ResultItem, + SearchJobBackupsResult, + SearchJobSummary, + SearchScope, + ServiceQuotaExceededException, + StringCondition, + ThrottlingException, + TimeCondition, + ValidationException, +} from "../models/models_0"; + +/** + * serializeAws_restJson1GetSearchJobCommand + */ +export const se_GetSearchJobCommand = async ( + input: GetSearchJobCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = {}; + b.bp("/search-jobs/{SearchJobIdentifier}"); + b.p("SearchJobIdentifier", () => input.SearchJobIdentifier!, "{SearchJobIdentifier}", false); + let body: any; + b.m("GET").h(headers).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1GetSearchResultExportJobCommand + */ +export const se_GetSearchResultExportJobCommand = async ( + input: GetSearchResultExportJobCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = {}; + b.bp("/export-search-jobs/{ExportJobIdentifier}"); + b.p("ExportJobIdentifier", () => input.ExportJobIdentifier!, "{ExportJobIdentifier}", false); + let body: any; + b.m("GET").h(headers).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1ListSearchJobBackupsCommand + */ +export const se_ListSearchJobBackupsCommand = async ( + input: ListSearchJobBackupsCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = {}; + b.bp("/search-jobs/{SearchJobIdentifier}/backups"); + b.p("SearchJobIdentifier", () => input.SearchJobIdentifier!, "{SearchJobIdentifier}", false); + const query: any = map({ + [_nT]: [, input[_NT]!], + [_mR]: [() => input.MaxResults !== void 0, () => input[_MR]!.toString()], + }); + let body: any; + b.m("GET").h(headers).q(query).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1ListSearchJobResultsCommand + */ +export const se_ListSearchJobResultsCommand = async ( + input: ListSearchJobResultsCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = {}; + b.bp("/search-jobs/{SearchJobIdentifier}/search-results"); + b.p("SearchJobIdentifier", () => input.SearchJobIdentifier!, "{SearchJobIdentifier}", false); + const query: any = map({ + [_nT]: [, input[_NT]!], + [_mR]: [() => input.MaxResults !== void 0, () => input[_MR]!.toString()], + }); + let body: any; + b.m("GET").h(headers).q(query).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1ListSearchJobsCommand + */ +export const se_ListSearchJobsCommand = async ( + input: ListSearchJobsCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = {}; + b.bp("/search-jobs"); + const query: any = map({ + [_S]: [, input[_BS]!], + [_NT]: [, input[_NT]!], + [_MR]: [() => input.MaxResults !== void 0, () => input[_MR]!.toString()], + }); + let body: any; + b.m("GET").h(headers).q(query).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1ListSearchResultExportJobsCommand + */ +export const se_ListSearchResultExportJobsCommand = async ( + input: ListSearchResultExportJobsCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = {}; + b.bp("/export-search-jobs"); + const query: any = map({ + [_S]: [, input[_S]!], + [_SJI]: [, input[_SJI]!], + [_NT]: [, input[_NT]!], + [_MR]: [() => input.MaxResults !== void 0, () => input[_MR]!.toString()], + }); + let body: any; + b.m("GET").h(headers).q(query).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1ListTagsForResourceCommand + */ +export const se_ListTagsForResourceCommand = async ( + input: ListTagsForResourceCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = {}; + b.bp("/tags/{ResourceArn}"); + b.p("ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); + let body: any; + b.m("GET").h(headers).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1StartSearchJobCommand + */ +export const se_StartSearchJobCommand = async ( + input: StartSearchJobCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = { + "content-type": "application/json", + }; + b.bp("/search-jobs"); + let body: any; + body = JSON.stringify( + take(input, { + ClientToken: [], + EncryptionKeyArn: [], + ItemFilters: (_) => se_ItemFilters(_, context), + Name: [], + SearchScope: (_) => se_SearchScope(_, context), + Tags: (_) => se_TagMap(_, context), + }) + ); + b.m("PUT").h(headers).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1StartSearchResultExportJobCommand + */ +export const se_StartSearchResultExportJobCommand = async ( + input: StartSearchResultExportJobCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = { + "content-type": "application/json", + }; + b.bp("/export-search-jobs"); + let body: any; + body = JSON.stringify( + take(input, { + ClientToken: [], + ExportSpecification: (_) => _json(_), + RoleArn: [], + SearchJobIdentifier: [], + Tags: (_) => se_TagMap(_, context), + }) + ); + b.m("PUT").h(headers).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1StopSearchJobCommand + */ +export const se_StopSearchJobCommand = async ( + input: StopSearchJobCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = {}; + b.bp("/search-jobs/{SearchJobIdentifier}/actions/cancel"); + b.p("SearchJobIdentifier", () => input.SearchJobIdentifier!, "{SearchJobIdentifier}", false); + let body: any; + b.m("PUT").h(headers).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1TagResourceCommand + */ +export const se_TagResourceCommand = async ( + input: TagResourceCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = { + "content-type": "application/json", + }; + b.bp("/tags/{ResourceArn}"); + b.p("ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); + let body: any; + body = JSON.stringify( + take(input, { + Tags: (_) => se_TagMap(_, context), + }) + ); + b.m("POST").h(headers).b(body); + return b.build(); +}; + +/** + * serializeAws_restJson1UntagResourceCommand + */ +export const se_UntagResourceCommand = async ( + input: UntagResourceCommandInput, + context: __SerdeContext +): Promise<__HttpRequest> => { + const b = rb(input, context); + const headers: any = {}; + b.bp("/tags/{ResourceArn}"); + b.p("ResourceArn", () => input.ResourceArn!, "{ResourceArn}", false); + const query: any = map({ + [_tK]: [__expectNonNull(input.TagKeys, `TagKeys`) != null, () => input[_TK]! || []], + }); + let body: any; + b.m("DELETE").h(headers).q(query).b(body); + return b.build(); +}; + +/** + * deserializeAws_restJson1GetSearchJobCommand + */ +export const de_GetSearchJobCommand = 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, { + CompletionTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + CreationTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + CurrentSearchProgress: _json, + EncryptionKeyArn: __expectString, + ItemFilters: (_) => de_ItemFilters(_, context), + Name: __expectString, + SearchJobArn: __expectString, + SearchJobIdentifier: __expectString, + SearchScope: (_) => de_SearchScope(_, context), + SearchScopeSummary: _json, + Status: __expectString, + StatusMessage: __expectString, + }); + Object.assign(contents, doc); + return contents; +}; + +/** + * deserializeAws_restJson1GetSearchResultExportJobCommand + */ +export const de_GetSearchResultExportJobCommand = 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, { + CompletionTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + CreationTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + ExportJobArn: __expectString, + ExportJobIdentifier: __expectString, + ExportSpecification: (_) => _json(__expectUnion(_)), + SearchJobArn: __expectString, + Status: __expectString, + StatusMessage: __expectString, + }); + Object.assign(contents, doc); + return contents; +}; + +/** + * deserializeAws_restJson1ListSearchJobBackupsCommand + */ +export const de_ListSearchJobBackupsCommand = 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, + Results: (_) => de_SearchJobBackupsResults(_, context), + }); + Object.assign(contents, doc); + return contents; +}; + +/** + * deserializeAws_restJson1ListSearchJobResultsCommand + */ +export const de_ListSearchJobResultsCommand = 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, + Results: (_) => de_Results(_, context), + }); + Object.assign(contents, doc); + return contents; +}; + +/** + * deserializeAws_restJson1ListSearchJobsCommand + */ +export const de_ListSearchJobsCommand = 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, + SearchJobs: (_) => de_SearchJobs(_, context), + }); + Object.assign(contents, doc); + return contents; +}; + +/** + * deserializeAws_restJson1ListSearchResultExportJobsCommand + */ +export const de_ListSearchResultExportJobsCommand = 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, { + ExportJobs: (_) => de_ExportJobSummaries(_, context), + NextToken: __expectString, + }); + Object.assign(contents, doc); + return contents; +}; + +/** + * deserializeAws_restJson1ListTagsForResourceCommand + */ +export const de_ListTagsForResourceCommand = 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, { + Tags: (_) => de_TagMap(_, context), + }); + Object.assign(contents, doc); + return contents; +}; + +/** + * deserializeAws_restJson1StartSearchJobCommand + */ +export const de_StartSearchJobCommand = 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, { + CreationTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + SearchJobArn: __expectString, + SearchJobIdentifier: __expectString, + }); + Object.assign(contents, doc); + return contents; +}; + +/** + * deserializeAws_restJson1StartSearchResultExportJobCommand + */ +export const de_StartSearchResultExportJobCommand = 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, { + ExportJobArn: __expectString, + ExportJobIdentifier: __expectString, + }); + Object.assign(contents, doc); + return contents; +}; + +/** + * deserializeAws_restJson1StopSearchJobCommand + */ +export const de_StopSearchJobCommand = 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_restJson1TagResourceCommand + */ +export const de_TagResourceCommand = 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_restJson1UntagResourceCommand + */ +export const de_UntagResourceCommand = 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; +}; + +/** + * deserialize_Aws_restJson1CommandError + */ +const de_CommandError = async (output: __HttpResponse, context: __SerdeContext): Promise => { + const parsedOutput: any = { + ...output, + body: await parseErrorBody(output.body, context), + }; + const errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "AccessDeniedException": + case "com.amazonaws.backupsearch#AccessDeniedException": + throw await de_AccessDeniedExceptionRes(parsedOutput, context); + case "InternalServerException": + case "com.amazonaws.backupsearch#InternalServerException": + throw await de_InternalServerExceptionRes(parsedOutput, context); + case "ResourceNotFoundException": + case "com.amazonaws.backupsearch#ResourceNotFoundException": + throw await de_ResourceNotFoundExceptionRes(parsedOutput, context); + case "ThrottlingException": + case "com.amazonaws.backupsearch#ThrottlingException": + throw await de_ThrottlingExceptionRes(parsedOutput, context); + case "ValidationException": + case "com.amazonaws.backupsearch#ValidationException": + throw await de_ValidationExceptionRes(parsedOutput, context); + case "ServiceQuotaExceededException": + case "com.amazonaws.backupsearch#ServiceQuotaExceededException": + throw await de_ServiceQuotaExceededExceptionRes(parsedOutput, context); + case "ConflictException": + case "com.amazonaws.backupsearch#ConflictException": + throw await de_ConflictExceptionRes(parsedOutput, context); + default: + const parsedBody = parsedOutput.body; + return throwDefaultError({ + output, + parsedBody, + errorCode, + }) as never; + } +}; + +const throwDefaultError = withBaseException(__BaseException); +/** + * deserializeAws_restJson1AccessDeniedExceptionRes + */ +const de_AccessDeniedExceptionRes = async ( + parsedOutput: any, + context: __SerdeContext +): Promise => { + const contents: any = map({}); + const data: any = parsedOutput.body; + const doc = take(data, { + message: __expectString, + }); + Object.assign(contents, doc); + const exception = new AccessDeniedException({ + $metadata: deserializeMetadata(parsedOutput), + ...contents, + }); + return __decorateServiceException(exception, parsedOutput.body); +}; + +/** + * deserializeAws_restJson1ConflictExceptionRes + */ +const de_ConflictExceptionRes = async (parsedOutput: any, context: __SerdeContext): Promise => { + const contents: any = map({}); + const data: any = parsedOutput.body; + const doc = take(data, { + message: __expectString, + resourceId: __expectString, + resourceType: __expectString, + }); + Object.assign(contents, doc); + const exception = new ConflictException({ + $metadata: deserializeMetadata(parsedOutput), + ...contents, + }); + return __decorateServiceException(exception, parsedOutput.body); +}; + +/** + * deserializeAws_restJson1InternalServerExceptionRes + */ +const de_InternalServerExceptionRes = async ( + parsedOutput: any, + context: __SerdeContext +): Promise => { + const contents: any = map({ + [_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => __strictParseInt32(parsedOutput.headers[_ra])], + }); + const data: any = parsedOutput.body; + const doc = take(data, { + message: __expectString, + }); + Object.assign(contents, doc); + const exception = new InternalServerException({ + $metadata: deserializeMetadata(parsedOutput), + ...contents, + }); + return __decorateServiceException(exception, parsedOutput.body); +}; + +/** + * deserializeAws_restJson1ResourceNotFoundExceptionRes + */ +const de_ResourceNotFoundExceptionRes = async ( + parsedOutput: any, + context: __SerdeContext +): Promise => { + const contents: any = map({}); + const data: any = parsedOutput.body; + const doc = take(data, { + message: __expectString, + resourceId: __expectString, + resourceType: __expectString, + }); + Object.assign(contents, doc); + const exception = new ResourceNotFoundException({ + $metadata: deserializeMetadata(parsedOutput), + ...contents, + }); + return __decorateServiceException(exception, parsedOutput.body); +}; + +/** + * deserializeAws_restJson1ServiceQuotaExceededExceptionRes + */ +const de_ServiceQuotaExceededExceptionRes = async ( + parsedOutput: any, + context: __SerdeContext +): Promise => { + const contents: any = map({}); + const data: any = parsedOutput.body; + const doc = take(data, { + message: __expectString, + quotaCode: __expectString, + resourceId: __expectString, + resourceType: __expectString, + serviceCode: __expectString, + }); + Object.assign(contents, doc); + const exception = new ServiceQuotaExceededException({ + $metadata: deserializeMetadata(parsedOutput), + ...contents, + }); + return __decorateServiceException(exception, parsedOutput.body); +}; + +/** + * deserializeAws_restJson1ThrottlingExceptionRes + */ +const de_ThrottlingExceptionRes = async (parsedOutput: any, context: __SerdeContext): Promise => { + const contents: any = map({ + [_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => __strictParseInt32(parsedOutput.headers[_ra])], + }); + const data: any = parsedOutput.body; + const doc = take(data, { + message: __expectString, + quotaCode: __expectString, + serviceCode: __expectString, + }); + Object.assign(contents, doc); + const exception = new ThrottlingException({ + $metadata: deserializeMetadata(parsedOutput), + ...contents, + }); + return __decorateServiceException(exception, parsedOutput.body); +}; + +/** + * deserializeAws_restJson1ValidationExceptionRes + */ +const de_ValidationExceptionRes = async (parsedOutput: any, context: __SerdeContext): Promise => { + const contents: any = map({}); + const data: any = parsedOutput.body; + const doc = take(data, { + message: __expectString, + }); + Object.assign(contents, doc); + const exception = new ValidationException({ + $metadata: deserializeMetadata(parsedOutput), + ...contents, + }); + return __decorateServiceException(exception, parsedOutput.body); +}; + +/** + * serializeAws_restJson1BackupCreationTimeFilter + */ +const se_BackupCreationTimeFilter = (input: BackupCreationTimeFilter, context: __SerdeContext): any => { + return take(input, { + CreatedAfter: (_) => _.getTime() / 1_000, + CreatedBefore: (_) => _.getTime() / 1_000, + }); +}; + +/** + * serializeAws_restJson1EBSItemFilter + */ +const se_EBSItemFilter = (input: EBSItemFilter, context: __SerdeContext): any => { + return take(input, { + CreationTimes: (_) => se_TimeConditionList(_, context), + FilePaths: _json, + LastModificationTimes: (_) => se_TimeConditionList(_, context), + Sizes: _json, + }); +}; + +/** + * serializeAws_restJson1EBSItemFilters + */ +const se_EBSItemFilters = (input: EBSItemFilter[], context: __SerdeContext): any => { + return input + .filter((e: any) => e != null) + .map((entry) => { + return se_EBSItemFilter(entry, context); + }); +}; + +// se_ExportSpecification omitted. + +/** + * serializeAws_restJson1ItemFilters + */ +const se_ItemFilters = (input: ItemFilters, context: __SerdeContext): any => { + return take(input, { + EBSItemFilters: (_) => se_EBSItemFilters(_, context), + S3ItemFilters: (_) => se_S3ItemFilters(_, context), + }); +}; + +// se_LongCondition omitted. + +// se_LongConditionList omitted. + +// se_RecoveryPointArnList omitted. + +// se_ResourceArnList omitted. + +// se_ResourceTypeList omitted. + +// se_S3ExportSpecification omitted. + +/** + * serializeAws_restJson1S3ItemFilter + */ +const se_S3ItemFilter = (input: S3ItemFilter, context: __SerdeContext): any => { + return take(input, { + CreationTimes: (_) => se_TimeConditionList(_, context), + ETags: _json, + ObjectKeys: _json, + Sizes: _json, + VersionIds: _json, + }); +}; + +/** + * serializeAws_restJson1S3ItemFilters + */ +const se_S3ItemFilters = (input: S3ItemFilter[], context: __SerdeContext): any => { + return input + .filter((e: any) => e != null) + .map((entry) => { + return se_S3ItemFilter(entry, context); + }); +}; + +/** + * serializeAws_restJson1SearchScope + */ +const se_SearchScope = (input: SearchScope, context: __SerdeContext): any => { + return take(input, { + BackupResourceArns: _json, + BackupResourceCreationTime: (_) => se_BackupCreationTimeFilter(_, context), + BackupResourceTags: (_) => se_TagMap(_, context), + BackupResourceTypes: _json, + SourceResourceArns: _json, + }); +}; + +// se_StringCondition omitted. + +// se_StringConditionList omitted. + +/** + * serializeAws_restJson1TagMap + */ +const se_TagMap = (input: Record, context: __SerdeContext): any => { + return Object.entries(input).reduce((acc: Record, [key, value]: [string, any]) => { + if (value === null) { + acc[key] = null as any; + return acc; + } + acc[key] = value; + return acc; + }, {}); +}; + +/** + * serializeAws_restJson1TimeCondition + */ +const se_TimeCondition = (input: TimeCondition, context: __SerdeContext): any => { + return take(input, { + Operator: [], + Value: (_) => _.getTime() / 1_000, + }); +}; + +/** + * serializeAws_restJson1TimeConditionList + */ +const se_TimeConditionList = (input: TimeCondition[], context: __SerdeContext): any => { + return input + .filter((e: any) => e != null) + .map((entry) => { + return se_TimeCondition(entry, context); + }); +}; + +/** + * deserializeAws_restJson1BackupCreationTimeFilter + */ +const de_BackupCreationTimeFilter = (output: any, context: __SerdeContext): BackupCreationTimeFilter => { + return take(output, { + CreatedAfter: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + CreatedBefore: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + }) as any; +}; + +// de_CurrentSearchProgress omitted. + +/** + * deserializeAws_restJson1EBSItemFilter + */ +const de_EBSItemFilter = (output: any, context: __SerdeContext): EBSItemFilter => { + return take(output, { + CreationTimes: (_: any) => de_TimeConditionList(_, context), + FilePaths: _json, + LastModificationTimes: (_: any) => de_TimeConditionList(_, context), + Sizes: _json, + }) as any; +}; + +/** + * deserializeAws_restJson1EBSItemFilters + */ +const de_EBSItemFilters = (output: any, context: __SerdeContext): EBSItemFilter[] => { + const retVal = (output || []) + .filter((e: any) => e != null) + .map((entry: any) => { + return de_EBSItemFilter(entry, context); + }); + return retVal; +}; + +/** + * deserializeAws_restJson1EBSResultItem + */ +const de_EBSResultItem = (output: any, context: __SerdeContext): EBSResultItem => { + return take(output, { + BackupResourceArn: __expectString, + BackupVaultName: __expectString, + CreationTime: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + FilePath: __expectString, + FileSize: __expectLong, + FileSystemIdentifier: __expectString, + LastModifiedTime: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + SourceResourceArn: __expectString, + }) as any; +}; + +/** + * deserializeAws_restJson1ExportJobSummaries + */ +const de_ExportJobSummaries = (output: any, context: __SerdeContext): ExportJobSummary[] => { + const retVal = (output || []) + .filter((e: any) => e != null) + .map((entry: any) => { + return de_ExportJobSummary(entry, context); + }); + return retVal; +}; + +/** + * deserializeAws_restJson1ExportJobSummary + */ +const de_ExportJobSummary = (output: any, context: __SerdeContext): ExportJobSummary => { + return take(output, { + CompletionTime: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + CreationTime: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + ExportJobArn: __expectString, + ExportJobIdentifier: __expectString, + SearchJobArn: __expectString, + Status: __expectString, + StatusMessage: __expectString, + }) as any; +}; + +// de_ExportSpecification omitted. + +/** + * deserializeAws_restJson1ItemFilters + */ +const de_ItemFilters = (output: any, context: __SerdeContext): ItemFilters => { + return take(output, { + EBSItemFilters: (_: any) => de_EBSItemFilters(_, context), + S3ItemFilters: (_: any) => de_S3ItemFilters(_, context), + }) as any; +}; + +// de_LongCondition omitted. + +// de_LongConditionList omitted. + +// de_RecoveryPointArnList omitted. + +// de_ResourceArnList omitted. + +// de_ResourceTypeList omitted. + +/** + * deserializeAws_restJson1ResultItem + */ +const de_ResultItem = (output: any, context: __SerdeContext): ResultItem => { + if (output.EBSResultItem != null) { + return { + EBSResultItem: de_EBSResultItem(output.EBSResultItem, context), + }; + } + if (output.S3ResultItem != null) { + return { + S3ResultItem: de_S3ResultItem(output.S3ResultItem, context), + }; + } + return { $unknown: Object.entries(output)[0] }; +}; + +/** + * deserializeAws_restJson1Results + */ +const de_Results = (output: any, context: __SerdeContext): ResultItem[] => { + const retVal = (output || []) + .filter((e: any) => e != null) + .map((entry: any) => { + return de_ResultItem(__expectUnion(entry), context); + }); + return retVal; +}; + +// de_S3ExportSpecification omitted. + +/** + * deserializeAws_restJson1S3ItemFilter + */ +const de_S3ItemFilter = (output: any, context: __SerdeContext): S3ItemFilter => { + return take(output, { + CreationTimes: (_: any) => de_TimeConditionList(_, context), + ETags: _json, + ObjectKeys: _json, + Sizes: _json, + VersionIds: _json, + }) as any; +}; + +/** + * deserializeAws_restJson1S3ItemFilters + */ +const de_S3ItemFilters = (output: any, context: __SerdeContext): S3ItemFilter[] => { + const retVal = (output || []) + .filter((e: any) => e != null) + .map((entry: any) => { + return de_S3ItemFilter(entry, context); + }); + return retVal; +}; + +/** + * deserializeAws_restJson1S3ResultItem + */ +const de_S3ResultItem = (output: any, context: __SerdeContext): S3ResultItem => { + return take(output, { + BackupResourceArn: __expectString, + BackupVaultName: __expectString, + CreationTime: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + ETag: __expectString, + ObjectKey: __expectString, + ObjectSize: __expectLong, + SourceResourceArn: __expectString, + VersionId: __expectString, + }) as any; +}; + +/** + * deserializeAws_restJson1SearchJobBackupsResult + */ +const de_SearchJobBackupsResult = (output: any, context: __SerdeContext): SearchJobBackupsResult => { + return take(output, { + BackupCreationTime: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + BackupResourceArn: __expectString, + IndexCreationTime: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + ResourceType: __expectString, + SourceResourceArn: __expectString, + Status: __expectString, + StatusMessage: __expectString, + }) as any; +}; + +/** + * deserializeAws_restJson1SearchJobBackupsResults + */ +const de_SearchJobBackupsResults = (output: any, context: __SerdeContext): SearchJobBackupsResult[] => { + const retVal = (output || []) + .filter((e: any) => e != null) + .map((entry: any) => { + return de_SearchJobBackupsResult(entry, context); + }); + return retVal; +}; + +/** + * deserializeAws_restJson1SearchJobs + */ +const de_SearchJobs = (output: any, context: __SerdeContext): SearchJobSummary[] => { + const retVal = (output || []) + .filter((e: any) => e != null) + .map((entry: any) => { + return de_SearchJobSummary(entry, context); + }); + return retVal; +}; + +/** + * deserializeAws_restJson1SearchJobSummary + */ +const de_SearchJobSummary = (output: any, context: __SerdeContext): SearchJobSummary => { + return take(output, { + CompletionTime: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + CreationTime: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + Name: __expectString, + SearchJobArn: __expectString, + SearchJobIdentifier: __expectString, + SearchScopeSummary: _json, + Status: __expectString, + StatusMessage: __expectString, + }) as any; +}; + +/** + * deserializeAws_restJson1SearchScope + */ +const de_SearchScope = (output: any, context: __SerdeContext): SearchScope => { + return take(output, { + BackupResourceArns: _json, + BackupResourceCreationTime: (_: any) => de_BackupCreationTimeFilter(_, context), + BackupResourceTags: (_: any) => de_TagMap(_, context), + BackupResourceTypes: _json, + SourceResourceArns: _json, + }) as any; +}; + +// de_SearchScopeSummary omitted. + +// de_StringCondition omitted. + +// de_StringConditionList omitted. + +/** + * deserializeAws_restJson1TagMap + */ +const de_TagMap = (output: any, context: __SerdeContext): Record => { + return Object.entries(output).reduce((acc: Record, [key, value]: [string, any]) => { + if (value === null) { + acc[key as string] = null as any; + return acc; + } + acc[key as string] = __expectString(value) as any; + return acc; + }, {} as Record); +}; + +/** + * deserializeAws_restJson1TimeCondition + */ +const de_TimeCondition = (output: any, context: __SerdeContext): TimeCondition => { + return take(output, { + Operator: __expectString, + Value: (_: any) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))), + }) as any; +}; + +/** + * deserializeAws_restJson1TimeConditionList + */ +const de_TimeConditionList = (output: any, context: __SerdeContext): TimeCondition[] => { + const retVal = (output || []) + .filter((e: any) => e != null) + .map((entry: any) => { + return de_TimeCondition(entry, context); + }); + return retVal; +}; + +const deserializeMetadata = (output: __HttpResponse): __ResponseMetadata => ({ + httpStatusCode: output.statusCode, + requestId: + output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"], + extendedRequestId: output.headers["x-amz-id-2"], + cfId: output.headers["x-amz-cf-id"], +}); + +// Encode Uint8Array data into string with utf-8. +const collectBodyString = (streamBody: any, context: __SerdeContext): Promise => + collectBody(streamBody, context).then((body) => context.utf8Encoder(body)); + +const _BS = "ByStatus"; +const _MR = "MaxResults"; +const _NT = "NextToken"; +const _S = "Status"; +const _SJI = "SearchJobIdentifier"; +const _TK = "TagKeys"; +const _mR = "maxResults"; +const _nT = "nextToken"; +const _rAS = "retryAfterSeconds"; +const _ra = "retry-after"; +const _tK = "tagKeys"; diff --git a/clients/client-backupsearch/src/runtimeConfig.browser.ts b/clients/client-backupsearch/src/runtimeConfig.browser.ts new file mode 100644 index 000000000000..64739b286ee2 --- /dev/null +++ b/clients/client-backupsearch/src/runtimeConfig.browser.ts @@ -0,0 +1,44 @@ +// smithy-typescript generated code +// @ts-ignore: package.json will be imported from dist folders +import packageInfo from "../package.json"; // eslint-disable-line + +import { Sha256 } from "@aws-crypto/sha256-browser"; +import { createDefaultUserAgentProvider } from "@aws-sdk/util-user-agent-browser"; +import { DEFAULT_USE_DUALSTACK_ENDPOINT, DEFAULT_USE_FIPS_ENDPOINT } from "@smithy/config-resolver"; +import { FetchHttpHandler as RequestHandler, streamCollector } from "@smithy/fetch-http-handler"; +import { invalidProvider } from "@smithy/invalid-dependency"; +import { calculateBodyLength } from "@smithy/util-body-length-browser"; +import { DEFAULT_MAX_ATTEMPTS, DEFAULT_RETRY_MODE } from "@smithy/util-retry"; +import { BackupSearchClientConfig } from "./BackupSearchClient"; +import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared"; +import { loadConfigsForDefaultMode } from "@smithy/smithy-client"; +import { resolveDefaultsModeConfig } from "@smithy/util-defaults-mode-browser"; + +/** + * @internal + */ +export const getRuntimeConfig = (config: BackupSearchClientConfig) => { + const defaultsMode = resolveDefaultsModeConfig(config); + const defaultConfigProvider = () => defaultsMode().then(loadConfigsForDefaultMode); + const clientSharedValues = getSharedRuntimeConfig(config); + return { + ...clientSharedValues, + ...config, + runtime: "browser", + defaultsMode, + bodyLengthChecker: config?.bodyLengthChecker ?? calculateBodyLength, + credentialDefaultProvider: + config?.credentialDefaultProvider ?? ((_: unknown) => () => Promise.reject(new Error("Credential is missing"))), + defaultUserAgentProvider: + config?.defaultUserAgentProvider ?? + createDefaultUserAgentProvider({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), + maxAttempts: config?.maxAttempts ?? DEFAULT_MAX_ATTEMPTS, + region: config?.region ?? invalidProvider("Region is missing"), + requestHandler: RequestHandler.create(config?.requestHandler ?? defaultConfigProvider), + retryMode: config?.retryMode ?? (async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE), + sha256: config?.sha256 ?? Sha256, + streamCollector: config?.streamCollector ?? streamCollector, + useDualstackEndpoint: config?.useDualstackEndpoint ?? (() => Promise.resolve(DEFAULT_USE_DUALSTACK_ENDPOINT)), + useFipsEndpoint: config?.useFipsEndpoint ?? (() => Promise.resolve(DEFAULT_USE_FIPS_ENDPOINT)), + }; +}; diff --git a/clients/client-backupsearch/src/runtimeConfig.native.ts b/clients/client-backupsearch/src/runtimeConfig.native.ts new file mode 100644 index 000000000000..b2a9f4c53dd6 --- /dev/null +++ b/clients/client-backupsearch/src/runtimeConfig.native.ts @@ -0,0 +1,18 @@ +// smithy-typescript generated code +import { Sha256 } from "@aws-crypto/sha256-js"; + +import { BackupSearchClientConfig } from "./BackupSearchClient"; +import { getRuntimeConfig as getBrowserRuntimeConfig } from "./runtimeConfig.browser"; + +/** + * @internal + */ +export const getRuntimeConfig = (config: BackupSearchClientConfig) => { + const browserDefaults = getBrowserRuntimeConfig(config); + return { + ...browserDefaults, + ...config, + runtime: "react-native", + sha256: config?.sha256 ?? Sha256, + }; +}; diff --git a/clients/client-backupsearch/src/runtimeConfig.shared.ts b/clients/client-backupsearch/src/runtimeConfig.shared.ts new file mode 100644 index 000000000000..1e5a4e6fac59 --- /dev/null +++ b/clients/client-backupsearch/src/runtimeConfig.shared.ts @@ -0,0 +1,38 @@ +// smithy-typescript generated code +import { AwsSdkSigV4Signer } from "@aws-sdk/core"; +import { NoOpLogger } from "@smithy/smithy-client"; +import { IdentityProviderConfig } from "@smithy/types"; +import { parseUrl } from "@smithy/url-parser"; +import { fromBase64, toBase64 } from "@smithy/util-base64"; +import { fromUtf8, toUtf8 } from "@smithy/util-utf8"; + +import { defaultBackupSearchHttpAuthSchemeProvider } from "./auth/httpAuthSchemeProvider"; +import { BackupSearchClientConfig } from "./BackupSearchClient"; +import { defaultEndpointResolver } from "./endpoint/endpointResolver"; + +/** + * @internal + */ +export const getRuntimeConfig = (config: BackupSearchClientConfig) => { + return { + apiVersion: "2018-05-10", + base64Decoder: config?.base64Decoder ?? fromBase64, + base64Encoder: config?.base64Encoder ?? toBase64, + disableHostPrefix: config?.disableHostPrefix ?? false, + endpointProvider: config?.endpointProvider ?? defaultEndpointResolver, + extensions: config?.extensions ?? [], + httpAuthSchemeProvider: config?.httpAuthSchemeProvider ?? defaultBackupSearchHttpAuthSchemeProvider, + httpAuthSchemes: config?.httpAuthSchemes ?? [ + { + schemeId: "aws.auth#sigv4", + identityProvider: (ipc: IdentityProviderConfig) => ipc.getIdentityProvider("aws.auth#sigv4"), + signer: new AwsSdkSigV4Signer(), + }, + ], + logger: config?.logger ?? new NoOpLogger(), + serviceId: config?.serviceId ?? "BackupSearch", + urlParser: config?.urlParser ?? parseUrl, + utf8Decoder: config?.utf8Decoder ?? fromUtf8, + utf8Encoder: config?.utf8Encoder ?? toUtf8, + }; +}; diff --git a/clients/client-backupsearch/src/runtimeConfig.ts b/clients/client-backupsearch/src/runtimeConfig.ts new file mode 100644 index 000000000000..003ef3287024 --- /dev/null +++ b/clients/client-backupsearch/src/runtimeConfig.ts @@ -0,0 +1,67 @@ +// smithy-typescript generated code +// @ts-ignore: package.json will be imported from dist folders +import packageInfo from "../package.json"; // eslint-disable-line + +import { emitWarningIfUnsupportedVersion as awsCheckVersion } from "@aws-sdk/core"; +import { defaultProvider as credentialDefaultProvider } from "@aws-sdk/credential-provider-node"; +import { NODE_APP_ID_CONFIG_OPTIONS, createDefaultUserAgentProvider } from "@aws-sdk/util-user-agent-node"; +import { + NODE_REGION_CONFIG_FILE_OPTIONS, + NODE_REGION_CONFIG_OPTIONS, + NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, + NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, +} from "@smithy/config-resolver"; +import { Hash } from "@smithy/hash-node"; +import { NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS } from "@smithy/middleware-retry"; +import { loadConfig as loadNodeConfig } from "@smithy/node-config-provider"; +import { NodeHttpHandler as RequestHandler, streamCollector } from "@smithy/node-http-handler"; +import { calculateBodyLength } from "@smithy/util-body-length-node"; +import { DEFAULT_RETRY_MODE } from "@smithy/util-retry"; +import { BackupSearchClientConfig } from "./BackupSearchClient"; +import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared"; +import { loadConfigsForDefaultMode } from "@smithy/smithy-client"; +import { resolveDefaultsModeConfig } from "@smithy/util-defaults-mode-node"; +import { emitWarningIfUnsupportedVersion } from "@smithy/smithy-client"; + +/** + * @internal + */ +export const getRuntimeConfig = (config: BackupSearchClientConfig) => { + emitWarningIfUnsupportedVersion(process.version); + const defaultsMode = resolveDefaultsModeConfig(config); + const defaultConfigProvider = () => defaultsMode().then(loadConfigsForDefaultMode); + const clientSharedValues = getSharedRuntimeConfig(config); + awsCheckVersion(process.version); + const profileConfig = { profile: config?.profile }; + return { + ...clientSharedValues, + ...config, + runtime: "node", + defaultsMode, + bodyLengthChecker: config?.bodyLengthChecker ?? calculateBodyLength, + credentialDefaultProvider: config?.credentialDefaultProvider ?? credentialDefaultProvider, + defaultUserAgentProvider: + config?.defaultUserAgentProvider ?? + createDefaultUserAgentProvider({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }), + maxAttempts: config?.maxAttempts ?? loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS, config), + region: + config?.region ?? + loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, { ...NODE_REGION_CONFIG_FILE_OPTIONS, ...profileConfig }), + requestHandler: RequestHandler.create(config?.requestHandler ?? defaultConfigProvider), + retryMode: + config?.retryMode ?? + loadNodeConfig( + { + ...NODE_RETRY_MODE_CONFIG_OPTIONS, + default: async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE, + }, + config + ), + sha256: config?.sha256 ?? Hash.bind(null, "sha256"), + streamCollector: config?.streamCollector ?? streamCollector, + useDualstackEndpoint: + config?.useDualstackEndpoint ?? loadNodeConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, profileConfig), + useFipsEndpoint: config?.useFipsEndpoint ?? loadNodeConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, profileConfig), + userAgentAppId: config?.userAgentAppId ?? loadNodeConfig(NODE_APP_ID_CONFIG_OPTIONS, profileConfig), + }; +}; diff --git a/clients/client-backupsearch/src/runtimeExtensions.ts b/clients/client-backupsearch/src/runtimeExtensions.ts new file mode 100644 index 000000000000..77741416fa18 --- /dev/null +++ b/clients/client-backupsearch/src/runtimeExtensions.ts @@ -0,0 +1,48 @@ +// smithy-typescript generated code +import { + getAwsRegionExtensionConfiguration, + resolveAwsRegionExtensionConfiguration, +} from "@aws-sdk/region-config-resolver"; +import { getHttpHandlerExtensionConfiguration, resolveHttpHandlerRuntimeConfig } from "@smithy/protocol-http"; +import { getDefaultExtensionConfiguration, resolveDefaultRuntimeConfig } from "@smithy/smithy-client"; + +import { getHttpAuthExtensionConfiguration, resolveHttpAuthRuntimeConfig } from "./auth/httpAuthExtensionConfiguration"; +import { BackupSearchExtensionConfiguration } from "./extensionConfiguration"; + +/** + * @public + */ +export interface RuntimeExtension { + configure(extensionConfiguration: BackupSearchExtensionConfiguration): void; +} + +/** + * @public + */ +export interface RuntimeExtensionsConfig { + extensions: RuntimeExtension[]; +} + +const asPartial = >(t: T) => t; + +/** + * @internal + */ +export const resolveRuntimeExtensions = (runtimeConfig: any, extensions: RuntimeExtension[]) => { + const extensionConfiguration: BackupSearchExtensionConfiguration = { + ...asPartial(getAwsRegionExtensionConfiguration(runtimeConfig)), + ...asPartial(getDefaultExtensionConfiguration(runtimeConfig)), + ...asPartial(getHttpHandlerExtensionConfiguration(runtimeConfig)), + ...asPartial(getHttpAuthExtensionConfiguration(runtimeConfig)), + }; + + extensions.forEach((extension) => extension.configure(extensionConfiguration)); + + return { + ...runtimeConfig, + ...resolveAwsRegionExtensionConfiguration(extensionConfiguration), + ...resolveDefaultRuntimeConfig(extensionConfiguration), + ...resolveHttpHandlerRuntimeConfig(extensionConfiguration), + ...resolveHttpAuthRuntimeConfig(extensionConfiguration), + }; +}; diff --git a/clients/client-backupsearch/tsconfig.cjs.json b/clients/client-backupsearch/tsconfig.cjs.json new file mode 100644 index 000000000000..3567d85ba846 --- /dev/null +++ b/clients/client-backupsearch/tsconfig.cjs.json @@ -0,0 +1,6 @@ +{ + "extends": "./tsconfig", + "compilerOptions": { + "outDir": "dist-cjs" + } +} diff --git a/clients/client-backupsearch/tsconfig.es.json b/clients/client-backupsearch/tsconfig.es.json new file mode 100644 index 000000000000..809f57bde65e --- /dev/null +++ b/clients/client-backupsearch/tsconfig.es.json @@ -0,0 +1,8 @@ +{ + "extends": "./tsconfig", + "compilerOptions": { + "lib": ["dom"], + "module": "esnext", + "outDir": "dist-es" + } +} diff --git a/clients/client-backupsearch/tsconfig.json b/clients/client-backupsearch/tsconfig.json new file mode 100644 index 000000000000..e7f5ec56b742 --- /dev/null +++ b/clients/client-backupsearch/tsconfig.json @@ -0,0 +1,13 @@ +{ + "extends": "@tsconfig/node16/tsconfig.json", + "compilerOptions": { + "downlevelIteration": true, + "importHelpers": true, + "incremental": true, + "removeComments": true, + "resolveJsonModule": true, + "rootDir": "src", + "useUnknownInCatchVariables": false + }, + "exclude": ["test/"] +} diff --git a/clients/client-backupsearch/tsconfig.types.json b/clients/client-backupsearch/tsconfig.types.json new file mode 100644 index 000000000000..4c3dfa7b3d25 --- /dev/null +++ b/clients/client-backupsearch/tsconfig.types.json @@ -0,0 +1,10 @@ +{ + "extends": "./tsconfig", + "compilerOptions": { + "removeComments": false, + "declaration": true, + "declarationDir": "dist-types", + "emitDeclarationOnly": true + }, + "exclude": ["test/**/*", "dist-types/**/*"] +} diff --git a/codegen/sdk-codegen/aws-models/backupsearch.json b/codegen/sdk-codegen/aws-models/backupsearch.json new file mode 100644 index 000000000000..f48788555d02 --- /dev/null +++ b/codegen/sdk-codegen/aws-models/backupsearch.json @@ -0,0 +1,2820 @@ +{ + "smithy": "2.0", + "shapes": { + "com.amazonaws.backupsearch#AccessDeniedException": { + "type": "structure", + "members": { + "message": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

User does not have sufficient access to perform this action.

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

You do not have sufficient access to perform this action.

", + "smithy.api#error": "client", + "smithy.api#httpError": 403 + } + }, + "com.amazonaws.backupsearch#BackupCreationTimeFilter": { + "type": "structure", + "members": { + "CreatedAfter": { + "target": "smithy.api#Timestamp", + "traits": { + "smithy.api#documentation": "

This timestamp includes recovery points only \n created after the specified time.

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

This timestamp includes recovery points only \n created before the specified time.

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

This filters by recovery points within the CreatedAfter \n and CreatedBefore timestamps.

" + } + }, + "com.amazonaws.backupsearch#ConflictException": { + "type": "structure", + "members": { + "message": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

Updating or deleting a resource can cause an inconsistent state.

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

Identifier of the resource affected.

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

Type of the resource affected.

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

This exception occurs when a conflict with a previous successful\n operation is detected. This generally occurs when the previous \n operation did not have time to propagate to the host serving the \n current request.

\n

A retry (with appropriate backoff logic) is the recommended \n response to this exception.

", + "smithy.api#error": "client", + "smithy.api#httpError": 409 + } + }, + "com.amazonaws.backupsearch#CryoBackupSearchService": { + "type": "service", + "version": "2018-05-10", + "operations": [ + { + "target": "com.amazonaws.backupsearch#ListSearchJobBackups" + }, + { + "target": "com.amazonaws.backupsearch#ListSearchJobResults" + }, + { + "target": "com.amazonaws.backupsearch#ListTagsForResource" + }, + { + "target": "com.amazonaws.backupsearch#TagResource" + }, + { + "target": "com.amazonaws.backupsearch#UntagResource" + } + ], + "resources": [ + { + "target": "com.amazonaws.backupsearch#SearchJob" + }, + { + "target": "com.amazonaws.backupsearch#SearchResultExportJob" + } + ], + "errors": [ + { + "target": "com.amazonaws.backupsearch#AccessDeniedException" + }, + { + "target": "com.amazonaws.backupsearch#InternalServerException" + }, + { + "target": "com.amazonaws.backupsearch#ThrottlingException" + }, + { + "target": "com.amazonaws.backupsearch#ValidationException" + } + ], + "traits": { + "aws.api#service": { + "sdkId": "BackupSearch", + "arnNamespace": "backup-search", + "endpointPrefix": "backup-search", + "cloudTrailEventSource": "backup.amazonaws.com" + }, + "aws.auth#sigv4": { + "name": "backup-search" + }, + "aws.endpoints#dualStackOnlyEndpoints": {}, + "aws.endpoints#standardPartitionalEndpoints": { + "endpointPatternType": "service_region_dnsSuffix" + }, + "aws.protocols#restJson1": {}, + "smithy.api#cors": { + "additionalAllowedHeaders": [ + "*", + "Authorization", + "Date", + "X-Amz-Date", + "X-Amz-Security-Token", + "X-Amz-Target", + "content-type", + "x-amz-content-sha256", + "x-amz-user-agent", + "x-amzn-platform-id", + "x-amzn-trace-id" + ], + "additionalExposedHeaders": [ + "x-amzn-errortype", + "x-amzn-requestid", + "x-amzn-errormessage", + "x-amzn-trace-id", + "x-amzn-requestid", + "x-amz-apigw-id", + "date" + ] + }, + "smithy.api#documentation": "Backup Search\n

Backup Search is the recovery point and item level search for Backup.

\n

For additional information, see:

\n ", + "smithy.api#paginated": { + "inputToken": "NextToken", + "outputToken": "NextToken", + "pageSize": "MaxResults" + }, + "smithy.api#title": "AWS Backup Search", + "smithy.rules#endpointRuleSet": { + "version": "1.0", + "parameters": { + "UseFIPS": { + "builtIn": "AWS::UseFIPS", + "required": true, + "default": false, + "documentation": "When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.", + "type": "Boolean" + }, + "Endpoint": { + "builtIn": "SDK::Endpoint", + "required": false, + "documentation": "Override the endpoint used to send this request", + "type": "String" + }, + "Region": { + "builtIn": "AWS::Region", + "required": false, + "documentation": "The AWS region used to dispatch the request.", + "type": "String" + } + }, + "rules": [ + { + "conditions": [ + { + "fn": "isSet", + "argv": [ + { + "ref": "Endpoint" + } + ] + } + ], + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseFIPS" + }, + true + ] + } + ], + "error": "Invalid Configuration: FIPS and custom endpoint are not supported", + "type": "error" + }, + { + "conditions": [], + "endpoint": { + "url": { + "ref": "Endpoint" + }, + "properties": {}, + "headers": {} + }, + "type": "endpoint" + } + ], + "type": "tree" + }, + { + "conditions": [], + "rules": [ + { + "conditions": [ + { + "fn": "isSet", + "argv": [ + { + "ref": "Region" + } + ] + } + ], + "rules": [ + { + "conditions": [ + { + "fn": "aws.partition", + "argv": [ + { + "ref": "Region" + } + ], + "assign": "PartitionResult" + } + ], + "rules": [ + { + "conditions": [ + { + "fn": "booleanEquals", + "argv": [ + { + "ref": "UseFIPS" + }, + true + ] + } + ], + "endpoint": { + "url": "https://backup-search-fips.{PartitionResult#implicitGlobalRegion}.{PartitionResult#dualStackDnsSuffix}", + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "{PartitionResult#implicitGlobalRegion}" + } + ] + }, + "headers": {} + }, + "type": "endpoint" + }, + { + "conditions": [], + "endpoint": { + "url": "https://backup-search.{PartitionResult#implicitGlobalRegion}.{PartitionResult#dualStackDnsSuffix}", + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "{PartitionResult#implicitGlobalRegion}" + } + ] + }, + "headers": {} + }, + "type": "endpoint" + } + ], + "type": "tree" + } + ], + "type": "tree" + }, + { + "conditions": [], + "error": "Invalid Configuration: Missing Region", + "type": "error" + } + ], + "type": "tree" + } + ] + }, + "smithy.rules#endpointTests": { + "testCases": [ + { + "documentation": "For custom endpoint with region not set and fips disabled", + "expect": { + "endpoint": { + "url": "https://example.com" + } + }, + "params": { + "Endpoint": "https://example.com", + "UseFIPS": false + } + }, + { + "documentation": "For custom endpoint with fips enabled", + "expect": { + "error": "Invalid Configuration: FIPS and custom endpoint are not supported" + }, + "params": { + "Endpoint": "https://example.com", + "UseFIPS": true + } + }, + { + "documentation": "For region us-east-1 with FIPS enabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "us-east-1" + } + ] + }, + "url": "https://backup-search-fips.us-east-1.api.aws" + } + }, + "params": { + "Region": "us-east-1", + "UseFIPS": true + } + }, + { + "documentation": "For region us-east-1 with FIPS disabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "us-east-1" + } + ] + }, + "url": "https://backup-search.us-east-1.api.aws" + } + }, + "params": { + "Region": "us-east-1", + "UseFIPS": false + } + }, + { + "documentation": "For region cn-northwest-1 with FIPS enabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "cn-northwest-1" + } + ] + }, + "url": "https://backup-search-fips.cn-northwest-1.api.amazonwebservices.com.cn" + } + }, + "params": { + "Region": "cn-northwest-1", + "UseFIPS": true + } + }, + { + "documentation": "For region cn-northwest-1 with FIPS disabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "cn-northwest-1" + } + ] + }, + "url": "https://backup-search.cn-northwest-1.api.amazonwebservices.com.cn" + } + }, + "params": { + "Region": "cn-northwest-1", + "UseFIPS": false + } + }, + { + "documentation": "For region us-gov-west-1 with FIPS enabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "us-gov-west-1" + } + ] + }, + "url": "https://backup-search-fips.us-gov-west-1.api.aws" + } + }, + "params": { + "Region": "us-gov-west-1", + "UseFIPS": true + } + }, + { + "documentation": "For region us-gov-west-1 with FIPS disabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "us-gov-west-1" + } + ] + }, + "url": "https://backup-search.us-gov-west-1.api.aws" + } + }, + "params": { + "Region": "us-gov-west-1", + "UseFIPS": false + } + }, + { + "documentation": "For region us-iso-east-1 with FIPS enabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "us-iso-east-1" + } + ] + }, + "url": "https://backup-search-fips.us-iso-east-1.c2s.ic.gov" + } + }, + "params": { + "Region": "us-iso-east-1", + "UseFIPS": true + } + }, + { + "documentation": "For region us-iso-east-1 with FIPS disabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "us-iso-east-1" + } + ] + }, + "url": "https://backup-search.us-iso-east-1.c2s.ic.gov" + } + }, + "params": { + "Region": "us-iso-east-1", + "UseFIPS": false + } + }, + { + "documentation": "For region us-isob-east-1 with FIPS enabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "us-isob-east-1" + } + ] + }, + "url": "https://backup-search-fips.us-isob-east-1.sc2s.sgov.gov" + } + }, + "params": { + "Region": "us-isob-east-1", + "UseFIPS": true + } + }, + { + "documentation": "For region us-isob-east-1 with FIPS disabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "us-isob-east-1" + } + ] + }, + "url": "https://backup-search.us-isob-east-1.sc2s.sgov.gov" + } + }, + "params": { + "Region": "us-isob-east-1", + "UseFIPS": false + } + }, + { + "documentation": "For region eu-isoe-west-1 with FIPS enabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "eu-isoe-west-1" + } + ] + }, + "url": "https://backup-search-fips.eu-isoe-west-1.cloud.adc-e.uk" + } + }, + "params": { + "Region": "eu-isoe-west-1", + "UseFIPS": true + } + }, + { + "documentation": "For region eu-isoe-west-1 with FIPS disabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "eu-isoe-west-1" + } + ] + }, + "url": "https://backup-search.eu-isoe-west-1.cloud.adc-e.uk" + } + }, + "params": { + "Region": "eu-isoe-west-1", + "UseFIPS": false + } + }, + { + "documentation": "For region us-isof-south-1 with FIPS enabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "us-isof-south-1" + } + ] + }, + "url": "https://backup-search-fips.us-isof-south-1.csp.hci.ic.gov" + } + }, + "params": { + "Region": "us-isof-south-1", + "UseFIPS": true + } + }, + { + "documentation": "For region us-isof-south-1 with FIPS disabled and DualStack enabled", + "expect": { + "endpoint": { + "properties": { + "authSchemes": [ + { + "name": "sigv4", + "signingRegion": "us-isof-south-1" + } + ] + }, + "url": "https://backup-search.us-isof-south-1.csp.hci.ic.gov" + } + }, + "params": { + "Region": "us-isof-south-1", + "UseFIPS": false + } + }, + { + "documentation": "Missing region", + "expect": { + "error": "Invalid Configuration: Missing Region" + } + } + ], + "version": "1.0" + } + } + }, + "com.amazonaws.backupsearch#CurrentSearchProgress": { + "type": "structure", + "members": { + "RecoveryPointsScannedCount": { + "target": "smithy.api#Integer", + "traits": { + "smithy.api#documentation": "

This number is the sum of all backups that \n have been scanned so far during a search job.

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

This number is the sum of all items that \n have been scanned so far during a search job.

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

This number is the sum of all items that match \n the item filters in a search job in progress.

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

This contains information results retrieved from \n a search job that may not have completed.

" + } + }, + "com.amazonaws.backupsearch#EBSItemFilter": { + "type": "structure", + "members": { + "FilePaths": { + "target": "com.amazonaws.backupsearch#StringConditionList", + "traits": { + "smithy.api#documentation": "

You can include 1 to 10 values.

\n

If one file path is included, the results will \n return only items that match the file path.

\n

If more than one file path is included, the \n results will return all items that match any of the \n file paths.

" + } + }, + "Sizes": { + "target": "com.amazonaws.backupsearch#LongConditionList", + "traits": { + "smithy.api#documentation": "

You can include 1 to 10 values.

\n

If one is included, the results will \n return only items that match.

\n

If more than one is included, the \n results will return all items that match any of \n the included values.

" + } + }, + "CreationTimes": { + "target": "com.amazonaws.backupsearch#TimeConditionList", + "traits": { + "smithy.api#documentation": "

You can include 1 to 10 values.

\n

If one is included, the results will \n return only items that match.

\n

If more than one is included, the \n results will return all items that match any of \n the included values.

" + } + }, + "LastModificationTimes": { + "target": "com.amazonaws.backupsearch#TimeConditionList", + "traits": { + "smithy.api#documentation": "

You can include 1 to 10 values.

\n

If one is included, the results will \n return only items that match.

\n

If more than one is included, the \n results will return all items that match any of \n the included values.

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

This contains arrays of objects, which may include \n CreationTimes time condition objects, FilePaths \n string objects, LastModificationTimes time \n condition objects,

" + } + }, + "com.amazonaws.backupsearch#EBSItemFilters": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#EBSItemFilter" + }, + "traits": { + "smithy.api#length": { + "min": 0, + "max": 10 + } + } + }, + "com.amazonaws.backupsearch#EBSResultItem": { + "type": "structure", + "members": { + "BackupResourceArn": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

These are one or more items in the \n results that match values for the Amazon Resource \n Name (ARN) of recovery points returned in a search \n of Amazon EBS backup metadata.

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

These are one or more items in the \n results that match values for the Amazon Resource \n Name (ARN) of source resources returned in a search \n of Amazon EBS backup metadata.

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

The name of the backup vault.

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

These are one or more items in the \n results that match values for file systems returned \n in a search of Amazon EBS backup metadata.

" + } + }, + "FilePath": { + "target": "com.amazonaws.backupsearch#FilePath", + "traits": { + "smithy.api#documentation": "

These are one or more items in the \n results that match values for file paths returned \n in a search of Amazon EBS backup metadata.

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

These are one or more items in the \n results that match values for file sizes returned \n in a search of Amazon EBS backup metadata.

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

These are one or more items in the \n results that match values for creation times returned \n in a search of Amazon EBS backup metadata.

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

These are one or more items in the \n results that match values for Last Modified Time returned \n in a search of Amazon EBS backup metadata.

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

These are the items returned in the results of \n a search of Amazon EBS backup metadata.

" + } + }, + "com.amazonaws.backupsearch#EncryptionKeyArn": { + "type": "string", + "traits": { + "aws.api#arnReference": { + "type": "AWS::KMS::Key" + } + } + }, + "com.amazonaws.backupsearch#ExportJobArn": { + "type": "string", + "traits": { + "aws.api#arnReference": { + "service": "com.amazonaws.backupsearch#CryoBackupSearchService" + } + } + }, + "com.amazonaws.backupsearch#ExportJobStatus": { + "type": "enum", + "members": { + "RUNNING": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "RUNNING" + } + }, + "FAILED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "FAILED" + } + }, + "COMPLETED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "COMPLETED" + } + } + } + }, + "com.amazonaws.backupsearch#ExportJobSummaries": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#ExportJobSummary" + } + }, + "com.amazonaws.backupsearch#ExportJobSummary": { + "type": "structure", + "members": { + "ExportJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

This is the unique string that identifies a \n specific export job.

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

This is the unique ARN (Amazon Resource Name) that \n belongs to the new export job.

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

The status of the export job is one of the \n following:

\n

\n CREATED; RUNNING; \n FAILED; or COMPLETED.

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

This is a timestamp of the time the export job \n was created.

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

This is a timestamp of the time the export job \n compeleted.

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

A status message is a string that is returned for an export\n job.

\n

A status message is included for any status other \n than COMPLETED without issues.

" + } + }, + "SearchJobArn": { + "target": "com.amazonaws.backupsearch#SearchJobArn", + "traits": { + "smithy.api#documentation": "

The unique string that identifies the Amazon Resource \n Name (ARN) of the specified search job.

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

This is the summary of an export job.

" + } + }, + "com.amazonaws.backupsearch#ExportSpecification": { + "type": "union", + "members": { + "s3ExportSpecification": { + "target": "com.amazonaws.backupsearch#S3ExportSpecification", + "traits": { + "smithy.api#documentation": "

This specifies the destination Amazon S3 \n bucket for the export job. And, if included, it also \n specifies the destination prefix.

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

This contains the export specification object.

" + } + }, + "com.amazonaws.backupsearch#FilePath": { + "type": "string", + "traits": { + "smithy.api#sensitive": {} + } + }, + "com.amazonaws.backupsearch#GenericId": { + "type": "string" + }, + "com.amazonaws.backupsearch#GetSearchJob": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#GetSearchJobInput" + }, + "output": { + "target": "com.amazonaws.backupsearch#GetSearchJobOutput" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ResourceNotFoundException" + } + ], + "traits": { + "smithy.api#documentation": "

This operation retrieves metadata of a search job, \n including its progress.

", + "smithy.api#http": { + "code": 200, + "method": "GET", + "uri": "/search-jobs/{SearchJobIdentifier}" + }, + "smithy.api#readonly": {} + } + }, + "com.amazonaws.backupsearch#GetSearchJobInput": { + "type": "structure", + "members": { + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

Required unique string that specifies the \n search job.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#GetSearchJobOutput": { + "type": "structure", + "members": { + "Name": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

Returned name of the specified search job.

" + } + }, + "SearchScopeSummary": { + "target": "com.amazonaws.backupsearch#SearchScopeSummary", + "traits": { + "smithy.api#documentation": "

Returned summary of the specified search job scope, \n including:\n

\n
    \n
  • \n

    TotalBackupsToScanCount, the number of \n recovery points returned by the search.

    \n
  • \n
  • \n

    TotalItemsToScanCount, the number of \n items returned by the search.

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

Returns numbers representing BackupsScannedCount, \n ItemsScanned, and ItemsMatched.

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

A status message will be returned for either a \n earch job with a status of ERRORED or a status of \n COMPLETED jobs with issues.

\n

For example, a message may say that a search \n contained recovery points unable to be scanned because \n of a permissions issue.

" + } + }, + "EncryptionKeyArn": { + "target": "com.amazonaws.backupsearch#EncryptionKeyArn", + "traits": { + "smithy.api#documentation": "

The encryption key for the specified \n search job.

\n

Example: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab.

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

The date and time that a search job completed, in Unix format and Coordinated\n Universal Time (UTC). The value of CompletionTime is accurate to milliseconds.\n For example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087\n AM.

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

The current status of the specified search job.

\n

A search job may have one of the following statuses: \n RUNNING; COMPLETED; STOPPED; \n FAILED; TIMED_OUT; or EXPIRED\n .

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

The search scope is all backup \n properties input into a search.

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

Item Filters represent all input item \n properties specified when the search was \n created.

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

The date and time that a search job was created, in Unix format and Coordinated\n Universal Time (UTC). The value of CompletionTime is accurate to milliseconds.\n For example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087\n AM.

", + "smithy.api#required": {} + } + }, + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

The unique string that identifies the specified search job.

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

The unique string that identifies the Amazon Resource \n Name (ARN) of the specified search job.

", + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#GetSearchResultExportJob": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#GetSearchResultExportJobInput" + }, + "output": { + "target": "com.amazonaws.backupsearch#GetSearchResultExportJobOutput" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ResourceNotFoundException" + } + ], + "traits": { + "smithy.api#documentation": "

This operation retrieves the metadata of an export job.

\n

An export job is an operation that transmits the results \n of a search job to a specified S3 bucket in a \n .csv file.

\n

An export job allows you to retain results of a search \n beyond the search job's scheduled retention of 7 days.

", + "smithy.api#http": { + "code": 200, + "method": "GET", + "uri": "/export-search-jobs/{ExportJobIdentifier}" + }, + "smithy.api#readonly": {} + } + }, + "com.amazonaws.backupsearch#GetSearchResultExportJobInput": { + "type": "structure", + "members": { + "ExportJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

This is the unique string that identifies a \n specific export job.

\n

Required for this operation.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#GetSearchResultExportJobOutput": { + "type": "structure", + "members": { + "ExportJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

This is the unique string that identifies the \n specified export job.

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

The unique Amazon Resource Name (ARN) that uniquely identifies \n the export job.

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

This is the current status of the export job.

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

The date and time that an export job was created, in Unix format and Coordinated Universal\n Time (UTC). The value of CreationTime is accurate to milliseconds. For\n example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087\n AM.

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

The date and time that an export job completed, in Unix format and Coordinated Universal\n Time (UTC). The value of CreationTime is accurate to milliseconds. For\n example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087\n AM.

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

A status message is a string that is returned for search job \n with a status of FAILED, along with steps to remedy \n and retry the operation.

" + } + }, + "ExportSpecification": { + "target": "com.amazonaws.backupsearch#ExportSpecification", + "traits": { + "smithy.api#documentation": "

The export specification consists of the destination \n S3 bucket to which the search results were exported, along \n with the destination prefix.

" + } + }, + "SearchJobArn": { + "target": "com.amazonaws.backupsearch#SearchJobArn", + "traits": { + "smithy.api#documentation": "

The unique string that identifies the Amazon Resource \n Name (ARN) of the specified search job.

" + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#IamRoleArn": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 20, + "max": 2048 + }, + "smithy.api#pattern": "^arn:(?:aws|aws-cn|aws-us-gov):iam::[a-z0-9-]+:role/(.+)$" + } + }, + "com.amazonaws.backupsearch#InternalServerException": { + "type": "structure", + "members": { + "message": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

Unexpected error during processing of request.

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

Retry the call after number of seconds.

", + "smithy.api#httpHeader": "Retry-After" + } + } + }, + "traits": { + "smithy.api#documentation": "

An internal server error occurred. Retry your request.

", + "smithy.api#error": "server", + "smithy.api#httpError": 500, + "smithy.api#retryable": {} + } + }, + "com.amazonaws.backupsearch#ItemFilters": { + "type": "structure", + "members": { + "S3ItemFilters": { + "target": "com.amazonaws.backupsearch#S3ItemFilters", + "traits": { + "smithy.api#documentation": "

This array can contain CreationTimes, ETags, \n ObjectKeys, Sizes, or VersionIds objects.

" + } + }, + "EBSItemFilters": { + "target": "com.amazonaws.backupsearch#EBSItemFilters", + "traits": { + "smithy.api#documentation": "

This array can contain CreationTimes, \n FilePaths, LastModificationTimes, or Sizes objects.

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

Item Filters represent all input item \n properties specified when the search was \n created.

\n

Contains either EBSItemFilters or \n S3ItemFilters

" + } + }, + "com.amazonaws.backupsearch#ListSearchJobBackups": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#ListSearchJobBackupsInput" + }, + "output": { + "target": "com.amazonaws.backupsearch#ListSearchJobBackupsOutput" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ResourceNotFoundException" + } + ], + "traits": { + "smithy.api#documentation": "

This operation returns a list of all backups (recovery \n points) in a paginated format that were included in \n the search job.

\n

If a search does not display an expected backup in \n the results, you can call this operation to display each \n backup included in the search. Any backups that were not \n included because they have a FAILED status \n from a permissions issue will be displayed, along with a \n status message.

\n

Only recovery points with a backup index that has \n a status of ACTIVE will be included in search results. \n If the index has any other status, its status will be \n displayed along with a status message.

", + "smithy.api#http": { + "code": 200, + "method": "GET", + "uri": "/search-jobs/{SearchJobIdentifier}/backups" + }, + "smithy.api#paginated": { + "inputToken": "NextToken", + "outputToken": "NextToken", + "pageSize": "MaxResults", + "items": "Results" + }, + "smithy.api#readonly": {} + } + }, + "com.amazonaws.backupsearch#ListSearchJobBackupsInput": { + "type": "structure", + "members": { + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

The unique string that specifies the search job.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + }, + "NextToken": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The next item following a partial list of returned backups \n included in a search job.

\n

For example, if a request\n is made to return MaxResults number of backups, NextToken\n allows you to return more items in your list starting at the location pointed to by the\n next token.

", + "smithy.api#httpQuery": "nextToken" + } + }, + "MaxResults": { + "target": "smithy.api#Integer", + "traits": { + "smithy.api#default": 1000, + "smithy.api#documentation": "

The maximum number of resource list items to be returned.

", + "smithy.api#httpQuery": "maxResults", + "smithy.api#range": { + "min": 1, + "max": 1000 + } + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#ListSearchJobBackupsOutput": { + "type": "structure", + "members": { + "Results": { + "target": "com.amazonaws.backupsearch#SearchJobBackupsResults", + "traits": { + "smithy.api#documentation": "

The recovery points returned the results of a \n search job

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

The next item following a partial list of returned backups \n included in a search job.

\n

For example, if a request\n is made to return MaxResults number of backups, NextToken\n allows you to return more items in your list starting at the location pointed to by the\n next token.

" + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#ListSearchJobResults": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#ListSearchJobResultsInput" + }, + "output": { + "target": "com.amazonaws.backupsearch#ListSearchJobResultsOutput" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ResourceNotFoundException" + } + ], + "traits": { + "aws.api#dataPlane": {}, + "smithy.api#documentation": "

This operation returns a list of a specified search job.

", + "smithy.api#http": { + "code": 200, + "method": "GET", + "uri": "/search-jobs/{SearchJobIdentifier}/search-results" + }, + "smithy.api#paginated": { + "items": "Results" + }, + "smithy.api#readonly": {} + } + }, + "com.amazonaws.backupsearch#ListSearchJobResultsInput": { + "type": "structure", + "members": { + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

The unique string that specifies the search job.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + }, + "NextToken": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The next item following a partial list of returned \n search job results.

\n

For example, if a request\n is made to return MaxResults number of \n search job results, NextToken\n allows you to return more items in your list starting at the location pointed to by the\n next token.

", + "smithy.api#httpQuery": "nextToken" + } + }, + "MaxResults": { + "target": "smithy.api#Integer", + "traits": { + "smithy.api#default": 1000, + "smithy.api#documentation": "

The maximum number of resource list items to be returned.

", + "smithy.api#httpQuery": "maxResults", + "smithy.api#range": { + "min": 1, + "max": 1000 + } + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#ListSearchJobResultsOutput": { + "type": "structure", + "members": { + "Results": { + "target": "com.amazonaws.backupsearch#Results", + "traits": { + "smithy.api#documentation": "

The results consist of either EBSResultItem or S3ResultItem.

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

The next item following a partial list of \n search job results.

\n

For example, if a request\n is made to return MaxResults number of backups, NextToken\n allows you to return more items in your list starting at the location pointed to by the\n next token.

" + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#ListSearchJobs": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#ListSearchJobsInput" + }, + "output": { + "target": "com.amazonaws.backupsearch#ListSearchJobsOutput" + }, + "traits": { + "smithy.api#documentation": "

This operation returns a list of search jobs belonging \n to an account.

", + "smithy.api#http": { + "code": 200, + "method": "GET", + "uri": "/search-jobs" + }, + "smithy.api#paginated": { + "items": "SearchJobs" + }, + "smithy.api#readonly": {}, + "smithy.test#smokeTests": [ + { + "id": "ListSearchJobsSuccess", + "params": {}, + "expect": { + "success": {} + }, + "vendorParamsShape": "aws.test#AwsVendorParams", + "vendorParams": { + "region": "us-east-1" + } + } + ] + } + }, + "com.amazonaws.backupsearch#ListSearchJobsInput": { + "type": "structure", + "members": { + "ByStatus": { + "target": "com.amazonaws.backupsearch#SearchJobState", + "traits": { + "smithy.api#documentation": "

Include this parameter to filter list by search \n job status.

", + "smithy.api#httpQuery": "Status", + "smithy.api#notProperty": {} + } + }, + "NextToken": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The next item following a partial list of returned \n search jobs.

\n

For example, if a request\n is made to return MaxResults number of backups, NextToken\n allows you to return more items in your list starting at the location pointed to by the\n next token.

", + "smithy.api#httpQuery": "NextToken", + "smithy.api#notProperty": {} + } + }, + "MaxResults": { + "target": "smithy.api#Integer", + "traits": { + "smithy.api#default": 1000, + "smithy.api#documentation": "

The maximum number of resource list items to be returned.

", + "smithy.api#httpQuery": "MaxResults", + "smithy.api#notProperty": {}, + "smithy.api#range": { + "min": 1, + "max": 1000 + } + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#ListSearchJobsOutput": { + "type": "structure", + "members": { + "SearchJobs": { + "target": "com.amazonaws.backupsearch#SearchJobs", + "traits": { + "smithy.api#documentation": "

The search jobs among the list, with details of \n the returned search jobs.

", + "smithy.api#notProperty": {}, + "smithy.api#required": {} + } + }, + "NextToken": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The next item following a partial list of returned backups \n included in a search job.

\n

For example, if a request\n is made to return MaxResults number of backups, NextToken\n allows you to return more items in your list starting at the location pointed to by the\n next token.

", + "smithy.api#notProperty": {} + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#ListSearchResultExportJobs": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#ListSearchResultExportJobsInput" + }, + "output": { + "target": "com.amazonaws.backupsearch#ListSearchResultExportJobsOutput" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ResourceNotFoundException" + }, + { + "target": "com.amazonaws.backupsearch#ServiceQuotaExceededException" + } + ], + "traits": { + "smithy.api#documentation": "

This operation exports search results of a search job \n to a specified destination S3 bucket.

", + "smithy.api#http": { + "code": 200, + "method": "GET", + "uri": "/export-search-jobs" + }, + "smithy.api#paginated": { + "items": "ExportJobs" + }, + "smithy.api#readonly": {} + } + }, + "com.amazonaws.backupsearch#ListSearchResultExportJobsInput": { + "type": "structure", + "members": { + "Status": { + "target": "com.amazonaws.backupsearch#ExportJobStatus", + "traits": { + "smithy.api#documentation": "

The search jobs to be included in the export job \n can be filtered by including this parameter.

", + "smithy.api#httpQuery": "Status", + "smithy.api#notProperty": {} + } + }, + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

The unique string that specifies the search job.

", + "smithy.api#httpQuery": "SearchJobIdentifier", + "smithy.api#notProperty": {} + } + }, + "NextToken": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The next item following a partial list of returned backups \n included in a search job.

\n

For example, if a request\n is made to return MaxResults number of backups, NextToken\n allows you to return more items in your list starting at the location pointed to by the\n next token.

", + "smithy.api#httpQuery": "NextToken", + "smithy.api#notProperty": {} + } + }, + "MaxResults": { + "target": "smithy.api#Integer", + "traits": { + "smithy.api#default": 1000, + "smithy.api#documentation": "

The maximum number of resource list items to be returned.

", + "smithy.api#httpQuery": "MaxResults", + "smithy.api#notProperty": {}, + "smithy.api#range": { + "min": 1, + "max": 1000 + } + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#ListSearchResultExportJobsOutput": { + "type": "structure", + "members": { + "ExportJobs": { + "target": "com.amazonaws.backupsearch#ExportJobSummaries", + "traits": { + "smithy.api#documentation": "

The operation returns the included export jobs.

", + "smithy.api#notProperty": {}, + "smithy.api#required": {} + } + }, + "NextToken": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The next item following a partial list of returned backups \n included in a search job.

\n

For example, if a request\n is made to return MaxResults number of backups, NextToken\n allows you to return more items in your list starting at the location pointed to by the\n next token.

", + "smithy.api#notProperty": {} + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#ListTagsForResource": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#ListTagsForResourceRequest" + }, + "output": { + "target": "com.amazonaws.backupsearch#ListTagsForResourceResponse" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ResourceNotFoundException" + } + ], + "traits": { + "smithy.api#documentation": "

This operation returns the tags for a resource type.

", + "smithy.api#http": { + "uri": "/tags/{ResourceArn}", + "method": "GET" + }, + "smithy.api#readonly": {} + } + }, + "com.amazonaws.backupsearch#ListTagsForResourceRequest": { + "type": "structure", + "members": { + "ResourceArn": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The Amazon Resource Name (ARN) that uniquely identifies \n the resource.>

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#ListTagsForResourceResponse": { + "type": "structure", + "members": { + "Tags": { + "target": "com.amazonaws.backupsearch#TagMap", + "traits": { + "smithy.api#documentation": "

List of tags returned by the operation.

" + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#LongCondition": { + "type": "structure", + "members": { + "Value": { + "target": "smithy.api#Long", + "traits": { + "smithy.api#documentation": "

The value of an item included in one of the search \n item filters.

", + "smithy.api#required": {} + } + }, + "Operator": { + "target": "com.amazonaws.backupsearch#LongConditionOperator", + "traits": { + "smithy.api#default": "EQUALS_TO", + "smithy.api#documentation": "

A string that defines what values will be \n returned.

\n

If this is included, avoid combinations of \n operators that will return all possible values. \n For example, including both EQUALS_TO \n and NOT_EQUALS_TO with a value of 4 \n will return all values.

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

The long condition contains a Value \n and can optionally contain an Operator.

" + } + }, + "com.amazonaws.backupsearch#LongConditionList": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#LongCondition" + }, + "traits": { + "smithy.api#length": { + "min": 1, + "max": 10 + } + } + }, + "com.amazonaws.backupsearch#LongConditionOperator": { + "type": "enum", + "members": { + "EQUALS_TO": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "EQUALS_TO" + } + }, + "NOT_EQUALS_TO": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "NOT_EQUALS_TO" + } + }, + "LESS_THAN_EQUAL_TO": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "LESS_THAN_EQUAL_TO" + } + }, + "GREATER_THAN_EQUAL_TO": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "GREATER_THAN_EQUAL_TO" + } + } + } + }, + "com.amazonaws.backupsearch#ObjectKey": { + "type": "string", + "traits": { + "smithy.api#sensitive": {} + } + }, + "com.amazonaws.backupsearch#RecoveryPoint": { + "type": "string", + "traits": { + "aws.api#arnReference": { + "type": "AWS::Backup::RecoveryPoint" + } + } + }, + "com.amazonaws.backupsearch#RecoveryPointArnList": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#RecoveryPoint" + }, + "traits": { + "smithy.api#length": { + "min": 0, + "max": 50 + } + } + }, + "com.amazonaws.backupsearch#ResourceArnList": { + "type": "list", + "member": { + "target": "smithy.api#String" + }, + "traits": { + "smithy.api#length": { + "min": 0, + "max": 50 + } + } + }, + "com.amazonaws.backupsearch#ResourceNotFoundException": { + "type": "structure", + "members": { + "message": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

Request references a resource which does not exist.

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

Hypothetical identifier of the resource affected.

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

Hypothetical type of the resource affected.

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

The resource was not found for this request.

\n

Confirm the resource information, such as the ARN or type is correct \n and exists, then retry the request.

", + "smithy.api#error": "client", + "smithy.api#httpError": 404 + } + }, + "com.amazonaws.backupsearch#ResourceType": { + "type": "enum", + "members": { + "S3": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "S3" + } + }, + "EBS": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "EBS" + } + } + } + }, + "com.amazonaws.backupsearch#ResourceTypeList": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#ResourceType" + }, + "traits": { + "smithy.api#length": { + "min": 1, + "max": 1 + } + } + }, + "com.amazonaws.backupsearch#ResultItem": { + "type": "union", + "members": { + "S3ResultItem": { + "target": "com.amazonaws.backupsearch#S3ResultItem", + "traits": { + "smithy.api#documentation": "

These are items returned in the search results \n of an Amazon S3 search.

" + } + }, + "EBSResultItem": { + "target": "com.amazonaws.backupsearch#EBSResultItem", + "traits": { + "smithy.api#documentation": "

These are items returned in the search results \n of an Amazon EBS search.

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

This is an object representing the item \n returned in the results of a search for a specific \n resource type.

" + } + }, + "com.amazonaws.backupsearch#Results": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#ResultItem" + } + }, + "com.amazonaws.backupsearch#S3ExportSpecification": { + "type": "structure", + "members": { + "DestinationBucket": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

This specifies the destination Amazon S3 \n bucket for the export job.

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

This specifies the prefix for the destination \n Amazon S3 bucket for the export job.

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

This specification contains a required string of the \n destination bucket; optionally, you can include the \n destination prefix.

" + } + }, + "com.amazonaws.backupsearch#S3ItemFilter": { + "type": "structure", + "members": { + "ObjectKeys": { + "target": "com.amazonaws.backupsearch#StringConditionList", + "traits": { + "smithy.api#documentation": "

You can include 1 to 10 values.

\n

If one value is included, the results will \n return only items that match the value.

\n

If more than one value is included, the \n results will return all items that match any of the \n values.

" + } + }, + "Sizes": { + "target": "com.amazonaws.backupsearch#LongConditionList", + "traits": { + "smithy.api#documentation": "

You can include 1 to 10 values.

\n

If one value is included, the results will \n return only items that match the value.

\n

If more than one value is included, the \n results will return all items that match any of the \n values.

" + } + }, + "CreationTimes": { + "target": "com.amazonaws.backupsearch#TimeConditionList", + "traits": { + "smithy.api#documentation": "

You can include 1 to 10 values.

\n

If one value is included, the results will \n return only items that match the value.

\n

If more than one value is included, the \n results will return all items that match any of the \n values.

" + } + }, + "VersionIds": { + "target": "com.amazonaws.backupsearch#StringConditionList", + "traits": { + "smithy.api#documentation": "

You can include 1 to 10 values.

\n

If one value is included, the results will \n return only items that match the value.

\n

If more than one value is included, the \n results will return all items that match any of the \n values.

" + } + }, + "ETags": { + "target": "com.amazonaws.backupsearch#StringConditionList", + "traits": { + "smithy.api#documentation": "

You can include 1 to 10 values.

\n

If one value is included, the results will \n return only items that match the value.

\n

If more than one value is included, the \n results will return all items that match any of the \n values.

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

This contains arrays of objects, which may include \n ObjectKeys, Sizes, CreationTimes, VersionIds, and/or \n Etags.

" + } + }, + "com.amazonaws.backupsearch#S3ItemFilters": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#S3ItemFilter" + }, + "traits": { + "smithy.api#length": { + "min": 0, + "max": 10 + } + } + }, + "com.amazonaws.backupsearch#S3ResultItem": { + "type": "structure", + "members": { + "BackupResourceArn": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

These are items in the returned results that match \n recovery point Amazon Resource Names (ARN) input during \n a search of Amazon S3 backup metadata.

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

These are items in the returned results that match \n source Amazon Resource Names (ARN) input during \n a search of Amazon S3 backup metadata.

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

The name of the backup vault.

" + } + }, + "ObjectKey": { + "target": "com.amazonaws.backupsearch#ObjectKey", + "traits": { + "smithy.api#documentation": "

This is one or more items \n returned in the results of a search of Amazon S3 \n backup metadata that match the values input for \n object key.

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

These are items in the returned results that match \n values for object size(s) input during a search of \n Amazon S3 backup metadata.

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

These are one or more items in the returned results \n that match values for item creation time input during \n a search of Amazon S3 backup metadata.

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

These are one or more items in the returned results \n that match values for ETags input during \n a search of Amazon S3 backup metadata.

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

These are one or more items in the returned results \n that match values for version IDs input during \n a search of Amazon S3 backup metadata.

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

These are the items returned in the results of \n a search of Amazon S3 backup metadata.

" + } + }, + "com.amazonaws.backupsearch#SearchJob": { + "type": "resource", + "identifiers": { + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId" + } + }, + "properties": { + "Status": { + "target": "com.amazonaws.backupsearch#SearchJobState" + }, + "Name": { + "target": "smithy.api#String" + }, + "EncryptionKeyArn": { + "target": "com.amazonaws.backupsearch#EncryptionKeyArn" + }, + "SearchScope": { + "target": "com.amazonaws.backupsearch#SearchScope" + }, + "ItemFilters": { + "target": "com.amazonaws.backupsearch#ItemFilters" + }, + "CreationTime": { + "target": "smithy.api#Timestamp" + }, + "CompletionTime": { + "target": "smithy.api#Timestamp" + }, + "SearchScopeSummary": { + "target": "com.amazonaws.backupsearch#SearchScopeSummary" + }, + "CurrentSearchProgress": { + "target": "com.amazonaws.backupsearch#CurrentSearchProgress" + }, + "StatusMessage": { + "target": "smithy.api#String" + }, + "ClientToken": { + "target": "smithy.api#String" + }, + "Tags": { + "target": "com.amazonaws.backupsearch#TagMap" + }, + "SearchJobArn": { + "target": "com.amazonaws.backupsearch#SearchJobArn" + } + }, + "create": { + "target": "com.amazonaws.backupsearch#StartSearchJob" + }, + "read": { + "target": "com.amazonaws.backupsearch#GetSearchJob" + }, + "update": { + "target": "com.amazonaws.backupsearch#StopSearchJob" + }, + "list": { + "target": "com.amazonaws.backupsearch#ListSearchJobs" + } + }, + "com.amazonaws.backupsearch#SearchJobArn": { + "type": "string", + "traits": { + "aws.api#arnReference": { + "service": "com.amazonaws.backupsearch#CryoBackupSearchService" + } + } + }, + "com.amazonaws.backupsearch#SearchJobBackupsResult": { + "type": "structure", + "members": { + "Status": { + "target": "com.amazonaws.backupsearch#SearchJobState", + "traits": { + "smithy.api#documentation": "

This is the status of the search job backup result.

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

This is the status message included with the results.

" + } + }, + "ResourceType": { + "target": "com.amazonaws.backupsearch#ResourceType", + "traits": { + "smithy.api#documentation": "

This is the resource type of the search.

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

The Amazon Resource Name (ARN) that uniquely identifies \n the backup resources.

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

The Amazon Resource Name (ARN) that uniquely identifies \n the source resources.

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

This is the creation time of the backup index.

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

This is the creation time of the backup (recovery point).

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

This contains the information about recovery \n points returned in results of a search job.

" + } + }, + "com.amazonaws.backupsearch#SearchJobBackupsResults": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#SearchJobBackupsResult" + } + }, + "com.amazonaws.backupsearch#SearchJobState": { + "type": "enum", + "members": { + "RUNNING": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "RUNNING" + } + }, + "COMPLETED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "COMPLETED" + } + }, + "STOPPING": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "STOPPING" + } + }, + "STOPPED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "STOPPED" + } + }, + "FAILED": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "FAILED" + } + } + } + }, + "com.amazonaws.backupsearch#SearchJobSummary": { + "type": "structure", + "members": { + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

The unique string that specifies the search job.

" + } + }, + "SearchJobArn": { + "target": "com.amazonaws.backupsearch#SearchJobArn", + "traits": { + "smithy.api#documentation": "

The unique string that identifies the Amazon Resource \n Name (ARN) of the specified search job.

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

This is the name of the search job.

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

This is the status of the search job.

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

This is the creation time of the search job.

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

This is the completion time of the search job.

" + } + }, + "SearchScopeSummary": { + "target": "com.amazonaws.backupsearch#SearchScopeSummary", + "traits": { + "smithy.api#documentation": "

Returned summary of the specified search job scope, \n including:\n

\n
    \n
  • \n

    TotalBackupsToScanCount, the number of \n recovery points returned by the search.

    \n
  • \n
  • \n

    TotalItemsToScanCount, the number of \n items returned by the search.

    \n
  • \n
" + } + }, + "StatusMessage": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

A status message will be returned for either a \n earch job with a status of ERRORED or a status of \n COMPLETED jobs with issues.

\n

For example, a message may say that a search \n contained recovery points unable to be scanned because \n of a permissions issue.

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

This is information pertaining to a search job.

" + } + }, + "com.amazonaws.backupsearch#SearchJobs": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#SearchJobSummary" + } + }, + "com.amazonaws.backupsearch#SearchResultExportJob": { + "type": "resource", + "identifiers": { + "ExportJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId" + } + }, + "properties": { + "ExportJobArn": { + "target": "com.amazonaws.backupsearch#ExportJobArn" + }, + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId" + }, + "SearchJobArn": { + "target": "com.amazonaws.backupsearch#SearchJobArn" + }, + "Status": { + "target": "com.amazonaws.backupsearch#ExportJobStatus" + }, + "StatusMessage": { + "target": "smithy.api#String" + }, + "CreationTime": { + "target": "smithy.api#Timestamp" + }, + "CompletionTime": { + "target": "smithy.api#Timestamp" + }, + "ExportSpecification": { + "target": "com.amazonaws.backupsearch#ExportSpecification" + }, + "ClientToken": { + "target": "smithy.api#String" + }, + "Tags": { + "target": "com.amazonaws.backupsearch#TagMap" + }, + "RoleArn": { + "target": "com.amazonaws.backupsearch#IamRoleArn" + } + }, + "create": { + "target": "com.amazonaws.backupsearch#StartSearchResultExportJob" + }, + "read": { + "target": "com.amazonaws.backupsearch#GetSearchResultExportJob" + }, + "list": { + "target": "com.amazonaws.backupsearch#ListSearchResultExportJobs" + } + }, + "com.amazonaws.backupsearch#SearchScope": { + "type": "structure", + "members": { + "BackupResourceTypes": { + "target": "com.amazonaws.backupsearch#ResourceTypeList", + "traits": { + "smithy.api#documentation": "

The resource types included in a search.

\n

Eligible resource types include S3 and EBS.

", + "smithy.api#required": {} + } + }, + "BackupResourceCreationTime": { + "target": "com.amazonaws.backupsearch#BackupCreationTimeFilter", + "traits": { + "smithy.api#documentation": "

This is the time a backup resource was created.

" + } + }, + "SourceResourceArns": { + "target": "com.amazonaws.backupsearch#ResourceArnList", + "traits": { + "smithy.api#documentation": "

The Amazon Resource Name (ARN) that uniquely identifies \n the source resources.

" + } + }, + "BackupResourceArns": { + "target": "com.amazonaws.backupsearch#RecoveryPointArnList", + "traits": { + "smithy.api#documentation": "

The Amazon Resource Name (ARN) that uniquely identifies \n the backup resources.

" + } + }, + "BackupResourceTags": { + "target": "com.amazonaws.backupsearch#TagMap", + "traits": { + "smithy.api#documentation": "

These are one or more tags on the backup (recovery \n point).

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

The search scope is all backup \n properties input into a search.

" + } + }, + "com.amazonaws.backupsearch#SearchScopeSummary": { + "type": "structure", + "members": { + "TotalRecoveryPointsToScanCount": { + "target": "smithy.api#Integer", + "traits": { + "smithy.api#documentation": "

This is the count of the total number of backups \n that will be scanned in a search.

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

This is the count of the total number of items \n that will be scanned in a search.

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

The summary of the specified search job scope, \n including:\n

\n
    \n
  • \n

    TotalBackupsToScanCount, the number of \n recovery points returned by the search.

    \n
  • \n
  • \n

    TotalItemsToScanCount, the number of \n items returned by the search.

    \n
  • \n
" + } + }, + "com.amazonaws.backupsearch#ServiceQuotaExceededException": { + "type": "structure", + "members": { + "message": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

This request was not successful due to a service quota exceeding limits.

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

Identifier of the resource.

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

Type of resource.

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

This is the code unique to the originating service with the quota.

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

This is the code specific to the quota type.

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

The request denied due to exceeding the quota limits permitted.

", + "smithy.api#error": "client", + "smithy.api#httpError": 402 + } + }, + "com.amazonaws.backupsearch#StartSearchJob": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#StartSearchJobInput" + }, + "output": { + "target": "com.amazonaws.backupsearch#StartSearchJobOutput" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ConflictException" + }, + { + "target": "com.amazonaws.backupsearch#ServiceQuotaExceededException" + } + ], + "traits": { + "smithy.api#documentation": "

This operation creates a search job which returns \n recovery points filtered by SearchScope and items \n filtered by ItemFilters.

\n

You can optionally include ClientToken, \n EncryptionKeyArn, Name, and/or Tags.

", + "smithy.api#http": { + "code": 200, + "method": "PUT", + "uri": "/search-jobs" + }, + "smithy.api#idempotent": {} + } + }, + "com.amazonaws.backupsearch#StartSearchJobInput": { + "type": "structure", + "members": { + "Tags": { + "target": "com.amazonaws.backupsearch#TagMap", + "traits": { + "smithy.api#documentation": "

List of tags returned by the operation.

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

Include alphanumeric characters to create a \n name for this search job.

", + "smithy.api#length": { + "max": 500 + } + } + }, + "EncryptionKeyArn": { + "target": "com.amazonaws.backupsearch#EncryptionKeyArn", + "traits": { + "smithy.api#documentation": "

The encryption key for the specified \n search job.

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

Include this parameter to allow multiple identical \n calls for idempotency.

\n

A client token is valid for 8 hours after the first \n request that uses it is completed. After this time,\n any request with the same token is treated as a \n new request.

" + } + }, + "SearchScope": { + "target": "com.amazonaws.backupsearch#SearchScope", + "traits": { + "smithy.api#documentation": "

This object can contain BackupResourceTypes, \n BackupResourceArns, BackupResourceCreationTime, \n BackupResourceTags, and SourceResourceArns to \n filter the recovery points returned by the search \n job.

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

Item Filters represent all input item \n properties specified when the search was \n created.

\n

Contains either EBSItemFilters or \n S3ItemFilters

" + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#StartSearchJobOutput": { + "type": "structure", + "members": { + "SearchJobArn": { + "target": "com.amazonaws.backupsearch#SearchJobArn", + "traits": { + "smithy.api#documentation": "

The unique string that identifies the Amazon Resource \n Name (ARN) of the specified search job.

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

The date and time that a job was created, in Unix format and Coordinated\n Universal Time (UTC). The value of CompletionTime is accurate to milliseconds.\n For example, the value 1516925490.087 represents Friday, January 26, 2018 12:11:30.087\n AM.

" + } + }, + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

The unique string that specifies the search job.

", + "smithy.api#notProperty": {} + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#StartSearchResultExportJob": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#StartSearchResultExportJobInput" + }, + "output": { + "target": "com.amazonaws.backupsearch#StartSearchResultExportJobOutput" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ConflictException" + }, + { + "target": "com.amazonaws.backupsearch#ResourceNotFoundException" + }, + { + "target": "com.amazonaws.backupsearch#ServiceQuotaExceededException" + } + ], + "traits": { + "smithy.api#documentation": "

This operations starts a job to export the results \n of search job to a designated S3 bucket.

", + "smithy.api#http": { + "code": 200, + "method": "PUT", + "uri": "/export-search-jobs" + }, + "smithy.api#idempotent": {} + } + }, + "com.amazonaws.backupsearch#StartSearchResultExportJobInput": { + "type": "structure", + "members": { + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

The unique string that specifies the search job.

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

This specification contains a required string of the \n destination bucket; optionally, you can include the \n destination prefix.

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

Include this parameter to allow multiple identical \n calls for idempotency.

\n

A client token is valid for 8 hours after the first \n request that uses it is completed. After this time,\n any request with the same token is treated as a \n new request.

" + } + }, + "Tags": { + "target": "com.amazonaws.backupsearch#TagMap", + "traits": { + "smithy.api#documentation": "

Optional tags to include. A tag is a key-value pair you can use to manage, \n filter, and search for your resources. Allowed characters include UTF-8 letters, \n numbers, spaces, and the following characters: + - = . _ : /.

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

This parameter specifies the role ARN used to start \n the search results export jobs.

" + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#StartSearchResultExportJobOutput": { + "type": "structure", + "members": { + "ExportJobArn": { + "target": "com.amazonaws.backupsearch#ExportJobArn", + "traits": { + "smithy.api#documentation": "

This is the unique ARN (Amazon Resource Name) that \n belongs to the new export job.

" + } + }, + "ExportJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

This is the unique identifier that \n specifies the new export job.

", + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#StopSearchJob": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#StopSearchJobInput" + }, + "output": { + "target": "com.amazonaws.backupsearch#StopSearchJobOutput" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ConflictException" + }, + { + "target": "com.amazonaws.backupsearch#ResourceNotFoundException" + } + ], + "traits": { + "smithy.api#documentation": "

This operations ends a search job.

\n

Only a search job with a status of RUNNING \n can be stopped.

", + "smithy.api#http": { + "code": 200, + "method": "PUT", + "uri": "/search-jobs/{SearchJobIdentifier}/actions/cancel" + }, + "smithy.api#idempotent": {} + } + }, + "com.amazonaws.backupsearch#StopSearchJobInput": { + "type": "structure", + "members": { + "SearchJobIdentifier": { + "target": "com.amazonaws.backupsearch#GenericId", + "traits": { + "smithy.api#documentation": "

The unique string that specifies the search job.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#StopSearchJobOutput": { + "type": "structure", + "members": {}, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#StringCondition": { + "type": "structure", + "members": { + "Value": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The value of the string.

", + "smithy.api#required": {} + } + }, + "Operator": { + "target": "com.amazonaws.backupsearch#StringConditionOperator", + "traits": { + "smithy.api#default": "EQUALS_TO", + "smithy.api#documentation": "

A string that defines what values will be \n returned.

\n

If this is included, avoid combinations of \n operators that will return all possible values. \n For example, including both EQUALS_TO \n and NOT_EQUALS_TO with a value of 4 \n will return all values.

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

This contains the value of the string and can contain \n one or more operators.

" + } + }, + "com.amazonaws.backupsearch#StringConditionList": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#StringCondition" + }, + "traits": { + "smithy.api#length": { + "min": 1, + "max": 10 + } + } + }, + "com.amazonaws.backupsearch#StringConditionOperator": { + "type": "enum", + "members": { + "EQUALS_TO": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "EQUALS_TO" + } + }, + "NOT_EQUALS_TO": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "NOT_EQUALS_TO" + } + }, + "CONTAINS": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "CONTAINS" + } + }, + "DOES_NOT_CONTAIN": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "DOES_NOT_CONTAIN" + } + }, + "BEGINS_WITH": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "BEGINS_WITH" + } + }, + "ENDS_WITH": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "ENDS_WITH" + } + }, + "DOES_NOT_BEGIN_WITH": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "DOES_NOT_BEGIN_WITH" + } + }, + "DOES_NOT_END_WITH": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "DOES_NOT_END_WITH" + } + } + } + }, + "com.amazonaws.backupsearch#TagKeys": { + "type": "list", + "member": { + "target": "smithy.api#String" + } + }, + "com.amazonaws.backupsearch#TagMap": { + "type": "map", + "key": { + "target": "smithy.api#String" + }, + "value": { + "target": "smithy.api#String" + }, + "traits": { + "smithy.api#sparse": {} + } + }, + "com.amazonaws.backupsearch#TagResource": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#TagResourceRequest" + }, + "output": { + "target": "com.amazonaws.backupsearch#TagResourceResponse" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ResourceNotFoundException" + } + ], + "traits": { + "smithy.api#documentation": "

This operation puts tags on the resource you indicate.

", + "smithy.api#http": { + "uri": "/tags/{ResourceArn}", + "method": "POST" + }, + "smithy.api#idempotent": {} + } + }, + "com.amazonaws.backupsearch#TagResourceRequest": { + "type": "structure", + "members": { + "ResourceArn": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The Amazon Resource Name (ARN) that uniquely identifies \n the resource.

\n

This is the resource that will have the indicated tags.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + }, + "Tags": { + "target": "com.amazonaws.backupsearch#TagMap", + "traits": { + "smithy.api#documentation": "

Required tags to include. A tag is a key-value pair you can use to manage, \n filter, and search for your resources. Allowed characters include UTF-8 letters, \n numbers, spaces, and the following characters: + - = . _ : /.

", + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#TagResourceResponse": { + "type": "structure", + "members": {}, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#ThrottlingException": { + "type": "structure", + "members": { + "message": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

Request was unsuccessful due to request throttling.

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

This is the code unique to the originating service.

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

This is the code unique to the originating service with the quota.

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

Retry the call after number of seconds.

", + "smithy.api#httpHeader": "Retry-After" + } + } + }, + "traits": { + "smithy.api#documentation": "

The request was denied due to request throttling.

", + "smithy.api#error": "client", + "smithy.api#httpError": 429, + "smithy.api#retryable": { + "throttling": true + } + } + }, + "com.amazonaws.backupsearch#TimeCondition": { + "type": "structure", + "members": { + "Value": { + "target": "smithy.api#Timestamp", + "traits": { + "smithy.api#documentation": "

This is the timestamp value of the time condition.

", + "smithy.api#required": {} + } + }, + "Operator": { + "target": "com.amazonaws.backupsearch#TimeConditionOperator", + "traits": { + "smithy.api#default": "EQUALS_TO", + "smithy.api#documentation": "

A string that defines what values will be \n returned.

\n

If this is included, avoid combinations of \n operators that will return all possible values. \n For example, including both EQUALS_TO \n and NOT_EQUALS_TO with a value of 4 \n will return all values.

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

A time condition denotes a creation time, last modification time, \n or other time.

" + } + }, + "com.amazonaws.backupsearch#TimeConditionList": { + "type": "list", + "member": { + "target": "com.amazonaws.backupsearch#TimeCondition" + }, + "traits": { + "smithy.api#length": { + "min": 1, + "max": 10 + } + } + }, + "com.amazonaws.backupsearch#TimeConditionOperator": { + "type": "enum", + "members": { + "EQUALS_TO": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "EQUALS_TO" + } + }, + "NOT_EQUALS_TO": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "NOT_EQUALS_TO" + } + }, + "LESS_THAN_EQUAL_TO": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "LESS_THAN_EQUAL_TO" + } + }, + "GREATER_THAN_EQUAL_TO": { + "target": "smithy.api#Unit", + "traits": { + "smithy.api#enumValue": "GREATER_THAN_EQUAL_TO" + } + } + } + }, + "com.amazonaws.backupsearch#UntagResource": { + "type": "operation", + "input": { + "target": "com.amazonaws.backupsearch#UntagResourceRequest" + }, + "output": { + "target": "com.amazonaws.backupsearch#UntagResourceResponse" + }, + "errors": [ + { + "target": "com.amazonaws.backupsearch#ResourceNotFoundException" + } + ], + "traits": { + "smithy.api#documentation": "

This operation removes tags from the specified resource.

", + "smithy.api#http": { + "uri": "/tags/{ResourceArn}", + "method": "DELETE" + }, + "smithy.api#idempotent": {} + } + }, + "com.amazonaws.backupsearch#UntagResourceRequest": { + "type": "structure", + "members": { + "ResourceArn": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The Amazon Resource Name (ARN) that uniquely identifies \n the resource where you want to remove tags.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + }, + "TagKeys": { + "target": "com.amazonaws.backupsearch#TagKeys", + "traits": { + "smithy.api#documentation": "

This required parameter contains the tag keys you \n want to remove from the source.

", + "smithy.api#httpQuery": "tagKeys", + "smithy.api#required": {} + } + } + }, + "traits": { + "smithy.api#input": {} + } + }, + "com.amazonaws.backupsearch#UntagResourceResponse": { + "type": "structure", + "members": {}, + "traits": { + "smithy.api#output": {} + } + }, + "com.amazonaws.backupsearch#ValidationException": { + "type": "structure", + "members": { + "message": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The input fails to satisfy the constraints specified by an Amazon service.

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

The input fails to satisfy the constraints specified by a service.

", + "smithy.api#error": "client", + "smithy.api#httpError": 400 + } + } + } +}