diff --git a/.eslintrc b/.eslintrc
new file mode 100644
index 0000000..5a80290
--- /dev/null
+++ b/.eslintrc
@@ -0,0 +1,3 @@
+{
+ "extends": "@bifravst/eslint-config-typescript"
+}
diff --git a/.github/workflows/test-and-release.yaml b/.github/workflows/test-and-release.yaml
new file mode 100644
index 0000000..6e4fb62
--- /dev/null
+++ b/.github/workflows/test-and-release.yaml
@@ -0,0 +1,29 @@
+name: Test and Release
+
+on: push
+
+env:
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+
+jobs:
+ tests:
+ runs-on: ubuntu-latest
+
+ steps:
+ - uses: actions/checkout@v2
+ - uses: actions/setup-node@v2
+ with:
+ node-version: "12.x"
+ - name: Keep npm cache around to speed up installs
+ uses: actions/cache@v2
+ with:
+ path: ~/.npm
+ key: ${{ runner.OS }}-build-${{ hashFiles('**/package-lock.json') }}
+ - run: npm ci --no-audit
+ - run: npx tsc
+ - run: npm run build
+ - name: Semantic release
+ continue-on-error: true
+ run: |
+ npm i --no-save semantic-release
+ npx semantic-release
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..ef5c31f
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,4 @@
+node_modules/
+dist/
+build/*
+!build/index.js
\ No newline at end of file
diff --git a/.prettierignore b/.prettierignore
new file mode 100644
index 0000000..3ad4c84
--- /dev/null
+++ b/.prettierignore
@@ -0,0 +1,2 @@
+dist/
+package-lock.json
diff --git a/.prettierrc.js b/.prettierrc.js
new file mode 100644
index 0000000..ff901ec
--- /dev/null
+++ b/.prettierrc.js
@@ -0,0 +1,3 @@
+module.exports = {
+ ...require('@bifravst/code-style/.prettierrc'),
+}
diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md
new file mode 100644
index 0000000..ca4ba37
--- /dev/null
+++ b/CODE_OF_CONDUCT.md
@@ -0,0 +1 @@
+See https://github.com/bifravst/bifravst/blob/saga/CODE_OF_CONDUCT.md
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 0000000..21880d9
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,29 @@
+BSD 3-Clause License
+
+Copyright (c) 2019-2021, Nordic Semiconductor ASA | nordicsemi.no
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+1. Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+
+2. Redistributions in binary form must reproduce the above copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+
+3. Neither the name of the copyright holder nor the names of its
+ contributors may be used to endorse or promote products derived from
+ this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..89184e8
--- /dev/null
+++ b/README.md
@@ -0,0 +1,14 @@
+# Firmware CI feature runner GitHub action for AWS
+
+[![GitHub Actions](https://github.com/bifravst/firmware-ci-feature-runner-action-aws/workflows/Test%20and%20Release/badge.svg)](https://github.com/bifravst/firmware-ci-feature-runner-action-aws/actions)
+[![Known Vulnerabilities](https://snyk.io/test/github/bifravst/firmware-ci-feature-runner-action-aws/badge.svg)](https://snyk.io/test/github/bifravst/firmware-ci-feature-runner-action-aws)
+[![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)
+[![Renovate](https://img.shields.io/badge/renovate-enabled-brightgreen.svg)](https://renovatebot.com)
+[![Mergify Status](https://img.shields.io/endpoint.svg?url=https://dashboard.mergify.io/badges/bifravst/firmware-ci-feature-runner-action-aws&style=flat)](https://mergify.io)
+[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg)](http://commitizen.github.io/cz-cli/)
+[![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg)](https://github.com/prettier/prettier/)
+[![ESLint: TypeScript](https://img.shields.io/badge/ESLint-TypeScript-blue.svg)](https://github.com/typescript-eslint/typescript-eslint)
+
+Uses
+[`@bifravst/e2e-bdd-test-runner`](https://github.com/bifravst/e2e-bdd-test-runner)
+to run features files of a firmware.
diff --git a/action.yml b/action.yml
new file mode 100644
index 0000000..89af8da
--- /dev/null
+++ b/action.yml
@@ -0,0 +1,36 @@
+name: "Firmware CI feature runner"
+description:
+ "Uses @bifravst/e2e-bdd-test-runner to run features files of a firmware."
+inputs:
+ job id:
+ description: "The ID of the job"
+ required: true
+ app version:
+ description:
+ "The version string to use for the app. This is used with the FOTA test."
+ required: true
+ aws access key id:
+ description: "Access Key ID for the Firmware CI Runner"
+ required: true
+ aws secret access key:
+ description: "Secret Access Key for the Firmware CI Runner"
+ required: true
+ aws region:
+ description: "AWS region to use"
+ required: false
+ default: us-west-1
+ broker hostname:
+ description: "AWS IoT broker hostname to use"
+ required: true
+ stack name:
+ description: "Stack name of the cloud backend to use"
+ required: false
+ default: bifravst
+ feature dir:
+ description: "Location of the feature files"
+ required: false
+ default: features
+
+runs:
+ using: "node12"
+ main: "build/index.js"
diff --git a/build/index.js b/build/index.js
new file mode 100644
index 0000000..bb5d227
--- /dev/null
+++ b/build/index.js
@@ -0,0 +1,282679 @@
+module.exports =
+/******/ (() => { // webpackBootstrap
+/******/ var __webpack_modules__ = ({
+
+/***/ 51194:
+/***/ ((module) => {
+
+"use strict";
+module.exports = JSON.parse("{\"name\":\"@aws-sdk/client-cloudformation\",\"description\":\"AWS SDK for JavaScript Cloudformation Client for Node.js, Browser and React Native\",\"version\":\"3.3.0\",\"scripts\":{\"clean\":\"yarn remove-definitions && yarn remove-dist && yarn remove-documentation\",\"build-documentation\":\"yarn remove-documentation && typedoc ./\",\"prepublishOnly\":\"yarn build\",\"pretest\":\"yarn build:cjs\",\"remove-definitions\":\"rimraf ./types\",\"remove-dist\":\"rimraf ./dist\",\"remove-documentation\":\"rimraf ./docs\",\"test\":\"exit 0\",\"build:cjs\":\"tsc -p tsconfig.json\",\"build:es\":\"tsc -p tsconfig.es.json\",\"build\":\"yarn build:cjs && yarn build:es\"},\"main\":\"./dist/cjs/index.js\",\"types\":\"./types/index.d.ts\",\"module\":\"./dist/es/index.js\",\"browser\":{\"./runtimeConfig\":\"./runtimeConfig.browser\"},\"react-native\":{\"./runtimeConfig\":\"./runtimeConfig.native\"},\"sideEffects\":false,\"dependencies\":{\"@aws-crypto/sha256-browser\":\"^1.0.0\",\"@aws-crypto/sha256-js\":\"^1.0.0\",\"@aws-sdk/config-resolver\":\"3.3.0\",\"@aws-sdk/credential-provider-node\":\"3.3.0\",\"@aws-sdk/fetch-http-handler\":\"3.3.0\",\"@aws-sdk/hash-node\":\"3.3.0\",\"@aws-sdk/invalid-dependency\":\"3.3.0\",\"@aws-sdk/middleware-content-length\":\"3.3.0\",\"@aws-sdk/middleware-host-header\":\"3.3.0\",\"@aws-sdk/middleware-logger\":\"3.3.0\",\"@aws-sdk/middleware-retry\":\"3.3.0\",\"@aws-sdk/middleware-serde\":\"3.3.0\",\"@aws-sdk/middleware-signing\":\"3.3.0\",\"@aws-sdk/middleware-stack\":\"3.1.0\",\"@aws-sdk/middleware-user-agent\":\"3.3.0\",\"@aws-sdk/node-config-provider\":\"3.3.0\",\"@aws-sdk/node-http-handler\":\"3.3.0\",\"@aws-sdk/protocol-http\":\"3.3.0\",\"@aws-sdk/smithy-client\":\"3.3.0\",\"@aws-sdk/types\":\"3.1.0\",\"@aws-sdk/url-parser\":\"3.3.0\",\"@aws-sdk/url-parser-native\":\"3.3.0\",\"@aws-sdk/util-base64-browser\":\"3.1.0\",\"@aws-sdk/util-base64-node\":\"3.1.0\",\"@aws-sdk/util-body-length-browser\":\"3.1.0\",\"@aws-sdk/util-body-length-node\":\"3.1.0\",\"@aws-sdk/util-user-agent-browser\":\"3.3.0\",\"@aws-sdk/util-user-agent-node\":\"3.3.0\",\"@aws-sdk/util-utf8-browser\":\"3.1.0\",\"@aws-sdk/util-utf8-node\":\"3.1.0\",\"@aws-sdk/util-waiter\":\"3.3.0\",\"fast-xml-parser\":\"^3.16.0\",\"tslib\":\"^2.0.0\",\"uuid\":\"^3.0.0\"},\"devDependencies\":{\"@aws-sdk/client-documentation-generator\":\"3.1.0\",\"@types/node\":\"^12.7.5\",\"@types/uuid\":\"^3.0.0\",\"jest\":\"^26.1.0\",\"rimraf\":\"^3.0.0\",\"typedoc\":\"^0.19.2\",\"typescript\":\"~4.1.2\"},\"engines\":{\"node\":\">=10.0.0\"},\"author\":{\"name\":\"AWS SDK for JavaScript Team\",\"url\":\"https://aws.amazon.com/javascript/\"},\"license\":\"Apache-2.0\",\"homepage\":\"https://github.com/aws/aws-sdk-js-v3/tree/master/clients/client-cloudformation\",\"repository\":{\"type\":\"git\",\"url\":\"https://github.com/aws/aws-sdk-js-v3.git\",\"directory\":\"clients/client-cloudformation\"}}");
+
+/***/ }),
+
+/***/ 48166:
+/***/ ((module) => {
+
+"use strict";
+module.exports = JSON.parse("{\"name\":\"@aws-sdk/client-cognito-identity-provider\",\"description\":\"AWS SDK for JavaScript Cognito Identity Provider Client for Node.js, Browser and React Native\",\"version\":\"3.3.0\",\"scripts\":{\"clean\":\"yarn remove-definitions && yarn remove-dist && yarn remove-documentation\",\"build-documentation\":\"yarn remove-documentation && typedoc ./\",\"prepublishOnly\":\"yarn build\",\"pretest\":\"yarn build:cjs\",\"remove-definitions\":\"rimraf ./types\",\"remove-dist\":\"rimraf ./dist\",\"remove-documentation\":\"rimraf ./docs\",\"test\":\"exit 0\",\"build:cjs\":\"tsc -p tsconfig.json\",\"build:es\":\"tsc -p tsconfig.es.json\",\"build\":\"yarn build:cjs && yarn build:es\"},\"main\":\"./dist/cjs/index.js\",\"types\":\"./types/index.d.ts\",\"module\":\"./dist/es/index.js\",\"browser\":{\"./runtimeConfig\":\"./runtimeConfig.browser\"},\"react-native\":{\"./runtimeConfig\":\"./runtimeConfig.native\"},\"sideEffects\":false,\"dependencies\":{\"@aws-crypto/sha256-browser\":\"^1.0.0\",\"@aws-crypto/sha256-js\":\"^1.0.0\",\"@aws-sdk/config-resolver\":\"3.3.0\",\"@aws-sdk/credential-provider-node\":\"3.3.0\",\"@aws-sdk/fetch-http-handler\":\"3.3.0\",\"@aws-sdk/hash-node\":\"3.3.0\",\"@aws-sdk/invalid-dependency\":\"3.3.0\",\"@aws-sdk/middleware-content-length\":\"3.3.0\",\"@aws-sdk/middleware-host-header\":\"3.3.0\",\"@aws-sdk/middleware-logger\":\"3.3.0\",\"@aws-sdk/middleware-retry\":\"3.3.0\",\"@aws-sdk/middleware-serde\":\"3.3.0\",\"@aws-sdk/middleware-signing\":\"3.3.0\",\"@aws-sdk/middleware-stack\":\"3.1.0\",\"@aws-sdk/middleware-user-agent\":\"3.3.0\",\"@aws-sdk/node-config-provider\":\"3.3.0\",\"@aws-sdk/node-http-handler\":\"3.3.0\",\"@aws-sdk/protocol-http\":\"3.3.0\",\"@aws-sdk/smithy-client\":\"3.3.0\",\"@aws-sdk/types\":\"3.1.0\",\"@aws-sdk/url-parser\":\"3.3.0\",\"@aws-sdk/url-parser-native\":\"3.3.0\",\"@aws-sdk/util-base64-browser\":\"3.1.0\",\"@aws-sdk/util-base64-node\":\"3.1.0\",\"@aws-sdk/util-body-length-browser\":\"3.1.0\",\"@aws-sdk/util-body-length-node\":\"3.1.0\",\"@aws-sdk/util-user-agent-browser\":\"3.3.0\",\"@aws-sdk/util-user-agent-node\":\"3.3.0\",\"@aws-sdk/util-utf8-browser\":\"3.1.0\",\"@aws-sdk/util-utf8-node\":\"3.1.0\",\"tslib\":\"^2.0.0\"},\"devDependencies\":{\"@aws-sdk/client-documentation-generator\":\"3.1.0\",\"@types/node\":\"^12.7.5\",\"jest\":\"^26.1.0\",\"rimraf\":\"^3.0.0\",\"typedoc\":\"^0.19.2\",\"typescript\":\"~4.1.2\"},\"engines\":{\"node\":\">=10.0.0\"},\"author\":{\"name\":\"AWS SDK for JavaScript Team\",\"url\":\"https://aws.amazon.com/javascript/\"},\"license\":\"Apache-2.0\",\"homepage\":\"https://github.com/aws/aws-sdk-js-v3/tree/master/clients/client-cognito-identity-provider\",\"repository\":{\"type\":\"git\",\"url\":\"https://github.com/aws/aws-sdk-js-v3.git\",\"directory\":\"clients/client-cognito-identity-provider\"}}");
+
+/***/ }),
+
+/***/ 67367:
+/***/ ((module) => {
+
+"use strict";
+module.exports = JSON.parse("{\"name\":\"@aws-sdk/client-cognito-identity\",\"description\":\"AWS SDK for JavaScript Cognito Identity Client for Node.js, Browser and React Native\",\"version\":\"3.3.0\",\"scripts\":{\"clean\":\"yarn remove-definitions && yarn remove-dist && yarn remove-documentation\",\"build-documentation\":\"yarn remove-documentation && typedoc ./\",\"prepublishOnly\":\"yarn build\",\"pretest\":\"yarn build:cjs\",\"remove-definitions\":\"rimraf ./types\",\"remove-dist\":\"rimraf ./dist\",\"remove-documentation\":\"rimraf ./docs\",\"test:unit\":\"mocha **/cjs/**/*.spec.js\",\"test:e2e\":\"mocha **/cjs/**/*.ispec.js && karma start karma.conf.js\",\"test\":\"yarn test:unit\",\"build:cjs\":\"tsc -p tsconfig.json\",\"build:es\":\"tsc -p tsconfig.es.json\",\"build\":\"yarn build:cjs && yarn build:es\"},\"main\":\"./dist/cjs/index.js\",\"types\":\"./types/index.d.ts\",\"module\":\"./dist/es/index.js\",\"browser\":{\"./runtimeConfig\":\"./runtimeConfig.browser\"},\"react-native\":{\"./runtimeConfig\":\"./runtimeConfig.native\"},\"sideEffects\":false,\"dependencies\":{\"@aws-crypto/sha256-browser\":\"^1.0.0\",\"@aws-crypto/sha256-js\":\"^1.0.0\",\"@aws-sdk/config-resolver\":\"3.3.0\",\"@aws-sdk/credential-provider-node\":\"3.3.0\",\"@aws-sdk/fetch-http-handler\":\"3.3.0\",\"@aws-sdk/hash-node\":\"3.3.0\",\"@aws-sdk/invalid-dependency\":\"3.3.0\",\"@aws-sdk/middleware-content-length\":\"3.3.0\",\"@aws-sdk/middleware-host-header\":\"3.3.0\",\"@aws-sdk/middleware-logger\":\"3.3.0\",\"@aws-sdk/middleware-retry\":\"3.3.0\",\"@aws-sdk/middleware-serde\":\"3.3.0\",\"@aws-sdk/middleware-signing\":\"3.3.0\",\"@aws-sdk/middleware-stack\":\"3.1.0\",\"@aws-sdk/middleware-user-agent\":\"3.3.0\",\"@aws-sdk/node-config-provider\":\"3.3.0\",\"@aws-sdk/node-http-handler\":\"3.3.0\",\"@aws-sdk/protocol-http\":\"3.3.0\",\"@aws-sdk/smithy-client\":\"3.3.0\",\"@aws-sdk/types\":\"3.1.0\",\"@aws-sdk/url-parser\":\"3.3.0\",\"@aws-sdk/url-parser-native\":\"3.3.0\",\"@aws-sdk/util-base64-browser\":\"3.1.0\",\"@aws-sdk/util-base64-node\":\"3.1.0\",\"@aws-sdk/util-body-length-browser\":\"3.1.0\",\"@aws-sdk/util-body-length-node\":\"3.1.0\",\"@aws-sdk/util-user-agent-browser\":\"3.3.0\",\"@aws-sdk/util-user-agent-node\":\"3.3.0\",\"@aws-sdk/util-utf8-browser\":\"3.1.0\",\"@aws-sdk/util-utf8-node\":\"3.1.0\",\"tslib\":\"^2.0.0\"},\"devDependencies\":{\"@aws-sdk/client-documentation-generator\":\"3.1.0\",\"@aws-sdk/client-iam\":\"3.3.0\",\"@types/chai\":\"^4.2.11\",\"@types/mocha\":\"^8.0.4\",\"@types/node\":\"^12.7.5\",\"jest\":\"^26.1.0\",\"rimraf\":\"^3.0.0\",\"typedoc\":\"^0.19.2\",\"typescript\":\"~4.1.2\"},\"engines\":{\"node\":\">=10.0.0\"},\"author\":{\"name\":\"AWS SDK for JavaScript Team\",\"url\":\"https://aws.amazon.com/javascript/\"},\"license\":\"Apache-2.0\",\"homepage\":\"https://github.com/aws/aws-sdk-js-v3/tree/master/clients/client-cognito-identity\",\"repository\":{\"type\":\"git\",\"url\":\"https://github.com/aws/aws-sdk-js-v3.git\",\"directory\":\"clients/client-cognito-identity\"}}");
+
+/***/ }),
+
+/***/ 57111:
+/***/ ((module) => {
+
+"use strict";
+module.exports = JSON.parse("{\"name\":\"@aws-sdk/client-iot\",\"description\":\"AWS SDK for JavaScript Iot Client for Node.js, Browser and React Native\",\"version\":\"3.3.0\",\"scripts\":{\"clean\":\"yarn remove-definitions && yarn remove-dist && yarn remove-documentation\",\"build-documentation\":\"yarn remove-documentation && typedoc ./\",\"prepublishOnly\":\"yarn build\",\"pretest\":\"yarn build:cjs\",\"remove-definitions\":\"rimraf ./types\",\"remove-dist\":\"rimraf ./dist\",\"remove-documentation\":\"rimraf ./docs\",\"test\":\"exit 0\",\"build:cjs\":\"tsc -p tsconfig.json\",\"build:es\":\"tsc -p tsconfig.es.json\",\"build\":\"yarn build:cjs && yarn build:es\"},\"main\":\"./dist/cjs/index.js\",\"types\":\"./types/index.d.ts\",\"module\":\"./dist/es/index.js\",\"browser\":{\"./runtimeConfig\":\"./runtimeConfig.browser\"},\"react-native\":{\"./runtimeConfig\":\"./runtimeConfig.native\"},\"sideEffects\":false,\"dependencies\":{\"@aws-crypto/sha256-browser\":\"^1.0.0\",\"@aws-crypto/sha256-js\":\"^1.0.0\",\"@aws-sdk/config-resolver\":\"3.3.0\",\"@aws-sdk/credential-provider-node\":\"3.3.0\",\"@aws-sdk/fetch-http-handler\":\"3.3.0\",\"@aws-sdk/hash-node\":\"3.3.0\",\"@aws-sdk/invalid-dependency\":\"3.3.0\",\"@aws-sdk/middleware-content-length\":\"3.3.0\",\"@aws-sdk/middleware-host-header\":\"3.3.0\",\"@aws-sdk/middleware-logger\":\"3.3.0\",\"@aws-sdk/middleware-retry\":\"3.3.0\",\"@aws-sdk/middleware-serde\":\"3.3.0\",\"@aws-sdk/middleware-signing\":\"3.3.0\",\"@aws-sdk/middleware-stack\":\"3.1.0\",\"@aws-sdk/middleware-user-agent\":\"3.3.0\",\"@aws-sdk/node-config-provider\":\"3.3.0\",\"@aws-sdk/node-http-handler\":\"3.3.0\",\"@aws-sdk/protocol-http\":\"3.3.0\",\"@aws-sdk/smithy-client\":\"3.3.0\",\"@aws-sdk/types\":\"3.1.0\",\"@aws-sdk/url-parser\":\"3.3.0\",\"@aws-sdk/url-parser-native\":\"3.3.0\",\"@aws-sdk/util-base64-browser\":\"3.1.0\",\"@aws-sdk/util-base64-node\":\"3.1.0\",\"@aws-sdk/util-body-length-browser\":\"3.1.0\",\"@aws-sdk/util-body-length-node\":\"3.1.0\",\"@aws-sdk/util-user-agent-browser\":\"3.3.0\",\"@aws-sdk/util-user-agent-node\":\"3.3.0\",\"@aws-sdk/util-utf8-browser\":\"3.1.0\",\"@aws-sdk/util-utf8-node\":\"3.1.0\",\"tslib\":\"^2.0.0\",\"uuid\":\"^3.0.0\"},\"devDependencies\":{\"@aws-sdk/client-documentation-generator\":\"3.1.0\",\"@types/node\":\"^12.7.5\",\"@types/uuid\":\"^3.0.0\",\"jest\":\"^26.1.0\",\"rimraf\":\"^3.0.0\",\"typedoc\":\"^0.19.2\",\"typescript\":\"~4.1.2\"},\"engines\":{\"node\":\">=10.0.0\"},\"author\":{\"name\":\"AWS SDK for JavaScript Team\",\"url\":\"https://aws.amazon.com/javascript/\"},\"license\":\"Apache-2.0\",\"homepage\":\"https://github.com/aws/aws-sdk-js-v3/tree/master/clients/client-iot\",\"repository\":{\"type\":\"git\",\"url\":\"https://github.com/aws/aws-sdk-js-v3.git\",\"directory\":\"clients/client-iot\"}}");
+
+/***/ }),
+
+/***/ 73021:
+/***/ ((module) => {
+
+"use strict";
+module.exports = JSON.parse("{\"name\":\"@aws-sdk/client-sqs\",\"description\":\"AWS SDK for JavaScript Sqs Client for Node.js, Browser and React Native\",\"version\":\"3.3.0\",\"scripts\":{\"clean\":\"yarn remove-definitions && yarn remove-dist && yarn remove-documentation\",\"build-documentation\":\"yarn remove-documentation && typedoc ./\",\"prepublishOnly\":\"yarn build\",\"pretest\":\"yarn build:cjs\",\"remove-definitions\":\"rimraf ./types\",\"remove-dist\":\"rimraf ./dist\",\"remove-documentation\":\"rimraf ./docs\",\"test\":\"exit 0\",\"build:cjs\":\"tsc -p tsconfig.json\",\"build:es\":\"tsc -p tsconfig.es.json\",\"build\":\"yarn build:cjs && yarn build:es\"},\"main\":\"./dist/cjs/index.js\",\"types\":\"./types/index.d.ts\",\"module\":\"./dist/es/index.js\",\"browser\":{\"./runtimeConfig\":\"./runtimeConfig.browser\"},\"react-native\":{\"./runtimeConfig\":\"./runtimeConfig.native\"},\"sideEffects\":false,\"dependencies\":{\"@aws-crypto/sha256-browser\":\"^1.0.0\",\"@aws-crypto/sha256-js\":\"^1.0.0\",\"@aws-sdk/config-resolver\":\"3.3.0\",\"@aws-sdk/credential-provider-node\":\"3.3.0\",\"@aws-sdk/fetch-http-handler\":\"3.3.0\",\"@aws-sdk/hash-node\":\"3.3.0\",\"@aws-sdk/invalid-dependency\":\"3.3.0\",\"@aws-sdk/md5-js\":\"3.3.0\",\"@aws-sdk/middleware-content-length\":\"3.3.0\",\"@aws-sdk/middleware-host-header\":\"3.3.0\",\"@aws-sdk/middleware-logger\":\"3.3.0\",\"@aws-sdk/middleware-retry\":\"3.3.0\",\"@aws-sdk/middleware-sdk-sqs\":\"3.3.0\",\"@aws-sdk/middleware-serde\":\"3.3.0\",\"@aws-sdk/middleware-signing\":\"3.3.0\",\"@aws-sdk/middleware-stack\":\"3.1.0\",\"@aws-sdk/middleware-user-agent\":\"3.3.0\",\"@aws-sdk/node-config-provider\":\"3.3.0\",\"@aws-sdk/node-http-handler\":\"3.3.0\",\"@aws-sdk/protocol-http\":\"3.3.0\",\"@aws-sdk/smithy-client\":\"3.3.0\",\"@aws-sdk/types\":\"3.1.0\",\"@aws-sdk/url-parser\":\"3.3.0\",\"@aws-sdk/url-parser-native\":\"3.3.0\",\"@aws-sdk/util-base64-browser\":\"3.1.0\",\"@aws-sdk/util-base64-node\":\"3.1.0\",\"@aws-sdk/util-body-length-browser\":\"3.1.0\",\"@aws-sdk/util-body-length-node\":\"3.1.0\",\"@aws-sdk/util-user-agent-browser\":\"3.3.0\",\"@aws-sdk/util-user-agent-node\":\"3.3.0\",\"@aws-sdk/util-utf8-browser\":\"3.1.0\",\"@aws-sdk/util-utf8-node\":\"3.1.0\",\"fast-xml-parser\":\"^3.16.0\",\"tslib\":\"^2.0.0\"},\"devDependencies\":{\"@aws-sdk/client-documentation-generator\":\"3.1.0\",\"@types/node\":\"^12.7.5\",\"jest\":\"^26.1.0\",\"rimraf\":\"^3.0.0\",\"typedoc\":\"^0.19.2\",\"typescript\":\"~4.1.2\"},\"engines\":{\"node\":\">=10.0.0\"},\"author\":{\"name\":\"AWS SDK for JavaScript Team\",\"url\":\"https://aws.amazon.com/javascript/\"},\"license\":\"Apache-2.0\",\"homepage\":\"https://github.com/aws/aws-sdk-js-v3/tree/master/clients/client-sqs\",\"repository\":{\"type\":\"git\",\"url\":\"https://github.com/aws/aws-sdk-js-v3.git\",\"directory\":\"clients/client-sqs\"}}");
+
+/***/ }),
+
+/***/ 51508:
+/***/ ((module) => {
+
+"use strict";
+module.exports = JSON.parse("{\"name\":\"@aws-sdk/client-sts\",\"description\":\"AWS SDK for JavaScript Sts Client for Node.js, Browser and React Native\",\"version\":\"3.3.0\",\"scripts\":{\"clean\":\"yarn remove-definitions && yarn remove-dist && yarn remove-documentation\",\"build-documentation\":\"yarn remove-documentation && typedoc ./\",\"prepublishOnly\":\"yarn build\",\"pretest\":\"yarn build:cjs\",\"remove-definitions\":\"rimraf ./types\",\"remove-dist\":\"rimraf ./dist\",\"remove-documentation\":\"rimraf ./docs\",\"test\":\"exit 0\",\"build:cjs\":\"tsc -p tsconfig.json\",\"build:es\":\"tsc -p tsconfig.es.json\",\"build\":\"yarn build:cjs && yarn build:es\"},\"main\":\"./dist/cjs/index.js\",\"types\":\"./types/index.d.ts\",\"module\":\"./dist/es/index.js\",\"browser\":{\"./runtimeConfig\":\"./runtimeConfig.browser\"},\"react-native\":{\"./runtimeConfig\":\"./runtimeConfig.native\"},\"sideEffects\":false,\"dependencies\":{\"@aws-crypto/sha256-browser\":\"^1.0.0\",\"@aws-crypto/sha256-js\":\"^1.0.0\",\"@aws-sdk/config-resolver\":\"3.3.0\",\"@aws-sdk/credential-provider-node\":\"3.3.0\",\"@aws-sdk/fetch-http-handler\":\"3.3.0\",\"@aws-sdk/hash-node\":\"3.3.0\",\"@aws-sdk/invalid-dependency\":\"3.3.0\",\"@aws-sdk/middleware-content-length\":\"3.3.0\",\"@aws-sdk/middleware-host-header\":\"3.3.0\",\"@aws-sdk/middleware-logger\":\"3.3.0\",\"@aws-sdk/middleware-retry\":\"3.3.0\",\"@aws-sdk/middleware-serde\":\"3.3.0\",\"@aws-sdk/middleware-signing\":\"3.3.0\",\"@aws-sdk/middleware-stack\":\"3.1.0\",\"@aws-sdk/middleware-user-agent\":\"3.3.0\",\"@aws-sdk/node-config-provider\":\"3.3.0\",\"@aws-sdk/node-http-handler\":\"3.3.0\",\"@aws-sdk/protocol-http\":\"3.3.0\",\"@aws-sdk/smithy-client\":\"3.3.0\",\"@aws-sdk/types\":\"3.1.0\",\"@aws-sdk/url-parser\":\"3.3.0\",\"@aws-sdk/url-parser-native\":\"3.3.0\",\"@aws-sdk/util-base64-browser\":\"3.1.0\",\"@aws-sdk/util-base64-node\":\"3.1.0\",\"@aws-sdk/util-body-length-browser\":\"3.1.0\",\"@aws-sdk/util-body-length-node\":\"3.1.0\",\"@aws-sdk/util-user-agent-browser\":\"3.3.0\",\"@aws-sdk/util-user-agent-node\":\"3.3.0\",\"@aws-sdk/util-utf8-browser\":\"3.1.0\",\"@aws-sdk/util-utf8-node\":\"3.1.0\",\"fast-xml-parser\":\"^3.16.0\",\"tslib\":\"^2.0.0\"},\"devDependencies\":{\"@aws-sdk/client-documentation-generator\":\"3.1.0\",\"@types/node\":\"^12.7.5\",\"jest\":\"^26.1.0\",\"rimraf\":\"^3.0.0\",\"typedoc\":\"^0.19.2\",\"typescript\":\"~4.1.2\"},\"engines\":{\"node\":\">=10.0.0\"},\"author\":{\"name\":\"AWS SDK for JavaScript Team\",\"url\":\"https://aws.amazon.com/javascript/\"},\"license\":\"Apache-2.0\",\"homepage\":\"https://github.com/aws/aws-sdk-js-v3/tree/master/clients/client-sts\",\"repository\":{\"type\":\"git\",\"url\":\"https://github.com/aws/aws-sdk-js-v3.git\",\"directory\":\"clients/client-sts\"}}");
+
+/***/ }),
+
+/***/ 87351:
+/***/ (function(__unused_webpack_module, exports, __nccwpck_require__) {
+
+"use strict";
+
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
+ result["default"] = mod;
+ return result;
+};
+Object.defineProperty(exports, "__esModule", ({ value: true }));
+const os = __importStar(__nccwpck_require__(12087));
+const utils_1 = __nccwpck_require__(5278);
+/**
+ * Commands
+ *
+ * Command Format:
+ * ::name key=value,key=value::message
+ *
+ * Examples:
+ * ::warning::This is the message
+ * ::set-env name=MY_VAR::some value
+ */
+function issueCommand(command, properties, message) {
+ const cmd = new Command(command, properties, message);
+ process.stdout.write(cmd.toString() + os.EOL);
+}
+exports.issueCommand = issueCommand;
+function issue(name, message = '') {
+ issueCommand(name, {}, message);
+}
+exports.issue = issue;
+const CMD_STRING = '::';
+class Command {
+ constructor(command, properties, message) {
+ if (!command) {
+ command = 'missing.command';
+ }
+ this.command = command;
+ this.properties = properties;
+ this.message = message;
+ }
+ toString() {
+ let cmdStr = CMD_STRING + this.command;
+ if (this.properties && Object.keys(this.properties).length > 0) {
+ cmdStr += ' ';
+ let first = true;
+ for (const key in this.properties) {
+ if (this.properties.hasOwnProperty(key)) {
+ const val = this.properties[key];
+ if (val) {
+ if (first) {
+ first = false;
+ }
+ else {
+ cmdStr += ',';
+ }
+ cmdStr += `${key}=${escapeProperty(val)}`;
+ }
+ }
+ }
+ }
+ cmdStr += `${CMD_STRING}${escapeData(this.message)}`;
+ return cmdStr;
+ }
+}
+function escapeData(s) {
+ return utils_1.toCommandValue(s)
+ .replace(/%/g, '%25')
+ .replace(/\r/g, '%0D')
+ .replace(/\n/g, '%0A');
+}
+function escapeProperty(s) {
+ return utils_1.toCommandValue(s)
+ .replace(/%/g, '%25')
+ .replace(/\r/g, '%0D')
+ .replace(/\n/g, '%0A')
+ .replace(/:/g, '%3A')
+ .replace(/,/g, '%2C');
+}
+//# sourceMappingURL=command.js.map
+
+/***/ }),
+
+/***/ 42186:
+/***/ (function(__unused_webpack_module, exports, __nccwpck_require__) {
+
+"use strict";
+
+var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
+ return new (P || (P = Promise))(function (resolve, reject) {
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
+ });
+};
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
+ result["default"] = mod;
+ return result;
+};
+Object.defineProperty(exports, "__esModule", ({ value: true }));
+const command_1 = __nccwpck_require__(87351);
+const file_command_1 = __nccwpck_require__(717);
+const utils_1 = __nccwpck_require__(5278);
+const os = __importStar(__nccwpck_require__(12087));
+const path = __importStar(__nccwpck_require__(85622));
+/**
+ * The code to exit an action
+ */
+var ExitCode;
+(function (ExitCode) {
+ /**
+ * A code indicating that the action was successful
+ */
+ ExitCode[ExitCode["Success"] = 0] = "Success";
+ /**
+ * A code indicating that the action was a failure
+ */
+ ExitCode[ExitCode["Failure"] = 1] = "Failure";
+})(ExitCode = exports.ExitCode || (exports.ExitCode = {}));
+//-----------------------------------------------------------------------
+// Variables
+//-----------------------------------------------------------------------
+/**
+ * Sets env variable for this action and future actions in the job
+ * @param name the name of the variable to set
+ * @param val the value of the variable. Non-string values will be converted to a string via JSON.stringify
+ */
+// eslint-disable-next-line @typescript-eslint/no-explicit-any
+function exportVariable(name, val) {
+ const convertedVal = utils_1.toCommandValue(val);
+ process.env[name] = convertedVal;
+ const filePath = process.env['GITHUB_ENV'] || '';
+ if (filePath) {
+ const delimiter = '_GitHubActionsFileCommandDelimeter_';
+ const commandValue = `${name}<<${delimiter}${os.EOL}${convertedVal}${os.EOL}${delimiter}`;
+ file_command_1.issueCommand('ENV', commandValue);
+ }
+ else {
+ command_1.issueCommand('set-env', { name }, convertedVal);
+ }
+}
+exports.exportVariable = exportVariable;
+/**
+ * Registers a secret which will get masked from logs
+ * @param secret value of the secret
+ */
+function setSecret(secret) {
+ command_1.issueCommand('add-mask', {}, secret);
+}
+exports.setSecret = setSecret;
+/**
+ * Prepends inputPath to the PATH (for this action and future actions)
+ * @param inputPath
+ */
+function addPath(inputPath) {
+ const filePath = process.env['GITHUB_PATH'] || '';
+ if (filePath) {
+ file_command_1.issueCommand('PATH', inputPath);
+ }
+ else {
+ command_1.issueCommand('add-path', {}, inputPath);
+ }
+ process.env['PATH'] = `${inputPath}${path.delimiter}${process.env['PATH']}`;
+}
+exports.addPath = addPath;
+/**
+ * Gets the value of an input. The value is also trimmed.
+ *
+ * @param name name of the input to get
+ * @param options optional. See InputOptions.
+ * @returns string
+ */
+function getInput(name, options) {
+ const val = process.env[`INPUT_${name.replace(/ /g, '_').toUpperCase()}`] || '';
+ if (options && options.required && !val) {
+ throw new Error(`Input required and not supplied: ${name}`);
+ }
+ return val.trim();
+}
+exports.getInput = getInput;
+/**
+ * Sets the value of an output.
+ *
+ * @param name name of the output to set
+ * @param value value to store. Non-string values will be converted to a string via JSON.stringify
+ */
+// eslint-disable-next-line @typescript-eslint/no-explicit-any
+function setOutput(name, value) {
+ command_1.issueCommand('set-output', { name }, value);
+}
+exports.setOutput = setOutput;
+/**
+ * Enables or disables the echoing of commands into stdout for the rest of the step.
+ * Echoing is disabled by default if ACTIONS_STEP_DEBUG is not set.
+ *
+ */
+function setCommandEcho(enabled) {
+ command_1.issue('echo', enabled ? 'on' : 'off');
+}
+exports.setCommandEcho = setCommandEcho;
+//-----------------------------------------------------------------------
+// Results
+//-----------------------------------------------------------------------
+/**
+ * Sets the action status to failed.
+ * When the action exits it will be with an exit code of 1
+ * @param message add error issue message
+ */
+function setFailed(message) {
+ process.exitCode = ExitCode.Failure;
+ error(message);
+}
+exports.setFailed = setFailed;
+//-----------------------------------------------------------------------
+// Logging Commands
+//-----------------------------------------------------------------------
+/**
+ * Gets whether Actions Step Debug is on or not
+ */
+function isDebug() {
+ return process.env['RUNNER_DEBUG'] === '1';
+}
+exports.isDebug = isDebug;
+/**
+ * Writes debug message to user log
+ * @param message debug message
+ */
+function debug(message) {
+ command_1.issueCommand('debug', {}, message);
+}
+exports.debug = debug;
+/**
+ * Adds an error issue
+ * @param message error issue message. Errors will be converted to string via toString()
+ */
+function error(message) {
+ command_1.issue('error', message instanceof Error ? message.toString() : message);
+}
+exports.error = error;
+/**
+ * Adds an warning issue
+ * @param message warning issue message. Errors will be converted to string via toString()
+ */
+function warning(message) {
+ command_1.issue('warning', message instanceof Error ? message.toString() : message);
+}
+exports.warning = warning;
+/**
+ * Writes info to log with console.log.
+ * @param message info message
+ */
+function info(message) {
+ process.stdout.write(message + os.EOL);
+}
+exports.info = info;
+/**
+ * Begin an output group.
+ *
+ * Output until the next `groupEnd` will be foldable in this group
+ *
+ * @param name The name of the output group
+ */
+function startGroup(name) {
+ command_1.issue('group', name);
+}
+exports.startGroup = startGroup;
+/**
+ * End an output group.
+ */
+function endGroup() {
+ command_1.issue('endgroup');
+}
+exports.endGroup = endGroup;
+/**
+ * Wrap an asynchronous function call in a group.
+ *
+ * Returns the same type as the function itself.
+ *
+ * @param name The name of the group
+ * @param fn The function to wrap in the group
+ */
+function group(name, fn) {
+ return __awaiter(this, void 0, void 0, function* () {
+ startGroup(name);
+ let result;
+ try {
+ result = yield fn();
+ }
+ finally {
+ endGroup();
+ }
+ return result;
+ });
+}
+exports.group = group;
+//-----------------------------------------------------------------------
+// Wrapper action state
+//-----------------------------------------------------------------------
+/**
+ * Saves state for current action, the state can only be retrieved by this action's post job execution.
+ *
+ * @param name name of the state to store
+ * @param value value to store. Non-string values will be converted to a string via JSON.stringify
+ */
+// eslint-disable-next-line @typescript-eslint/no-explicit-any
+function saveState(name, value) {
+ command_1.issueCommand('save-state', { name }, value);
+}
+exports.saveState = saveState;
+/**
+ * Gets the value of an state set by this action's main execution.
+ *
+ * @param name name of the state to get
+ * @returns string
+ */
+function getState(name) {
+ return process.env[`STATE_${name}`] || '';
+}
+exports.getState = getState;
+//# sourceMappingURL=core.js.map
+
+/***/ }),
+
+/***/ 717:
+/***/ (function(__unused_webpack_module, exports, __nccwpck_require__) {
+
+"use strict";
+
+// For internal use, subject to change.
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
+ result["default"] = mod;
+ return result;
+};
+Object.defineProperty(exports, "__esModule", ({ value: true }));
+// We use any as a valid input type
+/* eslint-disable @typescript-eslint/no-explicit-any */
+const fs = __importStar(__nccwpck_require__(35747));
+const os = __importStar(__nccwpck_require__(12087));
+const utils_1 = __nccwpck_require__(5278);
+function issueCommand(command, message) {
+ const filePath = process.env[`GITHUB_${command}`];
+ if (!filePath) {
+ throw new Error(`Unable to find environment variable for file command ${command}`);
+ }
+ if (!fs.existsSync(filePath)) {
+ throw new Error(`Missing file at path: ${filePath}`);
+ }
+ fs.appendFileSync(filePath, `${utils_1.toCommandValue(message)}${os.EOL}`, {
+ encoding: 'utf8'
+ });
+}
+exports.issueCommand = issueCommand;
+//# sourceMappingURL=file-command.js.map
+
+/***/ }),
+
+/***/ 5278:
+/***/ ((__unused_webpack_module, exports) => {
+
+"use strict";
+
+// We use any as a valid input type
+/* eslint-disable @typescript-eslint/no-explicit-any */
+Object.defineProperty(exports, "__esModule", ({ value: true }));
+/**
+ * Sanitizes an input into a string so it can be passed into issueCommand safely
+ * @param input input to sanitize into a string
+ */
+function toCommandValue(input) {
+ if (input === null || input === undefined) {
+ return '';
+ }
+ else if (typeof input === 'string' || input instanceof String) {
+ return input;
+ }
+ return JSON.stringify(input);
+}
+exports.toCommandValue = toCommandValue;
+//# sourceMappingURL=utils.js.map
+
+/***/ }),
+
+/***/ 44074:
+/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
+
+"use strict";
+
+Object.defineProperty(exports, "__esModule", ({ value: true }));
+exports.CloudFormation = void 0;
+const CloudFormationClient_1 = __nccwpck_require__(25838);
+const CancelUpdateStackCommand_1 = __nccwpck_require__(78006);
+const ContinueUpdateRollbackCommand_1 = __nccwpck_require__(31828);
+const CreateChangeSetCommand_1 = __nccwpck_require__(87501);
+const CreateStackCommand_1 = __nccwpck_require__(42935);
+const CreateStackInstancesCommand_1 = __nccwpck_require__(53977);
+const CreateStackSetCommand_1 = __nccwpck_require__(94602);
+const DeleteChangeSetCommand_1 = __nccwpck_require__(8147);
+const DeleteStackCommand_1 = __nccwpck_require__(93619);
+const DeleteStackInstancesCommand_1 = __nccwpck_require__(96629);
+const DeleteStackSetCommand_1 = __nccwpck_require__(67548);
+const DeregisterTypeCommand_1 = __nccwpck_require__(38218);
+const DescribeAccountLimitsCommand_1 = __nccwpck_require__(67719);
+const DescribeChangeSetCommand_1 = __nccwpck_require__(433);
+const DescribeStackDriftDetectionStatusCommand_1 = __nccwpck_require__(30462);
+const DescribeStackEventsCommand_1 = __nccwpck_require__(99902);
+const DescribeStackInstanceCommand_1 = __nccwpck_require__(95705);
+const DescribeStackResourceCommand_1 = __nccwpck_require__(15305);
+const DescribeStackResourceDriftsCommand_1 = __nccwpck_require__(25794);
+const DescribeStackResourcesCommand_1 = __nccwpck_require__(28792);
+const DescribeStackSetCommand_1 = __nccwpck_require__(18050);
+const DescribeStackSetOperationCommand_1 = __nccwpck_require__(12422);
+const DescribeStacksCommand_1 = __nccwpck_require__(87840);
+const DescribeTypeCommand_1 = __nccwpck_require__(41499);
+const DescribeTypeRegistrationCommand_1 = __nccwpck_require__(39500);
+const DetectStackDriftCommand_1 = __nccwpck_require__(78948);
+const DetectStackResourceDriftCommand_1 = __nccwpck_require__(46403);
+const DetectStackSetDriftCommand_1 = __nccwpck_require__(19450);
+const EstimateTemplateCostCommand_1 = __nccwpck_require__(11152);
+const ExecuteChangeSetCommand_1 = __nccwpck_require__(73188);
+const GetStackPolicyCommand_1 = __nccwpck_require__(4482);
+const GetTemplateCommand_1 = __nccwpck_require__(99836);
+const GetTemplateSummaryCommand_1 = __nccwpck_require__(59396);
+const ListChangeSetsCommand_1 = __nccwpck_require__(99706);
+const ListExportsCommand_1 = __nccwpck_require__(60351);
+const ListImportsCommand_1 = __nccwpck_require__(72171);
+const ListStackInstancesCommand_1 = __nccwpck_require__(50991);
+const ListStackResourcesCommand_1 = __nccwpck_require__(83057);
+const ListStackSetOperationResultsCommand_1 = __nccwpck_require__(71155);
+const ListStackSetOperationsCommand_1 = __nccwpck_require__(62539);
+const ListStackSetsCommand_1 = __nccwpck_require__(40722);
+const ListStacksCommand_1 = __nccwpck_require__(54482);
+const ListTypeRegistrationsCommand_1 = __nccwpck_require__(34567);
+const ListTypeVersionsCommand_1 = __nccwpck_require__(72174);
+const ListTypesCommand_1 = __nccwpck_require__(5511);
+const RecordHandlerProgressCommand_1 = __nccwpck_require__(57237);
+const RegisterTypeCommand_1 = __nccwpck_require__(19011);
+const SetStackPolicyCommand_1 = __nccwpck_require__(91272);
+const SetTypeDefaultVersionCommand_1 = __nccwpck_require__(34356);
+const SignalResourceCommand_1 = __nccwpck_require__(80854);
+const StopStackSetOperationCommand_1 = __nccwpck_require__(44275);
+const UpdateStackCommand_1 = __nccwpck_require__(50944);
+const UpdateStackInstancesCommand_1 = __nccwpck_require__(54289);
+const UpdateStackSetCommand_1 = __nccwpck_require__(69969);
+const UpdateTerminationProtectionCommand_1 = __nccwpck_require__(72746);
+const ValidateTemplateCommand_1 = __nccwpck_require__(35583);
+/**
+ *
AWS CloudFormation allows you to create and manage AWS infrastructure deployments + * predictably and repeatedly. You can use AWS CloudFormation to leverage AWS products, such + * as Amazon Elastic Compute Cloud, Amazon Elastic Block Store, Amazon Simple Notification + * Service, Elastic Load Balancing, and Auto Scaling to build highly-reliable, highly + * scalable, cost-effective applications without creating or configuring the underlying AWS + * infrastructure.
+ *With AWS CloudFormation, you declare all of your resources and dependencies in a + * template file. The template defines a collection of resources as a single unit called a + * stack. AWS CloudFormation creates and deletes all member resources of the stack together + * and manages all dependencies between the resources for you.
+ *For more information about AWS CloudFormation, see the AWS CloudFormation Product Page.
+ *Amazon CloudFormation makes use of other AWS products. If you need additional + * technical information about a specific AWS product, you can find the product's technical + * documentation at docs.aws.amazon.com.
+ */ +class CloudFormation extends CloudFormationClient_1.CloudFormationClient { + cancelUpdateStack(args, optionsOrCb, cb) { + const command = new CancelUpdateStackCommand_1.CancelUpdateStackCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + continueUpdateRollback(args, optionsOrCb, cb) { + const command = new ContinueUpdateRollbackCommand_1.ContinueUpdateRollbackCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createChangeSet(args, optionsOrCb, cb) { + const command = new CreateChangeSetCommand_1.CreateChangeSetCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createStack(args, optionsOrCb, cb) { + const command = new CreateStackCommand_1.CreateStackCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createStackInstances(args, optionsOrCb, cb) { + const command = new CreateStackInstancesCommand_1.CreateStackInstancesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createStackSet(args, optionsOrCb, cb) { + const command = new CreateStackSetCommand_1.CreateStackSetCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteChangeSet(args, optionsOrCb, cb) { + const command = new DeleteChangeSetCommand_1.DeleteChangeSetCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteStack(args, optionsOrCb, cb) { + const command = new DeleteStackCommand_1.DeleteStackCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteStackInstances(args, optionsOrCb, cb) { + const command = new DeleteStackInstancesCommand_1.DeleteStackInstancesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteStackSet(args, optionsOrCb, cb) { + const command = new DeleteStackSetCommand_1.DeleteStackSetCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deregisterType(args, optionsOrCb, cb) { + const command = new DeregisterTypeCommand_1.DeregisterTypeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeAccountLimits(args, optionsOrCb, cb) { + const command = new DescribeAccountLimitsCommand_1.DescribeAccountLimitsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeChangeSet(args, optionsOrCb, cb) { + const command = new DescribeChangeSetCommand_1.DescribeChangeSetCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeStackDriftDetectionStatus(args, optionsOrCb, cb) { + const command = new DescribeStackDriftDetectionStatusCommand_1.DescribeStackDriftDetectionStatusCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeStackEvents(args, optionsOrCb, cb) { + const command = new DescribeStackEventsCommand_1.DescribeStackEventsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeStackInstance(args, optionsOrCb, cb) { + const command = new DescribeStackInstanceCommand_1.DescribeStackInstanceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeStackResource(args, optionsOrCb, cb) { + const command = new DescribeStackResourceCommand_1.DescribeStackResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeStackResourceDrifts(args, optionsOrCb, cb) { + const command = new DescribeStackResourceDriftsCommand_1.DescribeStackResourceDriftsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeStackResources(args, optionsOrCb, cb) { + const command = new DescribeStackResourcesCommand_1.DescribeStackResourcesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeStacks(args, optionsOrCb, cb) { + const command = new DescribeStacksCommand_1.DescribeStacksCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeStackSet(args, optionsOrCb, cb) { + const command = new DescribeStackSetCommand_1.DescribeStackSetCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeStackSetOperation(args, optionsOrCb, cb) { + const command = new DescribeStackSetOperationCommand_1.DescribeStackSetOperationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeType(args, optionsOrCb, cb) { + const command = new DescribeTypeCommand_1.DescribeTypeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeTypeRegistration(args, optionsOrCb, cb) { + const command = new DescribeTypeRegistrationCommand_1.DescribeTypeRegistrationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + detectStackDrift(args, optionsOrCb, cb) { + const command = new DetectStackDriftCommand_1.DetectStackDriftCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + detectStackResourceDrift(args, optionsOrCb, cb) { + const command = new DetectStackResourceDriftCommand_1.DetectStackResourceDriftCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + detectStackSetDrift(args, optionsOrCb, cb) { + const command = new DetectStackSetDriftCommand_1.DetectStackSetDriftCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + estimateTemplateCost(args, optionsOrCb, cb) { + const command = new EstimateTemplateCostCommand_1.EstimateTemplateCostCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + executeChangeSet(args, optionsOrCb, cb) { + const command = new ExecuteChangeSetCommand_1.ExecuteChangeSetCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getStackPolicy(args, optionsOrCb, cb) { + const command = new GetStackPolicyCommand_1.GetStackPolicyCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getTemplate(args, optionsOrCb, cb) { + const command = new GetTemplateCommand_1.GetTemplateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getTemplateSummary(args, optionsOrCb, cb) { + const command = new GetTemplateSummaryCommand_1.GetTemplateSummaryCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listChangeSets(args, optionsOrCb, cb) { + const command = new ListChangeSetsCommand_1.ListChangeSetsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listExports(args, optionsOrCb, cb) { + const command = new ListExportsCommand_1.ListExportsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listImports(args, optionsOrCb, cb) { + const command = new ListImportsCommand_1.ListImportsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listStackInstances(args, optionsOrCb, cb) { + const command = new ListStackInstancesCommand_1.ListStackInstancesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listStackResources(args, optionsOrCb, cb) { + const command = new ListStackResourcesCommand_1.ListStackResourcesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listStacks(args, optionsOrCb, cb) { + const command = new ListStacksCommand_1.ListStacksCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listStackSetOperationResults(args, optionsOrCb, cb) { + const command = new ListStackSetOperationResultsCommand_1.ListStackSetOperationResultsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listStackSetOperations(args, optionsOrCb, cb) { + const command = new ListStackSetOperationsCommand_1.ListStackSetOperationsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listStackSets(args, optionsOrCb, cb) { + const command = new ListStackSetsCommand_1.ListStackSetsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listTypeRegistrations(args, optionsOrCb, cb) { + const command = new ListTypeRegistrationsCommand_1.ListTypeRegistrationsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listTypes(args, optionsOrCb, cb) { + const command = new ListTypesCommand_1.ListTypesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listTypeVersions(args, optionsOrCb, cb) { + const command = new ListTypeVersionsCommand_1.ListTypeVersionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + recordHandlerProgress(args, optionsOrCb, cb) { + const command = new RecordHandlerProgressCommand_1.RecordHandlerProgressCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + registerType(args, optionsOrCb, cb) { + const command = new RegisterTypeCommand_1.RegisterTypeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setStackPolicy(args, optionsOrCb, cb) { + const command = new SetStackPolicyCommand_1.SetStackPolicyCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setTypeDefaultVersion(args, optionsOrCb, cb) { + const command = new SetTypeDefaultVersionCommand_1.SetTypeDefaultVersionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + signalResource(args, optionsOrCb, cb) { + const command = new SignalResourceCommand_1.SignalResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + stopStackSetOperation(args, optionsOrCb, cb) { + const command = new StopStackSetOperationCommand_1.StopStackSetOperationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateStack(args, optionsOrCb, cb) { + const command = new UpdateStackCommand_1.UpdateStackCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateStackInstances(args, optionsOrCb, cb) { + const command = new UpdateStackInstancesCommand_1.UpdateStackInstancesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateStackSet(args, optionsOrCb, cb) { + const command = new UpdateStackSetCommand_1.UpdateStackSetCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateTerminationProtection(args, optionsOrCb, cb) { + const command = new UpdateTerminationProtectionCommand_1.UpdateTerminationProtectionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + validateTemplate(args, optionsOrCb, cb) { + const command = new ValidateTemplateCommand_1.ValidateTemplateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } +} +exports.CloudFormation = CloudFormation; +//# sourceMappingURL=CloudFormation.js.map + +/***/ }), + +/***/ 25838: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CloudFormationClient = void 0; +const runtimeConfig_1 = __nccwpck_require__(64170); +const config_resolver_1 = __nccwpck_require__(87229); +const middleware_content_length_1 = __nccwpck_require__(69323); +const middleware_host_header_1 = __nccwpck_require__(58645); +const middleware_logger_1 = __nccwpck_require__(98685); +const middleware_retry_1 = __nccwpck_require__(7000); +const middleware_signing_1 = __nccwpck_require__(82487); +const middleware_user_agent_1 = __nccwpck_require__(55976); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *AWS CloudFormation allows you to create and manage AWS infrastructure deployments + * predictably and repeatedly. You can use AWS CloudFormation to leverage AWS products, such + * as Amazon Elastic Compute Cloud, Amazon Elastic Block Store, Amazon Simple Notification + * Service, Elastic Load Balancing, and Auto Scaling to build highly-reliable, highly + * scalable, cost-effective applications without creating or configuring the underlying AWS + * infrastructure.
+ *With AWS CloudFormation, you declare all of your resources and dependencies in a + * template file. The template defines a collection of resources as a single unit called a + * stack. AWS CloudFormation creates and deletes all member resources of the stack together + * and manages all dependencies between the resources for you.
+ *For more information about AWS CloudFormation, see the AWS CloudFormation Product Page.
+ *Amazon CloudFormation makes use of other AWS products. If you need additional + * technical information about a specific AWS product, you can find the product's technical + * documentation at docs.aws.amazon.com.
+ */ +class CloudFormationClient extends smithy_client_1.Client { + constructor(configuration) { + let _config_0 = { + ...runtimeConfig_1.ClientDefaultValues, + ...configuration, + }; + let _config_1 = config_resolver_1.resolveRegionConfig(_config_0); + let _config_2 = config_resolver_1.resolveEndpointsConfig(_config_1); + let _config_3 = middleware_signing_1.resolveAwsAuthConfig(_config_2); + let _config_4 = middleware_retry_1.resolveRetryConfig(_config_3); + let _config_5 = middleware_host_header_1.resolveHostHeaderConfig(_config_4); + let _config_6 = middleware_user_agent_1.resolveUserAgentConfig(_config_5); + super(_config_6); + this.config = _config_6; + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(this.config)); + this.middlewareStack.use(middleware_retry_1.getRetryPlugin(this.config)); + this.middlewareStack.use(middleware_content_length_1.getContentLengthPlugin(this.config)); + this.middlewareStack.use(middleware_host_header_1.getHostHeaderPlugin(this.config)); + this.middlewareStack.use(middleware_logger_1.getLoggerPlugin(this.config)); + this.middlewareStack.use(middleware_user_agent_1.getUserAgentPlugin(this.config)); + } + destroy() { + super.destroy(); + } +} +exports.CloudFormationClient = CloudFormationClient; +//# sourceMappingURL=CloudFormationClient.js.map + +/***/ }), + +/***/ 78006: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CancelUpdateStackCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Cancels an update on the specified stack. If the call completes successfully, the + * stack rolls back the update and reverts to the previous stack configuration.
+ *You can cancel only stacks that are in the UPDATE_IN_PROGRESS state.
+ *For a specified stack that is in the UPDATE_ROLLBACK_FAILED
state,
+ * continues rolling it back to the UPDATE_ROLLBACK_COMPLETE
state. Depending on
+ * the cause of the failure, you can manually fix the error and continue the rollback. By continuing the rollback, you can
+ * return your stack to a working state (the UPDATE_ROLLBACK_COMPLETE
state), and
+ * then try to update the stack again.
A stack goes into the UPDATE_ROLLBACK_FAILED
state when AWS
+ * CloudFormation cannot roll back all changes after a failed stack update. For example, you
+ * might have a stack that is rolling back to an old database instance that was deleted
+ * outside of AWS CloudFormation. Because AWS CloudFormation doesn't know the database was
+ * deleted, it assumes that the database instance still exists and attempts to roll back to
+ * it, causing the update rollback to fail.
Creates a list of changes that will be applied to a stack so that you can review the + * changes before executing them. You can create a change set for a stack that doesn't exist + * or an existing stack. If you create a change set for a stack that doesn't exist, the change + * set shows all of the resources that AWS CloudFormation will create. If you create a change + * set for an existing stack, AWS CloudFormation compares the stack's information with the + * information that you submit in the change set and lists the differences. Use change sets to + * understand which resources AWS CloudFormation will create or change, and how it will change + * resources in an existing stack, before you create or update a stack.
+ *To create a change set for a stack that doesn't exist, for the
+ * ChangeSetType
parameter, specify CREATE
. To create a change
+ * set for an existing stack, specify UPDATE
for the ChangeSetType
+ * parameter. To create a change set for an import operation, specify IMPORT
for
+ * the ChangeSetType
parameter. After the CreateChangeSet
call
+ * successfully completes, AWS CloudFormation starts creating the change set. To check the
+ * status of the change set or to review it, use the DescribeChangeSet
+ * action.
When you are satisfied with the changes the change set will make, execute the change + * set by using the ExecuteChangeSet action. AWS CloudFormation doesn't make + * changes until you execute the change set.
+ *To create a change set for the entire stack hierachy, set
+ * IncludeNestedStacks
to True
.
Creates a stack as specified in the template. After the call completes successfully, + * the stack creation starts. You can check the status of the stack via the DescribeStacks API.
+ */ +class CreateStackCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "CreateStackCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateStackInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateStackOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryCreateStackCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryCreateStackCommand(output, context); + } +} +exports.CreateStackCommand = CreateStackCommand; +//# sourceMappingURL=CreateStackCommand.js.map + +/***/ }), + +/***/ 53977: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateStackInstancesCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates stack instances for the specified accounts, within the specified Regions. A
+ * stack instance refers to a stack in a specific account and Region. You must specify at least one value for either Accounts
or DeploymentTargets
, and you must specify at least one value for Regions
.
Creates a stack set.
+ */ +class CreateStackSetCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "CreateStackSetCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateStackSetInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateStackSetOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryCreateStackSetCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryCreateStackSetCommand(output, context); + } +} +exports.CreateStackSetCommand = CreateStackSetCommand; +//# sourceMappingURL=CreateStackSetCommand.js.map + +/***/ }), + +/***/ 8147: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteChangeSetCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the specified change set. Deleting change sets ensures that no one executes + * the wrong change set.
+ *If the call successfully completes, AWS CloudFormation successfully deleted the + * change set.
+ *If IncludeNestedStacks
specifies True
during the creation of
+ * the nested change set, then DeleteChangeSet
will delete all change sets that belong to the stacks hierarchy and
+ * will also delete all change sets for nested stacks with the status of REVIEW_IN_PROGRESS
.
Deletes a specified stack. Once the call completes successfully, stack deletion + * starts. Deleted stacks do not show up in the DescribeStacks API if the + * deletion has been completed successfully.
+ */ +class DeleteStackCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DeleteStackCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteStackInput.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDeleteStackCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDeleteStackCommand(output, context); + } +} +exports.DeleteStackCommand = DeleteStackCommand; +//# sourceMappingURL=DeleteStackCommand.js.map + +/***/ }), + +/***/ 96629: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteStackInstancesCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes stack instances for the specified accounts, in the specified Regions.
+ */ +class DeleteStackInstancesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DeleteStackInstancesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteStackInstancesInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteStackInstancesOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDeleteStackInstancesCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDeleteStackInstancesCommand(output, context); + } +} +exports.DeleteStackInstancesCommand = DeleteStackInstancesCommand; +//# sourceMappingURL=DeleteStackInstancesCommand.js.map + +/***/ }), + +/***/ 67548: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteStackSetCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a stack set. Before you can delete a stack set, all of its member stack + * instances must be deleted. For more information about how to do this, see DeleteStackInstances.
+ */ +class DeleteStackSetCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DeleteStackSetCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteStackSetInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteStackSetOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDeleteStackSetCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDeleteStackSetCommand(output, context); + } +} +exports.DeleteStackSetCommand = DeleteStackSetCommand; +//# sourceMappingURL=DeleteStackSetCommand.js.map + +/***/ }), + +/***/ 38218: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeregisterTypeCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Removes a type or type version from active use in the CloudFormation registry. If a type or type version is deregistered, it cannot be used in CloudFormation operations.
+ *To deregister a type, you must individually deregister all registered versions of that type. If a type has only a single registered version, deregistering that version results in the type itself being deregistered.
+ *You cannot deregister the default version of a type, unless it is the only registered version of that type, in which case the type itself is deregistered as well.
+ */ +class DeregisterTypeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DeregisterTypeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeregisterTypeInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeregisterTypeOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDeregisterTypeCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDeregisterTypeCommand(output, context); + } +} +exports.DeregisterTypeCommand = DeregisterTypeCommand; +//# sourceMappingURL=DeregisterTypeCommand.js.map + +/***/ }), + +/***/ 67719: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeAccountLimitsCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Retrieves your account's AWS CloudFormation limits, such as the maximum number of + * stacks that you can create in your account. For more information about account limits, see + * AWS CloudFormation + * Limits in the AWS CloudFormation User Guide.
+ */ +class DescribeAccountLimitsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DescribeAccountLimitsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeAccountLimitsInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeAccountLimitsOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDescribeAccountLimitsCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDescribeAccountLimitsCommand(output, context); + } +} +exports.DescribeAccountLimitsCommand = DescribeAccountLimitsCommand; +//# sourceMappingURL=DescribeAccountLimitsCommand.js.map + +/***/ }), + +/***/ 433: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeChangeSetCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns the inputs for the change set and a list of changes that AWS CloudFormation + * will make if you execute the change set. For more information, see Updating Stacks Using Change Sets in the AWS CloudFormation User + * Guide.
+ */ +class DescribeChangeSetCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DescribeChangeSetCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeChangeSetInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeChangeSetOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDescribeChangeSetCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDescribeChangeSetCommand(output, context); + } +} +exports.DescribeChangeSetCommand = DescribeChangeSetCommand; +//# sourceMappingURL=DescribeChangeSetCommand.js.map + +/***/ }), + +/***/ 30462: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeStackDriftDetectionStatusCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns information about a stack drift detection operation. A stack drift detection + * operation detects whether a stack's actual configuration differs, or has + * drifted, from it's expected configuration, as defined in the stack + * template and any values specified as template parameters. A stack is considered to have + * drifted if one or more of its resources have drifted. For more information on stack and + * resource drift, see Detecting + * Unregulated Configuration Changes to Stacks and Resources.
+ *Use DetectStackDrift to initiate a stack drift detection operation.
+ * DetectStackDrift
returns a StackDriftDetectionId
you can use
+ * to monitor the progress of the operation using
+ * DescribeStackDriftDetectionStatus
. Once the drift detection operation has
+ * completed, use DescribeStackResourceDrifts to return drift information
+ * about the stack and its resources.
Returns all stack related events for a specified stack in reverse chronological + * order. For more information about a stack's event history, go to Stacks in the AWS CloudFormation User Guide.
+ *You can list events for stacks that have failed to create or have been deleted by + * specifying the unique stack identifier (stack ID).
+ *Returns the stack instance that's associated with the specified stack set, AWS + * account, and Region.
+ *For a list of stack instances that are associated with a specific stack set, use + * ListStackInstances.
+ */ +class DescribeStackInstanceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DescribeStackInstanceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeStackInstanceInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeStackInstanceOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDescribeStackInstanceCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDescribeStackInstanceCommand(output, context); + } +} +exports.DescribeStackInstanceCommand = DescribeStackInstanceCommand; +//# sourceMappingURL=DescribeStackInstanceCommand.js.map + +/***/ }), + +/***/ 15305: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeStackResourceCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns a description of the specified resource in the specified stack.
+ *For deleted stacks, DescribeStackResource returns resource information for up to 90 + * days after the stack has been deleted.
+ */ +class DescribeStackResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DescribeStackResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeStackResourceInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeStackResourceOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDescribeStackResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDescribeStackResourceCommand(output, context); + } +} +exports.DescribeStackResourceCommand = DescribeStackResourceCommand; +//# sourceMappingURL=DescribeStackResourceCommand.js.map + +/***/ }), + +/***/ 25794: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeStackResourceDriftsCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns drift information for the resources that have been checked for drift in the + * specified stack. This includes actual and expected configuration values for resources where + * AWS CloudFormation detects configuration drift.
+ *For a given stack, there will be one StackResourceDrift
for each stack
+ * resource that has been checked for drift. Resources that have not yet been checked for
+ * drift are not included. Resources that do not currently support drift detection are not
+ * checked, and so not included. For a list of resources that support drift detection, see
+ * Resources that Support Drift Detection.
Use DetectStackResourceDrift to detect drift on individual + * resources, or DetectStackDrift to detect drift on all supported resources + * for a given stack.
+ */ +class DescribeStackResourceDriftsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DescribeStackResourceDriftsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeStackResourceDriftsInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeStackResourceDriftsOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDescribeStackResourceDriftsCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDescribeStackResourceDriftsCommand(output, context); + } +} +exports.DescribeStackResourceDriftsCommand = DescribeStackResourceDriftsCommand; +//# sourceMappingURL=DescribeStackResourceDriftsCommand.js.map + +/***/ }), + +/***/ 28792: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeStackResourcesCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns AWS resource descriptions for running and deleted stacks. If
+ * StackName
is specified, all the associated resources that are part of the
+ * stack are returned. If PhysicalResourceId
is specified, the associated
+ * resources of the stack that the resource belongs to are returned.
Only the first 100 resources will be returned. If your stack has more resources
+ * than this, you should use ListStackResources
instead.
For deleted stacks, DescribeStackResources
returns resource information
+ * for up to 90 days after the stack has been deleted.
You must specify either StackName
or PhysicalResourceId
,
+ * but not both. In addition, you can specify LogicalResourceId
to filter the
+ * returned result. For more information about resources, the LogicalResourceId
+ * and PhysicalResourceId
, go to the AWS CloudFormation User
+ * Guide.
A ValidationError
is returned if you specify both
+ * StackName
and PhysicalResourceId
in the same
+ * request.
Returns the description of the specified stack set.
+ */ +class DescribeStackSetCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DescribeStackSetCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeStackSetInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeStackSetOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDescribeStackSetCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDescribeStackSetCommand(output, context); + } +} +exports.DescribeStackSetCommand = DescribeStackSetCommand; +//# sourceMappingURL=DescribeStackSetCommand.js.map + +/***/ }), + +/***/ 12422: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeStackSetOperationCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns the description of the specified stack set operation.
+ */ +class DescribeStackSetOperationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DescribeStackSetOperationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeStackSetOperationInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeStackSetOperationOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDescribeStackSetOperationCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDescribeStackSetOperationCommand(output, context); + } +} +exports.DescribeStackSetOperationCommand = DescribeStackSetOperationCommand; +//# sourceMappingURL=DescribeStackSetOperationCommand.js.map + +/***/ }), + +/***/ 87840: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeStacksCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns the description for the specified stack; if no stack name was specified, then + * it returns the description for all the stacks created.
+ *If the stack does not exist, an AmazonCloudFormationException
is
+ * returned.
Returns detailed information about a type that has been registered.
+ *If you specify a VersionId
, DescribeType
returns information about that specific type version. Otherwise, it returns information about the default type version.
Returns information about a type's registration, including its current status and type and version identifiers.
+ *When you initiate a registration request using
+ * RegisterType
+ *
, you can then use
+ * DescribeTypeRegistration
+ *
to monitor the progress of that registration request.
Once the registration request has completed, use
+ * DescribeType
+ *
to return detailed informaiton about a type.
Detects whether a stack's actual configuration differs, or has + * drifted, from it's expected configuration, as defined in the stack + * template and any values specified as template parameters. For each resource in the stack + * that supports drift detection, AWS CloudFormation compares the actual configuration of the resource with + * its expected template configuration. Only resource properties explicitly defined in the + * stack template are checked for drift. A stack is considered to have drifted if one or more + * of its resources differ from their expected template configurations. For more information, + * see Detecting + * Unregulated Configuration Changes to Stacks and Resources.
+ *Use DetectStackDrift
to detect drift on all supported resources for a
+ * given stack, or DetectStackResourceDrift to detect drift on individual
+ * resources.
For a list of stack resources that currently support drift detection, see Resources that Support Drift Detection.
+ *
+ * DetectStackDrift
can take up to several minutes, depending on the number
+ * of resources contained within the stack. Use DescribeStackDriftDetectionStatus to monitor the progress of a detect stack
+ * drift operation. Once the drift detection operation has completed, use DescribeStackResourceDrifts to return drift information about the stack and
+ * its resources.
When detecting drift on a stack, AWS CloudFormation does not detect drift on any nested stacks
+ * belonging to that stack. Perform DetectStackDrift
directly on the nested stack
+ * itself.
Returns information about whether a resource's actual configuration differs, or has + * drifted, from it's expected configuration, as defined in the stack + * template and any values specified as template parameters. This information includes actual + * and expected property values for resources in which AWS CloudFormation detects drift. Only resource + * properties explicitly defined in the stack template are checked for drift. For more + * information about stack and resource drift, see Detecting + * Unregulated Configuration Changes to Stacks and Resources.
+ *Use DetectStackResourceDrift
to detect drift on individual resources, or
+ * DetectStackDrift to detect drift on all resources in a given stack
+ * that support drift detection.
Resources that do not currently support drift detection cannot be checked. For a list + * of resources that support drift detection, see Resources that Support Drift Detection.
+ */ +class DetectStackResourceDriftCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "DetectStackResourceDriftCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DetectStackResourceDriftInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DetectStackResourceDriftOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryDetectStackResourceDriftCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryDetectStackResourceDriftCommand(output, context); + } +} +exports.DetectStackResourceDriftCommand = DetectStackResourceDriftCommand; +//# sourceMappingURL=DetectStackResourceDriftCommand.js.map + +/***/ }), + +/***/ 19450: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DetectStackSetDriftCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Detect drift on a stack set. When CloudFormation performs drift detection on a stack + * set, it performs drift detection on the stack associated with each stack instance in the + * stack set. For more information, see How CloudFormation + * Performs Drift Detection on a Stack Set.
+ *
+ * DetectStackSetDrift
returns the OperationId
of the stack set
+ * drift detection operation. Use this operation id with
+ * DescribeStackSetOperation
+ *
to monitor the progress of the drift
+ * detection operation. The drift detection operation may take some time, depending on the
+ * number of stack instances included in the stack set, as well as the number of resources
+ * included in each stack.
Once the operation has completed, use the following actions to return drift + * information:
+ *Use
+ * DescribeStackSet
+ *
to return detailed informaiton
+ * about the stack set, including detailed information about the last
+ * completed drift operation performed on the stack set.
+ * (Information about drift operations that are in progress is not included.)
Use
+ * ListStackInstances
+ *
to return a list of stack
+ * instances belonging to the stack set, including the drift status and last drift time
+ * checked of each instance.
Use
+ * DescribeStackInstance
+ *
to return detailed
+ * information about a specific stack instance, including its drift status and last
+ * drift time checked.
For more information on performing a drift detection operation on a stack set, see + * Detecting Unmanaged + * Changes in Stack Sets.
+ *You can only run a single drift detection operation on a given stack set at one time.
+ *To stop a drift detection stack set operation, use
+ * StopStackSetOperation
+ *
.
Returns the estimated monthly cost of a template. The return value is an AWS Simple + * Monthly Calculator URL with a query string that describes the resources required to run the + * template.
+ */ +class EstimateTemplateCostCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "EstimateTemplateCostCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.EstimateTemplateCostInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.EstimateTemplateCostOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryEstimateTemplateCostCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryEstimateTemplateCostCommand(output, context); + } +} +exports.EstimateTemplateCostCommand = EstimateTemplateCostCommand; +//# sourceMappingURL=EstimateTemplateCostCommand.js.map + +/***/ }), + +/***/ 73188: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ExecuteChangeSetCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates a stack using the input information that was provided when the specified + * change set was created. After the call successfully completes, AWS CloudFormation starts + * updating the stack. Use the DescribeStacks action to view the status of + * the update.
+ *When you execute a change set, AWS CloudFormation deletes all other change sets + * associated with the stack because they aren't valid for the updated stack.
+ *If a stack policy is associated with the stack, AWS CloudFormation enforces the + * policy during the update. You can't specify a temporary stack policy that overrides the + * current policy.
+ *To create a change set for the entire stack hierachy, IncludeNestedStacks
+ * must have been set to True
.
Returns the stack policy for a specified stack. If a stack doesn't have a policy, a + * null value is returned.
+ */ +class GetStackPolicyCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "GetStackPolicyCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetStackPolicyInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetStackPolicyOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryGetStackPolicyCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryGetStackPolicyCommand(output, context); + } +} +exports.GetStackPolicyCommand = GetStackPolicyCommand; +//# sourceMappingURL=GetStackPolicyCommand.js.map + +/***/ }), + +/***/ 99836: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetTemplateCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns the template body for a specified stack. You can get the template for running + * or deleted stacks.
+ *For deleted stacks, GetTemplate returns the template for up to 90 days after the + * stack has been deleted.
+ * If the template does not exist, a ValidationError
is returned.
+ *
Returns information about a new or existing template. The
+ * GetTemplateSummary
action is useful for viewing parameter information, such
+ * as default parameter values and parameter types, before you create or update a stack or
+ * stack set.
You can use the GetTemplateSummary
action when you submit a template, or
+ * you can get template information for a stack set, or a running or deleted stack.
For deleted stacks, GetTemplateSummary
returns the template information
+ * for up to 90 days after the stack has been deleted. If the template does not exist, a
+ * ValidationError
is returned.
Returns the ID and status of each active change set for a stack. For example, AWS
+ * CloudFormation lists change sets that are in the CREATE_IN_PROGRESS
or
+ * CREATE_PENDING
state.
Lists all exported output values in the account and Region in which you call this
+ * action. Use this action to see the exported output values that you can import into other
+ * stacks. To import values, use the
+ * Fn::ImportValue
+ * function.
For more information, see AWS + * CloudFormation Export Stack Output Values.
+ */ +class ListExportsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ListExportsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListExportsInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListExportsOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListExportsCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListExportsCommand(output, context); + } +} +exports.ListExportsCommand = ListExportsCommand; +//# sourceMappingURL=ListExportsCommand.js.map + +/***/ }), + +/***/ 72171: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListImportsCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists all stacks that are importing an exported output value. To modify or remove an + * exported output value, first use this action to see which stacks are using it. To see the + * exported output values in your account, see ListExports.
+ *For more information about importing an exported output value, see the
+ * Fn::ImportValue
+ * function.
Returns summary information about stack instances that are associated with the + * specified stack set. You can filter for stack instances that are associated with a specific + * AWS account name or Region, or that have a specific status.
+ */ +class ListStackInstancesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ListStackInstancesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListStackInstancesInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListStackInstancesOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListStackInstancesCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListStackInstancesCommand(output, context); + } +} +exports.ListStackInstancesCommand = ListStackInstancesCommand; +//# sourceMappingURL=ListStackInstancesCommand.js.map + +/***/ }), + +/***/ 83057: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListStackResourcesCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns descriptions of all resources of the specified stack.
+ *For deleted stacks, ListStackResources returns resource information for up to 90 days + * after the stack has been deleted.
+ */ +class ListStackResourcesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ListStackResourcesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListStackResourcesInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListStackResourcesOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListStackResourcesCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListStackResourcesCommand(output, context); + } +} +exports.ListStackResourcesCommand = ListStackResourcesCommand; +//# sourceMappingURL=ListStackResourcesCommand.js.map + +/***/ }), + +/***/ 71155: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListStackSetOperationResultsCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns summary information about the results of a stack set operation.
+ */ +class ListStackSetOperationResultsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ListStackSetOperationResultsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListStackSetOperationResultsInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListStackSetOperationResultsOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListStackSetOperationResultsCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListStackSetOperationResultsCommand(output, context); + } +} +exports.ListStackSetOperationResultsCommand = ListStackSetOperationResultsCommand; +//# sourceMappingURL=ListStackSetOperationResultsCommand.js.map + +/***/ }), + +/***/ 62539: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListStackSetOperationsCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns summary information about operations performed on a stack set.
+ */ +class ListStackSetOperationsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ListStackSetOperationsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListStackSetOperationsInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListStackSetOperationsOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListStackSetOperationsCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListStackSetOperationsCommand(output, context); + } +} +exports.ListStackSetOperationsCommand = ListStackSetOperationsCommand; +//# sourceMappingURL=ListStackSetOperationsCommand.js.map + +/***/ }), + +/***/ 40722: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListStackSetsCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns summary information about stack sets that are associated with the + * user.
+ */ +class ListStackSetsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ListStackSetsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListStackSetsInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListStackSetsOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListStackSetsCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListStackSetsCommand(output, context); + } +} +exports.ListStackSetsCommand = ListStackSetsCommand; +//# sourceMappingURL=ListStackSetsCommand.js.map + +/***/ }), + +/***/ 54482: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListStacksCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns the summary information for stacks whose status matches the specified + * StackStatusFilter. Summary information for stacks that have been deleted is kept for 90 + * days after the stack is deleted. If no StackStatusFilter is specified, summary information + * for all stacks is returned (including existing stacks and stacks that have been + * deleted).
+ */ +class ListStacksCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ListStacksCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListStacksInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListStacksOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListStacksCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListStacksCommand(output, context); + } +} +exports.ListStacksCommand = ListStacksCommand; +//# sourceMappingURL=ListStacksCommand.js.map + +/***/ }), + +/***/ 34567: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListTypeRegistrationsCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns a list of registration tokens for the specified type(s).
+ */ +class ListTypeRegistrationsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ListTypeRegistrationsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListTypeRegistrationsInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListTypeRegistrationsOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListTypeRegistrationsCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListTypeRegistrationsCommand(output, context); + } +} +exports.ListTypeRegistrationsCommand = ListTypeRegistrationsCommand; +//# sourceMappingURL=ListTypeRegistrationsCommand.js.map + +/***/ }), + +/***/ 72174: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListTypeVersionsCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns summary information about the versions of a type.
+ */ +class ListTypeVersionsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ListTypeVersionsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListTypeVersionsInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListTypeVersionsOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListTypeVersionsCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListTypeVersionsCommand(output, context); + } +} +exports.ListTypeVersionsCommand = ListTypeVersionsCommand; +//# sourceMappingURL=ListTypeVersionsCommand.js.map + +/***/ }), + +/***/ 5511: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListTypesCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns summary information about types that have been registered with CloudFormation.
+ */ +class ListTypesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ListTypesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListTypesInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListTypesOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListTypesCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListTypesCommand(output, context); + } +} +exports.ListTypesCommand = ListTypesCommand; +//# sourceMappingURL=ListTypesCommand.js.map + +/***/ }), + +/***/ 57237: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.RecordHandlerProgressCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Reports progress of a resource handler to CloudFormation.
+ *Reserved for use by the CloudFormation CLI. Do not use this API in your code.
+ */ +class RecordHandlerProgressCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "RecordHandlerProgressCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.RecordHandlerProgressInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.RecordHandlerProgressOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryRecordHandlerProgressCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryRecordHandlerProgressCommand(output, context); + } +} +exports.RecordHandlerProgressCommand = RecordHandlerProgressCommand; +//# sourceMappingURL=RecordHandlerProgressCommand.js.map + +/***/ }), + +/***/ 19011: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.RegisterTypeCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Registers a type with the CloudFormation service. Registering a type makes it available for use in CloudFormation templates in your AWS account, and includes:
+ *Validating the resource schema
+ *Determining which handlers have been specified for the resource
+ *Making the resource type available for use in your account
+ *For more information on how to develop types and ready them for registeration, see Creating Resource Providers in the CloudFormation CLI User Guide.
+ *You can have a maximum of 50 resource type versions registered at a time. This maximum is per account and per region. Use DeregisterType to deregister specific resource type versions if necessary.
+ *Once you have initiated a registration request using
+ * RegisterType
+ *
, you can use
+ * DescribeTypeRegistration
+ *
to monitor the progress of the registration request.
Sets a stack policy for a specified stack.
+ */ +class SetStackPolicyCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "SetStackPolicyCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.SetStackPolicyInput.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_querySetStackPolicyCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_querySetStackPolicyCommand(output, context); + } +} +exports.SetStackPolicyCommand = SetStackPolicyCommand; +//# sourceMappingURL=SetStackPolicyCommand.js.map + +/***/ }), + +/***/ 34356: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SetTypeDefaultVersionCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Specify the default version of a type. The default version of a type will be used in CloudFormation operations.
+ */ +class SetTypeDefaultVersionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "SetTypeDefaultVersionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.SetTypeDefaultVersionInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.SetTypeDefaultVersionOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_querySetTypeDefaultVersionCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_querySetTypeDefaultVersionCommand(output, context); + } +} +exports.SetTypeDefaultVersionCommand = SetTypeDefaultVersionCommand; +//# sourceMappingURL=SetTypeDefaultVersionCommand.js.map + +/***/ }), + +/***/ 80854: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SignalResourceCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Sends a signal to the specified resource with a success or failure status. You can + * use the SignalResource API in conjunction with a creation policy or update policy. AWS + * CloudFormation doesn't proceed with a stack creation or update until resources receive the + * required number of signals or the timeout period is exceeded. The SignalResource API is + * useful in cases where you want to send signals from anywhere other than an Amazon EC2 + * instance.
+ */ +class SignalResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "SignalResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.SignalResourceInput.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_querySignalResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_querySignalResourceCommand(output, context); + } +} +exports.SignalResourceCommand = SignalResourceCommand; +//# sourceMappingURL=SignalResourceCommand.js.map + +/***/ }), + +/***/ 44275: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.StopStackSetOperationCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Stops an in-progress operation on a stack set and its associated stack instances.
+ */ +class StopStackSetOperationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "StopStackSetOperationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.StopStackSetOperationInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.StopStackSetOperationOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryStopStackSetOperationCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryStopStackSetOperationCommand(output, context); + } +} +exports.StopStackSetOperationCommand = StopStackSetOperationCommand; +//# sourceMappingURL=StopStackSetOperationCommand.js.map + +/***/ }), + +/***/ 50944: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateStackCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates a stack as specified in the template. After the call completes successfully, + * the stack update starts. You can check the status of the stack via the DescribeStacks action.
+ *To get a copy of the template for an existing stack, you can use the GetTemplate action.
+ *For more information about creating an update template, updating a stack, and + * monitoring the progress of the update, see Updating a + * Stack.
+ */ +class UpdateStackCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "UpdateStackCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.UpdateStackInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.UpdateStackOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryUpdateStackCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryUpdateStackCommand(output, context); + } +} +exports.UpdateStackCommand = UpdateStackCommand; +//# sourceMappingURL=UpdateStackCommand.js.map + +/***/ }), + +/***/ 54289: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateStackInstancesCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the parameter values for stack instances for the specified accounts, within + * the specified Regions. A stack instance refers to a stack in a specific account and Region.
+ *You can only update stack instances in Regions and accounts where they already exist; + * to create additional stack instances, use CreateStackInstances.
+ *During stack set updates, any parameters overridden for a stack instance are not + * updated, but retain their overridden value.
+ *You can only update the parameter values that are specified in
+ * the stack set; to add or delete a parameter itself, use UpdateStackSet to update the stack set template. If you add a parameter to a
+ * template, before you can override the parameter value specified in the stack set you must
+ * first use UpdateStackSet to update all stack instances with the updated template and
+ * parameter value specified in the stack set. Once a stack instance has been updated with the
+ * new parameter, you can then override the parameter value using
+ * UpdateStackInstances
.
Updates the stack set, and associated stack instances in the specified accounts and + * Regions.
+ *Even if the stack set operation created by updating the stack set fails (completely + * or partially, below or above a specified failure tolerance), the stack set is updated with + * your changes. Subsequent CreateStackInstances calls on the specified + * stack set use the updated stack set.
+ */ +class UpdateStackSetCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "UpdateStackSetCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.UpdateStackSetInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.UpdateStackSetOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryUpdateStackSetCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryUpdateStackSetCommand(output, context); + } +} +exports.UpdateStackSetCommand = UpdateStackSetCommand; +//# sourceMappingURL=UpdateStackSetCommand.js.map + +/***/ }), + +/***/ 72746: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateTerminationProtectionCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates termination protection for the specified stack. If a user attempts to delete + * a stack with termination protection enabled, the operation fails and the stack remains + * unchanged. For more information, see Protecting a + * Stack From Being Deleted in the AWS CloudFormation User Guide.
+ *For nested + * stacks, termination protection is set on the root stack and cannot be changed + * directly on the nested stack.
+ */ +class UpdateTerminationProtectionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "UpdateTerminationProtectionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.UpdateTerminationProtectionInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.UpdateTerminationProtectionOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryUpdateTerminationProtectionCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryUpdateTerminationProtectionCommand(output, context); + } +} +exports.UpdateTerminationProtectionCommand = UpdateTerminationProtectionCommand; +//# sourceMappingURL=UpdateTerminationProtectionCommand.js.map + +/***/ }), + +/***/ 35583: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ValidateTemplateCommand = void 0; +const models_0_1 = __nccwpck_require__(50499); +const Aws_query_1 = __nccwpck_require__(46408); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Validates a specified template. AWS CloudFormation first checks if the template is + * valid JSON. If it isn't, AWS CloudFormation checks if the template is valid YAML. If both + * these checks fail, AWS CloudFormation returns a template validation error.
+ */ +class ValidateTemplateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CloudFormationClient"; + const commandName = "ValidateTemplateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ValidateTemplateInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ValidateTemplateOutput.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryValidateTemplateCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryValidateTemplateCommand(output, context); + } +} +exports.ValidateTemplateCommand = ValidateTemplateCommand; +//# sourceMappingURL=ValidateTemplateCommand.js.map + +/***/ }), + +/***/ 8628: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.defaultRegionInfoProvider = void 0; +// Partition default templates +const AWS_TEMPLATE = "cloudformation.{region}.amazonaws.com"; +const AWS_CN_TEMPLATE = "cloudformation.{region}.amazonaws.com.cn"; +const AWS_ISO_TEMPLATE = "cloudformation.{region}.c2s.ic.gov"; +const AWS_ISO_B_TEMPLATE = "cloudformation.{region}.sc2s.sgov.gov"; +const AWS_US_GOV_TEMPLATE = "cloudformation.{region}.amazonaws.com"; +// Partition regions +const AWS_REGIONS = new Set([ + "af-south-1", + "ap-east-1", + "ap-northeast-1", + "ap-northeast-2", + "ap-south-1", + "ap-southeast-1", + "ap-southeast-2", + "ca-central-1", + "eu-central-1", + "eu-north-1", + "eu-south-1", + "eu-west-1", + "eu-west-2", + "eu-west-3", + "me-south-1", + "sa-east-1", + "us-east-1", + "us-east-2", + "us-west-1", + "us-west-2", +]); +const AWS_CN_REGIONS = new Set(["cn-north-1", "cn-northwest-1"]); +const AWS_ISO_REGIONS = new Set(["us-iso-east-1"]); +const AWS_ISO_B_REGIONS = new Set(["us-isob-east-1"]); +const AWS_US_GOV_REGIONS = new Set(["us-gov-east-1", "us-gov-west-1"]); +const defaultRegionInfoProvider = (region, options) => { + let regionInfo = undefined; + switch (region) { + // First, try to match exact region names. + case "af-south-1": + regionInfo = { + hostname: "cloudformation.af-south-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-east-1": + regionInfo = { + hostname: "cloudformation.ap-east-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-northeast-1": + regionInfo = { + hostname: "cloudformation.ap-northeast-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-northeast-2": + regionInfo = { + hostname: "cloudformation.ap-northeast-2.amazonaws.com", + partition: "aws", + }; + break; + case "ap-south-1": + regionInfo = { + hostname: "cloudformation.ap-south-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-southeast-1": + regionInfo = { + hostname: "cloudformation.ap-southeast-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-southeast-2": + regionInfo = { + hostname: "cloudformation.ap-southeast-2.amazonaws.com", + partition: "aws", + }; + break; + case "ca-central-1": + regionInfo = { + hostname: "cloudformation.ca-central-1.amazonaws.com", + partition: "aws", + }; + break; + case "cn-north-1": + regionInfo = { + hostname: "cloudformation.cn-north-1.amazonaws.com.cn", + partition: "aws-cn", + }; + break; + case "cn-northwest-1": + regionInfo = { + hostname: "cloudformation.cn-northwest-1.amazonaws.com.cn", + partition: "aws-cn", + }; + break; + case "eu-central-1": + regionInfo = { + hostname: "cloudformation.eu-central-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-north-1": + regionInfo = { + hostname: "cloudformation.eu-north-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-south-1": + regionInfo = { + hostname: "cloudformation.eu-south-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-west-1": + regionInfo = { + hostname: "cloudformation.eu-west-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-west-2": + regionInfo = { + hostname: "cloudformation.eu-west-2.amazonaws.com", + partition: "aws", + }; + break; + case "eu-west-3": + regionInfo = { + hostname: "cloudformation.eu-west-3.amazonaws.com", + partition: "aws", + }; + break; + case "me-south-1": + regionInfo = { + hostname: "cloudformation.me-south-1.amazonaws.com", + partition: "aws", + }; + break; + case "sa-east-1": + regionInfo = { + hostname: "cloudformation.sa-east-1.amazonaws.com", + partition: "aws", + }; + break; + case "us-east-1": + regionInfo = { + hostname: "cloudformation.us-east-1.amazonaws.com", + partition: "aws", + }; + break; + case "us-east-1-fips": + regionInfo = { + hostname: "cloudformation-fips.us-east-1.amazonaws.com", + partition: "aws", + signingRegion: "us-east-1", + }; + break; + case "us-east-2": + regionInfo = { + hostname: "cloudformation.us-east-2.amazonaws.com", + partition: "aws", + }; + break; + case "us-east-2-fips": + regionInfo = { + hostname: "cloudformation-fips.us-east-2.amazonaws.com", + partition: "aws", + signingRegion: "us-east-2", + }; + break; + case "us-gov-east-1": + regionInfo = { + hostname: "cloudformation.us-gov-east-1.amazonaws.com", + partition: "aws-us-gov", + signingRegion: "us-gov-east-1", + }; + break; + case "us-gov-west-1": + regionInfo = { + hostname: "cloudformation.us-gov-west-1.amazonaws.com", + partition: "aws-us-gov", + signingRegion: "us-gov-west-1", + }; + break; + case "us-iso-east-1": + regionInfo = { + hostname: "cloudformation.us-iso-east-1.c2s.ic.gov", + partition: "aws-iso", + }; + break; + case "us-isob-east-1": + regionInfo = { + hostname: "cloudformation.us-isob-east-1.sc2s.sgov.gov", + partition: "aws-iso-b", + }; + break; + case "us-west-1": + regionInfo = { + hostname: "cloudformation.us-west-1.amazonaws.com", + partition: "aws", + }; + break; + case "us-west-1-fips": + regionInfo = { + hostname: "cloudformation-fips.us-west-1.amazonaws.com", + partition: "aws", + signingRegion: "us-west-1", + }; + break; + case "us-west-2": + regionInfo = { + hostname: "cloudformation.us-west-2.amazonaws.com", + partition: "aws", + }; + break; + case "us-west-2-fips": + regionInfo = { + hostname: "cloudformation-fips.us-west-2.amazonaws.com", + partition: "aws", + signingRegion: "us-west-2", + }; + break; + // Next, try to match partition endpoints. + default: + if (AWS_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_TEMPLATE.replace("{region}", region), + partition: "aws", + }; + } + if (AWS_CN_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_CN_TEMPLATE.replace("{region}", region), + partition: "aws-cn", + }; + } + if (AWS_ISO_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_ISO_TEMPLATE.replace("{region}", region), + partition: "aws-iso", + }; + } + if (AWS_ISO_B_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_ISO_B_TEMPLATE.replace("{region}", region), + partition: "aws-iso-b", + }; + } + if (AWS_US_GOV_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_US_GOV_TEMPLATE.replace("{region}", region), + partition: "aws-us-gov", + }; + } + // Finally, assume it's an AWS partition endpoint. + if (regionInfo === undefined) { + regionInfo = { + hostname: AWS_TEMPLATE.replace("{region}", region), + partition: "aws", + }; + } + } + return Promise.resolve({ signingService: "cloudformation", ...regionInfo }); +}; +exports.defaultRegionInfoProvider = defaultRegionInfoProvider; +//# sourceMappingURL=endpoints.js.map + +/***/ }), + +/***/ 22932: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +const tslib_1 = __nccwpck_require__(91663); +tslib_1.__exportStar(__nccwpck_require__(25838), exports); +tslib_1.__exportStar(__nccwpck_require__(44074), exports); +tslib_1.__exportStar(__nccwpck_require__(78006), exports); +tslib_1.__exportStar(__nccwpck_require__(31828), exports); +tslib_1.__exportStar(__nccwpck_require__(87501), exports); +tslib_1.__exportStar(__nccwpck_require__(42935), exports); +tslib_1.__exportStar(__nccwpck_require__(53977), exports); +tslib_1.__exportStar(__nccwpck_require__(94602), exports); +tslib_1.__exportStar(__nccwpck_require__(8147), exports); +tslib_1.__exportStar(__nccwpck_require__(93619), exports); +tslib_1.__exportStar(__nccwpck_require__(96629), exports); +tslib_1.__exportStar(__nccwpck_require__(67548), exports); +tslib_1.__exportStar(__nccwpck_require__(38218), exports); +tslib_1.__exportStar(__nccwpck_require__(67719), exports); +tslib_1.__exportStar(__nccwpck_require__(93821), exports); +tslib_1.__exportStar(__nccwpck_require__(433), exports); +tslib_1.__exportStar(__nccwpck_require__(30462), exports); +tslib_1.__exportStar(__nccwpck_require__(99902), exports); +tslib_1.__exportStar(__nccwpck_require__(77993), exports); +tslib_1.__exportStar(__nccwpck_require__(95705), exports); +tslib_1.__exportStar(__nccwpck_require__(15305), exports); +tslib_1.__exportStar(__nccwpck_require__(25794), exports); +tslib_1.__exportStar(__nccwpck_require__(5335), exports); +tslib_1.__exportStar(__nccwpck_require__(28792), exports); +tslib_1.__exportStar(__nccwpck_require__(87840), exports); +tslib_1.__exportStar(__nccwpck_require__(66474), exports); +tslib_1.__exportStar(__nccwpck_require__(18050), exports); +tslib_1.__exportStar(__nccwpck_require__(12422), exports); +tslib_1.__exportStar(__nccwpck_require__(41499), exports); +tslib_1.__exportStar(__nccwpck_require__(39500), exports); +tslib_1.__exportStar(__nccwpck_require__(68435), exports); +tslib_1.__exportStar(__nccwpck_require__(78948), exports); +tslib_1.__exportStar(__nccwpck_require__(46403), exports); +tslib_1.__exportStar(__nccwpck_require__(19450), exports); +tslib_1.__exportStar(__nccwpck_require__(11152), exports); +tslib_1.__exportStar(__nccwpck_require__(73188), exports); +tslib_1.__exportStar(__nccwpck_require__(4482), exports); +tslib_1.__exportStar(__nccwpck_require__(99836), exports); +tslib_1.__exportStar(__nccwpck_require__(59396), exports); +tslib_1.__exportStar(__nccwpck_require__(99706), exports); +tslib_1.__exportStar(__nccwpck_require__(7377), exports); +tslib_1.__exportStar(__nccwpck_require__(60351), exports); +tslib_1.__exportStar(__nccwpck_require__(9252), exports); +tslib_1.__exportStar(__nccwpck_require__(72171), exports); +tslib_1.__exportStar(__nccwpck_require__(64976), exports); +tslib_1.__exportStar(__nccwpck_require__(50991), exports); +tslib_1.__exportStar(__nccwpck_require__(99936), exports); +tslib_1.__exportStar(__nccwpck_require__(83057), exports); +tslib_1.__exportStar(__nccwpck_require__(55268), exports); +tslib_1.__exportStar(__nccwpck_require__(54482), exports); +tslib_1.__exportStar(__nccwpck_require__(3533), exports); +tslib_1.__exportStar(__nccwpck_require__(71155), exports); +tslib_1.__exportStar(__nccwpck_require__(67014), exports); +tslib_1.__exportStar(__nccwpck_require__(62539), exports); +tslib_1.__exportStar(__nccwpck_require__(73469), exports); +tslib_1.__exportStar(__nccwpck_require__(40722), exports); +tslib_1.__exportStar(__nccwpck_require__(14034), exports); +tslib_1.__exportStar(__nccwpck_require__(34567), exports); +tslib_1.__exportStar(__nccwpck_require__(43356), exports); +tslib_1.__exportStar(__nccwpck_require__(5511), exports); +tslib_1.__exportStar(__nccwpck_require__(16689), exports); +tslib_1.__exportStar(__nccwpck_require__(72174), exports); +tslib_1.__exportStar(__nccwpck_require__(89809), exports); +tslib_1.__exportStar(__nccwpck_require__(57237), exports); +tslib_1.__exportStar(__nccwpck_require__(19011), exports); +tslib_1.__exportStar(__nccwpck_require__(91272), exports); +tslib_1.__exportStar(__nccwpck_require__(34356), exports); +tslib_1.__exportStar(__nccwpck_require__(80854), exports); +tslib_1.__exportStar(__nccwpck_require__(44275), exports); +tslib_1.__exportStar(__nccwpck_require__(50944), exports); +tslib_1.__exportStar(__nccwpck_require__(54289), exports); +tslib_1.__exportStar(__nccwpck_require__(69969), exports); +tslib_1.__exportStar(__nccwpck_require__(72746), exports); +tslib_1.__exportStar(__nccwpck_require__(35583), exports); +tslib_1.__exportStar(__nccwpck_require__(59638), exports); +tslib_1.__exportStar(__nccwpck_require__(51189), exports); +//# sourceMappingURL=index.js.map + +/***/ }), + +/***/ 51189: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +const tslib_1 = __nccwpck_require__(91663); +tslib_1.__exportStar(__nccwpck_require__(50499), exports); +//# sourceMappingURL=index.js.map + +/***/ }), + +/***/ 50499: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateStackSetInput = exports.CreatedButModifiedException = exports.StaleRequestException = exports.StackSetNotFoundException = exports.OperationInProgressException = exports.OperationIdAlreadyExistsException = exports.InvalidOperationException = exports.CreateStackInstancesOutput = exports.CreateStackInstancesInput = exports.StackSetOperationPreferences = exports.DeploymentTargets = exports.CreateStackOutput = exports.CreateStackInput = exports.OnFailure = exports.LimitExceededException = exports.InsufficientCapabilitiesException = exports.CreateChangeSetOutput = exports.CreateChangeSetInput = exports.Tag = exports.RollbackConfiguration = exports.RollbackTrigger = exports.ResourceToImport = exports.Parameter = exports.ContinueUpdateRollbackOutput = exports.ContinueUpdateRollbackInput = exports.ChangeSetType = exports.ChangeSetSummary = exports.ExecutionStatus = exports.ChangeSetStatus = exports.ChangeSetNotFoundException = exports.Change = exports.ChangeType = exports.ResourceChange = exports.Replacement = exports.ModuleInfo = exports.ResourceChangeDetail = exports.ResourceTargetDefinition = exports.RequiresRecreation = exports.ResourceAttribute = exports.EvaluationType = exports.ChangeSource = exports.ChangeAction = exports.CFNRegistryException = exports.Capability = exports.TokenAlreadyExistsException = exports.CancelUpdateStackInput = exports.AutoDeployment = exports.AlreadyExistsException = exports.AccountLimit = exports.AccountGateResult = void 0; +exports.Stack = exports.StackStatus = exports.Output = exports.StackDriftInformation = exports.DescribeStacksInput = exports.DescribeStackResourcesOutput = exports.StackResource = exports.DescribeStackResourcesInput = exports.DescribeStackResourceDriftsOutput = exports.StackResourceDrift = exports.PropertyDifference = exports.DifferenceType = exports.PhysicalResourceIdContextKeyValuePair = exports.DescribeStackResourceDriftsInput = exports.DescribeStackResourceOutput = exports.StackResourceDetail = exports.StackResourceDriftInformation = exports.StackResourceDriftStatus = exports.DescribeStackResourceInput = exports.StackInstanceNotFoundException = exports.DescribeStackInstanceOutput = exports.StackInstance = exports.StackInstanceComprehensiveStatus = exports.DescribeStackInstanceInput = exports.DescribeStackEventsOutput = exports.StackEvent = exports.ResourceStatus = exports.DescribeStackEventsInput = exports.DescribeStackDriftDetectionStatusOutput = exports.StackDriftStatus = exports.StackDriftDetectionStatus = exports.DescribeStackDriftDetectionStatusInput = exports.DescribeChangeSetOutput = exports.DescribeChangeSetInput = exports.DescribeAccountLimitsOutput = exports.DescribeAccountLimitsInput = exports.TypeNotFoundException = exports.DeregisterTypeOutput = exports.DeregisterTypeInput = exports.StackSetNotEmptyException = exports.DeleteStackSetOutput = exports.DeleteStackSetInput = exports.DeleteStackInstancesOutput = exports.DeleteStackInstancesInput = exports.DeleteStackInput = exports.InvalidChangeSetStatusException = exports.DeleteChangeSetOutput = exports.DeleteChangeSetInput = exports.NameAlreadyExistsException = exports.CreateStackSetOutput = void 0; +exports.StackResourceSummary = exports.StackResourceDriftInformationSummary = exports.ListStackResourcesInput = exports.ListStackInstancesOutput = exports.StackInstanceSummary = exports.ListStackInstancesInput = exports.StackInstanceFilter = exports.ListImportsOutput = exports.ListImportsInput = exports.ListExportsOutput = exports.Export = exports.ListExportsInput = exports.ListChangeSetsOutput = exports.ListChangeSetsInput = exports.GetTemplateSummaryOutput = exports.ResourceIdentifierSummary = exports.ParameterDeclaration = exports.ParameterConstraints = exports.GetTemplateSummaryInput = exports.GetTemplateOutput = exports.GetTemplateInput = exports.TemplateStage = exports.GetStackPolicyOutput = exports.GetStackPolicyInput = exports.ExecuteChangeSetOutput = exports.ExecuteChangeSetInput = exports.EstimateTemplateCostOutput = exports.EstimateTemplateCostInput = exports.DetectStackSetDriftOutput = exports.DetectStackSetDriftInput = exports.DetectStackResourceDriftOutput = exports.DetectStackResourceDriftInput = exports.DetectStackDriftOutput = exports.DetectStackDriftInput = exports.DescribeTypeRegistrationOutput = exports.DescribeTypeRegistrationInput = exports.DescribeTypeOutput = exports.LoggingConfig = exports.DescribeTypeInput = exports.OperationNotFoundException = exports.DescribeStackSetOperationOutput = exports.StackSetOperation = exports.DescribeStackSetOperationInput = exports.DescribeStackSetOutput = exports.StackSet = exports.StackSetDriftDetectionDetails = exports.StackSetDriftStatus = exports.StackSetDriftDetectionStatus = exports.DescribeStackSetInput = exports.DescribeStacksOutput = void 0; +exports.ValidateTemplateOutput = exports.TemplateParameter = exports.ValidateTemplateInput = exports.UpdateTerminationProtectionOutput = exports.UpdateTerminationProtectionInput = exports.UpdateStackSetOutput = exports.UpdateStackSetInput = exports.UpdateStackInstancesOutput = exports.UpdateStackInstancesInput = exports.UpdateStackOutput = exports.UpdateStackInput = exports.StopStackSetOperationOutput = exports.StopStackSetOperationInput = exports.SignalResourceInput = exports.ResourceSignalStatus = exports.SetTypeDefaultVersionOutput = exports.SetTypeDefaultVersionInput = exports.SetStackPolicyInput = exports.RegisterTypeOutput = exports.RegisterTypeInput = exports.RecordHandlerProgressOutput = exports.RecordHandlerProgressInput = exports.HandlerErrorCode = exports.OperationStatus = exports.OperationStatusCheckFailedException = exports.InvalidStateTransitionException = exports.ListTypeVersionsOutput = exports.TypeVersionSummary = exports.ListTypeVersionsInput = exports.ListTypesOutput = exports.TypeSummary = exports.ListTypesInput = exports.ListTypeRegistrationsOutput = exports.ListTypeRegistrationsInput = exports.ListStackSetsOutput = exports.StackSetSummary = exports.ListStackSetsInput = exports.ListStackSetOperationsOutput = exports.StackSetOperationSummary = exports.ListStackSetOperationsInput = exports.ListStackSetOperationResultsOutput = exports.StackSetOperationResultSummary = exports.ListStackSetOperationResultsInput = exports.ListStacksOutput = exports.StackSummary = exports.StackDriftInformationSummary = exports.ListStacksInput = exports.ListStackResourcesOutput = void 0; +var AccountGateResult; +(function (AccountGateResult) { + AccountGateResult.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AccountGateResult = exports.AccountGateResult || (exports.AccountGateResult = {})); +var AccountLimit; +(function (AccountLimit) { + AccountLimit.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AccountLimit = exports.AccountLimit || (exports.AccountLimit = {})); +var AlreadyExistsException; +(function (AlreadyExistsException) { + AlreadyExistsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AlreadyExistsException = exports.AlreadyExistsException || (exports.AlreadyExistsException = {})); +var AutoDeployment; +(function (AutoDeployment) { + AutoDeployment.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AutoDeployment = exports.AutoDeployment || (exports.AutoDeployment = {})); +var CancelUpdateStackInput; +(function (CancelUpdateStackInput) { + CancelUpdateStackInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CancelUpdateStackInput = exports.CancelUpdateStackInput || (exports.CancelUpdateStackInput = {})); +var TokenAlreadyExistsException; +(function (TokenAlreadyExistsException) { + TokenAlreadyExistsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TokenAlreadyExistsException = exports.TokenAlreadyExistsException || (exports.TokenAlreadyExistsException = {})); +var Capability; +(function (Capability) { + Capability["CAPABILITY_AUTO_EXPAND"] = "CAPABILITY_AUTO_EXPAND"; + Capability["CAPABILITY_IAM"] = "CAPABILITY_IAM"; + Capability["CAPABILITY_NAMED_IAM"] = "CAPABILITY_NAMED_IAM"; +})(Capability = exports.Capability || (exports.Capability = {})); +var CFNRegistryException; +(function (CFNRegistryException) { + CFNRegistryException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CFNRegistryException = exports.CFNRegistryException || (exports.CFNRegistryException = {})); +var ChangeAction; +(function (ChangeAction) { + ChangeAction["Add"] = "Add"; + ChangeAction["Dynamic"] = "Dynamic"; + ChangeAction["Import"] = "Import"; + ChangeAction["Modify"] = "Modify"; + ChangeAction["Remove"] = "Remove"; +})(ChangeAction = exports.ChangeAction || (exports.ChangeAction = {})); +var ChangeSource; +(function (ChangeSource) { + ChangeSource["Automatic"] = "Automatic"; + ChangeSource["DirectModification"] = "DirectModification"; + ChangeSource["ParameterReference"] = "ParameterReference"; + ChangeSource["ResourceAttribute"] = "ResourceAttribute"; + ChangeSource["ResourceReference"] = "ResourceReference"; +})(ChangeSource = exports.ChangeSource || (exports.ChangeSource = {})); +var EvaluationType; +(function (EvaluationType) { + EvaluationType["Dynamic"] = "Dynamic"; + EvaluationType["Static"] = "Static"; +})(EvaluationType = exports.EvaluationType || (exports.EvaluationType = {})); +var ResourceAttribute; +(function (ResourceAttribute) { + ResourceAttribute["CreationPolicy"] = "CreationPolicy"; + ResourceAttribute["DeletionPolicy"] = "DeletionPolicy"; + ResourceAttribute["Metadata"] = "Metadata"; + ResourceAttribute["Properties"] = "Properties"; + ResourceAttribute["Tags"] = "Tags"; + ResourceAttribute["UpdatePolicy"] = "UpdatePolicy"; +})(ResourceAttribute = exports.ResourceAttribute || (exports.ResourceAttribute = {})); +var RequiresRecreation; +(function (RequiresRecreation) { + RequiresRecreation["Always"] = "Always"; + RequiresRecreation["Conditionally"] = "Conditionally"; + RequiresRecreation["Never"] = "Never"; +})(RequiresRecreation = exports.RequiresRecreation || (exports.RequiresRecreation = {})); +var ResourceTargetDefinition; +(function (ResourceTargetDefinition) { + ResourceTargetDefinition.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceTargetDefinition = exports.ResourceTargetDefinition || (exports.ResourceTargetDefinition = {})); +var ResourceChangeDetail; +(function (ResourceChangeDetail) { + ResourceChangeDetail.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceChangeDetail = exports.ResourceChangeDetail || (exports.ResourceChangeDetail = {})); +var ModuleInfo; +(function (ModuleInfo) { + ModuleInfo.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ModuleInfo = exports.ModuleInfo || (exports.ModuleInfo = {})); +var Replacement; +(function (Replacement) { + Replacement["Conditional"] = "Conditional"; + Replacement["False"] = "False"; + Replacement["True"] = "True"; +})(Replacement = exports.Replacement || (exports.Replacement = {})); +var ResourceChange; +(function (ResourceChange) { + ResourceChange.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceChange = exports.ResourceChange || (exports.ResourceChange = {})); +var ChangeType; +(function (ChangeType) { + ChangeType["Resource"] = "Resource"; +})(ChangeType = exports.ChangeType || (exports.ChangeType = {})); +var Change; +(function (Change) { + Change.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Change = exports.Change || (exports.Change = {})); +var ChangeSetNotFoundException; +(function (ChangeSetNotFoundException) { + ChangeSetNotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ChangeSetNotFoundException = exports.ChangeSetNotFoundException || (exports.ChangeSetNotFoundException = {})); +var ChangeSetStatus; +(function (ChangeSetStatus) { + ChangeSetStatus["CREATE_COMPLETE"] = "CREATE_COMPLETE"; + ChangeSetStatus["CREATE_IN_PROGRESS"] = "CREATE_IN_PROGRESS"; + ChangeSetStatus["CREATE_PENDING"] = "CREATE_PENDING"; + ChangeSetStatus["DELETE_COMPLETE"] = "DELETE_COMPLETE"; + ChangeSetStatus["DELETE_FAILED"] = "DELETE_FAILED"; + ChangeSetStatus["DELETE_IN_PROGRESS"] = "DELETE_IN_PROGRESS"; + ChangeSetStatus["DELETE_PENDING"] = "DELETE_PENDING"; + ChangeSetStatus["FAILED"] = "FAILED"; +})(ChangeSetStatus = exports.ChangeSetStatus || (exports.ChangeSetStatus = {})); +var ExecutionStatus; +(function (ExecutionStatus) { + ExecutionStatus["AVAILABLE"] = "AVAILABLE"; + ExecutionStatus["EXECUTE_COMPLETE"] = "EXECUTE_COMPLETE"; + ExecutionStatus["EXECUTE_FAILED"] = "EXECUTE_FAILED"; + ExecutionStatus["EXECUTE_IN_PROGRESS"] = "EXECUTE_IN_PROGRESS"; + ExecutionStatus["OBSOLETE"] = "OBSOLETE"; + ExecutionStatus["UNAVAILABLE"] = "UNAVAILABLE"; +})(ExecutionStatus = exports.ExecutionStatus || (exports.ExecutionStatus = {})); +var ChangeSetSummary; +(function (ChangeSetSummary) { + ChangeSetSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ChangeSetSummary = exports.ChangeSetSummary || (exports.ChangeSetSummary = {})); +var ChangeSetType; +(function (ChangeSetType) { + ChangeSetType["CREATE"] = "CREATE"; + ChangeSetType["IMPORT"] = "IMPORT"; + ChangeSetType["UPDATE"] = "UPDATE"; +})(ChangeSetType = exports.ChangeSetType || (exports.ChangeSetType = {})); +var ContinueUpdateRollbackInput; +(function (ContinueUpdateRollbackInput) { + ContinueUpdateRollbackInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ContinueUpdateRollbackInput = exports.ContinueUpdateRollbackInput || (exports.ContinueUpdateRollbackInput = {})); +var ContinueUpdateRollbackOutput; +(function (ContinueUpdateRollbackOutput) { + ContinueUpdateRollbackOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ContinueUpdateRollbackOutput = exports.ContinueUpdateRollbackOutput || (exports.ContinueUpdateRollbackOutput = {})); +var Parameter; +(function (Parameter) { + Parameter.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Parameter = exports.Parameter || (exports.Parameter = {})); +var ResourceToImport; +(function (ResourceToImport) { + ResourceToImport.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceToImport = exports.ResourceToImport || (exports.ResourceToImport = {})); +var RollbackTrigger; +(function (RollbackTrigger) { + RollbackTrigger.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RollbackTrigger = exports.RollbackTrigger || (exports.RollbackTrigger = {})); +var RollbackConfiguration; +(function (RollbackConfiguration) { + RollbackConfiguration.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RollbackConfiguration = exports.RollbackConfiguration || (exports.RollbackConfiguration = {})); +var Tag; +(function (Tag) { + Tag.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Tag = exports.Tag || (exports.Tag = {})); +var CreateChangeSetInput; +(function (CreateChangeSetInput) { + CreateChangeSetInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateChangeSetInput = exports.CreateChangeSetInput || (exports.CreateChangeSetInput = {})); +var CreateChangeSetOutput; +(function (CreateChangeSetOutput) { + CreateChangeSetOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateChangeSetOutput = exports.CreateChangeSetOutput || (exports.CreateChangeSetOutput = {})); +var InsufficientCapabilitiesException; +(function (InsufficientCapabilitiesException) { + InsufficientCapabilitiesException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InsufficientCapabilitiesException = exports.InsufficientCapabilitiesException || (exports.InsufficientCapabilitiesException = {})); +var LimitExceededException; +(function (LimitExceededException) { + LimitExceededException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LimitExceededException = exports.LimitExceededException || (exports.LimitExceededException = {})); +var OnFailure; +(function (OnFailure) { + OnFailure["DELETE"] = "DELETE"; + OnFailure["DO_NOTHING"] = "DO_NOTHING"; + OnFailure["ROLLBACK"] = "ROLLBACK"; +})(OnFailure = exports.OnFailure || (exports.OnFailure = {})); +var CreateStackInput; +(function (CreateStackInput) { + CreateStackInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateStackInput = exports.CreateStackInput || (exports.CreateStackInput = {})); +var CreateStackOutput; +(function (CreateStackOutput) { + CreateStackOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateStackOutput = exports.CreateStackOutput || (exports.CreateStackOutput = {})); +var DeploymentTargets; +(function (DeploymentTargets) { + DeploymentTargets.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeploymentTargets = exports.DeploymentTargets || (exports.DeploymentTargets = {})); +var StackSetOperationPreferences; +(function (StackSetOperationPreferences) { + StackSetOperationPreferences.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackSetOperationPreferences = exports.StackSetOperationPreferences || (exports.StackSetOperationPreferences = {})); +var CreateStackInstancesInput; +(function (CreateStackInstancesInput) { + CreateStackInstancesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateStackInstancesInput = exports.CreateStackInstancesInput || (exports.CreateStackInstancesInput = {})); +var CreateStackInstancesOutput; +(function (CreateStackInstancesOutput) { + CreateStackInstancesOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateStackInstancesOutput = exports.CreateStackInstancesOutput || (exports.CreateStackInstancesOutput = {})); +var InvalidOperationException; +(function (InvalidOperationException) { + InvalidOperationException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidOperationException = exports.InvalidOperationException || (exports.InvalidOperationException = {})); +var OperationIdAlreadyExistsException; +(function (OperationIdAlreadyExistsException) { + OperationIdAlreadyExistsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(OperationIdAlreadyExistsException = exports.OperationIdAlreadyExistsException || (exports.OperationIdAlreadyExistsException = {})); +var OperationInProgressException; +(function (OperationInProgressException) { + OperationInProgressException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(OperationInProgressException = exports.OperationInProgressException || (exports.OperationInProgressException = {})); +var StackSetNotFoundException; +(function (StackSetNotFoundException) { + StackSetNotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackSetNotFoundException = exports.StackSetNotFoundException || (exports.StackSetNotFoundException = {})); +var StaleRequestException; +(function (StaleRequestException) { + StaleRequestException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StaleRequestException = exports.StaleRequestException || (exports.StaleRequestException = {})); +var CreatedButModifiedException; +(function (CreatedButModifiedException) { + CreatedButModifiedException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreatedButModifiedException = exports.CreatedButModifiedException || (exports.CreatedButModifiedException = {})); +var CreateStackSetInput; +(function (CreateStackSetInput) { + CreateStackSetInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateStackSetInput = exports.CreateStackSetInput || (exports.CreateStackSetInput = {})); +var CreateStackSetOutput; +(function (CreateStackSetOutput) { + CreateStackSetOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateStackSetOutput = exports.CreateStackSetOutput || (exports.CreateStackSetOutput = {})); +var NameAlreadyExistsException; +(function (NameAlreadyExistsException) { + NameAlreadyExistsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(NameAlreadyExistsException = exports.NameAlreadyExistsException || (exports.NameAlreadyExistsException = {})); +var DeleteChangeSetInput; +(function (DeleteChangeSetInput) { + DeleteChangeSetInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteChangeSetInput = exports.DeleteChangeSetInput || (exports.DeleteChangeSetInput = {})); +var DeleteChangeSetOutput; +(function (DeleteChangeSetOutput) { + DeleteChangeSetOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteChangeSetOutput = exports.DeleteChangeSetOutput || (exports.DeleteChangeSetOutput = {})); +var InvalidChangeSetStatusException; +(function (InvalidChangeSetStatusException) { + InvalidChangeSetStatusException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidChangeSetStatusException = exports.InvalidChangeSetStatusException || (exports.InvalidChangeSetStatusException = {})); +var DeleteStackInput; +(function (DeleteStackInput) { + DeleteStackInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteStackInput = exports.DeleteStackInput || (exports.DeleteStackInput = {})); +var DeleteStackInstancesInput; +(function (DeleteStackInstancesInput) { + DeleteStackInstancesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteStackInstancesInput = exports.DeleteStackInstancesInput || (exports.DeleteStackInstancesInput = {})); +var DeleteStackInstancesOutput; +(function (DeleteStackInstancesOutput) { + DeleteStackInstancesOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteStackInstancesOutput = exports.DeleteStackInstancesOutput || (exports.DeleteStackInstancesOutput = {})); +var DeleteStackSetInput; +(function (DeleteStackSetInput) { + DeleteStackSetInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteStackSetInput = exports.DeleteStackSetInput || (exports.DeleteStackSetInput = {})); +var DeleteStackSetOutput; +(function (DeleteStackSetOutput) { + DeleteStackSetOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteStackSetOutput = exports.DeleteStackSetOutput || (exports.DeleteStackSetOutput = {})); +var StackSetNotEmptyException; +(function (StackSetNotEmptyException) { + StackSetNotEmptyException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackSetNotEmptyException = exports.StackSetNotEmptyException || (exports.StackSetNotEmptyException = {})); +var DeregisterTypeInput; +(function (DeregisterTypeInput) { + DeregisterTypeInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeregisterTypeInput = exports.DeregisterTypeInput || (exports.DeregisterTypeInput = {})); +var DeregisterTypeOutput; +(function (DeregisterTypeOutput) { + DeregisterTypeOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeregisterTypeOutput = exports.DeregisterTypeOutput || (exports.DeregisterTypeOutput = {})); +var TypeNotFoundException; +(function (TypeNotFoundException) { + TypeNotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TypeNotFoundException = exports.TypeNotFoundException || (exports.TypeNotFoundException = {})); +var DescribeAccountLimitsInput; +(function (DescribeAccountLimitsInput) { + DescribeAccountLimitsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAccountLimitsInput = exports.DescribeAccountLimitsInput || (exports.DescribeAccountLimitsInput = {})); +var DescribeAccountLimitsOutput; +(function (DescribeAccountLimitsOutput) { + DescribeAccountLimitsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAccountLimitsOutput = exports.DescribeAccountLimitsOutput || (exports.DescribeAccountLimitsOutput = {})); +var DescribeChangeSetInput; +(function (DescribeChangeSetInput) { + DescribeChangeSetInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeChangeSetInput = exports.DescribeChangeSetInput || (exports.DescribeChangeSetInput = {})); +var DescribeChangeSetOutput; +(function (DescribeChangeSetOutput) { + DescribeChangeSetOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeChangeSetOutput = exports.DescribeChangeSetOutput || (exports.DescribeChangeSetOutput = {})); +var DescribeStackDriftDetectionStatusInput; +(function (DescribeStackDriftDetectionStatusInput) { + DescribeStackDriftDetectionStatusInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackDriftDetectionStatusInput = exports.DescribeStackDriftDetectionStatusInput || (exports.DescribeStackDriftDetectionStatusInput = {})); +var StackDriftDetectionStatus; +(function (StackDriftDetectionStatus) { + StackDriftDetectionStatus["DETECTION_COMPLETE"] = "DETECTION_COMPLETE"; + StackDriftDetectionStatus["DETECTION_FAILED"] = "DETECTION_FAILED"; + StackDriftDetectionStatus["DETECTION_IN_PROGRESS"] = "DETECTION_IN_PROGRESS"; +})(StackDriftDetectionStatus = exports.StackDriftDetectionStatus || (exports.StackDriftDetectionStatus = {})); +var StackDriftStatus; +(function (StackDriftStatus) { + StackDriftStatus["DRIFTED"] = "DRIFTED"; + StackDriftStatus["IN_SYNC"] = "IN_SYNC"; + StackDriftStatus["NOT_CHECKED"] = "NOT_CHECKED"; + StackDriftStatus["UNKNOWN"] = "UNKNOWN"; +})(StackDriftStatus = exports.StackDriftStatus || (exports.StackDriftStatus = {})); +var DescribeStackDriftDetectionStatusOutput; +(function (DescribeStackDriftDetectionStatusOutput) { + DescribeStackDriftDetectionStatusOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackDriftDetectionStatusOutput = exports.DescribeStackDriftDetectionStatusOutput || (exports.DescribeStackDriftDetectionStatusOutput = {})); +var DescribeStackEventsInput; +(function (DescribeStackEventsInput) { + DescribeStackEventsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackEventsInput = exports.DescribeStackEventsInput || (exports.DescribeStackEventsInput = {})); +var ResourceStatus; +(function (ResourceStatus) { + ResourceStatus["CREATE_COMPLETE"] = "CREATE_COMPLETE"; + ResourceStatus["CREATE_FAILED"] = "CREATE_FAILED"; + ResourceStatus["CREATE_IN_PROGRESS"] = "CREATE_IN_PROGRESS"; + ResourceStatus["DELETE_COMPLETE"] = "DELETE_COMPLETE"; + ResourceStatus["DELETE_FAILED"] = "DELETE_FAILED"; + ResourceStatus["DELETE_IN_PROGRESS"] = "DELETE_IN_PROGRESS"; + ResourceStatus["DELETE_SKIPPED"] = "DELETE_SKIPPED"; + ResourceStatus["IMPORT_COMPLETE"] = "IMPORT_COMPLETE"; + ResourceStatus["IMPORT_FAILED"] = "IMPORT_FAILED"; + ResourceStatus["IMPORT_IN_PROGRESS"] = "IMPORT_IN_PROGRESS"; + ResourceStatus["IMPORT_ROLLBACK_COMPLETE"] = "IMPORT_ROLLBACK_COMPLETE"; + ResourceStatus["IMPORT_ROLLBACK_FAILED"] = "IMPORT_ROLLBACK_FAILED"; + ResourceStatus["IMPORT_ROLLBACK_IN_PROGRESS"] = "IMPORT_ROLLBACK_IN_PROGRESS"; + ResourceStatus["UPDATE_COMPLETE"] = "UPDATE_COMPLETE"; + ResourceStatus["UPDATE_FAILED"] = "UPDATE_FAILED"; + ResourceStatus["UPDATE_IN_PROGRESS"] = "UPDATE_IN_PROGRESS"; +})(ResourceStatus = exports.ResourceStatus || (exports.ResourceStatus = {})); +var StackEvent; +(function (StackEvent) { + StackEvent.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackEvent = exports.StackEvent || (exports.StackEvent = {})); +var DescribeStackEventsOutput; +(function (DescribeStackEventsOutput) { + DescribeStackEventsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackEventsOutput = exports.DescribeStackEventsOutput || (exports.DescribeStackEventsOutput = {})); +var DescribeStackInstanceInput; +(function (DescribeStackInstanceInput) { + DescribeStackInstanceInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackInstanceInput = exports.DescribeStackInstanceInput || (exports.DescribeStackInstanceInput = {})); +var StackInstanceComprehensiveStatus; +(function (StackInstanceComprehensiveStatus) { + StackInstanceComprehensiveStatus.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackInstanceComprehensiveStatus = exports.StackInstanceComprehensiveStatus || (exports.StackInstanceComprehensiveStatus = {})); +var StackInstance; +(function (StackInstance) { + StackInstance.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackInstance = exports.StackInstance || (exports.StackInstance = {})); +var DescribeStackInstanceOutput; +(function (DescribeStackInstanceOutput) { + DescribeStackInstanceOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackInstanceOutput = exports.DescribeStackInstanceOutput || (exports.DescribeStackInstanceOutput = {})); +var StackInstanceNotFoundException; +(function (StackInstanceNotFoundException) { + StackInstanceNotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackInstanceNotFoundException = exports.StackInstanceNotFoundException || (exports.StackInstanceNotFoundException = {})); +var DescribeStackResourceInput; +(function (DescribeStackResourceInput) { + DescribeStackResourceInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackResourceInput = exports.DescribeStackResourceInput || (exports.DescribeStackResourceInput = {})); +var StackResourceDriftStatus; +(function (StackResourceDriftStatus) { + StackResourceDriftStatus["DELETED"] = "DELETED"; + StackResourceDriftStatus["IN_SYNC"] = "IN_SYNC"; + StackResourceDriftStatus["MODIFIED"] = "MODIFIED"; + StackResourceDriftStatus["NOT_CHECKED"] = "NOT_CHECKED"; +})(StackResourceDriftStatus = exports.StackResourceDriftStatus || (exports.StackResourceDriftStatus = {})); +var StackResourceDriftInformation; +(function (StackResourceDriftInformation) { + StackResourceDriftInformation.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackResourceDriftInformation = exports.StackResourceDriftInformation || (exports.StackResourceDriftInformation = {})); +var StackResourceDetail; +(function (StackResourceDetail) { + StackResourceDetail.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackResourceDetail = exports.StackResourceDetail || (exports.StackResourceDetail = {})); +var DescribeStackResourceOutput; +(function (DescribeStackResourceOutput) { + DescribeStackResourceOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackResourceOutput = exports.DescribeStackResourceOutput || (exports.DescribeStackResourceOutput = {})); +var DescribeStackResourceDriftsInput; +(function (DescribeStackResourceDriftsInput) { + DescribeStackResourceDriftsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackResourceDriftsInput = exports.DescribeStackResourceDriftsInput || (exports.DescribeStackResourceDriftsInput = {})); +var PhysicalResourceIdContextKeyValuePair; +(function (PhysicalResourceIdContextKeyValuePair) { + PhysicalResourceIdContextKeyValuePair.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PhysicalResourceIdContextKeyValuePair = exports.PhysicalResourceIdContextKeyValuePair || (exports.PhysicalResourceIdContextKeyValuePair = {})); +var DifferenceType; +(function (DifferenceType) { + DifferenceType["ADD"] = "ADD"; + DifferenceType["NOT_EQUAL"] = "NOT_EQUAL"; + DifferenceType["REMOVE"] = "REMOVE"; +})(DifferenceType = exports.DifferenceType || (exports.DifferenceType = {})); +var PropertyDifference; +(function (PropertyDifference) { + PropertyDifference.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PropertyDifference = exports.PropertyDifference || (exports.PropertyDifference = {})); +var StackResourceDrift; +(function (StackResourceDrift) { + StackResourceDrift.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackResourceDrift = exports.StackResourceDrift || (exports.StackResourceDrift = {})); +var DescribeStackResourceDriftsOutput; +(function (DescribeStackResourceDriftsOutput) { + DescribeStackResourceDriftsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackResourceDriftsOutput = exports.DescribeStackResourceDriftsOutput || (exports.DescribeStackResourceDriftsOutput = {})); +var DescribeStackResourcesInput; +(function (DescribeStackResourcesInput) { + DescribeStackResourcesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackResourcesInput = exports.DescribeStackResourcesInput || (exports.DescribeStackResourcesInput = {})); +var StackResource; +(function (StackResource) { + StackResource.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackResource = exports.StackResource || (exports.StackResource = {})); +var DescribeStackResourcesOutput; +(function (DescribeStackResourcesOutput) { + DescribeStackResourcesOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackResourcesOutput = exports.DescribeStackResourcesOutput || (exports.DescribeStackResourcesOutput = {})); +var DescribeStacksInput; +(function (DescribeStacksInput) { + DescribeStacksInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStacksInput = exports.DescribeStacksInput || (exports.DescribeStacksInput = {})); +var StackDriftInformation; +(function (StackDriftInformation) { + StackDriftInformation.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackDriftInformation = exports.StackDriftInformation || (exports.StackDriftInformation = {})); +var Output; +(function (Output) { + Output.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Output = exports.Output || (exports.Output = {})); +var StackStatus; +(function (StackStatus) { + StackStatus["CREATE_COMPLETE"] = "CREATE_COMPLETE"; + StackStatus["CREATE_FAILED"] = "CREATE_FAILED"; + StackStatus["CREATE_IN_PROGRESS"] = "CREATE_IN_PROGRESS"; + StackStatus["DELETE_COMPLETE"] = "DELETE_COMPLETE"; + StackStatus["DELETE_FAILED"] = "DELETE_FAILED"; + StackStatus["DELETE_IN_PROGRESS"] = "DELETE_IN_PROGRESS"; + StackStatus["IMPORT_COMPLETE"] = "IMPORT_COMPLETE"; + StackStatus["IMPORT_IN_PROGRESS"] = "IMPORT_IN_PROGRESS"; + StackStatus["IMPORT_ROLLBACK_COMPLETE"] = "IMPORT_ROLLBACK_COMPLETE"; + StackStatus["IMPORT_ROLLBACK_FAILED"] = "IMPORT_ROLLBACK_FAILED"; + StackStatus["IMPORT_ROLLBACK_IN_PROGRESS"] = "IMPORT_ROLLBACK_IN_PROGRESS"; + StackStatus["REVIEW_IN_PROGRESS"] = "REVIEW_IN_PROGRESS"; + StackStatus["ROLLBACK_COMPLETE"] = "ROLLBACK_COMPLETE"; + StackStatus["ROLLBACK_FAILED"] = "ROLLBACK_FAILED"; + StackStatus["ROLLBACK_IN_PROGRESS"] = "ROLLBACK_IN_PROGRESS"; + StackStatus["UPDATE_COMPLETE"] = "UPDATE_COMPLETE"; + StackStatus["UPDATE_COMPLETE_CLEANUP_IN_PROGRESS"] = "UPDATE_COMPLETE_CLEANUP_IN_PROGRESS"; + StackStatus["UPDATE_IN_PROGRESS"] = "UPDATE_IN_PROGRESS"; + StackStatus["UPDATE_ROLLBACK_COMPLETE"] = "UPDATE_ROLLBACK_COMPLETE"; + StackStatus["UPDATE_ROLLBACK_COMPLETE_CLEANUP_IN_PROGRESS"] = "UPDATE_ROLLBACK_COMPLETE_CLEANUP_IN_PROGRESS"; + StackStatus["UPDATE_ROLLBACK_FAILED"] = "UPDATE_ROLLBACK_FAILED"; + StackStatus["UPDATE_ROLLBACK_IN_PROGRESS"] = "UPDATE_ROLLBACK_IN_PROGRESS"; +})(StackStatus = exports.StackStatus || (exports.StackStatus = {})); +var Stack; +(function (Stack) { + Stack.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Stack = exports.Stack || (exports.Stack = {})); +var DescribeStacksOutput; +(function (DescribeStacksOutput) { + DescribeStacksOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStacksOutput = exports.DescribeStacksOutput || (exports.DescribeStacksOutput = {})); +var DescribeStackSetInput; +(function (DescribeStackSetInput) { + DescribeStackSetInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackSetInput = exports.DescribeStackSetInput || (exports.DescribeStackSetInput = {})); +var StackSetDriftDetectionStatus; +(function (StackSetDriftDetectionStatus) { + StackSetDriftDetectionStatus["COMPLETED"] = "COMPLETED"; + StackSetDriftDetectionStatus["FAILED"] = "FAILED"; + StackSetDriftDetectionStatus["IN_PROGRESS"] = "IN_PROGRESS"; + StackSetDriftDetectionStatus["PARTIAL_SUCCESS"] = "PARTIAL_SUCCESS"; + StackSetDriftDetectionStatus["STOPPED"] = "STOPPED"; +})(StackSetDriftDetectionStatus = exports.StackSetDriftDetectionStatus || (exports.StackSetDriftDetectionStatus = {})); +var StackSetDriftStatus; +(function (StackSetDriftStatus) { + StackSetDriftStatus["DRIFTED"] = "DRIFTED"; + StackSetDriftStatus["IN_SYNC"] = "IN_SYNC"; + StackSetDriftStatus["NOT_CHECKED"] = "NOT_CHECKED"; +})(StackSetDriftStatus = exports.StackSetDriftStatus || (exports.StackSetDriftStatus = {})); +var StackSetDriftDetectionDetails; +(function (StackSetDriftDetectionDetails) { + StackSetDriftDetectionDetails.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackSetDriftDetectionDetails = exports.StackSetDriftDetectionDetails || (exports.StackSetDriftDetectionDetails = {})); +var StackSet; +(function (StackSet) { + StackSet.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackSet = exports.StackSet || (exports.StackSet = {})); +var DescribeStackSetOutput; +(function (DescribeStackSetOutput) { + DescribeStackSetOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackSetOutput = exports.DescribeStackSetOutput || (exports.DescribeStackSetOutput = {})); +var DescribeStackSetOperationInput; +(function (DescribeStackSetOperationInput) { + DescribeStackSetOperationInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackSetOperationInput = exports.DescribeStackSetOperationInput || (exports.DescribeStackSetOperationInput = {})); +var StackSetOperation; +(function (StackSetOperation) { + StackSetOperation.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackSetOperation = exports.StackSetOperation || (exports.StackSetOperation = {})); +var DescribeStackSetOperationOutput; +(function (DescribeStackSetOperationOutput) { + DescribeStackSetOperationOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStackSetOperationOutput = exports.DescribeStackSetOperationOutput || (exports.DescribeStackSetOperationOutput = {})); +var OperationNotFoundException; +(function (OperationNotFoundException) { + OperationNotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(OperationNotFoundException = exports.OperationNotFoundException || (exports.OperationNotFoundException = {})); +var DescribeTypeInput; +(function (DescribeTypeInput) { + DescribeTypeInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeTypeInput = exports.DescribeTypeInput || (exports.DescribeTypeInput = {})); +var LoggingConfig; +(function (LoggingConfig) { + LoggingConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LoggingConfig = exports.LoggingConfig || (exports.LoggingConfig = {})); +var DescribeTypeOutput; +(function (DescribeTypeOutput) { + DescribeTypeOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeTypeOutput = exports.DescribeTypeOutput || (exports.DescribeTypeOutput = {})); +var DescribeTypeRegistrationInput; +(function (DescribeTypeRegistrationInput) { + DescribeTypeRegistrationInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeTypeRegistrationInput = exports.DescribeTypeRegistrationInput || (exports.DescribeTypeRegistrationInput = {})); +var DescribeTypeRegistrationOutput; +(function (DescribeTypeRegistrationOutput) { + DescribeTypeRegistrationOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeTypeRegistrationOutput = exports.DescribeTypeRegistrationOutput || (exports.DescribeTypeRegistrationOutput = {})); +var DetectStackDriftInput; +(function (DetectStackDriftInput) { + DetectStackDriftInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetectStackDriftInput = exports.DetectStackDriftInput || (exports.DetectStackDriftInput = {})); +var DetectStackDriftOutput; +(function (DetectStackDriftOutput) { + DetectStackDriftOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetectStackDriftOutput = exports.DetectStackDriftOutput || (exports.DetectStackDriftOutput = {})); +var DetectStackResourceDriftInput; +(function (DetectStackResourceDriftInput) { + DetectStackResourceDriftInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetectStackResourceDriftInput = exports.DetectStackResourceDriftInput || (exports.DetectStackResourceDriftInput = {})); +var DetectStackResourceDriftOutput; +(function (DetectStackResourceDriftOutput) { + DetectStackResourceDriftOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetectStackResourceDriftOutput = exports.DetectStackResourceDriftOutput || (exports.DetectStackResourceDriftOutput = {})); +var DetectStackSetDriftInput; +(function (DetectStackSetDriftInput) { + DetectStackSetDriftInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetectStackSetDriftInput = exports.DetectStackSetDriftInput || (exports.DetectStackSetDriftInput = {})); +var DetectStackSetDriftOutput; +(function (DetectStackSetDriftOutput) { + DetectStackSetDriftOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetectStackSetDriftOutput = exports.DetectStackSetDriftOutput || (exports.DetectStackSetDriftOutput = {})); +var EstimateTemplateCostInput; +(function (EstimateTemplateCostInput) { + EstimateTemplateCostInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(EstimateTemplateCostInput = exports.EstimateTemplateCostInput || (exports.EstimateTemplateCostInput = {})); +var EstimateTemplateCostOutput; +(function (EstimateTemplateCostOutput) { + EstimateTemplateCostOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(EstimateTemplateCostOutput = exports.EstimateTemplateCostOutput || (exports.EstimateTemplateCostOutput = {})); +var ExecuteChangeSetInput; +(function (ExecuteChangeSetInput) { + ExecuteChangeSetInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ExecuteChangeSetInput = exports.ExecuteChangeSetInput || (exports.ExecuteChangeSetInput = {})); +var ExecuteChangeSetOutput; +(function (ExecuteChangeSetOutput) { + ExecuteChangeSetOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ExecuteChangeSetOutput = exports.ExecuteChangeSetOutput || (exports.ExecuteChangeSetOutput = {})); +var GetStackPolicyInput; +(function (GetStackPolicyInput) { + GetStackPolicyInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetStackPolicyInput = exports.GetStackPolicyInput || (exports.GetStackPolicyInput = {})); +var GetStackPolicyOutput; +(function (GetStackPolicyOutput) { + GetStackPolicyOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetStackPolicyOutput = exports.GetStackPolicyOutput || (exports.GetStackPolicyOutput = {})); +var TemplateStage; +(function (TemplateStage) { + TemplateStage["Original"] = "Original"; + TemplateStage["Processed"] = "Processed"; +})(TemplateStage = exports.TemplateStage || (exports.TemplateStage = {})); +var GetTemplateInput; +(function (GetTemplateInput) { + GetTemplateInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetTemplateInput = exports.GetTemplateInput || (exports.GetTemplateInput = {})); +var GetTemplateOutput; +(function (GetTemplateOutput) { + GetTemplateOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetTemplateOutput = exports.GetTemplateOutput || (exports.GetTemplateOutput = {})); +var GetTemplateSummaryInput; +(function (GetTemplateSummaryInput) { + GetTemplateSummaryInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetTemplateSummaryInput = exports.GetTemplateSummaryInput || (exports.GetTemplateSummaryInput = {})); +var ParameterConstraints; +(function (ParameterConstraints) { + ParameterConstraints.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ParameterConstraints = exports.ParameterConstraints || (exports.ParameterConstraints = {})); +var ParameterDeclaration; +(function (ParameterDeclaration) { + ParameterDeclaration.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ParameterDeclaration = exports.ParameterDeclaration || (exports.ParameterDeclaration = {})); +var ResourceIdentifierSummary; +(function (ResourceIdentifierSummary) { + ResourceIdentifierSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceIdentifierSummary = exports.ResourceIdentifierSummary || (exports.ResourceIdentifierSummary = {})); +var GetTemplateSummaryOutput; +(function (GetTemplateSummaryOutput) { + GetTemplateSummaryOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetTemplateSummaryOutput = exports.GetTemplateSummaryOutput || (exports.GetTemplateSummaryOutput = {})); +var ListChangeSetsInput; +(function (ListChangeSetsInput) { + ListChangeSetsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListChangeSetsInput = exports.ListChangeSetsInput || (exports.ListChangeSetsInput = {})); +var ListChangeSetsOutput; +(function (ListChangeSetsOutput) { + ListChangeSetsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListChangeSetsOutput = exports.ListChangeSetsOutput || (exports.ListChangeSetsOutput = {})); +var ListExportsInput; +(function (ListExportsInput) { + ListExportsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListExportsInput = exports.ListExportsInput || (exports.ListExportsInput = {})); +var Export; +(function (Export) { + Export.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Export = exports.Export || (exports.Export = {})); +var ListExportsOutput; +(function (ListExportsOutput) { + ListExportsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListExportsOutput = exports.ListExportsOutput || (exports.ListExportsOutput = {})); +var ListImportsInput; +(function (ListImportsInput) { + ListImportsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListImportsInput = exports.ListImportsInput || (exports.ListImportsInput = {})); +var ListImportsOutput; +(function (ListImportsOutput) { + ListImportsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListImportsOutput = exports.ListImportsOutput || (exports.ListImportsOutput = {})); +var StackInstanceFilter; +(function (StackInstanceFilter) { + StackInstanceFilter.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackInstanceFilter = exports.StackInstanceFilter || (exports.StackInstanceFilter = {})); +var ListStackInstancesInput; +(function (ListStackInstancesInput) { + ListStackInstancesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStackInstancesInput = exports.ListStackInstancesInput || (exports.ListStackInstancesInput = {})); +var StackInstanceSummary; +(function (StackInstanceSummary) { + StackInstanceSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackInstanceSummary = exports.StackInstanceSummary || (exports.StackInstanceSummary = {})); +var ListStackInstancesOutput; +(function (ListStackInstancesOutput) { + ListStackInstancesOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStackInstancesOutput = exports.ListStackInstancesOutput || (exports.ListStackInstancesOutput = {})); +var ListStackResourcesInput; +(function (ListStackResourcesInput) { + ListStackResourcesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStackResourcesInput = exports.ListStackResourcesInput || (exports.ListStackResourcesInput = {})); +var StackResourceDriftInformationSummary; +(function (StackResourceDriftInformationSummary) { + StackResourceDriftInformationSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackResourceDriftInformationSummary = exports.StackResourceDriftInformationSummary || (exports.StackResourceDriftInformationSummary = {})); +var StackResourceSummary; +(function (StackResourceSummary) { + StackResourceSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackResourceSummary = exports.StackResourceSummary || (exports.StackResourceSummary = {})); +var ListStackResourcesOutput; +(function (ListStackResourcesOutput) { + ListStackResourcesOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStackResourcesOutput = exports.ListStackResourcesOutput || (exports.ListStackResourcesOutput = {})); +var ListStacksInput; +(function (ListStacksInput) { + ListStacksInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStacksInput = exports.ListStacksInput || (exports.ListStacksInput = {})); +var StackDriftInformationSummary; +(function (StackDriftInformationSummary) { + StackDriftInformationSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackDriftInformationSummary = exports.StackDriftInformationSummary || (exports.StackDriftInformationSummary = {})); +var StackSummary; +(function (StackSummary) { + StackSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackSummary = exports.StackSummary || (exports.StackSummary = {})); +var ListStacksOutput; +(function (ListStacksOutput) { + ListStacksOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStacksOutput = exports.ListStacksOutput || (exports.ListStacksOutput = {})); +var ListStackSetOperationResultsInput; +(function (ListStackSetOperationResultsInput) { + ListStackSetOperationResultsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStackSetOperationResultsInput = exports.ListStackSetOperationResultsInput || (exports.ListStackSetOperationResultsInput = {})); +var StackSetOperationResultSummary; +(function (StackSetOperationResultSummary) { + StackSetOperationResultSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackSetOperationResultSummary = exports.StackSetOperationResultSummary || (exports.StackSetOperationResultSummary = {})); +var ListStackSetOperationResultsOutput; +(function (ListStackSetOperationResultsOutput) { + ListStackSetOperationResultsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStackSetOperationResultsOutput = exports.ListStackSetOperationResultsOutput || (exports.ListStackSetOperationResultsOutput = {})); +var ListStackSetOperationsInput; +(function (ListStackSetOperationsInput) { + ListStackSetOperationsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStackSetOperationsInput = exports.ListStackSetOperationsInput || (exports.ListStackSetOperationsInput = {})); +var StackSetOperationSummary; +(function (StackSetOperationSummary) { + StackSetOperationSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackSetOperationSummary = exports.StackSetOperationSummary || (exports.StackSetOperationSummary = {})); +var ListStackSetOperationsOutput; +(function (ListStackSetOperationsOutput) { + ListStackSetOperationsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStackSetOperationsOutput = exports.ListStackSetOperationsOutput || (exports.ListStackSetOperationsOutput = {})); +var ListStackSetsInput; +(function (ListStackSetsInput) { + ListStackSetsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStackSetsInput = exports.ListStackSetsInput || (exports.ListStackSetsInput = {})); +var StackSetSummary; +(function (StackSetSummary) { + StackSetSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StackSetSummary = exports.StackSetSummary || (exports.StackSetSummary = {})); +var ListStackSetsOutput; +(function (ListStackSetsOutput) { + ListStackSetsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStackSetsOutput = exports.ListStackSetsOutput || (exports.ListStackSetsOutput = {})); +var ListTypeRegistrationsInput; +(function (ListTypeRegistrationsInput) { + ListTypeRegistrationsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTypeRegistrationsInput = exports.ListTypeRegistrationsInput || (exports.ListTypeRegistrationsInput = {})); +var ListTypeRegistrationsOutput; +(function (ListTypeRegistrationsOutput) { + ListTypeRegistrationsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTypeRegistrationsOutput = exports.ListTypeRegistrationsOutput || (exports.ListTypeRegistrationsOutput = {})); +var ListTypesInput; +(function (ListTypesInput) { + ListTypesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTypesInput = exports.ListTypesInput || (exports.ListTypesInput = {})); +var TypeSummary; +(function (TypeSummary) { + TypeSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TypeSummary = exports.TypeSummary || (exports.TypeSummary = {})); +var ListTypesOutput; +(function (ListTypesOutput) { + ListTypesOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTypesOutput = exports.ListTypesOutput || (exports.ListTypesOutput = {})); +var ListTypeVersionsInput; +(function (ListTypeVersionsInput) { + ListTypeVersionsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTypeVersionsInput = exports.ListTypeVersionsInput || (exports.ListTypeVersionsInput = {})); +var TypeVersionSummary; +(function (TypeVersionSummary) { + TypeVersionSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TypeVersionSummary = exports.TypeVersionSummary || (exports.TypeVersionSummary = {})); +var ListTypeVersionsOutput; +(function (ListTypeVersionsOutput) { + ListTypeVersionsOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTypeVersionsOutput = exports.ListTypeVersionsOutput || (exports.ListTypeVersionsOutput = {})); +var InvalidStateTransitionException; +(function (InvalidStateTransitionException) { + InvalidStateTransitionException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidStateTransitionException = exports.InvalidStateTransitionException || (exports.InvalidStateTransitionException = {})); +var OperationStatusCheckFailedException; +(function (OperationStatusCheckFailedException) { + OperationStatusCheckFailedException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(OperationStatusCheckFailedException = exports.OperationStatusCheckFailedException || (exports.OperationStatusCheckFailedException = {})); +var OperationStatus; +(function (OperationStatus) { + OperationStatus["FAILED"] = "FAILED"; + OperationStatus["IN_PROGRESS"] = "IN_PROGRESS"; + OperationStatus["PENDING"] = "PENDING"; + OperationStatus["SUCCESS"] = "SUCCESS"; +})(OperationStatus = exports.OperationStatus || (exports.OperationStatus = {})); +var HandlerErrorCode; +(function (HandlerErrorCode) { + HandlerErrorCode["AccessDenied"] = "AccessDenied"; + HandlerErrorCode["AlreadyExists"] = "AlreadyExists"; + HandlerErrorCode["GeneralServiceException"] = "GeneralServiceException"; + HandlerErrorCode["InternalFailure"] = "InternalFailure"; + HandlerErrorCode["InvalidCredentials"] = "InvalidCredentials"; + HandlerErrorCode["InvalidRequest"] = "InvalidRequest"; + HandlerErrorCode["NetworkFailure"] = "NetworkFailure"; + HandlerErrorCode["NotFound"] = "NotFound"; + HandlerErrorCode["NotUpdatable"] = "NotUpdatable"; + HandlerErrorCode["ResourceConflict"] = "ResourceConflict"; + HandlerErrorCode["ServiceInternalError"] = "ServiceInternalError"; + HandlerErrorCode["ServiceLimitExceeded"] = "ServiceLimitExceeded"; + HandlerErrorCode["ServiceTimeout"] = "NotStabilized"; + HandlerErrorCode["Throttling"] = "Throttling"; +})(HandlerErrorCode = exports.HandlerErrorCode || (exports.HandlerErrorCode = {})); +var RecordHandlerProgressInput; +(function (RecordHandlerProgressInput) { + RecordHandlerProgressInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RecordHandlerProgressInput = exports.RecordHandlerProgressInput || (exports.RecordHandlerProgressInput = {})); +var RecordHandlerProgressOutput; +(function (RecordHandlerProgressOutput) { + RecordHandlerProgressOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RecordHandlerProgressOutput = exports.RecordHandlerProgressOutput || (exports.RecordHandlerProgressOutput = {})); +var RegisterTypeInput; +(function (RegisterTypeInput) { + RegisterTypeInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegisterTypeInput = exports.RegisterTypeInput || (exports.RegisterTypeInput = {})); +var RegisterTypeOutput; +(function (RegisterTypeOutput) { + RegisterTypeOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegisterTypeOutput = exports.RegisterTypeOutput || (exports.RegisterTypeOutput = {})); +var SetStackPolicyInput; +(function (SetStackPolicyInput) { + SetStackPolicyInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetStackPolicyInput = exports.SetStackPolicyInput || (exports.SetStackPolicyInput = {})); +var SetTypeDefaultVersionInput; +(function (SetTypeDefaultVersionInput) { + SetTypeDefaultVersionInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetTypeDefaultVersionInput = exports.SetTypeDefaultVersionInput || (exports.SetTypeDefaultVersionInput = {})); +var SetTypeDefaultVersionOutput; +(function (SetTypeDefaultVersionOutput) { + SetTypeDefaultVersionOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetTypeDefaultVersionOutput = exports.SetTypeDefaultVersionOutput || (exports.SetTypeDefaultVersionOutput = {})); +var ResourceSignalStatus; +(function (ResourceSignalStatus) { + ResourceSignalStatus["FAILURE"] = "FAILURE"; + ResourceSignalStatus["SUCCESS"] = "SUCCESS"; +})(ResourceSignalStatus = exports.ResourceSignalStatus || (exports.ResourceSignalStatus = {})); +var SignalResourceInput; +(function (SignalResourceInput) { + SignalResourceInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SignalResourceInput = exports.SignalResourceInput || (exports.SignalResourceInput = {})); +var StopStackSetOperationInput; +(function (StopStackSetOperationInput) { + StopStackSetOperationInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StopStackSetOperationInput = exports.StopStackSetOperationInput || (exports.StopStackSetOperationInput = {})); +var StopStackSetOperationOutput; +(function (StopStackSetOperationOutput) { + StopStackSetOperationOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StopStackSetOperationOutput = exports.StopStackSetOperationOutput || (exports.StopStackSetOperationOutput = {})); +var UpdateStackInput; +(function (UpdateStackInput) { + UpdateStackInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateStackInput = exports.UpdateStackInput || (exports.UpdateStackInput = {})); +var UpdateStackOutput; +(function (UpdateStackOutput) { + UpdateStackOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateStackOutput = exports.UpdateStackOutput || (exports.UpdateStackOutput = {})); +var UpdateStackInstancesInput; +(function (UpdateStackInstancesInput) { + UpdateStackInstancesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateStackInstancesInput = exports.UpdateStackInstancesInput || (exports.UpdateStackInstancesInput = {})); +var UpdateStackInstancesOutput; +(function (UpdateStackInstancesOutput) { + UpdateStackInstancesOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateStackInstancesOutput = exports.UpdateStackInstancesOutput || (exports.UpdateStackInstancesOutput = {})); +var UpdateStackSetInput; +(function (UpdateStackSetInput) { + UpdateStackSetInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateStackSetInput = exports.UpdateStackSetInput || (exports.UpdateStackSetInput = {})); +var UpdateStackSetOutput; +(function (UpdateStackSetOutput) { + UpdateStackSetOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateStackSetOutput = exports.UpdateStackSetOutput || (exports.UpdateStackSetOutput = {})); +var UpdateTerminationProtectionInput; +(function (UpdateTerminationProtectionInput) { + UpdateTerminationProtectionInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateTerminationProtectionInput = exports.UpdateTerminationProtectionInput || (exports.UpdateTerminationProtectionInput = {})); +var UpdateTerminationProtectionOutput; +(function (UpdateTerminationProtectionOutput) { + UpdateTerminationProtectionOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateTerminationProtectionOutput = exports.UpdateTerminationProtectionOutput || (exports.UpdateTerminationProtectionOutput = {})); +var ValidateTemplateInput; +(function (ValidateTemplateInput) { + ValidateTemplateInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ValidateTemplateInput = exports.ValidateTemplateInput || (exports.ValidateTemplateInput = {})); +var TemplateParameter; +(function (TemplateParameter) { + TemplateParameter.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TemplateParameter = exports.TemplateParameter || (exports.TemplateParameter = {})); +var ValidateTemplateOutput; +(function (ValidateTemplateOutput) { + ValidateTemplateOutput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ValidateTemplateOutput = exports.ValidateTemplateOutput || (exports.ValidateTemplateOutput = {})); +//# sourceMappingURL=models_0.js.map + +/***/ }), + +/***/ 93821: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateDescribeAccountLimits = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const DescribeAccountLimitsCommand_1 = __nccwpck_require__(67719); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new DescribeAccountLimitsCommand_1.DescribeAccountLimitsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.describeAccountLimits(input, ...args); +}; +async function* paginateDescribeAccountLimits(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateDescribeAccountLimits = paginateDescribeAccountLimits; +//# sourceMappingURL=DescribeAccountLimitsPaginator.js.map + +/***/ }), + +/***/ 77993: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateDescribeStackEvents = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const DescribeStackEventsCommand_1 = __nccwpck_require__(99902); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new DescribeStackEventsCommand_1.DescribeStackEventsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.describeStackEvents(input, ...args); +}; +async function* paginateDescribeStackEvents(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateDescribeStackEvents = paginateDescribeStackEvents; +//# sourceMappingURL=DescribeStackEventsPaginator.js.map + +/***/ }), + +/***/ 5335: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateDescribeStackResourceDrifts = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const DescribeStackResourceDriftsCommand_1 = __nccwpck_require__(25794); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new DescribeStackResourceDriftsCommand_1.DescribeStackResourceDriftsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.describeStackResourceDrifts(input, ...args); +}; +async function* paginateDescribeStackResourceDrifts(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateDescribeStackResourceDrifts = paginateDescribeStackResourceDrifts; +//# sourceMappingURL=DescribeStackResourceDriftsPaginator.js.map + +/***/ }), + +/***/ 66474: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateDescribeStacks = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const DescribeStacksCommand_1 = __nccwpck_require__(87840); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new DescribeStacksCommand_1.DescribeStacksCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.describeStacks(input, ...args); +}; +async function* paginateDescribeStacks(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateDescribeStacks = paginateDescribeStacks; +//# sourceMappingURL=DescribeStacksPaginator.js.map + +/***/ }), + +/***/ 59638: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +//# sourceMappingURL=Interfaces.js.map + +/***/ }), + +/***/ 7377: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListChangeSets = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListChangeSetsCommand_1 = __nccwpck_require__(99706); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListChangeSetsCommand_1.ListChangeSetsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listChangeSets(input, ...args); +}; +async function* paginateListChangeSets(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListChangeSets = paginateListChangeSets; +//# sourceMappingURL=ListChangeSetsPaginator.js.map + +/***/ }), + +/***/ 9252: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListExports = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListExportsCommand_1 = __nccwpck_require__(60351); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListExportsCommand_1.ListExportsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listExports(input, ...args); +}; +async function* paginateListExports(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListExports = paginateListExports; +//# sourceMappingURL=ListExportsPaginator.js.map + +/***/ }), + +/***/ 64976: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListImports = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListImportsCommand_1 = __nccwpck_require__(72171); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListImportsCommand_1.ListImportsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listImports(input, ...args); +}; +async function* paginateListImports(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListImports = paginateListImports; +//# sourceMappingURL=ListImportsPaginator.js.map + +/***/ }), + +/***/ 99936: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListStackInstances = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListStackInstancesCommand_1 = __nccwpck_require__(50991); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListStackInstancesCommand_1.ListStackInstancesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listStackInstances(input, ...args); +}; +async function* paginateListStackInstances(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListStackInstances = paginateListStackInstances; +//# sourceMappingURL=ListStackInstancesPaginator.js.map + +/***/ }), + +/***/ 55268: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListStackResources = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListStackResourcesCommand_1 = __nccwpck_require__(83057); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListStackResourcesCommand_1.ListStackResourcesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listStackResources(input, ...args); +}; +async function* paginateListStackResources(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListStackResources = paginateListStackResources; +//# sourceMappingURL=ListStackResourcesPaginator.js.map + +/***/ }), + +/***/ 67014: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListStackSetOperationResults = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListStackSetOperationResultsCommand_1 = __nccwpck_require__(71155); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListStackSetOperationResultsCommand_1.ListStackSetOperationResultsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listStackSetOperationResults(input, ...args); +}; +async function* paginateListStackSetOperationResults(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListStackSetOperationResults = paginateListStackSetOperationResults; +//# sourceMappingURL=ListStackSetOperationResultsPaginator.js.map + +/***/ }), + +/***/ 73469: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListStackSetOperations = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListStackSetOperationsCommand_1 = __nccwpck_require__(62539); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListStackSetOperationsCommand_1.ListStackSetOperationsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listStackSetOperations(input, ...args); +}; +async function* paginateListStackSetOperations(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListStackSetOperations = paginateListStackSetOperations; +//# sourceMappingURL=ListStackSetOperationsPaginator.js.map + +/***/ }), + +/***/ 14034: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListStackSets = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListStackSetsCommand_1 = __nccwpck_require__(40722); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListStackSetsCommand_1.ListStackSetsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listStackSets(input, ...args); +}; +async function* paginateListStackSets(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListStackSets = paginateListStackSets; +//# sourceMappingURL=ListStackSetsPaginator.js.map + +/***/ }), + +/***/ 3533: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListStacks = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListStacksCommand_1 = __nccwpck_require__(54482); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListStacksCommand_1.ListStacksCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listStacks(input, ...args); +}; +async function* paginateListStacks(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListStacks = paginateListStacks; +//# sourceMappingURL=ListStacksPaginator.js.map + +/***/ }), + +/***/ 43356: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListTypeRegistrations = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListTypeRegistrationsCommand_1 = __nccwpck_require__(34567); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListTypeRegistrationsCommand_1.ListTypeRegistrationsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listTypeRegistrations(input, ...args); +}; +async function* paginateListTypeRegistrations(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListTypeRegistrations = paginateListTypeRegistrations; +//# sourceMappingURL=ListTypeRegistrationsPaginator.js.map + +/***/ }), + +/***/ 89809: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListTypeVersions = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListTypeVersionsCommand_1 = __nccwpck_require__(72174); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListTypeVersionsCommand_1.ListTypeVersionsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listTypeVersions(input, ...args); +}; +async function* paginateListTypeVersions(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListTypeVersions = paginateListTypeVersions; +//# sourceMappingURL=ListTypeVersionsPaginator.js.map + +/***/ }), + +/***/ 16689: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListTypes = void 0; +const CloudFormation_1 = __nccwpck_require__(44074); +const CloudFormationClient_1 = __nccwpck_require__(25838); +const ListTypesCommand_1 = __nccwpck_require__(5511); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListTypesCommand_1.ListTypesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listTypes(input, ...args); +}; +async function* paginateListTypes(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CloudFormation_1.CloudFormation) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CloudFormationClient_1.CloudFormationClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CloudFormation | CloudFormationClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListTypes = paginateListTypes; +//# sourceMappingURL=ListTypesPaginator.js.map + +/***/ }), + +/***/ 46408: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.serializeAws_queryStopStackSetOperationCommand = exports.serializeAws_querySignalResourceCommand = exports.serializeAws_querySetTypeDefaultVersionCommand = exports.serializeAws_querySetStackPolicyCommand = exports.serializeAws_queryRegisterTypeCommand = exports.serializeAws_queryRecordHandlerProgressCommand = exports.serializeAws_queryListTypeVersionsCommand = exports.serializeAws_queryListTypesCommand = exports.serializeAws_queryListTypeRegistrationsCommand = exports.serializeAws_queryListStackSetsCommand = exports.serializeAws_queryListStackSetOperationsCommand = exports.serializeAws_queryListStackSetOperationResultsCommand = exports.serializeAws_queryListStacksCommand = exports.serializeAws_queryListStackResourcesCommand = exports.serializeAws_queryListStackInstancesCommand = exports.serializeAws_queryListImportsCommand = exports.serializeAws_queryListExportsCommand = exports.serializeAws_queryListChangeSetsCommand = exports.serializeAws_queryGetTemplateSummaryCommand = exports.serializeAws_queryGetTemplateCommand = exports.serializeAws_queryGetStackPolicyCommand = exports.serializeAws_queryExecuteChangeSetCommand = exports.serializeAws_queryEstimateTemplateCostCommand = exports.serializeAws_queryDetectStackSetDriftCommand = exports.serializeAws_queryDetectStackResourceDriftCommand = exports.serializeAws_queryDetectStackDriftCommand = exports.serializeAws_queryDescribeTypeRegistrationCommand = exports.serializeAws_queryDescribeTypeCommand = exports.serializeAws_queryDescribeStackSetOperationCommand = exports.serializeAws_queryDescribeStackSetCommand = exports.serializeAws_queryDescribeStacksCommand = exports.serializeAws_queryDescribeStackResourcesCommand = exports.serializeAws_queryDescribeStackResourceDriftsCommand = exports.serializeAws_queryDescribeStackResourceCommand = exports.serializeAws_queryDescribeStackInstanceCommand = exports.serializeAws_queryDescribeStackEventsCommand = exports.serializeAws_queryDescribeStackDriftDetectionStatusCommand = exports.serializeAws_queryDescribeChangeSetCommand = exports.serializeAws_queryDescribeAccountLimitsCommand = exports.serializeAws_queryDeregisterTypeCommand = exports.serializeAws_queryDeleteStackSetCommand = exports.serializeAws_queryDeleteStackInstancesCommand = exports.serializeAws_queryDeleteStackCommand = exports.serializeAws_queryDeleteChangeSetCommand = exports.serializeAws_queryCreateStackSetCommand = exports.serializeAws_queryCreateStackInstancesCommand = exports.serializeAws_queryCreateStackCommand = exports.serializeAws_queryCreateChangeSetCommand = exports.serializeAws_queryContinueUpdateRollbackCommand = exports.serializeAws_queryCancelUpdateStackCommand = void 0; +exports.deserializeAws_queryRecordHandlerProgressCommand = exports.deserializeAws_queryListTypeVersionsCommand = exports.deserializeAws_queryListTypesCommand = exports.deserializeAws_queryListTypeRegistrationsCommand = exports.deserializeAws_queryListStackSetsCommand = exports.deserializeAws_queryListStackSetOperationsCommand = exports.deserializeAws_queryListStackSetOperationResultsCommand = exports.deserializeAws_queryListStacksCommand = exports.deserializeAws_queryListStackResourcesCommand = exports.deserializeAws_queryListStackInstancesCommand = exports.deserializeAws_queryListImportsCommand = exports.deserializeAws_queryListExportsCommand = exports.deserializeAws_queryListChangeSetsCommand = exports.deserializeAws_queryGetTemplateSummaryCommand = exports.deserializeAws_queryGetTemplateCommand = exports.deserializeAws_queryGetStackPolicyCommand = exports.deserializeAws_queryExecuteChangeSetCommand = exports.deserializeAws_queryEstimateTemplateCostCommand = exports.deserializeAws_queryDetectStackSetDriftCommand = exports.deserializeAws_queryDetectStackResourceDriftCommand = exports.deserializeAws_queryDetectStackDriftCommand = exports.deserializeAws_queryDescribeTypeRegistrationCommand = exports.deserializeAws_queryDescribeTypeCommand = exports.deserializeAws_queryDescribeStackSetOperationCommand = exports.deserializeAws_queryDescribeStackSetCommand = exports.deserializeAws_queryDescribeStacksCommand = exports.deserializeAws_queryDescribeStackResourcesCommand = exports.deserializeAws_queryDescribeStackResourceDriftsCommand = exports.deserializeAws_queryDescribeStackResourceCommand = exports.deserializeAws_queryDescribeStackInstanceCommand = exports.deserializeAws_queryDescribeStackEventsCommand = exports.deserializeAws_queryDescribeStackDriftDetectionStatusCommand = exports.deserializeAws_queryDescribeChangeSetCommand = exports.deserializeAws_queryDescribeAccountLimitsCommand = exports.deserializeAws_queryDeregisterTypeCommand = exports.deserializeAws_queryDeleteStackSetCommand = exports.deserializeAws_queryDeleteStackInstancesCommand = exports.deserializeAws_queryDeleteStackCommand = exports.deserializeAws_queryDeleteChangeSetCommand = exports.deserializeAws_queryCreateStackSetCommand = exports.deserializeAws_queryCreateStackInstancesCommand = exports.deserializeAws_queryCreateStackCommand = exports.deserializeAws_queryCreateChangeSetCommand = exports.deserializeAws_queryContinueUpdateRollbackCommand = exports.deserializeAws_queryCancelUpdateStackCommand = exports.serializeAws_queryValidateTemplateCommand = exports.serializeAws_queryUpdateTerminationProtectionCommand = exports.serializeAws_queryUpdateStackSetCommand = exports.serializeAws_queryUpdateStackInstancesCommand = exports.serializeAws_queryUpdateStackCommand = void 0; +exports.deserializeAws_queryValidateTemplateCommand = exports.deserializeAws_queryUpdateTerminationProtectionCommand = exports.deserializeAws_queryUpdateStackSetCommand = exports.deserializeAws_queryUpdateStackInstancesCommand = exports.deserializeAws_queryUpdateStackCommand = exports.deserializeAws_queryStopStackSetOperationCommand = exports.deserializeAws_querySignalResourceCommand = exports.deserializeAws_querySetTypeDefaultVersionCommand = exports.deserializeAws_querySetStackPolicyCommand = exports.deserializeAws_queryRegisterTypeCommand = void 0; +const protocol_http_1 = __nccwpck_require__(67498); +const smithy_client_1 = __nccwpck_require__(84060); +const fast_xml_parser_1 = __nccwpck_require__(27448); +const uuid_1 = __nccwpck_require__(2155); +const serializeAws_queryCancelUpdateStackCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryCancelUpdateStackInput(input, context), + Action: "CancelUpdateStack", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryCancelUpdateStackCommand = serializeAws_queryCancelUpdateStackCommand; +const serializeAws_queryContinueUpdateRollbackCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryContinueUpdateRollbackInput(input, context), + Action: "ContinueUpdateRollback", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryContinueUpdateRollbackCommand = serializeAws_queryContinueUpdateRollbackCommand; +const serializeAws_queryCreateChangeSetCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryCreateChangeSetInput(input, context), + Action: "CreateChangeSet", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryCreateChangeSetCommand = serializeAws_queryCreateChangeSetCommand; +const serializeAws_queryCreateStackCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryCreateStackInput(input, context), + Action: "CreateStack", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryCreateStackCommand = serializeAws_queryCreateStackCommand; +const serializeAws_queryCreateStackInstancesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryCreateStackInstancesInput(input, context), + Action: "CreateStackInstances", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryCreateStackInstancesCommand = serializeAws_queryCreateStackInstancesCommand; +const serializeAws_queryCreateStackSetCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryCreateStackSetInput(input, context), + Action: "CreateStackSet", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryCreateStackSetCommand = serializeAws_queryCreateStackSetCommand; +const serializeAws_queryDeleteChangeSetCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDeleteChangeSetInput(input, context), + Action: "DeleteChangeSet", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDeleteChangeSetCommand = serializeAws_queryDeleteChangeSetCommand; +const serializeAws_queryDeleteStackCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDeleteStackInput(input, context), + Action: "DeleteStack", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDeleteStackCommand = serializeAws_queryDeleteStackCommand; +const serializeAws_queryDeleteStackInstancesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDeleteStackInstancesInput(input, context), + Action: "DeleteStackInstances", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDeleteStackInstancesCommand = serializeAws_queryDeleteStackInstancesCommand; +const serializeAws_queryDeleteStackSetCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDeleteStackSetInput(input, context), + Action: "DeleteStackSet", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDeleteStackSetCommand = serializeAws_queryDeleteStackSetCommand; +const serializeAws_queryDeregisterTypeCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDeregisterTypeInput(input, context), + Action: "DeregisterType", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDeregisterTypeCommand = serializeAws_queryDeregisterTypeCommand; +const serializeAws_queryDescribeAccountLimitsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeAccountLimitsInput(input, context), + Action: "DescribeAccountLimits", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeAccountLimitsCommand = serializeAws_queryDescribeAccountLimitsCommand; +const serializeAws_queryDescribeChangeSetCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeChangeSetInput(input, context), + Action: "DescribeChangeSet", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeChangeSetCommand = serializeAws_queryDescribeChangeSetCommand; +const serializeAws_queryDescribeStackDriftDetectionStatusCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeStackDriftDetectionStatusInput(input, context), + Action: "DescribeStackDriftDetectionStatus", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeStackDriftDetectionStatusCommand = serializeAws_queryDescribeStackDriftDetectionStatusCommand; +const serializeAws_queryDescribeStackEventsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeStackEventsInput(input, context), + Action: "DescribeStackEvents", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeStackEventsCommand = serializeAws_queryDescribeStackEventsCommand; +const serializeAws_queryDescribeStackInstanceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeStackInstanceInput(input, context), + Action: "DescribeStackInstance", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeStackInstanceCommand = serializeAws_queryDescribeStackInstanceCommand; +const serializeAws_queryDescribeStackResourceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeStackResourceInput(input, context), + Action: "DescribeStackResource", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeStackResourceCommand = serializeAws_queryDescribeStackResourceCommand; +const serializeAws_queryDescribeStackResourceDriftsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeStackResourceDriftsInput(input, context), + Action: "DescribeStackResourceDrifts", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeStackResourceDriftsCommand = serializeAws_queryDescribeStackResourceDriftsCommand; +const serializeAws_queryDescribeStackResourcesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeStackResourcesInput(input, context), + Action: "DescribeStackResources", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeStackResourcesCommand = serializeAws_queryDescribeStackResourcesCommand; +const serializeAws_queryDescribeStacksCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeStacksInput(input, context), + Action: "DescribeStacks", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeStacksCommand = serializeAws_queryDescribeStacksCommand; +const serializeAws_queryDescribeStackSetCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeStackSetInput(input, context), + Action: "DescribeStackSet", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeStackSetCommand = serializeAws_queryDescribeStackSetCommand; +const serializeAws_queryDescribeStackSetOperationCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeStackSetOperationInput(input, context), + Action: "DescribeStackSetOperation", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeStackSetOperationCommand = serializeAws_queryDescribeStackSetOperationCommand; +const serializeAws_queryDescribeTypeCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeTypeInput(input, context), + Action: "DescribeType", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeTypeCommand = serializeAws_queryDescribeTypeCommand; +const serializeAws_queryDescribeTypeRegistrationCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDescribeTypeRegistrationInput(input, context), + Action: "DescribeTypeRegistration", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDescribeTypeRegistrationCommand = serializeAws_queryDescribeTypeRegistrationCommand; +const serializeAws_queryDetectStackDriftCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDetectStackDriftInput(input, context), + Action: "DetectStackDrift", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDetectStackDriftCommand = serializeAws_queryDetectStackDriftCommand; +const serializeAws_queryDetectStackResourceDriftCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDetectStackResourceDriftInput(input, context), + Action: "DetectStackResourceDrift", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDetectStackResourceDriftCommand = serializeAws_queryDetectStackResourceDriftCommand; +const serializeAws_queryDetectStackSetDriftCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryDetectStackSetDriftInput(input, context), + Action: "DetectStackSetDrift", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryDetectStackSetDriftCommand = serializeAws_queryDetectStackSetDriftCommand; +const serializeAws_queryEstimateTemplateCostCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryEstimateTemplateCostInput(input, context), + Action: "EstimateTemplateCost", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryEstimateTemplateCostCommand = serializeAws_queryEstimateTemplateCostCommand; +const serializeAws_queryExecuteChangeSetCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryExecuteChangeSetInput(input, context), + Action: "ExecuteChangeSet", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryExecuteChangeSetCommand = serializeAws_queryExecuteChangeSetCommand; +const serializeAws_queryGetStackPolicyCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryGetStackPolicyInput(input, context), + Action: "GetStackPolicy", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryGetStackPolicyCommand = serializeAws_queryGetStackPolicyCommand; +const serializeAws_queryGetTemplateCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryGetTemplateInput(input, context), + Action: "GetTemplate", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryGetTemplateCommand = serializeAws_queryGetTemplateCommand; +const serializeAws_queryGetTemplateSummaryCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryGetTemplateSummaryInput(input, context), + Action: "GetTemplateSummary", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryGetTemplateSummaryCommand = serializeAws_queryGetTemplateSummaryCommand; +const serializeAws_queryListChangeSetsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListChangeSetsInput(input, context), + Action: "ListChangeSets", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListChangeSetsCommand = serializeAws_queryListChangeSetsCommand; +const serializeAws_queryListExportsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListExportsInput(input, context), + Action: "ListExports", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListExportsCommand = serializeAws_queryListExportsCommand; +const serializeAws_queryListImportsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListImportsInput(input, context), + Action: "ListImports", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListImportsCommand = serializeAws_queryListImportsCommand; +const serializeAws_queryListStackInstancesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListStackInstancesInput(input, context), + Action: "ListStackInstances", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListStackInstancesCommand = serializeAws_queryListStackInstancesCommand; +const serializeAws_queryListStackResourcesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListStackResourcesInput(input, context), + Action: "ListStackResources", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListStackResourcesCommand = serializeAws_queryListStackResourcesCommand; +const serializeAws_queryListStacksCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListStacksInput(input, context), + Action: "ListStacks", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListStacksCommand = serializeAws_queryListStacksCommand; +const serializeAws_queryListStackSetOperationResultsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListStackSetOperationResultsInput(input, context), + Action: "ListStackSetOperationResults", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListStackSetOperationResultsCommand = serializeAws_queryListStackSetOperationResultsCommand; +const serializeAws_queryListStackSetOperationsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListStackSetOperationsInput(input, context), + Action: "ListStackSetOperations", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListStackSetOperationsCommand = serializeAws_queryListStackSetOperationsCommand; +const serializeAws_queryListStackSetsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListStackSetsInput(input, context), + Action: "ListStackSets", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListStackSetsCommand = serializeAws_queryListStackSetsCommand; +const serializeAws_queryListTypeRegistrationsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListTypeRegistrationsInput(input, context), + Action: "ListTypeRegistrations", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListTypeRegistrationsCommand = serializeAws_queryListTypeRegistrationsCommand; +const serializeAws_queryListTypesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListTypesInput(input, context), + Action: "ListTypes", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListTypesCommand = serializeAws_queryListTypesCommand; +const serializeAws_queryListTypeVersionsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryListTypeVersionsInput(input, context), + Action: "ListTypeVersions", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryListTypeVersionsCommand = serializeAws_queryListTypeVersionsCommand; +const serializeAws_queryRecordHandlerProgressCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryRecordHandlerProgressInput(input, context), + Action: "RecordHandlerProgress", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryRecordHandlerProgressCommand = serializeAws_queryRecordHandlerProgressCommand; +const serializeAws_queryRegisterTypeCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryRegisterTypeInput(input, context), + Action: "RegisterType", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryRegisterTypeCommand = serializeAws_queryRegisterTypeCommand; +const serializeAws_querySetStackPolicyCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_querySetStackPolicyInput(input, context), + Action: "SetStackPolicy", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_querySetStackPolicyCommand = serializeAws_querySetStackPolicyCommand; +const serializeAws_querySetTypeDefaultVersionCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_querySetTypeDefaultVersionInput(input, context), + Action: "SetTypeDefaultVersion", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_querySetTypeDefaultVersionCommand = serializeAws_querySetTypeDefaultVersionCommand; +const serializeAws_querySignalResourceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_querySignalResourceInput(input, context), + Action: "SignalResource", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_querySignalResourceCommand = serializeAws_querySignalResourceCommand; +const serializeAws_queryStopStackSetOperationCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryStopStackSetOperationInput(input, context), + Action: "StopStackSetOperation", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryStopStackSetOperationCommand = serializeAws_queryStopStackSetOperationCommand; +const serializeAws_queryUpdateStackCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryUpdateStackInput(input, context), + Action: "UpdateStack", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryUpdateStackCommand = serializeAws_queryUpdateStackCommand; +const serializeAws_queryUpdateStackInstancesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryUpdateStackInstancesInput(input, context), + Action: "UpdateStackInstances", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryUpdateStackInstancesCommand = serializeAws_queryUpdateStackInstancesCommand; +const serializeAws_queryUpdateStackSetCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryUpdateStackSetInput(input, context), + Action: "UpdateStackSet", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryUpdateStackSetCommand = serializeAws_queryUpdateStackSetCommand; +const serializeAws_queryUpdateTerminationProtectionCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryUpdateTerminationProtectionInput(input, context), + Action: "UpdateTerminationProtection", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryUpdateTerminationProtectionCommand = serializeAws_queryUpdateTerminationProtectionCommand; +const serializeAws_queryValidateTemplateCommand = async (input, context) => { + const headers = { + "content-type": "application/x-www-form-urlencoded", + }; + let body; + body = buildFormUrlencodedString({ + ...serializeAws_queryValidateTemplateInput(input, context), + Action: "ValidateTemplate", + Version: "2010-05-15", + }); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_queryValidateTemplateCommand = serializeAws_queryValidateTemplateCommand; +const deserializeAws_queryCancelUpdateStackCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryCancelUpdateStackCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryCancelUpdateStackCommand = deserializeAws_queryCancelUpdateStackCommand; +const deserializeAws_queryCancelUpdateStackCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "TokenAlreadyExistsException": + case "com.amazonaws.cloudformation#TokenAlreadyExistsException": + response = { + ...(await deserializeAws_queryTokenAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryContinueUpdateRollbackCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryContinueUpdateRollbackCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryContinueUpdateRollbackOutput(data.ContinueUpdateRollbackResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryContinueUpdateRollbackCommand = deserializeAws_queryContinueUpdateRollbackCommand; +const deserializeAws_queryContinueUpdateRollbackCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "TokenAlreadyExistsException": + case "com.amazonaws.cloudformation#TokenAlreadyExistsException": + response = { + ...(await deserializeAws_queryTokenAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryCreateChangeSetCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryCreateChangeSetCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryCreateChangeSetOutput(data.CreateChangeSetResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryCreateChangeSetCommand = deserializeAws_queryCreateChangeSetCommand; +const deserializeAws_queryCreateChangeSetCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "AlreadyExistsException": + case "com.amazonaws.cloudformation#AlreadyExistsException": + response = { + ...(await deserializeAws_queryAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InsufficientCapabilitiesException": + case "com.amazonaws.cloudformation#InsufficientCapabilitiesException": + response = { + ...(await deserializeAws_queryInsufficientCapabilitiesExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cloudformation#LimitExceededException": + response = { + ...(await deserializeAws_queryLimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryCreateStackCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryCreateStackCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryCreateStackOutput(data.CreateStackResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryCreateStackCommand = deserializeAws_queryCreateStackCommand; +const deserializeAws_queryCreateStackCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "AlreadyExistsException": + case "com.amazonaws.cloudformation#AlreadyExistsException": + response = { + ...(await deserializeAws_queryAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InsufficientCapabilitiesException": + case "com.amazonaws.cloudformation#InsufficientCapabilitiesException": + response = { + ...(await deserializeAws_queryInsufficientCapabilitiesExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cloudformation#LimitExceededException": + response = { + ...(await deserializeAws_queryLimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TokenAlreadyExistsException": + case "com.amazonaws.cloudformation#TokenAlreadyExistsException": + response = { + ...(await deserializeAws_queryTokenAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryCreateStackInstancesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryCreateStackInstancesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryCreateStackInstancesOutput(data.CreateStackInstancesResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryCreateStackInstancesCommand = deserializeAws_queryCreateStackInstancesCommand; +const deserializeAws_queryCreateStackInstancesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidOperationException": + case "com.amazonaws.cloudformation#InvalidOperationException": + response = { + ...(await deserializeAws_queryInvalidOperationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cloudformation#LimitExceededException": + response = { + ...(await deserializeAws_queryLimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationIdAlreadyExistsException": + case "com.amazonaws.cloudformation#OperationIdAlreadyExistsException": + response = { + ...(await deserializeAws_queryOperationIdAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationInProgressException": + case "com.amazonaws.cloudformation#OperationInProgressException": + response = { + ...(await deserializeAws_queryOperationInProgressExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StaleRequestException": + case "com.amazonaws.cloudformation#StaleRequestException": + response = { + ...(await deserializeAws_queryStaleRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryCreateStackSetCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryCreateStackSetCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryCreateStackSetOutput(data.CreateStackSetResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryCreateStackSetCommand = deserializeAws_queryCreateStackSetCommand; +const deserializeAws_queryCreateStackSetCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CreatedButModifiedException": + case "com.amazonaws.cloudformation#CreatedButModifiedException": + response = { + ...(await deserializeAws_queryCreatedButModifiedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cloudformation#LimitExceededException": + response = { + ...(await deserializeAws_queryLimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NameAlreadyExistsException": + case "com.amazonaws.cloudformation#NameAlreadyExistsException": + response = { + ...(await deserializeAws_queryNameAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDeleteChangeSetCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDeleteChangeSetCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDeleteChangeSetOutput(data.DeleteChangeSetResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDeleteChangeSetCommand = deserializeAws_queryDeleteChangeSetCommand; +const deserializeAws_queryDeleteChangeSetCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidChangeSetStatusException": + case "com.amazonaws.cloudformation#InvalidChangeSetStatusException": + response = { + ...(await deserializeAws_queryInvalidChangeSetStatusExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDeleteStackCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDeleteStackCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDeleteStackCommand = deserializeAws_queryDeleteStackCommand; +const deserializeAws_queryDeleteStackCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "TokenAlreadyExistsException": + case "com.amazonaws.cloudformation#TokenAlreadyExistsException": + response = { + ...(await deserializeAws_queryTokenAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDeleteStackInstancesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDeleteStackInstancesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDeleteStackInstancesOutput(data.DeleteStackInstancesResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDeleteStackInstancesCommand = deserializeAws_queryDeleteStackInstancesCommand; +const deserializeAws_queryDeleteStackInstancesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidOperationException": + case "com.amazonaws.cloudformation#InvalidOperationException": + response = { + ...(await deserializeAws_queryInvalidOperationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationIdAlreadyExistsException": + case "com.amazonaws.cloudformation#OperationIdAlreadyExistsException": + response = { + ...(await deserializeAws_queryOperationIdAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationInProgressException": + case "com.amazonaws.cloudformation#OperationInProgressException": + response = { + ...(await deserializeAws_queryOperationInProgressExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StaleRequestException": + case "com.amazonaws.cloudformation#StaleRequestException": + response = { + ...(await deserializeAws_queryStaleRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDeleteStackSetCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDeleteStackSetCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDeleteStackSetOutput(data.DeleteStackSetResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDeleteStackSetCommand = deserializeAws_queryDeleteStackSetCommand; +const deserializeAws_queryDeleteStackSetCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "OperationInProgressException": + case "com.amazonaws.cloudformation#OperationInProgressException": + response = { + ...(await deserializeAws_queryOperationInProgressExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackSetNotEmptyException": + case "com.amazonaws.cloudformation#StackSetNotEmptyException": + response = { + ...(await deserializeAws_queryStackSetNotEmptyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDeregisterTypeCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDeregisterTypeCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDeregisterTypeOutput(data.DeregisterTypeResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDeregisterTypeCommand = deserializeAws_queryDeregisterTypeCommand; +const deserializeAws_queryDeregisterTypeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CFNRegistryException": + case "com.amazonaws.cloudformation#CFNRegistryException": + response = { + ...(await deserializeAws_queryCFNRegistryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TypeNotFoundException": + case "com.amazonaws.cloudformation#TypeNotFoundException": + response = { + ...(await deserializeAws_queryTypeNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeAccountLimitsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeAccountLimitsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeAccountLimitsOutput(data.DescribeAccountLimitsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeAccountLimitsCommand = deserializeAws_queryDescribeAccountLimitsCommand; +const deserializeAws_queryDescribeAccountLimitsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeChangeSetCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeChangeSetCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeChangeSetOutput(data.DescribeChangeSetResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeChangeSetCommand = deserializeAws_queryDescribeChangeSetCommand; +const deserializeAws_queryDescribeChangeSetCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ChangeSetNotFoundException": + case "com.amazonaws.cloudformation#ChangeSetNotFoundException": + response = { + ...(await deserializeAws_queryChangeSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeStackDriftDetectionStatusCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeStackDriftDetectionStatusCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeStackDriftDetectionStatusOutput(data.DescribeStackDriftDetectionStatusResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeStackDriftDetectionStatusCommand = deserializeAws_queryDescribeStackDriftDetectionStatusCommand; +const deserializeAws_queryDescribeStackDriftDetectionStatusCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeStackEventsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeStackEventsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeStackEventsOutput(data.DescribeStackEventsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeStackEventsCommand = deserializeAws_queryDescribeStackEventsCommand; +const deserializeAws_queryDescribeStackEventsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeStackInstanceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeStackInstanceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeStackInstanceOutput(data.DescribeStackInstanceResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeStackInstanceCommand = deserializeAws_queryDescribeStackInstanceCommand; +const deserializeAws_queryDescribeStackInstanceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "StackInstanceNotFoundException": + case "com.amazonaws.cloudformation#StackInstanceNotFoundException": + response = { + ...(await deserializeAws_queryStackInstanceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeStackResourceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeStackResourceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeStackResourceOutput(data.DescribeStackResourceResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeStackResourceCommand = deserializeAws_queryDescribeStackResourceCommand; +const deserializeAws_queryDescribeStackResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeStackResourceDriftsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeStackResourceDriftsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeStackResourceDriftsOutput(data.DescribeStackResourceDriftsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeStackResourceDriftsCommand = deserializeAws_queryDescribeStackResourceDriftsCommand; +const deserializeAws_queryDescribeStackResourceDriftsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeStackResourcesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeStackResourcesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeStackResourcesOutput(data.DescribeStackResourcesResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeStackResourcesCommand = deserializeAws_queryDescribeStackResourcesCommand; +const deserializeAws_queryDescribeStackResourcesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeStacksCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeStacksCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeStacksOutput(data.DescribeStacksResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeStacksCommand = deserializeAws_queryDescribeStacksCommand; +const deserializeAws_queryDescribeStacksCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeStackSetCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeStackSetCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeStackSetOutput(data.DescribeStackSetResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeStackSetCommand = deserializeAws_queryDescribeStackSetCommand; +const deserializeAws_queryDescribeStackSetCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeStackSetOperationCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeStackSetOperationCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeStackSetOperationOutput(data.DescribeStackSetOperationResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeStackSetOperationCommand = deserializeAws_queryDescribeStackSetOperationCommand; +const deserializeAws_queryDescribeStackSetOperationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "OperationNotFoundException": + case "com.amazonaws.cloudformation#OperationNotFoundException": + response = { + ...(await deserializeAws_queryOperationNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeTypeCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeTypeCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeTypeOutput(data.DescribeTypeResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeTypeCommand = deserializeAws_queryDescribeTypeCommand; +const deserializeAws_queryDescribeTypeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CFNRegistryException": + case "com.amazonaws.cloudformation#CFNRegistryException": + response = { + ...(await deserializeAws_queryCFNRegistryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TypeNotFoundException": + case "com.amazonaws.cloudformation#TypeNotFoundException": + response = { + ...(await deserializeAws_queryTypeNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDescribeTypeRegistrationCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDescribeTypeRegistrationCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDescribeTypeRegistrationOutput(data.DescribeTypeRegistrationResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDescribeTypeRegistrationCommand = deserializeAws_queryDescribeTypeRegistrationCommand; +const deserializeAws_queryDescribeTypeRegistrationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CFNRegistryException": + case "com.amazonaws.cloudformation#CFNRegistryException": + response = { + ...(await deserializeAws_queryCFNRegistryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDetectStackDriftCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDetectStackDriftCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDetectStackDriftOutput(data.DetectStackDriftResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDetectStackDriftCommand = deserializeAws_queryDetectStackDriftCommand; +const deserializeAws_queryDetectStackDriftCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDetectStackResourceDriftCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDetectStackResourceDriftCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDetectStackResourceDriftOutput(data.DetectStackResourceDriftResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDetectStackResourceDriftCommand = deserializeAws_queryDetectStackResourceDriftCommand; +const deserializeAws_queryDetectStackResourceDriftCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryDetectStackSetDriftCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryDetectStackSetDriftCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryDetectStackSetDriftOutput(data.DetectStackSetDriftResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryDetectStackSetDriftCommand = deserializeAws_queryDetectStackSetDriftCommand; +const deserializeAws_queryDetectStackSetDriftCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidOperationException": + case "com.amazonaws.cloudformation#InvalidOperationException": + response = { + ...(await deserializeAws_queryInvalidOperationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationInProgressException": + case "com.amazonaws.cloudformation#OperationInProgressException": + response = { + ...(await deserializeAws_queryOperationInProgressExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryEstimateTemplateCostCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryEstimateTemplateCostCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryEstimateTemplateCostOutput(data.EstimateTemplateCostResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryEstimateTemplateCostCommand = deserializeAws_queryEstimateTemplateCostCommand; +const deserializeAws_queryEstimateTemplateCostCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryExecuteChangeSetCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryExecuteChangeSetCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryExecuteChangeSetOutput(data.ExecuteChangeSetResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryExecuteChangeSetCommand = deserializeAws_queryExecuteChangeSetCommand; +const deserializeAws_queryExecuteChangeSetCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ChangeSetNotFoundException": + case "com.amazonaws.cloudformation#ChangeSetNotFoundException": + response = { + ...(await deserializeAws_queryChangeSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InsufficientCapabilitiesException": + case "com.amazonaws.cloudformation#InsufficientCapabilitiesException": + response = { + ...(await deserializeAws_queryInsufficientCapabilitiesExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidChangeSetStatusException": + case "com.amazonaws.cloudformation#InvalidChangeSetStatusException": + response = { + ...(await deserializeAws_queryInvalidChangeSetStatusExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TokenAlreadyExistsException": + case "com.amazonaws.cloudformation#TokenAlreadyExistsException": + response = { + ...(await deserializeAws_queryTokenAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryGetStackPolicyCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryGetStackPolicyCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryGetStackPolicyOutput(data.GetStackPolicyResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryGetStackPolicyCommand = deserializeAws_queryGetStackPolicyCommand; +const deserializeAws_queryGetStackPolicyCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryGetTemplateCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryGetTemplateCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryGetTemplateOutput(data.GetTemplateResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryGetTemplateCommand = deserializeAws_queryGetTemplateCommand; +const deserializeAws_queryGetTemplateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ChangeSetNotFoundException": + case "com.amazonaws.cloudformation#ChangeSetNotFoundException": + response = { + ...(await deserializeAws_queryChangeSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryGetTemplateSummaryCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryGetTemplateSummaryCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryGetTemplateSummaryOutput(data.GetTemplateSummaryResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryGetTemplateSummaryCommand = deserializeAws_queryGetTemplateSummaryCommand; +const deserializeAws_queryGetTemplateSummaryCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListChangeSetsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListChangeSetsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListChangeSetsOutput(data.ListChangeSetsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListChangeSetsCommand = deserializeAws_queryListChangeSetsCommand; +const deserializeAws_queryListChangeSetsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListExportsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListExportsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListExportsOutput(data.ListExportsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListExportsCommand = deserializeAws_queryListExportsCommand; +const deserializeAws_queryListExportsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListImportsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListImportsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListImportsOutput(data.ListImportsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListImportsCommand = deserializeAws_queryListImportsCommand; +const deserializeAws_queryListImportsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListStackInstancesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListStackInstancesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListStackInstancesOutput(data.ListStackInstancesResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListStackInstancesCommand = deserializeAws_queryListStackInstancesCommand; +const deserializeAws_queryListStackInstancesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListStackResourcesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListStackResourcesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListStackResourcesOutput(data.ListStackResourcesResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListStackResourcesCommand = deserializeAws_queryListStackResourcesCommand; +const deserializeAws_queryListStackResourcesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListStacksCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListStacksCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListStacksOutput(data.ListStacksResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListStacksCommand = deserializeAws_queryListStacksCommand; +const deserializeAws_queryListStacksCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListStackSetOperationResultsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListStackSetOperationResultsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListStackSetOperationResultsOutput(data.ListStackSetOperationResultsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListStackSetOperationResultsCommand = deserializeAws_queryListStackSetOperationResultsCommand; +const deserializeAws_queryListStackSetOperationResultsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "OperationNotFoundException": + case "com.amazonaws.cloudformation#OperationNotFoundException": + response = { + ...(await deserializeAws_queryOperationNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListStackSetOperationsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListStackSetOperationsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListStackSetOperationsOutput(data.ListStackSetOperationsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListStackSetOperationsCommand = deserializeAws_queryListStackSetOperationsCommand; +const deserializeAws_queryListStackSetOperationsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListStackSetsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListStackSetsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListStackSetsOutput(data.ListStackSetsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListStackSetsCommand = deserializeAws_queryListStackSetsCommand; +const deserializeAws_queryListStackSetsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListTypeRegistrationsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListTypeRegistrationsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListTypeRegistrationsOutput(data.ListTypeRegistrationsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListTypeRegistrationsCommand = deserializeAws_queryListTypeRegistrationsCommand; +const deserializeAws_queryListTypeRegistrationsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CFNRegistryException": + case "com.amazonaws.cloudformation#CFNRegistryException": + response = { + ...(await deserializeAws_queryCFNRegistryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListTypesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListTypesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListTypesOutput(data.ListTypesResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListTypesCommand = deserializeAws_queryListTypesCommand; +const deserializeAws_queryListTypesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CFNRegistryException": + case "com.amazonaws.cloudformation#CFNRegistryException": + response = { + ...(await deserializeAws_queryCFNRegistryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryListTypeVersionsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryListTypeVersionsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryListTypeVersionsOutput(data.ListTypeVersionsResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryListTypeVersionsCommand = deserializeAws_queryListTypeVersionsCommand; +const deserializeAws_queryListTypeVersionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CFNRegistryException": + case "com.amazonaws.cloudformation#CFNRegistryException": + response = { + ...(await deserializeAws_queryCFNRegistryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryRecordHandlerProgressCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryRecordHandlerProgressCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryRecordHandlerProgressOutput(data.RecordHandlerProgressResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryRecordHandlerProgressCommand = deserializeAws_queryRecordHandlerProgressCommand; +const deserializeAws_queryRecordHandlerProgressCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidStateTransitionException": + case "com.amazonaws.cloudformation#InvalidStateTransitionException": + response = { + ...(await deserializeAws_queryInvalidStateTransitionExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationStatusCheckFailedException": + case "com.amazonaws.cloudformation#OperationStatusCheckFailedException": + response = { + ...(await deserializeAws_queryOperationStatusCheckFailedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryRegisterTypeCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryRegisterTypeCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryRegisterTypeOutput(data.RegisterTypeResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryRegisterTypeCommand = deserializeAws_queryRegisterTypeCommand; +const deserializeAws_queryRegisterTypeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CFNRegistryException": + case "com.amazonaws.cloudformation#CFNRegistryException": + response = { + ...(await deserializeAws_queryCFNRegistryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_querySetStackPolicyCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_querySetStackPolicyCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_querySetStackPolicyCommand = deserializeAws_querySetStackPolicyCommand; +const deserializeAws_querySetStackPolicyCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_querySetTypeDefaultVersionCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_querySetTypeDefaultVersionCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_querySetTypeDefaultVersionOutput(data.SetTypeDefaultVersionResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_querySetTypeDefaultVersionCommand = deserializeAws_querySetTypeDefaultVersionCommand; +const deserializeAws_querySetTypeDefaultVersionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CFNRegistryException": + case "com.amazonaws.cloudformation#CFNRegistryException": + response = { + ...(await deserializeAws_queryCFNRegistryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TypeNotFoundException": + case "com.amazonaws.cloudformation#TypeNotFoundException": + response = { + ...(await deserializeAws_queryTypeNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_querySignalResourceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_querySignalResourceCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_querySignalResourceCommand = deserializeAws_querySignalResourceCommand; +const deserializeAws_querySignalResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryStopStackSetOperationCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryStopStackSetOperationCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryStopStackSetOperationOutput(data.StopStackSetOperationResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryStopStackSetOperationCommand = deserializeAws_queryStopStackSetOperationCommand; +const deserializeAws_queryStopStackSetOperationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidOperationException": + case "com.amazonaws.cloudformation#InvalidOperationException": + response = { + ...(await deserializeAws_queryInvalidOperationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationNotFoundException": + case "com.amazonaws.cloudformation#OperationNotFoundException": + response = { + ...(await deserializeAws_queryOperationNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryUpdateStackCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryUpdateStackCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryUpdateStackOutput(data.UpdateStackResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryUpdateStackCommand = deserializeAws_queryUpdateStackCommand; +const deserializeAws_queryUpdateStackCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InsufficientCapabilitiesException": + case "com.amazonaws.cloudformation#InsufficientCapabilitiesException": + response = { + ...(await deserializeAws_queryInsufficientCapabilitiesExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TokenAlreadyExistsException": + case "com.amazonaws.cloudformation#TokenAlreadyExistsException": + response = { + ...(await deserializeAws_queryTokenAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryUpdateStackInstancesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryUpdateStackInstancesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryUpdateStackInstancesOutput(data.UpdateStackInstancesResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryUpdateStackInstancesCommand = deserializeAws_queryUpdateStackInstancesCommand; +const deserializeAws_queryUpdateStackInstancesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidOperationException": + case "com.amazonaws.cloudformation#InvalidOperationException": + response = { + ...(await deserializeAws_queryInvalidOperationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationIdAlreadyExistsException": + case "com.amazonaws.cloudformation#OperationIdAlreadyExistsException": + response = { + ...(await deserializeAws_queryOperationIdAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationInProgressException": + case "com.amazonaws.cloudformation#OperationInProgressException": + response = { + ...(await deserializeAws_queryOperationInProgressExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackInstanceNotFoundException": + case "com.amazonaws.cloudformation#StackInstanceNotFoundException": + response = { + ...(await deserializeAws_queryStackInstanceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StaleRequestException": + case "com.amazonaws.cloudformation#StaleRequestException": + response = { + ...(await deserializeAws_queryStaleRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryUpdateStackSetCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryUpdateStackSetCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryUpdateStackSetOutput(data.UpdateStackSetResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryUpdateStackSetCommand = deserializeAws_queryUpdateStackSetCommand; +const deserializeAws_queryUpdateStackSetCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidOperationException": + case "com.amazonaws.cloudformation#InvalidOperationException": + response = { + ...(await deserializeAws_queryInvalidOperationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationIdAlreadyExistsException": + case "com.amazonaws.cloudformation#OperationIdAlreadyExistsException": + response = { + ...(await deserializeAws_queryOperationIdAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "OperationInProgressException": + case "com.amazonaws.cloudformation#OperationInProgressException": + response = { + ...(await deserializeAws_queryOperationInProgressExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackInstanceNotFoundException": + case "com.amazonaws.cloudformation#StackInstanceNotFoundException": + response = { + ...(await deserializeAws_queryStackInstanceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StackSetNotFoundException": + case "com.amazonaws.cloudformation#StackSetNotFoundException": + response = { + ...(await deserializeAws_queryStackSetNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "StaleRequestException": + case "com.amazonaws.cloudformation#StaleRequestException": + response = { + ...(await deserializeAws_queryStaleRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryUpdateTerminationProtectionCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryUpdateTerminationProtectionCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryUpdateTerminationProtectionOutput(data.UpdateTerminationProtectionResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryUpdateTerminationProtectionCommand = deserializeAws_queryUpdateTerminationProtectionCommand; +const deserializeAws_queryUpdateTerminationProtectionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryValidateTemplateCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_queryValidateTemplateCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_queryValidateTemplateOutput(data.ValidateTemplateResult, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_queryValidateTemplateCommand = deserializeAws_queryValidateTemplateCommand; +const deserializeAws_queryValidateTemplateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadQueryErrorCode(output, parsedOutput.body); + switch (errorCode) { + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.Error.code || parsedBody.Error.Code || errorCode; + response = { + ...parsedBody.Error, + name: `${errorCode}`, + message: parsedBody.Error.message || parsedBody.Error.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_queryAlreadyExistsExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryAlreadyExistsException(body.Error, context); + const contents = { + name: "AlreadyExistsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryCFNRegistryExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryCFNRegistryException(body.Error, context); + const contents = { + name: "CFNRegistryException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryChangeSetNotFoundExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryChangeSetNotFoundException(body.Error, context); + const contents = { + name: "ChangeSetNotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryCreatedButModifiedExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryCreatedButModifiedException(body.Error, context); + const contents = { + name: "CreatedButModifiedException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryInsufficientCapabilitiesExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryInsufficientCapabilitiesException(body.Error, context); + const contents = { + name: "InsufficientCapabilitiesException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryInvalidChangeSetStatusExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryInvalidChangeSetStatusException(body.Error, context); + const contents = { + name: "InvalidChangeSetStatusException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryInvalidOperationExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryInvalidOperationException(body.Error, context); + const contents = { + name: "InvalidOperationException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryInvalidStateTransitionExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryInvalidStateTransitionException(body.Error, context); + const contents = { + name: "InvalidStateTransitionException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryLimitExceededExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryLimitExceededException(body.Error, context); + const contents = { + name: "LimitExceededException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryNameAlreadyExistsExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryNameAlreadyExistsException(body.Error, context); + const contents = { + name: "NameAlreadyExistsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryOperationIdAlreadyExistsExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryOperationIdAlreadyExistsException(body.Error, context); + const contents = { + name: "OperationIdAlreadyExistsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryOperationInProgressExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryOperationInProgressException(body.Error, context); + const contents = { + name: "OperationInProgressException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryOperationNotFoundExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryOperationNotFoundException(body.Error, context); + const contents = { + name: "OperationNotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryOperationStatusCheckFailedExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryOperationStatusCheckFailedException(body.Error, context); + const contents = { + name: "OperationStatusCheckFailedException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryStackInstanceNotFoundExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryStackInstanceNotFoundException(body.Error, context); + const contents = { + name: "StackInstanceNotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryStackSetNotEmptyExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryStackSetNotEmptyException(body.Error, context); + const contents = { + name: "StackSetNotEmptyException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryStackSetNotFoundExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryStackSetNotFoundException(body.Error, context); + const contents = { + name: "StackSetNotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryStaleRequestExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryStaleRequestException(body.Error, context); + const contents = { + name: "StaleRequestException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryTokenAlreadyExistsExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryTokenAlreadyExistsException(body.Error, context); + const contents = { + name: "TokenAlreadyExistsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_queryTypeNotFoundExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_queryTypeNotFoundException(body.Error, context); + const contents = { + name: "TypeNotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const serializeAws_queryAccountList = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryAutoDeployment = (input, context) => { + const entries = {}; + if (input.Enabled !== undefined && input.Enabled !== null) { + entries["Enabled"] = input.Enabled; + } + if (input.RetainStacksOnAccountRemoval !== undefined && input.RetainStacksOnAccountRemoval !== null) { + entries["RetainStacksOnAccountRemoval"] = input.RetainStacksOnAccountRemoval; + } + return entries; +}; +const serializeAws_queryCancelUpdateStackInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.ClientRequestToken !== undefined && input.ClientRequestToken !== null) { + entries["ClientRequestToken"] = input.ClientRequestToken; + } + return entries; +}; +const serializeAws_queryCapabilities = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryContinueUpdateRollbackInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.RoleARN !== undefined && input.RoleARN !== null) { + entries["RoleARN"] = input.RoleARN; + } + if (input.ResourcesToSkip !== undefined && input.ResourcesToSkip !== null) { + const memberEntries = serializeAws_queryResourcesToSkip(input.ResourcesToSkip, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `ResourcesToSkip.${key}`; + entries[loc] = value; + }); + } + if (input.ClientRequestToken !== undefined && input.ClientRequestToken !== null) { + entries["ClientRequestToken"] = input.ClientRequestToken; + } + return entries; +}; +const serializeAws_queryCreateChangeSetInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.TemplateBody !== undefined && input.TemplateBody !== null) { + entries["TemplateBody"] = input.TemplateBody; + } + if (input.TemplateURL !== undefined && input.TemplateURL !== null) { + entries["TemplateURL"] = input.TemplateURL; + } + if (input.UsePreviousTemplate !== undefined && input.UsePreviousTemplate !== null) { + entries["UsePreviousTemplate"] = input.UsePreviousTemplate; + } + if (input.Parameters !== undefined && input.Parameters !== null) { + const memberEntries = serializeAws_queryParameters(input.Parameters, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Parameters.${key}`; + entries[loc] = value; + }); + } + if (input.Capabilities !== undefined && input.Capabilities !== null) { + const memberEntries = serializeAws_queryCapabilities(input.Capabilities, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Capabilities.${key}`; + entries[loc] = value; + }); + } + if (input.ResourceTypes !== undefined && input.ResourceTypes !== null) { + const memberEntries = serializeAws_queryResourceTypes(input.ResourceTypes, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `ResourceTypes.${key}`; + entries[loc] = value; + }); + } + if (input.RoleARN !== undefined && input.RoleARN !== null) { + entries["RoleARN"] = input.RoleARN; + } + if (input.RollbackConfiguration !== undefined && input.RollbackConfiguration !== null) { + const memberEntries = serializeAws_queryRollbackConfiguration(input.RollbackConfiguration, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `RollbackConfiguration.${key}`; + entries[loc] = value; + }); + } + if (input.NotificationARNs !== undefined && input.NotificationARNs !== null) { + const memberEntries = serializeAws_queryNotificationARNs(input.NotificationARNs, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `NotificationARNs.${key}`; + entries[loc] = value; + }); + } + if (input.Tags !== undefined && input.Tags !== null) { + const memberEntries = serializeAws_queryTags(input.Tags, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Tags.${key}`; + entries[loc] = value; + }); + } + if (input.ChangeSetName !== undefined && input.ChangeSetName !== null) { + entries["ChangeSetName"] = input.ChangeSetName; + } + if (input.ClientToken !== undefined && input.ClientToken !== null) { + entries["ClientToken"] = input.ClientToken; + } + if (input.Description !== undefined && input.Description !== null) { + entries["Description"] = input.Description; + } + if (input.ChangeSetType !== undefined && input.ChangeSetType !== null) { + entries["ChangeSetType"] = input.ChangeSetType; + } + if (input.ResourcesToImport !== undefined && input.ResourcesToImport !== null) { + const memberEntries = serializeAws_queryResourcesToImport(input.ResourcesToImport, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `ResourcesToImport.${key}`; + entries[loc] = value; + }); + } + if (input.IncludeNestedStacks !== undefined && input.IncludeNestedStacks !== null) { + entries["IncludeNestedStacks"] = input.IncludeNestedStacks; + } + return entries; +}; +const serializeAws_queryCreateStackInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.TemplateBody !== undefined && input.TemplateBody !== null) { + entries["TemplateBody"] = input.TemplateBody; + } + if (input.TemplateURL !== undefined && input.TemplateURL !== null) { + entries["TemplateURL"] = input.TemplateURL; + } + if (input.Parameters !== undefined && input.Parameters !== null) { + const memberEntries = serializeAws_queryParameters(input.Parameters, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Parameters.${key}`; + entries[loc] = value; + }); + } + if (input.DisableRollback !== undefined && input.DisableRollback !== null) { + entries["DisableRollback"] = input.DisableRollback; + } + if (input.RollbackConfiguration !== undefined && input.RollbackConfiguration !== null) { + const memberEntries = serializeAws_queryRollbackConfiguration(input.RollbackConfiguration, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `RollbackConfiguration.${key}`; + entries[loc] = value; + }); + } + if (input.TimeoutInMinutes !== undefined && input.TimeoutInMinutes !== null) { + entries["TimeoutInMinutes"] = input.TimeoutInMinutes; + } + if (input.NotificationARNs !== undefined && input.NotificationARNs !== null) { + const memberEntries = serializeAws_queryNotificationARNs(input.NotificationARNs, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `NotificationARNs.${key}`; + entries[loc] = value; + }); + } + if (input.Capabilities !== undefined && input.Capabilities !== null) { + const memberEntries = serializeAws_queryCapabilities(input.Capabilities, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Capabilities.${key}`; + entries[loc] = value; + }); + } + if (input.ResourceTypes !== undefined && input.ResourceTypes !== null) { + const memberEntries = serializeAws_queryResourceTypes(input.ResourceTypes, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `ResourceTypes.${key}`; + entries[loc] = value; + }); + } + if (input.RoleARN !== undefined && input.RoleARN !== null) { + entries["RoleARN"] = input.RoleARN; + } + if (input.OnFailure !== undefined && input.OnFailure !== null) { + entries["OnFailure"] = input.OnFailure; + } + if (input.StackPolicyBody !== undefined && input.StackPolicyBody !== null) { + entries["StackPolicyBody"] = input.StackPolicyBody; + } + if (input.StackPolicyURL !== undefined && input.StackPolicyURL !== null) { + entries["StackPolicyURL"] = input.StackPolicyURL; + } + if (input.Tags !== undefined && input.Tags !== null) { + const memberEntries = serializeAws_queryTags(input.Tags, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Tags.${key}`; + entries[loc] = value; + }); + } + if (input.ClientRequestToken !== undefined && input.ClientRequestToken !== null) { + entries["ClientRequestToken"] = input.ClientRequestToken; + } + if (input.EnableTerminationProtection !== undefined && input.EnableTerminationProtection !== null) { + entries["EnableTerminationProtection"] = input.EnableTerminationProtection; + } + return entries; +}; +const serializeAws_queryCreateStackInstancesInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.Accounts !== undefined && input.Accounts !== null) { + const memberEntries = serializeAws_queryAccountList(input.Accounts, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Accounts.${key}`; + entries[loc] = value; + }); + } + if (input.DeploymentTargets !== undefined && input.DeploymentTargets !== null) { + const memberEntries = serializeAws_queryDeploymentTargets(input.DeploymentTargets, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `DeploymentTargets.${key}`; + entries[loc] = value; + }); + } + if (input.Regions !== undefined && input.Regions !== null) { + const memberEntries = serializeAws_queryRegionList(input.Regions, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Regions.${key}`; + entries[loc] = value; + }); + } + if (input.ParameterOverrides !== undefined && input.ParameterOverrides !== null) { + const memberEntries = serializeAws_queryParameters(input.ParameterOverrides, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `ParameterOverrides.${key}`; + entries[loc] = value; + }); + } + if (input.OperationPreferences !== undefined && input.OperationPreferences !== null) { + const memberEntries = serializeAws_queryStackSetOperationPreferences(input.OperationPreferences, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `OperationPreferences.${key}`; + entries[loc] = value; + }); + } + if (input.OperationId === undefined) { + input.OperationId = uuid_1.v4(); + } + if (input.OperationId !== undefined && input.OperationId !== null) { + entries["OperationId"] = input.OperationId; + } + return entries; +}; +const serializeAws_queryCreateStackSetInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.Description !== undefined && input.Description !== null) { + entries["Description"] = input.Description; + } + if (input.TemplateBody !== undefined && input.TemplateBody !== null) { + entries["TemplateBody"] = input.TemplateBody; + } + if (input.TemplateURL !== undefined && input.TemplateURL !== null) { + entries["TemplateURL"] = input.TemplateURL; + } + if (input.Parameters !== undefined && input.Parameters !== null) { + const memberEntries = serializeAws_queryParameters(input.Parameters, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Parameters.${key}`; + entries[loc] = value; + }); + } + if (input.Capabilities !== undefined && input.Capabilities !== null) { + const memberEntries = serializeAws_queryCapabilities(input.Capabilities, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Capabilities.${key}`; + entries[loc] = value; + }); + } + if (input.Tags !== undefined && input.Tags !== null) { + const memberEntries = serializeAws_queryTags(input.Tags, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Tags.${key}`; + entries[loc] = value; + }); + } + if (input.AdministrationRoleARN !== undefined && input.AdministrationRoleARN !== null) { + entries["AdministrationRoleARN"] = input.AdministrationRoleARN; + } + if (input.ExecutionRoleName !== undefined && input.ExecutionRoleName !== null) { + entries["ExecutionRoleName"] = input.ExecutionRoleName; + } + if (input.PermissionModel !== undefined && input.PermissionModel !== null) { + entries["PermissionModel"] = input.PermissionModel; + } + if (input.AutoDeployment !== undefined && input.AutoDeployment !== null) { + const memberEntries = serializeAws_queryAutoDeployment(input.AutoDeployment, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `AutoDeployment.${key}`; + entries[loc] = value; + }); + } + if (input.ClientRequestToken === undefined) { + input.ClientRequestToken = uuid_1.v4(); + } + if (input.ClientRequestToken !== undefined && input.ClientRequestToken !== null) { + entries["ClientRequestToken"] = input.ClientRequestToken; + } + return entries; +}; +const serializeAws_queryDeleteChangeSetInput = (input, context) => { + const entries = {}; + if (input.ChangeSetName !== undefined && input.ChangeSetName !== null) { + entries["ChangeSetName"] = input.ChangeSetName; + } + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + return entries; +}; +const serializeAws_queryDeleteStackInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.RetainResources !== undefined && input.RetainResources !== null) { + const memberEntries = serializeAws_queryRetainResources(input.RetainResources, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `RetainResources.${key}`; + entries[loc] = value; + }); + } + if (input.RoleARN !== undefined && input.RoleARN !== null) { + entries["RoleARN"] = input.RoleARN; + } + if (input.ClientRequestToken !== undefined && input.ClientRequestToken !== null) { + entries["ClientRequestToken"] = input.ClientRequestToken; + } + return entries; +}; +const serializeAws_queryDeleteStackInstancesInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.Accounts !== undefined && input.Accounts !== null) { + const memberEntries = serializeAws_queryAccountList(input.Accounts, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Accounts.${key}`; + entries[loc] = value; + }); + } + if (input.DeploymentTargets !== undefined && input.DeploymentTargets !== null) { + const memberEntries = serializeAws_queryDeploymentTargets(input.DeploymentTargets, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `DeploymentTargets.${key}`; + entries[loc] = value; + }); + } + if (input.Regions !== undefined && input.Regions !== null) { + const memberEntries = serializeAws_queryRegionList(input.Regions, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Regions.${key}`; + entries[loc] = value; + }); + } + if (input.OperationPreferences !== undefined && input.OperationPreferences !== null) { + const memberEntries = serializeAws_queryStackSetOperationPreferences(input.OperationPreferences, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `OperationPreferences.${key}`; + entries[loc] = value; + }); + } + if (input.RetainStacks !== undefined && input.RetainStacks !== null) { + entries["RetainStacks"] = input.RetainStacks; + } + if (input.OperationId === undefined) { + input.OperationId = uuid_1.v4(); + } + if (input.OperationId !== undefined && input.OperationId !== null) { + entries["OperationId"] = input.OperationId; + } + return entries; +}; +const serializeAws_queryDeleteStackSetInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + return entries; +}; +const serializeAws_queryDeploymentTargets = (input, context) => { + const entries = {}; + if (input.Accounts !== undefined && input.Accounts !== null) { + const memberEntries = serializeAws_queryAccountList(input.Accounts, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Accounts.${key}`; + entries[loc] = value; + }); + } + if (input.OrganizationalUnitIds !== undefined && input.OrganizationalUnitIds !== null) { + const memberEntries = serializeAws_queryOrganizationalUnitIdList(input.OrganizationalUnitIds, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `OrganizationalUnitIds.${key}`; + entries[loc] = value; + }); + } + return entries; +}; +const serializeAws_queryDeregisterTypeInput = (input, context) => { + const entries = {}; + if (input.Arn !== undefined && input.Arn !== null) { + entries["Arn"] = input.Arn; + } + if (input.Type !== undefined && input.Type !== null) { + entries["Type"] = input.Type; + } + if (input.TypeName !== undefined && input.TypeName !== null) { + entries["TypeName"] = input.TypeName; + } + if (input.VersionId !== undefined && input.VersionId !== null) { + entries["VersionId"] = input.VersionId; + } + return entries; +}; +const serializeAws_queryDescribeAccountLimitsInput = (input, context) => { + const entries = {}; + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + return entries; +}; +const serializeAws_queryDescribeChangeSetInput = (input, context) => { + const entries = {}; + if (input.ChangeSetName !== undefined && input.ChangeSetName !== null) { + entries["ChangeSetName"] = input.ChangeSetName; + } + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + return entries; +}; +const serializeAws_queryDescribeStackDriftDetectionStatusInput = (input, context) => { + const entries = {}; + if (input.StackDriftDetectionId !== undefined && input.StackDriftDetectionId !== null) { + entries["StackDriftDetectionId"] = input.StackDriftDetectionId; + } + return entries; +}; +const serializeAws_queryDescribeStackEventsInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + return entries; +}; +const serializeAws_queryDescribeStackInstanceInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.StackInstanceAccount !== undefined && input.StackInstanceAccount !== null) { + entries["StackInstanceAccount"] = input.StackInstanceAccount; + } + if (input.StackInstanceRegion !== undefined && input.StackInstanceRegion !== null) { + entries["StackInstanceRegion"] = input.StackInstanceRegion; + } + return entries; +}; +const serializeAws_queryDescribeStackResourceDriftsInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.StackResourceDriftStatusFilters !== undefined && input.StackResourceDriftStatusFilters !== null) { + const memberEntries = serializeAws_queryStackResourceDriftStatusFilters(input.StackResourceDriftStatusFilters, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `StackResourceDriftStatusFilters.${key}`; + entries[loc] = value; + }); + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + if (input.MaxResults !== undefined && input.MaxResults !== null) { + entries["MaxResults"] = input.MaxResults; + } + return entries; +}; +const serializeAws_queryDescribeStackResourceInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.LogicalResourceId !== undefined && input.LogicalResourceId !== null) { + entries["LogicalResourceId"] = input.LogicalResourceId; + } + return entries; +}; +const serializeAws_queryDescribeStackResourcesInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.LogicalResourceId !== undefined && input.LogicalResourceId !== null) { + entries["LogicalResourceId"] = input.LogicalResourceId; + } + if (input.PhysicalResourceId !== undefined && input.PhysicalResourceId !== null) { + entries["PhysicalResourceId"] = input.PhysicalResourceId; + } + return entries; +}; +const serializeAws_queryDescribeStackSetInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + return entries; +}; +const serializeAws_queryDescribeStackSetOperationInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.OperationId !== undefined && input.OperationId !== null) { + entries["OperationId"] = input.OperationId; + } + return entries; +}; +const serializeAws_queryDescribeStacksInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + return entries; +}; +const serializeAws_queryDescribeTypeInput = (input, context) => { + const entries = {}; + if (input.Type !== undefined && input.Type !== null) { + entries["Type"] = input.Type; + } + if (input.TypeName !== undefined && input.TypeName !== null) { + entries["TypeName"] = input.TypeName; + } + if (input.Arn !== undefined && input.Arn !== null) { + entries["Arn"] = input.Arn; + } + if (input.VersionId !== undefined && input.VersionId !== null) { + entries["VersionId"] = input.VersionId; + } + return entries; +}; +const serializeAws_queryDescribeTypeRegistrationInput = (input, context) => { + const entries = {}; + if (input.RegistrationToken !== undefined && input.RegistrationToken !== null) { + entries["RegistrationToken"] = input.RegistrationToken; + } + return entries; +}; +const serializeAws_queryDetectStackDriftInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.LogicalResourceIds !== undefined && input.LogicalResourceIds !== null) { + const memberEntries = serializeAws_queryLogicalResourceIds(input.LogicalResourceIds, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `LogicalResourceIds.${key}`; + entries[loc] = value; + }); + } + return entries; +}; +const serializeAws_queryDetectStackResourceDriftInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.LogicalResourceId !== undefined && input.LogicalResourceId !== null) { + entries["LogicalResourceId"] = input.LogicalResourceId; + } + return entries; +}; +const serializeAws_queryDetectStackSetDriftInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.OperationPreferences !== undefined && input.OperationPreferences !== null) { + const memberEntries = serializeAws_queryStackSetOperationPreferences(input.OperationPreferences, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `OperationPreferences.${key}`; + entries[loc] = value; + }); + } + if (input.OperationId === undefined) { + input.OperationId = uuid_1.v4(); + } + if (input.OperationId !== undefined && input.OperationId !== null) { + entries["OperationId"] = input.OperationId; + } + return entries; +}; +const serializeAws_queryEstimateTemplateCostInput = (input, context) => { + const entries = {}; + if (input.TemplateBody !== undefined && input.TemplateBody !== null) { + entries["TemplateBody"] = input.TemplateBody; + } + if (input.TemplateURL !== undefined && input.TemplateURL !== null) { + entries["TemplateURL"] = input.TemplateURL; + } + if (input.Parameters !== undefined && input.Parameters !== null) { + const memberEntries = serializeAws_queryParameters(input.Parameters, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Parameters.${key}`; + entries[loc] = value; + }); + } + return entries; +}; +const serializeAws_queryExecuteChangeSetInput = (input, context) => { + const entries = {}; + if (input.ChangeSetName !== undefined && input.ChangeSetName !== null) { + entries["ChangeSetName"] = input.ChangeSetName; + } + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.ClientRequestToken !== undefined && input.ClientRequestToken !== null) { + entries["ClientRequestToken"] = input.ClientRequestToken; + } + return entries; +}; +const serializeAws_queryGetStackPolicyInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + return entries; +}; +const serializeAws_queryGetTemplateInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.ChangeSetName !== undefined && input.ChangeSetName !== null) { + entries["ChangeSetName"] = input.ChangeSetName; + } + if (input.TemplateStage !== undefined && input.TemplateStage !== null) { + entries["TemplateStage"] = input.TemplateStage; + } + return entries; +}; +const serializeAws_queryGetTemplateSummaryInput = (input, context) => { + const entries = {}; + if (input.TemplateBody !== undefined && input.TemplateBody !== null) { + entries["TemplateBody"] = input.TemplateBody; + } + if (input.TemplateURL !== undefined && input.TemplateURL !== null) { + entries["TemplateURL"] = input.TemplateURL; + } + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + return entries; +}; +const serializeAws_queryListChangeSetsInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + return entries; +}; +const serializeAws_queryListExportsInput = (input, context) => { + const entries = {}; + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + return entries; +}; +const serializeAws_queryListImportsInput = (input, context) => { + const entries = {}; + if (input.ExportName !== undefined && input.ExportName !== null) { + entries["ExportName"] = input.ExportName; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + return entries; +}; +const serializeAws_queryListStackInstancesInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + if (input.MaxResults !== undefined && input.MaxResults !== null) { + entries["MaxResults"] = input.MaxResults; + } + if (input.Filters !== undefined && input.Filters !== null) { + const memberEntries = serializeAws_queryStackInstanceFilters(input.Filters, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Filters.${key}`; + entries[loc] = value; + }); + } + if (input.StackInstanceAccount !== undefined && input.StackInstanceAccount !== null) { + entries["StackInstanceAccount"] = input.StackInstanceAccount; + } + if (input.StackInstanceRegion !== undefined && input.StackInstanceRegion !== null) { + entries["StackInstanceRegion"] = input.StackInstanceRegion; + } + return entries; +}; +const serializeAws_queryListStackResourcesInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + return entries; +}; +const serializeAws_queryListStackSetOperationResultsInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.OperationId !== undefined && input.OperationId !== null) { + entries["OperationId"] = input.OperationId; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + if (input.MaxResults !== undefined && input.MaxResults !== null) { + entries["MaxResults"] = input.MaxResults; + } + return entries; +}; +const serializeAws_queryListStackSetOperationsInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + if (input.MaxResults !== undefined && input.MaxResults !== null) { + entries["MaxResults"] = input.MaxResults; + } + return entries; +}; +const serializeAws_queryListStackSetsInput = (input, context) => { + const entries = {}; + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + if (input.MaxResults !== undefined && input.MaxResults !== null) { + entries["MaxResults"] = input.MaxResults; + } + if (input.Status !== undefined && input.Status !== null) { + entries["Status"] = input.Status; + } + return entries; +}; +const serializeAws_queryListStacksInput = (input, context) => { + const entries = {}; + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + if (input.StackStatusFilter !== undefined && input.StackStatusFilter !== null) { + const memberEntries = serializeAws_queryStackStatusFilter(input.StackStatusFilter, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `StackStatusFilter.${key}`; + entries[loc] = value; + }); + } + return entries; +}; +const serializeAws_queryListTypeRegistrationsInput = (input, context) => { + const entries = {}; + if (input.Type !== undefined && input.Type !== null) { + entries["Type"] = input.Type; + } + if (input.TypeName !== undefined && input.TypeName !== null) { + entries["TypeName"] = input.TypeName; + } + if (input.TypeArn !== undefined && input.TypeArn !== null) { + entries["TypeArn"] = input.TypeArn; + } + if (input.RegistrationStatusFilter !== undefined && input.RegistrationStatusFilter !== null) { + entries["RegistrationStatusFilter"] = input.RegistrationStatusFilter; + } + if (input.MaxResults !== undefined && input.MaxResults !== null) { + entries["MaxResults"] = input.MaxResults; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + return entries; +}; +const serializeAws_queryListTypesInput = (input, context) => { + const entries = {}; + if (input.Visibility !== undefined && input.Visibility !== null) { + entries["Visibility"] = input.Visibility; + } + if (input.ProvisioningType !== undefined && input.ProvisioningType !== null) { + entries["ProvisioningType"] = input.ProvisioningType; + } + if (input.DeprecatedStatus !== undefined && input.DeprecatedStatus !== null) { + entries["DeprecatedStatus"] = input.DeprecatedStatus; + } + if (input.Type !== undefined && input.Type !== null) { + entries["Type"] = input.Type; + } + if (input.MaxResults !== undefined && input.MaxResults !== null) { + entries["MaxResults"] = input.MaxResults; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + return entries; +}; +const serializeAws_queryListTypeVersionsInput = (input, context) => { + const entries = {}; + if (input.Type !== undefined && input.Type !== null) { + entries["Type"] = input.Type; + } + if (input.TypeName !== undefined && input.TypeName !== null) { + entries["TypeName"] = input.TypeName; + } + if (input.Arn !== undefined && input.Arn !== null) { + entries["Arn"] = input.Arn; + } + if (input.MaxResults !== undefined && input.MaxResults !== null) { + entries["MaxResults"] = input.MaxResults; + } + if (input.NextToken !== undefined && input.NextToken !== null) { + entries["NextToken"] = input.NextToken; + } + if (input.DeprecatedStatus !== undefined && input.DeprecatedStatus !== null) { + entries["DeprecatedStatus"] = input.DeprecatedStatus; + } + return entries; +}; +const serializeAws_queryLoggingConfig = (input, context) => { + const entries = {}; + if (input.LogRoleArn !== undefined && input.LogRoleArn !== null) { + entries["LogRoleArn"] = input.LogRoleArn; + } + if (input.LogGroupName !== undefined && input.LogGroupName !== null) { + entries["LogGroupName"] = input.LogGroupName; + } + return entries; +}; +const serializeAws_queryLogicalResourceIds = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryNotificationARNs = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryOrganizationalUnitIdList = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryParameter = (input, context) => { + const entries = {}; + if (input.ParameterKey !== undefined && input.ParameterKey !== null) { + entries["ParameterKey"] = input.ParameterKey; + } + if (input.ParameterValue !== undefined && input.ParameterValue !== null) { + entries["ParameterValue"] = input.ParameterValue; + } + if (input.UsePreviousValue !== undefined && input.UsePreviousValue !== null) { + entries["UsePreviousValue"] = input.UsePreviousValue; + } + if (input.ResolvedValue !== undefined && input.ResolvedValue !== null) { + entries["ResolvedValue"] = input.ResolvedValue; + } + return entries; +}; +const serializeAws_queryParameters = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + const memberEntries = serializeAws_queryParameter(entry, context); + Object.entries(memberEntries).forEach(([key, value]) => { + entries[`member.${counter}.${key}`] = value; + }); + counter++; + } + return entries; +}; +const serializeAws_queryRecordHandlerProgressInput = (input, context) => { + const entries = {}; + if (input.BearerToken !== undefined && input.BearerToken !== null) { + entries["BearerToken"] = input.BearerToken; + } + if (input.OperationStatus !== undefined && input.OperationStatus !== null) { + entries["OperationStatus"] = input.OperationStatus; + } + if (input.CurrentOperationStatus !== undefined && input.CurrentOperationStatus !== null) { + entries["CurrentOperationStatus"] = input.CurrentOperationStatus; + } + if (input.StatusMessage !== undefined && input.StatusMessage !== null) { + entries["StatusMessage"] = input.StatusMessage; + } + if (input.ErrorCode !== undefined && input.ErrorCode !== null) { + entries["ErrorCode"] = input.ErrorCode; + } + if (input.ResourceModel !== undefined && input.ResourceModel !== null) { + entries["ResourceModel"] = input.ResourceModel; + } + if (input.ClientRequestToken !== undefined && input.ClientRequestToken !== null) { + entries["ClientRequestToken"] = input.ClientRequestToken; + } + return entries; +}; +const serializeAws_queryRegionList = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryRegisterTypeInput = (input, context) => { + const entries = {}; + if (input.Type !== undefined && input.Type !== null) { + entries["Type"] = input.Type; + } + if (input.TypeName !== undefined && input.TypeName !== null) { + entries["TypeName"] = input.TypeName; + } + if (input.SchemaHandlerPackage !== undefined && input.SchemaHandlerPackage !== null) { + entries["SchemaHandlerPackage"] = input.SchemaHandlerPackage; + } + if (input.LoggingConfig !== undefined && input.LoggingConfig !== null) { + const memberEntries = serializeAws_queryLoggingConfig(input.LoggingConfig, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `LoggingConfig.${key}`; + entries[loc] = value; + }); + } + if (input.ExecutionRoleArn !== undefined && input.ExecutionRoleArn !== null) { + entries["ExecutionRoleArn"] = input.ExecutionRoleArn; + } + if (input.ClientRequestToken !== undefined && input.ClientRequestToken !== null) { + entries["ClientRequestToken"] = input.ClientRequestToken; + } + return entries; +}; +const serializeAws_queryResourceIdentifierProperties = (input, context) => { + const entries = {}; + let counter = 1; + Object.keys(input) + .filter((key) => input[key] != null) + .forEach((key) => { + entries[`entry.${counter}.key`] = key; + entries[`entry.${counter}.value`] = input[key]; + counter++; + }); + return entries; +}; +const serializeAws_queryResourcesToImport = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + const memberEntries = serializeAws_queryResourceToImport(entry, context); + Object.entries(memberEntries).forEach(([key, value]) => { + entries[`member.${counter}.${key}`] = value; + }); + counter++; + } + return entries; +}; +const serializeAws_queryResourcesToSkip = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryResourceToImport = (input, context) => { + const entries = {}; + if (input.ResourceType !== undefined && input.ResourceType !== null) { + entries["ResourceType"] = input.ResourceType; + } + if (input.LogicalResourceId !== undefined && input.LogicalResourceId !== null) { + entries["LogicalResourceId"] = input.LogicalResourceId; + } + if (input.ResourceIdentifier !== undefined && input.ResourceIdentifier !== null) { + const memberEntries = serializeAws_queryResourceIdentifierProperties(input.ResourceIdentifier, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `ResourceIdentifier.${key}`; + entries[loc] = value; + }); + } + return entries; +}; +const serializeAws_queryResourceTypes = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryRetainResources = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryRollbackConfiguration = (input, context) => { + const entries = {}; + if (input.RollbackTriggers !== undefined && input.RollbackTriggers !== null) { + const memberEntries = serializeAws_queryRollbackTriggers(input.RollbackTriggers, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `RollbackTriggers.${key}`; + entries[loc] = value; + }); + } + if (input.MonitoringTimeInMinutes !== undefined && input.MonitoringTimeInMinutes !== null) { + entries["MonitoringTimeInMinutes"] = input.MonitoringTimeInMinutes; + } + return entries; +}; +const serializeAws_queryRollbackTrigger = (input, context) => { + const entries = {}; + if (input.Arn !== undefined && input.Arn !== null) { + entries["Arn"] = input.Arn; + } + if (input.Type !== undefined && input.Type !== null) { + entries["Type"] = input.Type; + } + return entries; +}; +const serializeAws_queryRollbackTriggers = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + const memberEntries = serializeAws_queryRollbackTrigger(entry, context); + Object.entries(memberEntries).forEach(([key, value]) => { + entries[`member.${counter}.${key}`] = value; + }); + counter++; + } + return entries; +}; +const serializeAws_querySetStackPolicyInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.StackPolicyBody !== undefined && input.StackPolicyBody !== null) { + entries["StackPolicyBody"] = input.StackPolicyBody; + } + if (input.StackPolicyURL !== undefined && input.StackPolicyURL !== null) { + entries["StackPolicyURL"] = input.StackPolicyURL; + } + return entries; +}; +const serializeAws_querySetTypeDefaultVersionInput = (input, context) => { + const entries = {}; + if (input.Arn !== undefined && input.Arn !== null) { + entries["Arn"] = input.Arn; + } + if (input.Type !== undefined && input.Type !== null) { + entries["Type"] = input.Type; + } + if (input.TypeName !== undefined && input.TypeName !== null) { + entries["TypeName"] = input.TypeName; + } + if (input.VersionId !== undefined && input.VersionId !== null) { + entries["VersionId"] = input.VersionId; + } + return entries; +}; +const serializeAws_querySignalResourceInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.LogicalResourceId !== undefined && input.LogicalResourceId !== null) { + entries["LogicalResourceId"] = input.LogicalResourceId; + } + if (input.UniqueId !== undefined && input.UniqueId !== null) { + entries["UniqueId"] = input.UniqueId; + } + if (input.Status !== undefined && input.Status !== null) { + entries["Status"] = input.Status; + } + return entries; +}; +const serializeAws_queryStackInstanceFilter = (input, context) => { + const entries = {}; + if (input.Name !== undefined && input.Name !== null) { + entries["Name"] = input.Name; + } + if (input.Values !== undefined && input.Values !== null) { + entries["Values"] = input.Values; + } + return entries; +}; +const serializeAws_queryStackInstanceFilters = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + const memberEntries = serializeAws_queryStackInstanceFilter(entry, context); + Object.entries(memberEntries).forEach(([key, value]) => { + entries[`member.${counter}.${key}`] = value; + }); + counter++; + } + return entries; +}; +const serializeAws_queryStackResourceDriftStatusFilters = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryStackSetOperationPreferences = (input, context) => { + const entries = {}; + if (input.RegionOrder !== undefined && input.RegionOrder !== null) { + const memberEntries = serializeAws_queryRegionList(input.RegionOrder, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `RegionOrder.${key}`; + entries[loc] = value; + }); + } + if (input.FailureToleranceCount !== undefined && input.FailureToleranceCount !== null) { + entries["FailureToleranceCount"] = input.FailureToleranceCount; + } + if (input.FailureTolerancePercentage !== undefined && input.FailureTolerancePercentage !== null) { + entries["FailureTolerancePercentage"] = input.FailureTolerancePercentage; + } + if (input.MaxConcurrentCount !== undefined && input.MaxConcurrentCount !== null) { + entries["MaxConcurrentCount"] = input.MaxConcurrentCount; + } + if (input.MaxConcurrentPercentage !== undefined && input.MaxConcurrentPercentage !== null) { + entries["MaxConcurrentPercentage"] = input.MaxConcurrentPercentage; + } + return entries; +}; +const serializeAws_queryStackStatusFilter = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + entries[`member.${counter}`] = entry; + counter++; + } + return entries; +}; +const serializeAws_queryStopStackSetOperationInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.OperationId !== undefined && input.OperationId !== null) { + entries["OperationId"] = input.OperationId; + } + return entries; +}; +const serializeAws_queryTag = (input, context) => { + const entries = {}; + if (input.Key !== undefined && input.Key !== null) { + entries["Key"] = input.Key; + } + if (input.Value !== undefined && input.Value !== null) { + entries["Value"] = input.Value; + } + return entries; +}; +const serializeAws_queryTags = (input, context) => { + const entries = {}; + let counter = 1; + for (let entry of input) { + if (entry === null) { + continue; + } + const memberEntries = serializeAws_queryTag(entry, context); + Object.entries(memberEntries).forEach(([key, value]) => { + entries[`member.${counter}.${key}`] = value; + }); + counter++; + } + return entries; +}; +const serializeAws_queryUpdateStackInput = (input, context) => { + const entries = {}; + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + if (input.TemplateBody !== undefined && input.TemplateBody !== null) { + entries["TemplateBody"] = input.TemplateBody; + } + if (input.TemplateURL !== undefined && input.TemplateURL !== null) { + entries["TemplateURL"] = input.TemplateURL; + } + if (input.UsePreviousTemplate !== undefined && input.UsePreviousTemplate !== null) { + entries["UsePreviousTemplate"] = input.UsePreviousTemplate; + } + if (input.StackPolicyDuringUpdateBody !== undefined && input.StackPolicyDuringUpdateBody !== null) { + entries["StackPolicyDuringUpdateBody"] = input.StackPolicyDuringUpdateBody; + } + if (input.StackPolicyDuringUpdateURL !== undefined && input.StackPolicyDuringUpdateURL !== null) { + entries["StackPolicyDuringUpdateURL"] = input.StackPolicyDuringUpdateURL; + } + if (input.Parameters !== undefined && input.Parameters !== null) { + const memberEntries = serializeAws_queryParameters(input.Parameters, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Parameters.${key}`; + entries[loc] = value; + }); + } + if (input.Capabilities !== undefined && input.Capabilities !== null) { + const memberEntries = serializeAws_queryCapabilities(input.Capabilities, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Capabilities.${key}`; + entries[loc] = value; + }); + } + if (input.ResourceTypes !== undefined && input.ResourceTypes !== null) { + const memberEntries = serializeAws_queryResourceTypes(input.ResourceTypes, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `ResourceTypes.${key}`; + entries[loc] = value; + }); + } + if (input.RoleARN !== undefined && input.RoleARN !== null) { + entries["RoleARN"] = input.RoleARN; + } + if (input.RollbackConfiguration !== undefined && input.RollbackConfiguration !== null) { + const memberEntries = serializeAws_queryRollbackConfiguration(input.RollbackConfiguration, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `RollbackConfiguration.${key}`; + entries[loc] = value; + }); + } + if (input.StackPolicyBody !== undefined && input.StackPolicyBody !== null) { + entries["StackPolicyBody"] = input.StackPolicyBody; + } + if (input.StackPolicyURL !== undefined && input.StackPolicyURL !== null) { + entries["StackPolicyURL"] = input.StackPolicyURL; + } + if (input.NotificationARNs !== undefined && input.NotificationARNs !== null) { + const memberEntries = serializeAws_queryNotificationARNs(input.NotificationARNs, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `NotificationARNs.${key}`; + entries[loc] = value; + }); + } + if (input.Tags !== undefined && input.Tags !== null) { + const memberEntries = serializeAws_queryTags(input.Tags, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Tags.${key}`; + entries[loc] = value; + }); + } + if (input.ClientRequestToken !== undefined && input.ClientRequestToken !== null) { + entries["ClientRequestToken"] = input.ClientRequestToken; + } + return entries; +}; +const serializeAws_queryUpdateStackInstancesInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.Accounts !== undefined && input.Accounts !== null) { + const memberEntries = serializeAws_queryAccountList(input.Accounts, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Accounts.${key}`; + entries[loc] = value; + }); + } + if (input.DeploymentTargets !== undefined && input.DeploymentTargets !== null) { + const memberEntries = serializeAws_queryDeploymentTargets(input.DeploymentTargets, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `DeploymentTargets.${key}`; + entries[loc] = value; + }); + } + if (input.Regions !== undefined && input.Regions !== null) { + const memberEntries = serializeAws_queryRegionList(input.Regions, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Regions.${key}`; + entries[loc] = value; + }); + } + if (input.ParameterOverrides !== undefined && input.ParameterOverrides !== null) { + const memberEntries = serializeAws_queryParameters(input.ParameterOverrides, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `ParameterOverrides.${key}`; + entries[loc] = value; + }); + } + if (input.OperationPreferences !== undefined && input.OperationPreferences !== null) { + const memberEntries = serializeAws_queryStackSetOperationPreferences(input.OperationPreferences, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `OperationPreferences.${key}`; + entries[loc] = value; + }); + } + if (input.OperationId === undefined) { + input.OperationId = uuid_1.v4(); + } + if (input.OperationId !== undefined && input.OperationId !== null) { + entries["OperationId"] = input.OperationId; + } + return entries; +}; +const serializeAws_queryUpdateStackSetInput = (input, context) => { + const entries = {}; + if (input.StackSetName !== undefined && input.StackSetName !== null) { + entries["StackSetName"] = input.StackSetName; + } + if (input.Description !== undefined && input.Description !== null) { + entries["Description"] = input.Description; + } + if (input.TemplateBody !== undefined && input.TemplateBody !== null) { + entries["TemplateBody"] = input.TemplateBody; + } + if (input.TemplateURL !== undefined && input.TemplateURL !== null) { + entries["TemplateURL"] = input.TemplateURL; + } + if (input.UsePreviousTemplate !== undefined && input.UsePreviousTemplate !== null) { + entries["UsePreviousTemplate"] = input.UsePreviousTemplate; + } + if (input.Parameters !== undefined && input.Parameters !== null) { + const memberEntries = serializeAws_queryParameters(input.Parameters, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Parameters.${key}`; + entries[loc] = value; + }); + } + if (input.Capabilities !== undefined && input.Capabilities !== null) { + const memberEntries = serializeAws_queryCapabilities(input.Capabilities, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Capabilities.${key}`; + entries[loc] = value; + }); + } + if (input.Tags !== undefined && input.Tags !== null) { + const memberEntries = serializeAws_queryTags(input.Tags, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Tags.${key}`; + entries[loc] = value; + }); + } + if (input.OperationPreferences !== undefined && input.OperationPreferences !== null) { + const memberEntries = serializeAws_queryStackSetOperationPreferences(input.OperationPreferences, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `OperationPreferences.${key}`; + entries[loc] = value; + }); + } + if (input.AdministrationRoleARN !== undefined && input.AdministrationRoleARN !== null) { + entries["AdministrationRoleARN"] = input.AdministrationRoleARN; + } + if (input.ExecutionRoleName !== undefined && input.ExecutionRoleName !== null) { + entries["ExecutionRoleName"] = input.ExecutionRoleName; + } + if (input.DeploymentTargets !== undefined && input.DeploymentTargets !== null) { + const memberEntries = serializeAws_queryDeploymentTargets(input.DeploymentTargets, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `DeploymentTargets.${key}`; + entries[loc] = value; + }); + } + if (input.PermissionModel !== undefined && input.PermissionModel !== null) { + entries["PermissionModel"] = input.PermissionModel; + } + if (input.AutoDeployment !== undefined && input.AutoDeployment !== null) { + const memberEntries = serializeAws_queryAutoDeployment(input.AutoDeployment, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `AutoDeployment.${key}`; + entries[loc] = value; + }); + } + if (input.OperationId === undefined) { + input.OperationId = uuid_1.v4(); + } + if (input.OperationId !== undefined && input.OperationId !== null) { + entries["OperationId"] = input.OperationId; + } + if (input.Accounts !== undefined && input.Accounts !== null) { + const memberEntries = serializeAws_queryAccountList(input.Accounts, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Accounts.${key}`; + entries[loc] = value; + }); + } + if (input.Regions !== undefined && input.Regions !== null) { + const memberEntries = serializeAws_queryRegionList(input.Regions, context); + Object.entries(memberEntries).forEach(([key, value]) => { + const loc = `Regions.${key}`; + entries[loc] = value; + }); + } + return entries; +}; +const serializeAws_queryUpdateTerminationProtectionInput = (input, context) => { + const entries = {}; + if (input.EnableTerminationProtection !== undefined && input.EnableTerminationProtection !== null) { + entries["EnableTerminationProtection"] = input.EnableTerminationProtection; + } + if (input.StackName !== undefined && input.StackName !== null) { + entries["StackName"] = input.StackName; + } + return entries; +}; +const serializeAws_queryValidateTemplateInput = (input, context) => { + const entries = {}; + if (input.TemplateBody !== undefined && input.TemplateBody !== null) { + entries["TemplateBody"] = input.TemplateBody; + } + if (input.TemplateURL !== undefined && input.TemplateURL !== null) { + entries["TemplateURL"] = input.TemplateURL; + } + return entries; +}; +const deserializeAws_queryAccountGateResult = (output, context) => { + let contents = { + Status: undefined, + StatusReason: undefined, + }; + if (output["Status"] !== undefined) { + contents.Status = output["Status"]; + } + if (output["StatusReason"] !== undefined) { + contents.StatusReason = output["StatusReason"]; + } + return contents; +}; +const deserializeAws_queryAccountLimit = (output, context) => { + let contents = { + Name: undefined, + Value: undefined, + }; + if (output["Name"] !== undefined) { + contents.Name = output["Name"]; + } + if (output["Value"] !== undefined) { + contents.Value = parseInt(output["Value"]); + } + return contents; +}; +const deserializeAws_queryAccountLimitList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryAccountLimit(entry, context); + }); +}; +const deserializeAws_queryAccountList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryAllowedValues = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryAlreadyExistsException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryAutoDeployment = (output, context) => { + let contents = { + Enabled: undefined, + RetainStacksOnAccountRemoval: undefined, + }; + if (output["Enabled"] !== undefined) { + contents.Enabled = output["Enabled"] == "true"; + } + if (output["RetainStacksOnAccountRemoval"] !== undefined) { + contents.RetainStacksOnAccountRemoval = output["RetainStacksOnAccountRemoval"] == "true"; + } + return contents; +}; +const deserializeAws_queryCapabilities = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryCFNRegistryException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryChange = (output, context) => { + let contents = { + Type: undefined, + ResourceChange: undefined, + }; + if (output["Type"] !== undefined) { + contents.Type = output["Type"]; + } + if (output["ResourceChange"] !== undefined) { + contents.ResourceChange = deserializeAws_queryResourceChange(output["ResourceChange"], context); + } + return contents; +}; +const deserializeAws_queryChanges = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryChange(entry, context); + }); +}; +const deserializeAws_queryChangeSetNotFoundException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryChangeSetSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryChangeSetSummary(entry, context); + }); +}; +const deserializeAws_queryChangeSetSummary = (output, context) => { + let contents = { + StackId: undefined, + StackName: undefined, + ChangeSetId: undefined, + ChangeSetName: undefined, + ExecutionStatus: undefined, + Status: undefined, + StatusReason: undefined, + CreationTime: undefined, + Description: undefined, + IncludeNestedStacks: undefined, + ParentChangeSetId: undefined, + RootChangeSetId: undefined, + }; + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output["StackName"] !== undefined) { + contents.StackName = output["StackName"]; + } + if (output["ChangeSetId"] !== undefined) { + contents.ChangeSetId = output["ChangeSetId"]; + } + if (output["ChangeSetName"] !== undefined) { + contents.ChangeSetName = output["ChangeSetName"]; + } + if (output["ExecutionStatus"] !== undefined) { + contents.ExecutionStatus = output["ExecutionStatus"]; + } + if (output["Status"] !== undefined) { + contents.Status = output["Status"]; + } + if (output["StatusReason"] !== undefined) { + contents.StatusReason = output["StatusReason"]; + } + if (output["CreationTime"] !== undefined) { + contents.CreationTime = new Date(output["CreationTime"]); + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output["IncludeNestedStacks"] !== undefined) { + contents.IncludeNestedStacks = output["IncludeNestedStacks"] == "true"; + } + if (output["ParentChangeSetId"] !== undefined) { + contents.ParentChangeSetId = output["ParentChangeSetId"]; + } + if (output["RootChangeSetId"] !== undefined) { + contents.RootChangeSetId = output["RootChangeSetId"]; + } + return contents; +}; +const deserializeAws_queryContinueUpdateRollbackOutput = (output, context) => { + let contents = {}; + return contents; +}; +const deserializeAws_queryCreateChangeSetOutput = (output, context) => { + let contents = { + Id: undefined, + StackId: undefined, + }; + if (output["Id"] !== undefined) { + contents.Id = output["Id"]; + } + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + return contents; +}; +const deserializeAws_queryCreatedButModifiedException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryCreateStackInstancesOutput = (output, context) => { + let contents = { + OperationId: undefined, + }; + if (output["OperationId"] !== undefined) { + contents.OperationId = output["OperationId"]; + } + return contents; +}; +const deserializeAws_queryCreateStackOutput = (output, context) => { + let contents = { + StackId: undefined, + }; + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + return contents; +}; +const deserializeAws_queryCreateStackSetOutput = (output, context) => { + let contents = { + StackSetId: undefined, + }; + if (output["StackSetId"] !== undefined) { + contents.StackSetId = output["StackSetId"]; + } + return contents; +}; +const deserializeAws_queryDeleteChangeSetOutput = (output, context) => { + let contents = {}; + return contents; +}; +const deserializeAws_queryDeleteStackInstancesOutput = (output, context) => { + let contents = { + OperationId: undefined, + }; + if (output["OperationId"] !== undefined) { + contents.OperationId = output["OperationId"]; + } + return contents; +}; +const deserializeAws_queryDeleteStackSetOutput = (output, context) => { + let contents = {}; + return contents; +}; +const deserializeAws_queryDeploymentTargets = (output, context) => { + let contents = { + Accounts: undefined, + OrganizationalUnitIds: undefined, + }; + if (output.Accounts === "") { + contents.Accounts = []; + } + if (output["Accounts"] !== undefined && output["Accounts"]["member"] !== undefined) { + contents.Accounts = deserializeAws_queryAccountList(smithy_client_1.getArrayIfSingleItem(output["Accounts"]["member"]), context); + } + if (output.OrganizationalUnitIds === "") { + contents.OrganizationalUnitIds = []; + } + if (output["OrganizationalUnitIds"] !== undefined && output["OrganizationalUnitIds"]["member"] !== undefined) { + contents.OrganizationalUnitIds = deserializeAws_queryOrganizationalUnitIdList(smithy_client_1.getArrayIfSingleItem(output["OrganizationalUnitIds"]["member"]), context); + } + return contents; +}; +const deserializeAws_queryDeregisterTypeOutput = (output, context) => { + let contents = {}; + return contents; +}; +const deserializeAws_queryDescribeAccountLimitsOutput = (output, context) => { + let contents = { + AccountLimits: undefined, + NextToken: undefined, + }; + if (output.AccountLimits === "") { + contents.AccountLimits = []; + } + if (output["AccountLimits"] !== undefined && output["AccountLimits"]["member"] !== undefined) { + contents.AccountLimits = deserializeAws_queryAccountLimitList(smithy_client_1.getArrayIfSingleItem(output["AccountLimits"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryDescribeChangeSetOutput = (output, context) => { + let contents = { + ChangeSetName: undefined, + ChangeSetId: undefined, + StackId: undefined, + StackName: undefined, + Description: undefined, + Parameters: undefined, + CreationTime: undefined, + ExecutionStatus: undefined, + Status: undefined, + StatusReason: undefined, + NotificationARNs: undefined, + RollbackConfiguration: undefined, + Capabilities: undefined, + Tags: undefined, + Changes: undefined, + NextToken: undefined, + IncludeNestedStacks: undefined, + ParentChangeSetId: undefined, + RootChangeSetId: undefined, + }; + if (output["ChangeSetName"] !== undefined) { + contents.ChangeSetName = output["ChangeSetName"]; + } + if (output["ChangeSetId"] !== undefined) { + contents.ChangeSetId = output["ChangeSetId"]; + } + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output["StackName"] !== undefined) { + contents.StackName = output["StackName"]; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output.Parameters === "") { + contents.Parameters = []; + } + if (output["Parameters"] !== undefined && output["Parameters"]["member"] !== undefined) { + contents.Parameters = deserializeAws_queryParameters(smithy_client_1.getArrayIfSingleItem(output["Parameters"]["member"]), context); + } + if (output["CreationTime"] !== undefined) { + contents.CreationTime = new Date(output["CreationTime"]); + } + if (output["ExecutionStatus"] !== undefined) { + contents.ExecutionStatus = output["ExecutionStatus"]; + } + if (output["Status"] !== undefined) { + contents.Status = output["Status"]; + } + if (output["StatusReason"] !== undefined) { + contents.StatusReason = output["StatusReason"]; + } + if (output.NotificationARNs === "") { + contents.NotificationARNs = []; + } + if (output["NotificationARNs"] !== undefined && output["NotificationARNs"]["member"] !== undefined) { + contents.NotificationARNs = deserializeAws_queryNotificationARNs(smithy_client_1.getArrayIfSingleItem(output["NotificationARNs"]["member"]), context); + } + if (output["RollbackConfiguration"] !== undefined) { + contents.RollbackConfiguration = deserializeAws_queryRollbackConfiguration(output["RollbackConfiguration"], context); + } + if (output.Capabilities === "") { + contents.Capabilities = []; + } + if (output["Capabilities"] !== undefined && output["Capabilities"]["member"] !== undefined) { + contents.Capabilities = deserializeAws_queryCapabilities(smithy_client_1.getArrayIfSingleItem(output["Capabilities"]["member"]), context); + } + if (output.Tags === "") { + contents.Tags = []; + } + if (output["Tags"] !== undefined && output["Tags"]["member"] !== undefined) { + contents.Tags = deserializeAws_queryTags(smithy_client_1.getArrayIfSingleItem(output["Tags"]["member"]), context); + } + if (output.Changes === "") { + contents.Changes = []; + } + if (output["Changes"] !== undefined && output["Changes"]["member"] !== undefined) { + contents.Changes = deserializeAws_queryChanges(smithy_client_1.getArrayIfSingleItem(output["Changes"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + if (output["IncludeNestedStacks"] !== undefined) { + contents.IncludeNestedStacks = output["IncludeNestedStacks"] == "true"; + } + if (output["ParentChangeSetId"] !== undefined) { + contents.ParentChangeSetId = output["ParentChangeSetId"]; + } + if (output["RootChangeSetId"] !== undefined) { + contents.RootChangeSetId = output["RootChangeSetId"]; + } + return contents; +}; +const deserializeAws_queryDescribeStackDriftDetectionStatusOutput = (output, context) => { + let contents = { + StackId: undefined, + StackDriftDetectionId: undefined, + StackDriftStatus: undefined, + DetectionStatus: undefined, + DetectionStatusReason: undefined, + DriftedStackResourceCount: undefined, + Timestamp: undefined, + }; + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output["StackDriftDetectionId"] !== undefined) { + contents.StackDriftDetectionId = output["StackDriftDetectionId"]; + } + if (output["StackDriftStatus"] !== undefined) { + contents.StackDriftStatus = output["StackDriftStatus"]; + } + if (output["DetectionStatus"] !== undefined) { + contents.DetectionStatus = output["DetectionStatus"]; + } + if (output["DetectionStatusReason"] !== undefined) { + contents.DetectionStatusReason = output["DetectionStatusReason"]; + } + if (output["DriftedStackResourceCount"] !== undefined) { + contents.DriftedStackResourceCount = parseInt(output["DriftedStackResourceCount"]); + } + if (output["Timestamp"] !== undefined) { + contents.Timestamp = new Date(output["Timestamp"]); + } + return contents; +}; +const deserializeAws_queryDescribeStackEventsOutput = (output, context) => { + let contents = { + StackEvents: undefined, + NextToken: undefined, + }; + if (output.StackEvents === "") { + contents.StackEvents = []; + } + if (output["StackEvents"] !== undefined && output["StackEvents"]["member"] !== undefined) { + contents.StackEvents = deserializeAws_queryStackEvents(smithy_client_1.getArrayIfSingleItem(output["StackEvents"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryDescribeStackInstanceOutput = (output, context) => { + let contents = { + StackInstance: undefined, + }; + if (output["StackInstance"] !== undefined) { + contents.StackInstance = deserializeAws_queryStackInstance(output["StackInstance"], context); + } + return contents; +}; +const deserializeAws_queryDescribeStackResourceDriftsOutput = (output, context) => { + let contents = { + StackResourceDrifts: undefined, + NextToken: undefined, + }; + if (output.StackResourceDrifts === "") { + contents.StackResourceDrifts = []; + } + if (output["StackResourceDrifts"] !== undefined && output["StackResourceDrifts"]["member"] !== undefined) { + contents.StackResourceDrifts = deserializeAws_queryStackResourceDrifts(smithy_client_1.getArrayIfSingleItem(output["StackResourceDrifts"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryDescribeStackResourceOutput = (output, context) => { + let contents = { + StackResourceDetail: undefined, + }; + if (output["StackResourceDetail"] !== undefined) { + contents.StackResourceDetail = deserializeAws_queryStackResourceDetail(output["StackResourceDetail"], context); + } + return contents; +}; +const deserializeAws_queryDescribeStackResourcesOutput = (output, context) => { + let contents = { + StackResources: undefined, + }; + if (output.StackResources === "") { + contents.StackResources = []; + } + if (output["StackResources"] !== undefined && output["StackResources"]["member"] !== undefined) { + contents.StackResources = deserializeAws_queryStackResources(smithy_client_1.getArrayIfSingleItem(output["StackResources"]["member"]), context); + } + return contents; +}; +const deserializeAws_queryDescribeStackSetOperationOutput = (output, context) => { + let contents = { + StackSetOperation: undefined, + }; + if (output["StackSetOperation"] !== undefined) { + contents.StackSetOperation = deserializeAws_queryStackSetOperation(output["StackSetOperation"], context); + } + return contents; +}; +const deserializeAws_queryDescribeStackSetOutput = (output, context) => { + let contents = { + StackSet: undefined, + }; + if (output["StackSet"] !== undefined) { + contents.StackSet = deserializeAws_queryStackSet(output["StackSet"], context); + } + return contents; +}; +const deserializeAws_queryDescribeStacksOutput = (output, context) => { + let contents = { + Stacks: undefined, + NextToken: undefined, + }; + if (output.Stacks === "") { + contents.Stacks = []; + } + if (output["Stacks"] !== undefined && output["Stacks"]["member"] !== undefined) { + contents.Stacks = deserializeAws_queryStacks(smithy_client_1.getArrayIfSingleItem(output["Stacks"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryDescribeTypeOutput = (output, context) => { + let contents = { + Arn: undefined, + Type: undefined, + TypeName: undefined, + DefaultVersionId: undefined, + IsDefaultVersion: undefined, + Description: undefined, + Schema: undefined, + ProvisioningType: undefined, + DeprecatedStatus: undefined, + LoggingConfig: undefined, + ExecutionRoleArn: undefined, + Visibility: undefined, + SourceUrl: undefined, + DocumentationUrl: undefined, + LastUpdated: undefined, + TimeCreated: undefined, + }; + if (output["Arn"] !== undefined) { + contents.Arn = output["Arn"]; + } + if (output["Type"] !== undefined) { + contents.Type = output["Type"]; + } + if (output["TypeName"] !== undefined) { + contents.TypeName = output["TypeName"]; + } + if (output["DefaultVersionId"] !== undefined) { + contents.DefaultVersionId = output["DefaultVersionId"]; + } + if (output["IsDefaultVersion"] !== undefined) { + contents.IsDefaultVersion = output["IsDefaultVersion"] == "true"; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output["Schema"] !== undefined) { + contents.Schema = output["Schema"]; + } + if (output["ProvisioningType"] !== undefined) { + contents.ProvisioningType = output["ProvisioningType"]; + } + if (output["DeprecatedStatus"] !== undefined) { + contents.DeprecatedStatus = output["DeprecatedStatus"]; + } + if (output["LoggingConfig"] !== undefined) { + contents.LoggingConfig = deserializeAws_queryLoggingConfig(output["LoggingConfig"], context); + } + if (output["ExecutionRoleArn"] !== undefined) { + contents.ExecutionRoleArn = output["ExecutionRoleArn"]; + } + if (output["Visibility"] !== undefined) { + contents.Visibility = output["Visibility"]; + } + if (output["SourceUrl"] !== undefined) { + contents.SourceUrl = output["SourceUrl"]; + } + if (output["DocumentationUrl"] !== undefined) { + contents.DocumentationUrl = output["DocumentationUrl"]; + } + if (output["LastUpdated"] !== undefined) { + contents.LastUpdated = new Date(output["LastUpdated"]); + } + if (output["TimeCreated"] !== undefined) { + contents.TimeCreated = new Date(output["TimeCreated"]); + } + return contents; +}; +const deserializeAws_queryDescribeTypeRegistrationOutput = (output, context) => { + let contents = { + ProgressStatus: undefined, + Description: undefined, + TypeArn: undefined, + TypeVersionArn: undefined, + }; + if (output["ProgressStatus"] !== undefined) { + contents.ProgressStatus = output["ProgressStatus"]; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output["TypeArn"] !== undefined) { + contents.TypeArn = output["TypeArn"]; + } + if (output["TypeVersionArn"] !== undefined) { + contents.TypeVersionArn = output["TypeVersionArn"]; + } + return contents; +}; +const deserializeAws_queryDetectStackDriftOutput = (output, context) => { + let contents = { + StackDriftDetectionId: undefined, + }; + if (output["StackDriftDetectionId"] !== undefined) { + contents.StackDriftDetectionId = output["StackDriftDetectionId"]; + } + return contents; +}; +const deserializeAws_queryDetectStackResourceDriftOutput = (output, context) => { + let contents = { + StackResourceDrift: undefined, + }; + if (output["StackResourceDrift"] !== undefined) { + contents.StackResourceDrift = deserializeAws_queryStackResourceDrift(output["StackResourceDrift"], context); + } + return contents; +}; +const deserializeAws_queryDetectStackSetDriftOutput = (output, context) => { + let contents = { + OperationId: undefined, + }; + if (output["OperationId"] !== undefined) { + contents.OperationId = output["OperationId"]; + } + return contents; +}; +const deserializeAws_queryEstimateTemplateCostOutput = (output, context) => { + let contents = { + Url: undefined, + }; + if (output["Url"] !== undefined) { + contents.Url = output["Url"]; + } + return contents; +}; +const deserializeAws_queryExecuteChangeSetOutput = (output, context) => { + let contents = {}; + return contents; +}; +const deserializeAws_queryExport = (output, context) => { + let contents = { + ExportingStackId: undefined, + Name: undefined, + Value: undefined, + }; + if (output["ExportingStackId"] !== undefined) { + contents.ExportingStackId = output["ExportingStackId"]; + } + if (output["Name"] !== undefined) { + contents.Name = output["Name"]; + } + if (output["Value"] !== undefined) { + contents.Value = output["Value"]; + } + return contents; +}; +const deserializeAws_queryExports = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryExport(entry, context); + }); +}; +const deserializeAws_queryGetStackPolicyOutput = (output, context) => { + let contents = { + StackPolicyBody: undefined, + }; + if (output["StackPolicyBody"] !== undefined) { + contents.StackPolicyBody = output["StackPolicyBody"]; + } + return contents; +}; +const deserializeAws_queryGetTemplateOutput = (output, context) => { + let contents = { + TemplateBody: undefined, + StagesAvailable: undefined, + }; + if (output["TemplateBody"] !== undefined) { + contents.TemplateBody = output["TemplateBody"]; + } + if (output.StagesAvailable === "") { + contents.StagesAvailable = []; + } + if (output["StagesAvailable"] !== undefined && output["StagesAvailable"]["member"] !== undefined) { + contents.StagesAvailable = deserializeAws_queryStageList(smithy_client_1.getArrayIfSingleItem(output["StagesAvailable"]["member"]), context); + } + return contents; +}; +const deserializeAws_queryGetTemplateSummaryOutput = (output, context) => { + let contents = { + Parameters: undefined, + Description: undefined, + Capabilities: undefined, + CapabilitiesReason: undefined, + ResourceTypes: undefined, + Version: undefined, + Metadata: undefined, + DeclaredTransforms: undefined, + ResourceIdentifierSummaries: undefined, + }; + if (output.Parameters === "") { + contents.Parameters = []; + } + if (output["Parameters"] !== undefined && output["Parameters"]["member"] !== undefined) { + contents.Parameters = deserializeAws_queryParameterDeclarations(smithy_client_1.getArrayIfSingleItem(output["Parameters"]["member"]), context); + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output.Capabilities === "") { + contents.Capabilities = []; + } + if (output["Capabilities"] !== undefined && output["Capabilities"]["member"] !== undefined) { + contents.Capabilities = deserializeAws_queryCapabilities(smithy_client_1.getArrayIfSingleItem(output["Capabilities"]["member"]), context); + } + if (output["CapabilitiesReason"] !== undefined) { + contents.CapabilitiesReason = output["CapabilitiesReason"]; + } + if (output.ResourceTypes === "") { + contents.ResourceTypes = []; + } + if (output["ResourceTypes"] !== undefined && output["ResourceTypes"]["member"] !== undefined) { + contents.ResourceTypes = deserializeAws_queryResourceTypes(smithy_client_1.getArrayIfSingleItem(output["ResourceTypes"]["member"]), context); + } + if (output["Version"] !== undefined) { + contents.Version = output["Version"]; + } + if (output["Metadata"] !== undefined) { + contents.Metadata = output["Metadata"]; + } + if (output.DeclaredTransforms === "") { + contents.DeclaredTransforms = []; + } + if (output["DeclaredTransforms"] !== undefined && output["DeclaredTransforms"]["member"] !== undefined) { + contents.DeclaredTransforms = deserializeAws_queryTransformsList(smithy_client_1.getArrayIfSingleItem(output["DeclaredTransforms"]["member"]), context); + } + if (output.ResourceIdentifierSummaries === "") { + contents.ResourceIdentifierSummaries = []; + } + if (output["ResourceIdentifierSummaries"] !== undefined && + output["ResourceIdentifierSummaries"]["member"] !== undefined) { + contents.ResourceIdentifierSummaries = deserializeAws_queryResourceIdentifierSummaries(smithy_client_1.getArrayIfSingleItem(output["ResourceIdentifierSummaries"]["member"]), context); + } + return contents; +}; +const deserializeAws_queryImports = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryInsufficientCapabilitiesException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryInvalidChangeSetStatusException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryInvalidOperationException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryInvalidStateTransitionException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryLimitExceededException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryListChangeSetsOutput = (output, context) => { + let contents = { + Summaries: undefined, + NextToken: undefined, + }; + if (output.Summaries === "") { + contents.Summaries = []; + } + if (output["Summaries"] !== undefined && output["Summaries"]["member"] !== undefined) { + contents.Summaries = deserializeAws_queryChangeSetSummaries(smithy_client_1.getArrayIfSingleItem(output["Summaries"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListExportsOutput = (output, context) => { + let contents = { + Exports: undefined, + NextToken: undefined, + }; + if (output.Exports === "") { + contents.Exports = []; + } + if (output["Exports"] !== undefined && output["Exports"]["member"] !== undefined) { + contents.Exports = deserializeAws_queryExports(smithy_client_1.getArrayIfSingleItem(output["Exports"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListImportsOutput = (output, context) => { + let contents = { + Imports: undefined, + NextToken: undefined, + }; + if (output.Imports === "") { + contents.Imports = []; + } + if (output["Imports"] !== undefined && output["Imports"]["member"] !== undefined) { + contents.Imports = deserializeAws_queryImports(smithy_client_1.getArrayIfSingleItem(output["Imports"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListStackInstancesOutput = (output, context) => { + let contents = { + Summaries: undefined, + NextToken: undefined, + }; + if (output.Summaries === "") { + contents.Summaries = []; + } + if (output["Summaries"] !== undefined && output["Summaries"]["member"] !== undefined) { + contents.Summaries = deserializeAws_queryStackInstanceSummaries(smithy_client_1.getArrayIfSingleItem(output["Summaries"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListStackResourcesOutput = (output, context) => { + let contents = { + StackResourceSummaries: undefined, + NextToken: undefined, + }; + if (output.StackResourceSummaries === "") { + contents.StackResourceSummaries = []; + } + if (output["StackResourceSummaries"] !== undefined && output["StackResourceSummaries"]["member"] !== undefined) { + contents.StackResourceSummaries = deserializeAws_queryStackResourceSummaries(smithy_client_1.getArrayIfSingleItem(output["StackResourceSummaries"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListStackSetOperationResultsOutput = (output, context) => { + let contents = { + Summaries: undefined, + NextToken: undefined, + }; + if (output.Summaries === "") { + contents.Summaries = []; + } + if (output["Summaries"] !== undefined && output["Summaries"]["member"] !== undefined) { + contents.Summaries = deserializeAws_queryStackSetOperationResultSummaries(smithy_client_1.getArrayIfSingleItem(output["Summaries"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListStackSetOperationsOutput = (output, context) => { + let contents = { + Summaries: undefined, + NextToken: undefined, + }; + if (output.Summaries === "") { + contents.Summaries = []; + } + if (output["Summaries"] !== undefined && output["Summaries"]["member"] !== undefined) { + contents.Summaries = deserializeAws_queryStackSetOperationSummaries(smithy_client_1.getArrayIfSingleItem(output["Summaries"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListStackSetsOutput = (output, context) => { + let contents = { + Summaries: undefined, + NextToken: undefined, + }; + if (output.Summaries === "") { + contents.Summaries = []; + } + if (output["Summaries"] !== undefined && output["Summaries"]["member"] !== undefined) { + contents.Summaries = deserializeAws_queryStackSetSummaries(smithy_client_1.getArrayIfSingleItem(output["Summaries"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListStacksOutput = (output, context) => { + let contents = { + StackSummaries: undefined, + NextToken: undefined, + }; + if (output.StackSummaries === "") { + contents.StackSummaries = []; + } + if (output["StackSummaries"] !== undefined && output["StackSummaries"]["member"] !== undefined) { + contents.StackSummaries = deserializeAws_queryStackSummaries(smithy_client_1.getArrayIfSingleItem(output["StackSummaries"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListTypeRegistrationsOutput = (output, context) => { + let contents = { + RegistrationTokenList: undefined, + NextToken: undefined, + }; + if (output.RegistrationTokenList === "") { + contents.RegistrationTokenList = []; + } + if (output["RegistrationTokenList"] !== undefined && output["RegistrationTokenList"]["member"] !== undefined) { + contents.RegistrationTokenList = deserializeAws_queryRegistrationTokenList(smithy_client_1.getArrayIfSingleItem(output["RegistrationTokenList"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListTypesOutput = (output, context) => { + let contents = { + TypeSummaries: undefined, + NextToken: undefined, + }; + if (output.TypeSummaries === "") { + contents.TypeSummaries = []; + } + if (output["TypeSummaries"] !== undefined && output["TypeSummaries"]["member"] !== undefined) { + contents.TypeSummaries = deserializeAws_queryTypeSummaries(smithy_client_1.getArrayIfSingleItem(output["TypeSummaries"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryListTypeVersionsOutput = (output, context) => { + let contents = { + TypeVersionSummaries: undefined, + NextToken: undefined, + }; + if (output.TypeVersionSummaries === "") { + contents.TypeVersionSummaries = []; + } + if (output["TypeVersionSummaries"] !== undefined && output["TypeVersionSummaries"]["member"] !== undefined) { + contents.TypeVersionSummaries = deserializeAws_queryTypeVersionSummaries(smithy_client_1.getArrayIfSingleItem(output["TypeVersionSummaries"]["member"]), context); + } + if (output["NextToken"] !== undefined) { + contents.NextToken = output["NextToken"]; + } + return contents; +}; +const deserializeAws_queryLoggingConfig = (output, context) => { + let contents = { + LogRoleArn: undefined, + LogGroupName: undefined, + }; + if (output["LogRoleArn"] !== undefined) { + contents.LogRoleArn = output["LogRoleArn"]; + } + if (output["LogGroupName"] !== undefined) { + contents.LogGroupName = output["LogGroupName"]; + } + return contents; +}; +const deserializeAws_queryLogicalResourceIds = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryModuleInfo = (output, context) => { + let contents = { + TypeHierarchy: undefined, + LogicalIdHierarchy: undefined, + }; + if (output["TypeHierarchy"] !== undefined) { + contents.TypeHierarchy = output["TypeHierarchy"]; + } + if (output["LogicalIdHierarchy"] !== undefined) { + contents.LogicalIdHierarchy = output["LogicalIdHierarchy"]; + } + return contents; +}; +const deserializeAws_queryNameAlreadyExistsException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryNotificationARNs = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryOperationIdAlreadyExistsException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryOperationInProgressException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryOperationNotFoundException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryOperationStatusCheckFailedException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryOrganizationalUnitIdList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryOutput = (output, context) => { + let contents = { + OutputKey: undefined, + OutputValue: undefined, + Description: undefined, + ExportName: undefined, + }; + if (output["OutputKey"] !== undefined) { + contents.OutputKey = output["OutputKey"]; + } + if (output["OutputValue"] !== undefined) { + contents.OutputValue = output["OutputValue"]; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output["ExportName"] !== undefined) { + contents.ExportName = output["ExportName"]; + } + return contents; +}; +const deserializeAws_queryOutputs = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryOutput(entry, context); + }); +}; +const deserializeAws_queryParameter = (output, context) => { + let contents = { + ParameterKey: undefined, + ParameterValue: undefined, + UsePreviousValue: undefined, + ResolvedValue: undefined, + }; + if (output["ParameterKey"] !== undefined) { + contents.ParameterKey = output["ParameterKey"]; + } + if (output["ParameterValue"] !== undefined) { + contents.ParameterValue = output["ParameterValue"]; + } + if (output["UsePreviousValue"] !== undefined) { + contents.UsePreviousValue = output["UsePreviousValue"] == "true"; + } + if (output["ResolvedValue"] !== undefined) { + contents.ResolvedValue = output["ResolvedValue"]; + } + return contents; +}; +const deserializeAws_queryParameterConstraints = (output, context) => { + let contents = { + AllowedValues: undefined, + }; + if (output.AllowedValues === "") { + contents.AllowedValues = []; + } + if (output["AllowedValues"] !== undefined && output["AllowedValues"]["member"] !== undefined) { + contents.AllowedValues = deserializeAws_queryAllowedValues(smithy_client_1.getArrayIfSingleItem(output["AllowedValues"]["member"]), context); + } + return contents; +}; +const deserializeAws_queryParameterDeclaration = (output, context) => { + let contents = { + ParameterKey: undefined, + DefaultValue: undefined, + ParameterType: undefined, + NoEcho: undefined, + Description: undefined, + ParameterConstraints: undefined, + }; + if (output["ParameterKey"] !== undefined) { + contents.ParameterKey = output["ParameterKey"]; + } + if (output["DefaultValue"] !== undefined) { + contents.DefaultValue = output["DefaultValue"]; + } + if (output["ParameterType"] !== undefined) { + contents.ParameterType = output["ParameterType"]; + } + if (output["NoEcho"] !== undefined) { + contents.NoEcho = output["NoEcho"] == "true"; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output["ParameterConstraints"] !== undefined) { + contents.ParameterConstraints = deserializeAws_queryParameterConstraints(output["ParameterConstraints"], context); + } + return contents; +}; +const deserializeAws_queryParameterDeclarations = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryParameterDeclaration(entry, context); + }); +}; +const deserializeAws_queryParameters = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryParameter(entry, context); + }); +}; +const deserializeAws_queryPhysicalResourceIdContext = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryPhysicalResourceIdContextKeyValuePair(entry, context); + }); +}; +const deserializeAws_queryPhysicalResourceIdContextKeyValuePair = (output, context) => { + let contents = { + Key: undefined, + Value: undefined, + }; + if (output["Key"] !== undefined) { + contents.Key = output["Key"]; + } + if (output["Value"] !== undefined) { + contents.Value = output["Value"]; + } + return contents; +}; +const deserializeAws_queryPropertyDifference = (output, context) => { + let contents = { + PropertyPath: undefined, + ExpectedValue: undefined, + ActualValue: undefined, + DifferenceType: undefined, + }; + if (output["PropertyPath"] !== undefined) { + contents.PropertyPath = output["PropertyPath"]; + } + if (output["ExpectedValue"] !== undefined) { + contents.ExpectedValue = output["ExpectedValue"]; + } + if (output["ActualValue"] !== undefined) { + contents.ActualValue = output["ActualValue"]; + } + if (output["DifferenceType"] !== undefined) { + contents.DifferenceType = output["DifferenceType"]; + } + return contents; +}; +const deserializeAws_queryPropertyDifferences = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryPropertyDifference(entry, context); + }); +}; +const deserializeAws_queryRecordHandlerProgressOutput = (output, context) => { + let contents = {}; + return contents; +}; +const deserializeAws_queryRegionList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryRegisterTypeOutput = (output, context) => { + let contents = { + RegistrationToken: undefined, + }; + if (output["RegistrationToken"] !== undefined) { + contents.RegistrationToken = output["RegistrationToken"]; + } + return contents; +}; +const deserializeAws_queryRegistrationTokenList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryResourceChange = (output, context) => { + let contents = { + Action: undefined, + LogicalResourceId: undefined, + PhysicalResourceId: undefined, + ResourceType: undefined, + Replacement: undefined, + Scope: undefined, + Details: undefined, + ChangeSetId: undefined, + ModuleInfo: undefined, + }; + if (output["Action"] !== undefined) { + contents.Action = output["Action"]; + } + if (output["LogicalResourceId"] !== undefined) { + contents.LogicalResourceId = output["LogicalResourceId"]; + } + if (output["PhysicalResourceId"] !== undefined) { + contents.PhysicalResourceId = output["PhysicalResourceId"]; + } + if (output["ResourceType"] !== undefined) { + contents.ResourceType = output["ResourceType"]; + } + if (output["Replacement"] !== undefined) { + contents.Replacement = output["Replacement"]; + } + if (output.Scope === "") { + contents.Scope = []; + } + if (output["Scope"] !== undefined && output["Scope"]["member"] !== undefined) { + contents.Scope = deserializeAws_queryScope(smithy_client_1.getArrayIfSingleItem(output["Scope"]["member"]), context); + } + if (output.Details === "") { + contents.Details = []; + } + if (output["Details"] !== undefined && output["Details"]["member"] !== undefined) { + contents.Details = deserializeAws_queryResourceChangeDetails(smithy_client_1.getArrayIfSingleItem(output["Details"]["member"]), context); + } + if (output["ChangeSetId"] !== undefined) { + contents.ChangeSetId = output["ChangeSetId"]; + } + if (output["ModuleInfo"] !== undefined) { + contents.ModuleInfo = deserializeAws_queryModuleInfo(output["ModuleInfo"], context); + } + return contents; +}; +const deserializeAws_queryResourceChangeDetail = (output, context) => { + let contents = { + Target: undefined, + Evaluation: undefined, + ChangeSource: undefined, + CausingEntity: undefined, + }; + if (output["Target"] !== undefined) { + contents.Target = deserializeAws_queryResourceTargetDefinition(output["Target"], context); + } + if (output["Evaluation"] !== undefined) { + contents.Evaluation = output["Evaluation"]; + } + if (output["ChangeSource"] !== undefined) { + contents.ChangeSource = output["ChangeSource"]; + } + if (output["CausingEntity"] !== undefined) { + contents.CausingEntity = output["CausingEntity"]; + } + return contents; +}; +const deserializeAws_queryResourceChangeDetails = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryResourceChangeDetail(entry, context); + }); +}; +const deserializeAws_queryResourceIdentifiers = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryResourceIdentifierSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryResourceIdentifierSummary(entry, context); + }); +}; +const deserializeAws_queryResourceIdentifierSummary = (output, context) => { + let contents = { + ResourceType: undefined, + LogicalResourceIds: undefined, + ResourceIdentifiers: undefined, + }; + if (output["ResourceType"] !== undefined) { + contents.ResourceType = output["ResourceType"]; + } + if (output.LogicalResourceIds === "") { + contents.LogicalResourceIds = []; + } + if (output["LogicalResourceIds"] !== undefined && output["LogicalResourceIds"]["member"] !== undefined) { + contents.LogicalResourceIds = deserializeAws_queryLogicalResourceIds(smithy_client_1.getArrayIfSingleItem(output["LogicalResourceIds"]["member"]), context); + } + if (output.ResourceIdentifiers === "") { + contents.ResourceIdentifiers = []; + } + if (output["ResourceIdentifiers"] !== undefined && output["ResourceIdentifiers"]["member"] !== undefined) { + contents.ResourceIdentifiers = deserializeAws_queryResourceIdentifiers(smithy_client_1.getArrayIfSingleItem(output["ResourceIdentifiers"]["member"]), context); + } + return contents; +}; +const deserializeAws_queryResourceTargetDefinition = (output, context) => { + let contents = { + Attribute: undefined, + Name: undefined, + RequiresRecreation: undefined, + }; + if (output["Attribute"] !== undefined) { + contents.Attribute = output["Attribute"]; + } + if (output["Name"] !== undefined) { + contents.Name = output["Name"]; + } + if (output["RequiresRecreation"] !== undefined) { + contents.RequiresRecreation = output["RequiresRecreation"]; + } + return contents; +}; +const deserializeAws_queryResourceTypes = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryRollbackConfiguration = (output, context) => { + let contents = { + RollbackTriggers: undefined, + MonitoringTimeInMinutes: undefined, + }; + if (output.RollbackTriggers === "") { + contents.RollbackTriggers = []; + } + if (output["RollbackTriggers"] !== undefined && output["RollbackTriggers"]["member"] !== undefined) { + contents.RollbackTriggers = deserializeAws_queryRollbackTriggers(smithy_client_1.getArrayIfSingleItem(output["RollbackTriggers"]["member"]), context); + } + if (output["MonitoringTimeInMinutes"] !== undefined) { + contents.MonitoringTimeInMinutes = parseInt(output["MonitoringTimeInMinutes"]); + } + return contents; +}; +const deserializeAws_queryRollbackTrigger = (output, context) => { + let contents = { + Arn: undefined, + Type: undefined, + }; + if (output["Arn"] !== undefined) { + contents.Arn = output["Arn"]; + } + if (output["Type"] !== undefined) { + contents.Type = output["Type"]; + } + return contents; +}; +const deserializeAws_queryRollbackTriggers = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryRollbackTrigger(entry, context); + }); +}; +const deserializeAws_queryScope = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_querySetTypeDefaultVersionOutput = (output, context) => { + let contents = {}; + return contents; +}; +const deserializeAws_queryStack = (output, context) => { + let contents = { + StackId: undefined, + StackName: undefined, + ChangeSetId: undefined, + Description: undefined, + Parameters: undefined, + CreationTime: undefined, + DeletionTime: undefined, + LastUpdatedTime: undefined, + RollbackConfiguration: undefined, + StackStatus: undefined, + StackStatusReason: undefined, + DisableRollback: undefined, + NotificationARNs: undefined, + TimeoutInMinutes: undefined, + Capabilities: undefined, + Outputs: undefined, + RoleARN: undefined, + Tags: undefined, + EnableTerminationProtection: undefined, + ParentId: undefined, + RootId: undefined, + DriftInformation: undefined, + }; + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output["StackName"] !== undefined) { + contents.StackName = output["StackName"]; + } + if (output["ChangeSetId"] !== undefined) { + contents.ChangeSetId = output["ChangeSetId"]; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output.Parameters === "") { + contents.Parameters = []; + } + if (output["Parameters"] !== undefined && output["Parameters"]["member"] !== undefined) { + contents.Parameters = deserializeAws_queryParameters(smithy_client_1.getArrayIfSingleItem(output["Parameters"]["member"]), context); + } + if (output["CreationTime"] !== undefined) { + contents.CreationTime = new Date(output["CreationTime"]); + } + if (output["DeletionTime"] !== undefined) { + contents.DeletionTime = new Date(output["DeletionTime"]); + } + if (output["LastUpdatedTime"] !== undefined) { + contents.LastUpdatedTime = new Date(output["LastUpdatedTime"]); + } + if (output["RollbackConfiguration"] !== undefined) { + contents.RollbackConfiguration = deserializeAws_queryRollbackConfiguration(output["RollbackConfiguration"], context); + } + if (output["StackStatus"] !== undefined) { + contents.StackStatus = output["StackStatus"]; + } + if (output["StackStatusReason"] !== undefined) { + contents.StackStatusReason = output["StackStatusReason"]; + } + if (output["DisableRollback"] !== undefined) { + contents.DisableRollback = output["DisableRollback"] == "true"; + } + if (output.NotificationARNs === "") { + contents.NotificationARNs = []; + } + if (output["NotificationARNs"] !== undefined && output["NotificationARNs"]["member"] !== undefined) { + contents.NotificationARNs = deserializeAws_queryNotificationARNs(smithy_client_1.getArrayIfSingleItem(output["NotificationARNs"]["member"]), context); + } + if (output["TimeoutInMinutes"] !== undefined) { + contents.TimeoutInMinutes = parseInt(output["TimeoutInMinutes"]); + } + if (output.Capabilities === "") { + contents.Capabilities = []; + } + if (output["Capabilities"] !== undefined && output["Capabilities"]["member"] !== undefined) { + contents.Capabilities = deserializeAws_queryCapabilities(smithy_client_1.getArrayIfSingleItem(output["Capabilities"]["member"]), context); + } + if (output.Outputs === "") { + contents.Outputs = []; + } + if (output["Outputs"] !== undefined && output["Outputs"]["member"] !== undefined) { + contents.Outputs = deserializeAws_queryOutputs(smithy_client_1.getArrayIfSingleItem(output["Outputs"]["member"]), context); + } + if (output["RoleARN"] !== undefined) { + contents.RoleARN = output["RoleARN"]; + } + if (output.Tags === "") { + contents.Tags = []; + } + if (output["Tags"] !== undefined && output["Tags"]["member"] !== undefined) { + contents.Tags = deserializeAws_queryTags(smithy_client_1.getArrayIfSingleItem(output["Tags"]["member"]), context); + } + if (output["EnableTerminationProtection"] !== undefined) { + contents.EnableTerminationProtection = output["EnableTerminationProtection"] == "true"; + } + if (output["ParentId"] !== undefined) { + contents.ParentId = output["ParentId"]; + } + if (output["RootId"] !== undefined) { + contents.RootId = output["RootId"]; + } + if (output["DriftInformation"] !== undefined) { + contents.DriftInformation = deserializeAws_queryStackDriftInformation(output["DriftInformation"], context); + } + return contents; +}; +const deserializeAws_queryStackDriftInformation = (output, context) => { + let contents = { + StackDriftStatus: undefined, + LastCheckTimestamp: undefined, + }; + if (output["StackDriftStatus"] !== undefined) { + contents.StackDriftStatus = output["StackDriftStatus"]; + } + if (output["LastCheckTimestamp"] !== undefined) { + contents.LastCheckTimestamp = new Date(output["LastCheckTimestamp"]); + } + return contents; +}; +const deserializeAws_queryStackDriftInformationSummary = (output, context) => { + let contents = { + StackDriftStatus: undefined, + LastCheckTimestamp: undefined, + }; + if (output["StackDriftStatus"] !== undefined) { + contents.StackDriftStatus = output["StackDriftStatus"]; + } + if (output["LastCheckTimestamp"] !== undefined) { + contents.LastCheckTimestamp = new Date(output["LastCheckTimestamp"]); + } + return contents; +}; +const deserializeAws_queryStackEvent = (output, context) => { + let contents = { + StackId: undefined, + EventId: undefined, + StackName: undefined, + LogicalResourceId: undefined, + PhysicalResourceId: undefined, + ResourceType: undefined, + Timestamp: undefined, + ResourceStatus: undefined, + ResourceStatusReason: undefined, + ResourceProperties: undefined, + ClientRequestToken: undefined, + }; + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output["EventId"] !== undefined) { + contents.EventId = output["EventId"]; + } + if (output["StackName"] !== undefined) { + contents.StackName = output["StackName"]; + } + if (output["LogicalResourceId"] !== undefined) { + contents.LogicalResourceId = output["LogicalResourceId"]; + } + if (output["PhysicalResourceId"] !== undefined) { + contents.PhysicalResourceId = output["PhysicalResourceId"]; + } + if (output["ResourceType"] !== undefined) { + contents.ResourceType = output["ResourceType"]; + } + if (output["Timestamp"] !== undefined) { + contents.Timestamp = new Date(output["Timestamp"]); + } + if (output["ResourceStatus"] !== undefined) { + contents.ResourceStatus = output["ResourceStatus"]; + } + if (output["ResourceStatusReason"] !== undefined) { + contents.ResourceStatusReason = output["ResourceStatusReason"]; + } + if (output["ResourceProperties"] !== undefined) { + contents.ResourceProperties = output["ResourceProperties"]; + } + if (output["ClientRequestToken"] !== undefined) { + contents.ClientRequestToken = output["ClientRequestToken"]; + } + return contents; +}; +const deserializeAws_queryStackEvents = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryStackEvent(entry, context); + }); +}; +const deserializeAws_queryStackInstance = (output, context) => { + let contents = { + StackSetId: undefined, + Region: undefined, + Account: undefined, + StackId: undefined, + ParameterOverrides: undefined, + Status: undefined, + StackInstanceStatus: undefined, + StatusReason: undefined, + OrganizationalUnitId: undefined, + DriftStatus: undefined, + LastDriftCheckTimestamp: undefined, + }; + if (output["StackSetId"] !== undefined) { + contents.StackSetId = output["StackSetId"]; + } + if (output["Region"] !== undefined) { + contents.Region = output["Region"]; + } + if (output["Account"] !== undefined) { + contents.Account = output["Account"]; + } + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output.ParameterOverrides === "") { + contents.ParameterOverrides = []; + } + if (output["ParameterOverrides"] !== undefined && output["ParameterOverrides"]["member"] !== undefined) { + contents.ParameterOverrides = deserializeAws_queryParameters(smithy_client_1.getArrayIfSingleItem(output["ParameterOverrides"]["member"]), context); + } + if (output["Status"] !== undefined) { + contents.Status = output["Status"]; + } + if (output["StackInstanceStatus"] !== undefined) { + contents.StackInstanceStatus = deserializeAws_queryStackInstanceComprehensiveStatus(output["StackInstanceStatus"], context); + } + if (output["StatusReason"] !== undefined) { + contents.StatusReason = output["StatusReason"]; + } + if (output["OrganizationalUnitId"] !== undefined) { + contents.OrganizationalUnitId = output["OrganizationalUnitId"]; + } + if (output["DriftStatus"] !== undefined) { + contents.DriftStatus = output["DriftStatus"]; + } + if (output["LastDriftCheckTimestamp"] !== undefined) { + contents.LastDriftCheckTimestamp = new Date(output["LastDriftCheckTimestamp"]); + } + return contents; +}; +const deserializeAws_queryStackInstanceComprehensiveStatus = (output, context) => { + let contents = { + DetailedStatus: undefined, + }; + if (output["DetailedStatus"] !== undefined) { + contents.DetailedStatus = output["DetailedStatus"]; + } + return contents; +}; +const deserializeAws_queryStackInstanceNotFoundException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryStackInstanceSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryStackInstanceSummary(entry, context); + }); +}; +const deserializeAws_queryStackInstanceSummary = (output, context) => { + let contents = { + StackSetId: undefined, + Region: undefined, + Account: undefined, + StackId: undefined, + Status: undefined, + StatusReason: undefined, + StackInstanceStatus: undefined, + OrganizationalUnitId: undefined, + DriftStatus: undefined, + LastDriftCheckTimestamp: undefined, + }; + if (output["StackSetId"] !== undefined) { + contents.StackSetId = output["StackSetId"]; + } + if (output["Region"] !== undefined) { + contents.Region = output["Region"]; + } + if (output["Account"] !== undefined) { + contents.Account = output["Account"]; + } + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output["Status"] !== undefined) { + contents.Status = output["Status"]; + } + if (output["StatusReason"] !== undefined) { + contents.StatusReason = output["StatusReason"]; + } + if (output["StackInstanceStatus"] !== undefined) { + contents.StackInstanceStatus = deserializeAws_queryStackInstanceComprehensiveStatus(output["StackInstanceStatus"], context); + } + if (output["OrganizationalUnitId"] !== undefined) { + contents.OrganizationalUnitId = output["OrganizationalUnitId"]; + } + if (output["DriftStatus"] !== undefined) { + contents.DriftStatus = output["DriftStatus"]; + } + if (output["LastDriftCheckTimestamp"] !== undefined) { + contents.LastDriftCheckTimestamp = new Date(output["LastDriftCheckTimestamp"]); + } + return contents; +}; +const deserializeAws_queryStackResource = (output, context) => { + let contents = { + StackName: undefined, + StackId: undefined, + LogicalResourceId: undefined, + PhysicalResourceId: undefined, + ResourceType: undefined, + Timestamp: undefined, + ResourceStatus: undefined, + ResourceStatusReason: undefined, + Description: undefined, + DriftInformation: undefined, + ModuleInfo: undefined, + }; + if (output["StackName"] !== undefined) { + contents.StackName = output["StackName"]; + } + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output["LogicalResourceId"] !== undefined) { + contents.LogicalResourceId = output["LogicalResourceId"]; + } + if (output["PhysicalResourceId"] !== undefined) { + contents.PhysicalResourceId = output["PhysicalResourceId"]; + } + if (output["ResourceType"] !== undefined) { + contents.ResourceType = output["ResourceType"]; + } + if (output["Timestamp"] !== undefined) { + contents.Timestamp = new Date(output["Timestamp"]); + } + if (output["ResourceStatus"] !== undefined) { + contents.ResourceStatus = output["ResourceStatus"]; + } + if (output["ResourceStatusReason"] !== undefined) { + contents.ResourceStatusReason = output["ResourceStatusReason"]; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output["DriftInformation"] !== undefined) { + contents.DriftInformation = deserializeAws_queryStackResourceDriftInformation(output["DriftInformation"], context); + } + if (output["ModuleInfo"] !== undefined) { + contents.ModuleInfo = deserializeAws_queryModuleInfo(output["ModuleInfo"], context); + } + return contents; +}; +const deserializeAws_queryStackResourceDetail = (output, context) => { + let contents = { + StackName: undefined, + StackId: undefined, + LogicalResourceId: undefined, + PhysicalResourceId: undefined, + ResourceType: undefined, + LastUpdatedTimestamp: undefined, + ResourceStatus: undefined, + ResourceStatusReason: undefined, + Description: undefined, + Metadata: undefined, + DriftInformation: undefined, + ModuleInfo: undefined, + }; + if (output["StackName"] !== undefined) { + contents.StackName = output["StackName"]; + } + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output["LogicalResourceId"] !== undefined) { + contents.LogicalResourceId = output["LogicalResourceId"]; + } + if (output["PhysicalResourceId"] !== undefined) { + contents.PhysicalResourceId = output["PhysicalResourceId"]; + } + if (output["ResourceType"] !== undefined) { + contents.ResourceType = output["ResourceType"]; + } + if (output["LastUpdatedTimestamp"] !== undefined) { + contents.LastUpdatedTimestamp = new Date(output["LastUpdatedTimestamp"]); + } + if (output["ResourceStatus"] !== undefined) { + contents.ResourceStatus = output["ResourceStatus"]; + } + if (output["ResourceStatusReason"] !== undefined) { + contents.ResourceStatusReason = output["ResourceStatusReason"]; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output["Metadata"] !== undefined) { + contents.Metadata = output["Metadata"]; + } + if (output["DriftInformation"] !== undefined) { + contents.DriftInformation = deserializeAws_queryStackResourceDriftInformation(output["DriftInformation"], context); + } + if (output["ModuleInfo"] !== undefined) { + contents.ModuleInfo = deserializeAws_queryModuleInfo(output["ModuleInfo"], context); + } + return contents; +}; +const deserializeAws_queryStackResourceDrift = (output, context) => { + let contents = { + StackId: undefined, + LogicalResourceId: undefined, + PhysicalResourceId: undefined, + PhysicalResourceIdContext: undefined, + ResourceType: undefined, + ExpectedProperties: undefined, + ActualProperties: undefined, + PropertyDifferences: undefined, + StackResourceDriftStatus: undefined, + Timestamp: undefined, + ModuleInfo: undefined, + }; + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output["LogicalResourceId"] !== undefined) { + contents.LogicalResourceId = output["LogicalResourceId"]; + } + if (output["PhysicalResourceId"] !== undefined) { + contents.PhysicalResourceId = output["PhysicalResourceId"]; + } + if (output.PhysicalResourceIdContext === "") { + contents.PhysicalResourceIdContext = []; + } + if (output["PhysicalResourceIdContext"] !== undefined && + output["PhysicalResourceIdContext"]["member"] !== undefined) { + contents.PhysicalResourceIdContext = deserializeAws_queryPhysicalResourceIdContext(smithy_client_1.getArrayIfSingleItem(output["PhysicalResourceIdContext"]["member"]), context); + } + if (output["ResourceType"] !== undefined) { + contents.ResourceType = output["ResourceType"]; + } + if (output["ExpectedProperties"] !== undefined) { + contents.ExpectedProperties = output["ExpectedProperties"]; + } + if (output["ActualProperties"] !== undefined) { + contents.ActualProperties = output["ActualProperties"]; + } + if (output.PropertyDifferences === "") { + contents.PropertyDifferences = []; + } + if (output["PropertyDifferences"] !== undefined && output["PropertyDifferences"]["member"] !== undefined) { + contents.PropertyDifferences = deserializeAws_queryPropertyDifferences(smithy_client_1.getArrayIfSingleItem(output["PropertyDifferences"]["member"]), context); + } + if (output["StackResourceDriftStatus"] !== undefined) { + contents.StackResourceDriftStatus = output["StackResourceDriftStatus"]; + } + if (output["Timestamp"] !== undefined) { + contents.Timestamp = new Date(output["Timestamp"]); + } + if (output["ModuleInfo"] !== undefined) { + contents.ModuleInfo = deserializeAws_queryModuleInfo(output["ModuleInfo"], context); + } + return contents; +}; +const deserializeAws_queryStackResourceDriftInformation = (output, context) => { + let contents = { + StackResourceDriftStatus: undefined, + LastCheckTimestamp: undefined, + }; + if (output["StackResourceDriftStatus"] !== undefined) { + contents.StackResourceDriftStatus = output["StackResourceDriftStatus"]; + } + if (output["LastCheckTimestamp"] !== undefined) { + contents.LastCheckTimestamp = new Date(output["LastCheckTimestamp"]); + } + return contents; +}; +const deserializeAws_queryStackResourceDriftInformationSummary = (output, context) => { + let contents = { + StackResourceDriftStatus: undefined, + LastCheckTimestamp: undefined, + }; + if (output["StackResourceDriftStatus"] !== undefined) { + contents.StackResourceDriftStatus = output["StackResourceDriftStatus"]; + } + if (output["LastCheckTimestamp"] !== undefined) { + contents.LastCheckTimestamp = new Date(output["LastCheckTimestamp"]); + } + return contents; +}; +const deserializeAws_queryStackResourceDrifts = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryStackResourceDrift(entry, context); + }); +}; +const deserializeAws_queryStackResources = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryStackResource(entry, context); + }); +}; +const deserializeAws_queryStackResourceSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryStackResourceSummary(entry, context); + }); +}; +const deserializeAws_queryStackResourceSummary = (output, context) => { + let contents = { + LogicalResourceId: undefined, + PhysicalResourceId: undefined, + ResourceType: undefined, + LastUpdatedTimestamp: undefined, + ResourceStatus: undefined, + ResourceStatusReason: undefined, + DriftInformation: undefined, + ModuleInfo: undefined, + }; + if (output["LogicalResourceId"] !== undefined) { + contents.LogicalResourceId = output["LogicalResourceId"]; + } + if (output["PhysicalResourceId"] !== undefined) { + contents.PhysicalResourceId = output["PhysicalResourceId"]; + } + if (output["ResourceType"] !== undefined) { + contents.ResourceType = output["ResourceType"]; + } + if (output["LastUpdatedTimestamp"] !== undefined) { + contents.LastUpdatedTimestamp = new Date(output["LastUpdatedTimestamp"]); + } + if (output["ResourceStatus"] !== undefined) { + contents.ResourceStatus = output["ResourceStatus"]; + } + if (output["ResourceStatusReason"] !== undefined) { + contents.ResourceStatusReason = output["ResourceStatusReason"]; + } + if (output["DriftInformation"] !== undefined) { + contents.DriftInformation = deserializeAws_queryStackResourceDriftInformationSummary(output["DriftInformation"], context); + } + if (output["ModuleInfo"] !== undefined) { + contents.ModuleInfo = deserializeAws_queryModuleInfo(output["ModuleInfo"], context); + } + return contents; +}; +const deserializeAws_queryStacks = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryStack(entry, context); + }); +}; +const deserializeAws_queryStackSet = (output, context) => { + let contents = { + StackSetName: undefined, + StackSetId: undefined, + Description: undefined, + Status: undefined, + TemplateBody: undefined, + Parameters: undefined, + Capabilities: undefined, + Tags: undefined, + StackSetARN: undefined, + AdministrationRoleARN: undefined, + ExecutionRoleName: undefined, + StackSetDriftDetectionDetails: undefined, + AutoDeployment: undefined, + PermissionModel: undefined, + OrganizationalUnitIds: undefined, + }; + if (output["StackSetName"] !== undefined) { + contents.StackSetName = output["StackSetName"]; + } + if (output["StackSetId"] !== undefined) { + contents.StackSetId = output["StackSetId"]; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output["Status"] !== undefined) { + contents.Status = output["Status"]; + } + if (output["TemplateBody"] !== undefined) { + contents.TemplateBody = output["TemplateBody"]; + } + if (output.Parameters === "") { + contents.Parameters = []; + } + if (output["Parameters"] !== undefined && output["Parameters"]["member"] !== undefined) { + contents.Parameters = deserializeAws_queryParameters(smithy_client_1.getArrayIfSingleItem(output["Parameters"]["member"]), context); + } + if (output.Capabilities === "") { + contents.Capabilities = []; + } + if (output["Capabilities"] !== undefined && output["Capabilities"]["member"] !== undefined) { + contents.Capabilities = deserializeAws_queryCapabilities(smithy_client_1.getArrayIfSingleItem(output["Capabilities"]["member"]), context); + } + if (output.Tags === "") { + contents.Tags = []; + } + if (output["Tags"] !== undefined && output["Tags"]["member"] !== undefined) { + contents.Tags = deserializeAws_queryTags(smithy_client_1.getArrayIfSingleItem(output["Tags"]["member"]), context); + } + if (output["StackSetARN"] !== undefined) { + contents.StackSetARN = output["StackSetARN"]; + } + if (output["AdministrationRoleARN"] !== undefined) { + contents.AdministrationRoleARN = output["AdministrationRoleARN"]; + } + if (output["ExecutionRoleName"] !== undefined) { + contents.ExecutionRoleName = output["ExecutionRoleName"]; + } + if (output["StackSetDriftDetectionDetails"] !== undefined) { + contents.StackSetDriftDetectionDetails = deserializeAws_queryStackSetDriftDetectionDetails(output["StackSetDriftDetectionDetails"], context); + } + if (output["AutoDeployment"] !== undefined) { + contents.AutoDeployment = deserializeAws_queryAutoDeployment(output["AutoDeployment"], context); + } + if (output["PermissionModel"] !== undefined) { + contents.PermissionModel = output["PermissionModel"]; + } + if (output.OrganizationalUnitIds === "") { + contents.OrganizationalUnitIds = []; + } + if (output["OrganizationalUnitIds"] !== undefined && output["OrganizationalUnitIds"]["member"] !== undefined) { + contents.OrganizationalUnitIds = deserializeAws_queryOrganizationalUnitIdList(smithy_client_1.getArrayIfSingleItem(output["OrganizationalUnitIds"]["member"]), context); + } + return contents; +}; +const deserializeAws_queryStackSetDriftDetectionDetails = (output, context) => { + let contents = { + DriftStatus: undefined, + DriftDetectionStatus: undefined, + LastDriftCheckTimestamp: undefined, + TotalStackInstancesCount: undefined, + DriftedStackInstancesCount: undefined, + InSyncStackInstancesCount: undefined, + InProgressStackInstancesCount: undefined, + FailedStackInstancesCount: undefined, + }; + if (output["DriftStatus"] !== undefined) { + contents.DriftStatus = output["DriftStatus"]; + } + if (output["DriftDetectionStatus"] !== undefined) { + contents.DriftDetectionStatus = output["DriftDetectionStatus"]; + } + if (output["LastDriftCheckTimestamp"] !== undefined) { + contents.LastDriftCheckTimestamp = new Date(output["LastDriftCheckTimestamp"]); + } + if (output["TotalStackInstancesCount"] !== undefined) { + contents.TotalStackInstancesCount = parseInt(output["TotalStackInstancesCount"]); + } + if (output["DriftedStackInstancesCount"] !== undefined) { + contents.DriftedStackInstancesCount = parseInt(output["DriftedStackInstancesCount"]); + } + if (output["InSyncStackInstancesCount"] !== undefined) { + contents.InSyncStackInstancesCount = parseInt(output["InSyncStackInstancesCount"]); + } + if (output["InProgressStackInstancesCount"] !== undefined) { + contents.InProgressStackInstancesCount = parseInt(output["InProgressStackInstancesCount"]); + } + if (output["FailedStackInstancesCount"] !== undefined) { + contents.FailedStackInstancesCount = parseInt(output["FailedStackInstancesCount"]); + } + return contents; +}; +const deserializeAws_queryStackSetNotEmptyException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryStackSetNotFoundException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryStackSetOperation = (output, context) => { + let contents = { + OperationId: undefined, + StackSetId: undefined, + Action: undefined, + Status: undefined, + OperationPreferences: undefined, + RetainStacks: undefined, + AdministrationRoleARN: undefined, + ExecutionRoleName: undefined, + CreationTimestamp: undefined, + EndTimestamp: undefined, + DeploymentTargets: undefined, + StackSetDriftDetectionDetails: undefined, + }; + if (output["OperationId"] !== undefined) { + contents.OperationId = output["OperationId"]; + } + if (output["StackSetId"] !== undefined) { + contents.StackSetId = output["StackSetId"]; + } + if (output["Action"] !== undefined) { + contents.Action = output["Action"]; + } + if (output["Status"] !== undefined) { + contents.Status = output["Status"]; + } + if (output["OperationPreferences"] !== undefined) { + contents.OperationPreferences = deserializeAws_queryStackSetOperationPreferences(output["OperationPreferences"], context); + } + if (output["RetainStacks"] !== undefined) { + contents.RetainStacks = output["RetainStacks"] == "true"; + } + if (output["AdministrationRoleARN"] !== undefined) { + contents.AdministrationRoleARN = output["AdministrationRoleARN"]; + } + if (output["ExecutionRoleName"] !== undefined) { + contents.ExecutionRoleName = output["ExecutionRoleName"]; + } + if (output["CreationTimestamp"] !== undefined) { + contents.CreationTimestamp = new Date(output["CreationTimestamp"]); + } + if (output["EndTimestamp"] !== undefined) { + contents.EndTimestamp = new Date(output["EndTimestamp"]); + } + if (output["DeploymentTargets"] !== undefined) { + contents.DeploymentTargets = deserializeAws_queryDeploymentTargets(output["DeploymentTargets"], context); + } + if (output["StackSetDriftDetectionDetails"] !== undefined) { + contents.StackSetDriftDetectionDetails = deserializeAws_queryStackSetDriftDetectionDetails(output["StackSetDriftDetectionDetails"], context); + } + return contents; +}; +const deserializeAws_queryStackSetOperationPreferences = (output, context) => { + let contents = { + RegionOrder: undefined, + FailureToleranceCount: undefined, + FailureTolerancePercentage: undefined, + MaxConcurrentCount: undefined, + MaxConcurrentPercentage: undefined, + }; + if (output.RegionOrder === "") { + contents.RegionOrder = []; + } + if (output["RegionOrder"] !== undefined && output["RegionOrder"]["member"] !== undefined) { + contents.RegionOrder = deserializeAws_queryRegionList(smithy_client_1.getArrayIfSingleItem(output["RegionOrder"]["member"]), context); + } + if (output["FailureToleranceCount"] !== undefined) { + contents.FailureToleranceCount = parseInt(output["FailureToleranceCount"]); + } + if (output["FailureTolerancePercentage"] !== undefined) { + contents.FailureTolerancePercentage = parseInt(output["FailureTolerancePercentage"]); + } + if (output["MaxConcurrentCount"] !== undefined) { + contents.MaxConcurrentCount = parseInt(output["MaxConcurrentCount"]); + } + if (output["MaxConcurrentPercentage"] !== undefined) { + contents.MaxConcurrentPercentage = parseInt(output["MaxConcurrentPercentage"]); + } + return contents; +}; +const deserializeAws_queryStackSetOperationResultSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryStackSetOperationResultSummary(entry, context); + }); +}; +const deserializeAws_queryStackSetOperationResultSummary = (output, context) => { + let contents = { + Account: undefined, + Region: undefined, + Status: undefined, + StatusReason: undefined, + AccountGateResult: undefined, + OrganizationalUnitId: undefined, + }; + if (output["Account"] !== undefined) { + contents.Account = output["Account"]; + } + if (output["Region"] !== undefined) { + contents.Region = output["Region"]; + } + if (output["Status"] !== undefined) { + contents.Status = output["Status"]; + } + if (output["StatusReason"] !== undefined) { + contents.StatusReason = output["StatusReason"]; + } + if (output["AccountGateResult"] !== undefined) { + contents.AccountGateResult = deserializeAws_queryAccountGateResult(output["AccountGateResult"], context); + } + if (output["OrganizationalUnitId"] !== undefined) { + contents.OrganizationalUnitId = output["OrganizationalUnitId"]; + } + return contents; +}; +const deserializeAws_queryStackSetOperationSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryStackSetOperationSummary(entry, context); + }); +}; +const deserializeAws_queryStackSetOperationSummary = (output, context) => { + let contents = { + OperationId: undefined, + Action: undefined, + Status: undefined, + CreationTimestamp: undefined, + EndTimestamp: undefined, + }; + if (output["OperationId"] !== undefined) { + contents.OperationId = output["OperationId"]; + } + if (output["Action"] !== undefined) { + contents.Action = output["Action"]; + } + if (output["Status"] !== undefined) { + contents.Status = output["Status"]; + } + if (output["CreationTimestamp"] !== undefined) { + contents.CreationTimestamp = new Date(output["CreationTimestamp"]); + } + if (output["EndTimestamp"] !== undefined) { + contents.EndTimestamp = new Date(output["EndTimestamp"]); + } + return contents; +}; +const deserializeAws_queryStackSetSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryStackSetSummary(entry, context); + }); +}; +const deserializeAws_queryStackSetSummary = (output, context) => { + let contents = { + StackSetName: undefined, + StackSetId: undefined, + Description: undefined, + Status: undefined, + AutoDeployment: undefined, + PermissionModel: undefined, + DriftStatus: undefined, + LastDriftCheckTimestamp: undefined, + }; + if (output["StackSetName"] !== undefined) { + contents.StackSetName = output["StackSetName"]; + } + if (output["StackSetId"] !== undefined) { + contents.StackSetId = output["StackSetId"]; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output["Status"] !== undefined) { + contents.Status = output["Status"]; + } + if (output["AutoDeployment"] !== undefined) { + contents.AutoDeployment = deserializeAws_queryAutoDeployment(output["AutoDeployment"], context); + } + if (output["PermissionModel"] !== undefined) { + contents.PermissionModel = output["PermissionModel"]; + } + if (output["DriftStatus"] !== undefined) { + contents.DriftStatus = output["DriftStatus"]; + } + if (output["LastDriftCheckTimestamp"] !== undefined) { + contents.LastDriftCheckTimestamp = new Date(output["LastDriftCheckTimestamp"]); + } + return contents; +}; +const deserializeAws_queryStackSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryStackSummary(entry, context); + }); +}; +const deserializeAws_queryStackSummary = (output, context) => { + let contents = { + StackId: undefined, + StackName: undefined, + TemplateDescription: undefined, + CreationTime: undefined, + LastUpdatedTime: undefined, + DeletionTime: undefined, + StackStatus: undefined, + StackStatusReason: undefined, + ParentId: undefined, + RootId: undefined, + DriftInformation: undefined, + }; + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + if (output["StackName"] !== undefined) { + contents.StackName = output["StackName"]; + } + if (output["TemplateDescription"] !== undefined) { + contents.TemplateDescription = output["TemplateDescription"]; + } + if (output["CreationTime"] !== undefined) { + contents.CreationTime = new Date(output["CreationTime"]); + } + if (output["LastUpdatedTime"] !== undefined) { + contents.LastUpdatedTime = new Date(output["LastUpdatedTime"]); + } + if (output["DeletionTime"] !== undefined) { + contents.DeletionTime = new Date(output["DeletionTime"]); + } + if (output["StackStatus"] !== undefined) { + contents.StackStatus = output["StackStatus"]; + } + if (output["StackStatusReason"] !== undefined) { + contents.StackStatusReason = output["StackStatusReason"]; + } + if (output["ParentId"] !== undefined) { + contents.ParentId = output["ParentId"]; + } + if (output["RootId"] !== undefined) { + contents.RootId = output["RootId"]; + } + if (output["DriftInformation"] !== undefined) { + contents.DriftInformation = deserializeAws_queryStackDriftInformationSummary(output["DriftInformation"], context); + } + return contents; +}; +const deserializeAws_queryStageList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryStaleRequestException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryStopStackSetOperationOutput = (output, context) => { + let contents = {}; + return contents; +}; +const deserializeAws_queryTag = (output, context) => { + let contents = { + Key: undefined, + Value: undefined, + }; + if (output["Key"] !== undefined) { + contents.Key = output["Key"]; + } + if (output["Value"] !== undefined) { + contents.Value = output["Value"]; + } + return contents; +}; +const deserializeAws_queryTags = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryTag(entry, context); + }); +}; +const deserializeAws_queryTemplateParameter = (output, context) => { + let contents = { + ParameterKey: undefined, + DefaultValue: undefined, + NoEcho: undefined, + Description: undefined, + }; + if (output["ParameterKey"] !== undefined) { + contents.ParameterKey = output["ParameterKey"]; + } + if (output["DefaultValue"] !== undefined) { + contents.DefaultValue = output["DefaultValue"]; + } + if (output["NoEcho"] !== undefined) { + contents.NoEcho = output["NoEcho"] == "true"; + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + return contents; +}; +const deserializeAws_queryTemplateParameters = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryTemplateParameter(entry, context); + }); +}; +const deserializeAws_queryTokenAlreadyExistsException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryTransformsList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_queryTypeNotFoundException = (output, context) => { + let contents = { + Message: undefined, + }; + if (output["Message"] !== undefined) { + contents.Message = output["Message"]; + } + return contents; +}; +const deserializeAws_queryTypeSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryTypeSummary(entry, context); + }); +}; +const deserializeAws_queryTypeSummary = (output, context) => { + let contents = { + Type: undefined, + TypeName: undefined, + DefaultVersionId: undefined, + TypeArn: undefined, + LastUpdated: undefined, + Description: undefined, + }; + if (output["Type"] !== undefined) { + contents.Type = output["Type"]; + } + if (output["TypeName"] !== undefined) { + contents.TypeName = output["TypeName"]; + } + if (output["DefaultVersionId"] !== undefined) { + contents.DefaultVersionId = output["DefaultVersionId"]; + } + if (output["TypeArn"] !== undefined) { + contents.TypeArn = output["TypeArn"]; + } + if (output["LastUpdated"] !== undefined) { + contents.LastUpdated = new Date(output["LastUpdated"]); + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + return contents; +}; +const deserializeAws_queryTypeVersionSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_queryTypeVersionSummary(entry, context); + }); +}; +const deserializeAws_queryTypeVersionSummary = (output, context) => { + let contents = { + Type: undefined, + TypeName: undefined, + VersionId: undefined, + IsDefaultVersion: undefined, + Arn: undefined, + TimeCreated: undefined, + Description: undefined, + }; + if (output["Type"] !== undefined) { + contents.Type = output["Type"]; + } + if (output["TypeName"] !== undefined) { + contents.TypeName = output["TypeName"]; + } + if (output["VersionId"] !== undefined) { + contents.VersionId = output["VersionId"]; + } + if (output["IsDefaultVersion"] !== undefined) { + contents.IsDefaultVersion = output["IsDefaultVersion"] == "true"; + } + if (output["Arn"] !== undefined) { + contents.Arn = output["Arn"]; + } + if (output["TimeCreated"] !== undefined) { + contents.TimeCreated = new Date(output["TimeCreated"]); + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + return contents; +}; +const deserializeAws_queryUpdateStackInstancesOutput = (output, context) => { + let contents = { + OperationId: undefined, + }; + if (output["OperationId"] !== undefined) { + contents.OperationId = output["OperationId"]; + } + return contents; +}; +const deserializeAws_queryUpdateStackOutput = (output, context) => { + let contents = { + StackId: undefined, + }; + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + return contents; +}; +const deserializeAws_queryUpdateStackSetOutput = (output, context) => { + let contents = { + OperationId: undefined, + }; + if (output["OperationId"] !== undefined) { + contents.OperationId = output["OperationId"]; + } + return contents; +}; +const deserializeAws_queryUpdateTerminationProtectionOutput = (output, context) => { + let contents = { + StackId: undefined, + }; + if (output["StackId"] !== undefined) { + contents.StackId = output["StackId"]; + } + return contents; +}; +const deserializeAws_queryValidateTemplateOutput = (output, context) => { + let contents = { + Parameters: undefined, + Description: undefined, + Capabilities: undefined, + CapabilitiesReason: undefined, + DeclaredTransforms: undefined, + }; + if (output.Parameters === "") { + contents.Parameters = []; + } + if (output["Parameters"] !== undefined && output["Parameters"]["member"] !== undefined) { + contents.Parameters = deserializeAws_queryTemplateParameters(smithy_client_1.getArrayIfSingleItem(output["Parameters"]["member"]), context); + } + if (output["Description"] !== undefined) { + contents.Description = output["Description"]; + } + if (output.Capabilities === "") { + contents.Capabilities = []; + } + if (output["Capabilities"] !== undefined && output["Capabilities"]["member"] !== undefined) { + contents.Capabilities = deserializeAws_queryCapabilities(smithy_client_1.getArrayIfSingleItem(output["Capabilities"]["member"]), context); + } + if (output["CapabilitiesReason"] !== undefined) { + contents.CapabilitiesReason = output["CapabilitiesReason"]; + } + if (output.DeclaredTransforms === "") { + contents.DeclaredTransforms = []; + } + if (output["DeclaredTransforms"] !== undefined && output["DeclaredTransforms"]["member"] !== undefined) { + contents.DeclaredTransforms = deserializeAws_queryTransformsList(smithy_client_1.getArrayIfSingleItem(output["DeclaredTransforms"]["member"]), context); + } + return contents; +}; +const deserializeMetadata = (output) => { + var _a; + return ({ + httpStatusCode: output.statusCode, + requestId: (_a = output.headers["x-amzn-requestid"]) !== null && _a !== void 0 ? _a : output.headers["x-amzn-request-id"], + extendedRequestId: output.headers["x-amz-id-2"], + cfId: output.headers["x-amz-cf-id"], + }); +}; +// Collect low-level response body stream to Uint8Array. +const collectBody = (streamBody = new Uint8Array(), context) => { + if (streamBody instanceof Uint8Array) { + return Promise.resolve(streamBody); + } + return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array()); +}; +// Encode Uint8Array data into string with utf-8. +const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body)); +const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => { + const { hostname, protocol = "https", port } = await context.endpoint(); + const contents = { + protocol, + hostname, + port, + method: "POST", + path, + headers, + }; + if (resolvedHostname !== undefined) { + contents.hostname = resolvedHostname; + } + if (body !== undefined) { + contents.body = body; + } + return new protocol_http_1.HttpRequest(contents); +}; +const decodeEscapedXML = (str) => str + .replace(/&/g, "&") + .replace(/'/g, "'") + .replace(/"/g, '"') + .replace(/>/g, ">") + .replace(/</g, "<"); +const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => { + if (encoded.length) { + const parsedObj = fast_xml_parser_1.parse(encoded, { + attributeNamePrefix: "", + ignoreAttributes: false, + parseNodeValue: false, + tagValueProcessor: (val, tagName) => decodeEscapedXML(val), + }); + const textNodeName = "#text"; + const key = Object.keys(parsedObj)[0]; + const parsedObjToReturn = parsedObj[key]; + if (parsedObjToReturn[textNodeName]) { + parsedObjToReturn[key] = parsedObjToReturn[textNodeName]; + delete parsedObjToReturn[textNodeName]; + } + return smithy_client_1.getValueFromTextNode(parsedObjToReturn); + } + return {}; +}); +const buildFormUrlencodedString = (formEntries) => Object.entries(formEntries) + .map(([key, value]) => smithy_client_1.extendedEncodeURIComponent(key) + "=" + smithy_client_1.extendedEncodeURIComponent(value)) + .join("&"); +const loadQueryErrorCode = (output, data) => { + if (data.Error.Code !== undefined) { + return data.Error.Code; + } + if (output.statusCode == 404) { + return "NotFound"; + } + return ""; +}; +//# sourceMappingURL=Aws_query.js.map + +/***/ }), + +/***/ 64170: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ClientDefaultValues = void 0; +const tslib_1 = __nccwpck_require__(91663); +const package_json_1 = tslib_1.__importDefault(__nccwpck_require__(51194)); +const config_resolver_1 = __nccwpck_require__(87229); +const credential_provider_node_1 = __nccwpck_require__(98030); +const hash_node_1 = __nccwpck_require__(90791); +const middleware_retry_1 = __nccwpck_require__(7000); +const node_config_provider_1 = __nccwpck_require__(71124); +const node_http_handler_1 = __nccwpck_require__(15168); +const util_base64_node_1 = __nccwpck_require__(2091); +const util_body_length_node_1 = __nccwpck_require__(40286); +const util_user_agent_node_1 = __nccwpck_require__(64717); +const util_utf8_node_1 = __nccwpck_require__(85227); +const runtimeConfig_shared_1 = __nccwpck_require__(49222); +/** + * @internal + */ +exports.ClientDefaultValues = { + ...runtimeConfig_shared_1.ClientSharedValues, + runtime: "node", + base64Decoder: util_base64_node_1.fromBase64, + base64Encoder: util_base64_node_1.toBase64, + bodyLengthChecker: util_body_length_node_1.calculateBodyLength, + credentialDefaultProvider: credential_provider_node_1.defaultProvider, + defaultUserAgentProvider: util_user_agent_node_1.defaultUserAgent({ + serviceId: runtimeConfig_shared_1.ClientSharedValues.serviceId, + clientVersion: package_json_1.default.version, + }), + maxAttempts: node_config_provider_1.loadConfig(middleware_retry_1.NODE_MAX_ATTEMPT_CONFIG_OPTIONS), + region: node_config_provider_1.loadConfig(config_resolver_1.NODE_REGION_CONFIG_OPTIONS, config_resolver_1.NODE_REGION_CONFIG_FILE_OPTIONS), + requestHandler: new node_http_handler_1.NodeHttpHandler(), + sha256: hash_node_1.Hash.bind(null, "sha256"), + streamCollector: node_http_handler_1.streamCollector, + utf8Decoder: util_utf8_node_1.fromUtf8, + utf8Encoder: util_utf8_node_1.toUtf8, +}; +//# sourceMappingURL=runtimeConfig.js.map + +/***/ }), + +/***/ 49222: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ClientSharedValues = void 0; +const endpoints_1 = __nccwpck_require__(8628); +const url_parser_1 = __nccwpck_require__(99427); +/** + * @internal + */ +exports.ClientSharedValues = { + apiVersion: "2010-05-15", + disableHostPrefix: false, + logger: {}, + regionInfoProvider: endpoints_1.defaultRegionInfoProvider, + serviceId: "CloudFormation", + urlParser: url_parser_1.parseUrl, +}; +//# sourceMappingURL=runtimeConfig.shared.js.map + +/***/ }), + +/***/ 68435: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.waitForTypeRegistrationComplete = void 0; +const DescribeTypeRegistrationCommand_1 = __nccwpck_require__(39500); +const util_waiter_1 = __nccwpck_require__(6243); +const checkState = async (client, input) => { + try { + let result = await client.send(new DescribeTypeRegistrationCommand_1.DescribeTypeRegistrationCommand(input)); + try { + let returnComparator = () => { + return result.ProgressStatus; + }; + if (returnComparator() === "COMPLETE") { + return { state: util_waiter_1.WaiterState.SUCCESS }; + } + } + catch (e) { } + try { + let returnComparator = () => { + return result.ProgressStatus; + }; + if (returnComparator() === "FAILED") { + return { state: util_waiter_1.WaiterState.FAILURE }; + } + } + catch (e) { } + } + catch (exception) { } + return { state: util_waiter_1.WaiterState.RETRY }; +}; +/** + * Wait until type registration is COMPLETE. + * @param params : Waiter configuration options. + * @param input : the input to DescribeTypeRegistrationCommand for polling. + */ +const waitForTypeRegistrationComplete = async (params, input) => { + const serviceDefaults = { minDelay: 30, maxDelay: 120 }; + return util_waiter_1.createWaiter({ ...serviceDefaults, ...params }, input, checkState); +}; +exports.waitForTypeRegistrationComplete = waitForTypeRegistrationComplete; +//# sourceMappingURL=waitForTypeRegistrationComplete.js.map + +/***/ }), + +/***/ 91663: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +__nccwpck_require__.r(__webpack_exports__); +/* harmony export */ __nccwpck_require__.d(__webpack_exports__, { +/* harmony export */ "__extends": () => /* binding */ __extends, +/* harmony export */ "__assign": () => /* binding */ __assign, +/* harmony export */ "__rest": () => /* binding */ __rest, +/* harmony export */ "__decorate": () => /* binding */ __decorate, +/* harmony export */ "__param": () => /* binding */ __param, +/* harmony export */ "__metadata": () => /* binding */ __metadata, +/* harmony export */ "__awaiter": () => /* binding */ __awaiter, +/* harmony export */ "__generator": () => /* binding */ __generator, +/* harmony export */ "__createBinding": () => /* binding */ __createBinding, +/* harmony export */ "__exportStar": () => /* binding */ __exportStar, +/* harmony export */ "__values": () => /* binding */ __values, +/* harmony export */ "__read": () => /* binding */ __read, +/* harmony export */ "__spread": () => /* binding */ __spread, +/* harmony export */ "__spreadArrays": () => /* binding */ __spreadArrays, +/* harmony export */ "__spreadArray": () => /* binding */ __spreadArray, +/* harmony export */ "__await": () => /* binding */ __await, +/* harmony export */ "__asyncGenerator": () => /* binding */ __asyncGenerator, +/* harmony export */ "__asyncDelegator": () => /* binding */ __asyncDelegator, +/* harmony export */ "__asyncValues": () => /* binding */ __asyncValues, +/* harmony export */ "__makeTemplateObject": () => /* binding */ __makeTemplateObject, +/* harmony export */ "__importStar": () => /* binding */ __importStar, +/* harmony export */ "__importDefault": () => /* binding */ __importDefault, +/* harmony export */ "__classPrivateFieldGet": () => /* binding */ __classPrivateFieldGet, +/* harmony export */ "__classPrivateFieldSet": () => /* binding */ __classPrivateFieldSet +/* harmony export */ }); +/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. +***************************************************************************** */ +/* global Reflect, Promise */ + +var extendStatics = function(d, b) { + extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; + return extendStatics(d, b); +}; + +function __extends(d, b) { + if (typeof b !== "function" && b !== null) + throw new TypeError("Class extends value " + String(b) + " is not a constructor or null"); + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +} + +var __assign = function() { + __assign = Object.assign || function __assign(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p]; + } + return t; + } + return __assign.apply(this, arguments); +} + +function __rest(s, e) { + var t = {}; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) + t[p] = s[p]; + if (s != null && typeof Object.getOwnPropertySymbols === "function") + for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { + if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) + t[p[i]] = s[p[i]]; + } + return t; +} + +function __decorate(decorators, target, key, desc) { + var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; + if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); + else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; + return c > 3 && r && Object.defineProperty(target, key, r), r; +} + +function __param(paramIndex, decorator) { + return function (target, key) { decorator(target, key, paramIndex); } +} + +function __metadata(metadataKey, metadataValue) { + if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue); +} + +function __awaiter(thisArg, _arguments, P, generator) { + function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } + return new (P || (P = Promise))(function (resolve, reject) { + function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } + function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } + function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + step((generator = generator.apply(thisArg, _arguments || [])).next()); + }); +} + +function __generator(thisArg, body) { + var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g; + return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g; + function verb(n) { return function (v) { return step([n, v]); }; } + function step(op) { + if (f) throw new TypeError("Generator is already executing."); + while (_) try { + if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t; + if (y = 0, t) op = [op[0] & 2, t.value]; + switch (op[0]) { + case 0: case 1: t = op; break; + case 4: _.label++; return { value: op[1], done: false }; + case 5: _.label++; y = op[1]; op = [0]; continue; + case 7: op = _.ops.pop(); _.trys.pop(); continue; + default: + if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; } + if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; } + if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; } + if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; } + if (t[2]) _.ops.pop(); + _.trys.pop(); continue; + } + op = body.call(thisArg, _); + } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; } + if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true }; + } +} + +var __createBinding = Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +}); + +function __exportStar(m, o) { + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p); +} + +function __values(o) { + var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0; + if (m) return m.call(o); + if (o && typeof o.length === "number") return { + next: function () { + if (o && i >= o.length) o = void 0; + return { value: o && o[i++], done: !o }; + } + }; + throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined."); +} + +function __read(o, n) { + var m = typeof Symbol === "function" && o[Symbol.iterator]; + if (!m) return o; + var i = m.call(o), r, ar = [], e; + try { + while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value); + } + catch (error) { e = { error: error }; } + finally { + try { + if (r && !r.done && (m = i["return"])) m.call(i); + } + finally { if (e) throw e.error; } + } + return ar; +} + +/** @deprecated */ +function __spread() { + for (var ar = [], i = 0; i < arguments.length; i++) + ar = ar.concat(__read(arguments[i])); + return ar; +} + +/** @deprecated */ +function __spreadArrays() { + for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length; + for (var r = Array(s), k = 0, i = 0; i < il; i++) + for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++) + r[k] = a[j]; + return r; +} + +function __spreadArray(to, from) { + for (var i = 0, il = from.length, j = to.length; i < il; i++, j++) + to[j] = from[i]; + return to; +} + +function __await(v) { + return this instanceof __await ? (this.v = v, this) : new __await(v); +} + +function __asyncGenerator(thisArg, _arguments, generator) { + if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined."); + var g = generator.apply(thisArg, _arguments || []), i, q = []; + return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i; + function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; } + function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } } + function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); } + function fulfill(value) { resume("next", value); } + function reject(value) { resume("throw", value); } + function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); } +} + +function __asyncDelegator(o) { + var i, p; + return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i; + function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; } +} + +function __asyncValues(o) { + if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined."); + var m = o[Symbol.asyncIterator], i; + return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i); + function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; } + function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); } +} + +function __makeTemplateObject(cooked, raw) { + if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; } + return cooked; +}; + +var __setModuleDefault = Object.create ? (function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); +}) : function(o, v) { + o["default"] = v; +}; + +function __importStar(mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + __setModuleDefault(result, mod); + return result; +} + +function __importDefault(mod) { + return (mod && mod.__esModule) ? mod : { default: mod }; +} + +function __classPrivateFieldGet(receiver, privateMap) { + if (!privateMap.has(receiver)) { + throw new TypeError("attempted to get private field on non-instance"); + } + return privateMap.get(receiver); +} + +function __classPrivateFieldSet(receiver, privateMap, value) { + if (!privateMap.has(receiver)) { + throw new TypeError("attempted to set private field on non-instance"); + } + privateMap.set(receiver, value); + return value; +} + + +/***/ }), + +/***/ 63436: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CognitoIdentityProvider = void 0; +const CognitoIdentityProviderClient_1 = __nccwpck_require__(32756); +const AddCustomAttributesCommand_1 = __nccwpck_require__(2336); +const AdminAddUserToGroupCommand_1 = __nccwpck_require__(63030); +const AdminConfirmSignUpCommand_1 = __nccwpck_require__(8330); +const AdminCreateUserCommand_1 = __nccwpck_require__(18188); +const AdminDeleteUserAttributesCommand_1 = __nccwpck_require__(49653); +const AdminDeleteUserCommand_1 = __nccwpck_require__(27623); +const AdminDisableProviderForUserCommand_1 = __nccwpck_require__(24718); +const AdminDisableUserCommand_1 = __nccwpck_require__(31989); +const AdminEnableUserCommand_1 = __nccwpck_require__(78365); +const AdminForgetDeviceCommand_1 = __nccwpck_require__(35436); +const AdminGetDeviceCommand_1 = __nccwpck_require__(7451); +const AdminGetUserCommand_1 = __nccwpck_require__(75054); +const AdminInitiateAuthCommand_1 = __nccwpck_require__(51153); +const AdminLinkProviderForUserCommand_1 = __nccwpck_require__(31763); +const AdminListDevicesCommand_1 = __nccwpck_require__(18926); +const AdminListGroupsForUserCommand_1 = __nccwpck_require__(4199); +const AdminListUserAuthEventsCommand_1 = __nccwpck_require__(76132); +const AdminRemoveUserFromGroupCommand_1 = __nccwpck_require__(9640); +const AdminResetUserPasswordCommand_1 = __nccwpck_require__(12557); +const AdminRespondToAuthChallengeCommand_1 = __nccwpck_require__(21828); +const AdminSetUserMFAPreferenceCommand_1 = __nccwpck_require__(13421); +const AdminSetUserPasswordCommand_1 = __nccwpck_require__(75616); +const AdminSetUserSettingsCommand_1 = __nccwpck_require__(36217); +const AdminUpdateAuthEventFeedbackCommand_1 = __nccwpck_require__(57675); +const AdminUpdateDeviceStatusCommand_1 = __nccwpck_require__(18824); +const AdminUpdateUserAttributesCommand_1 = __nccwpck_require__(1541); +const AdminUserGlobalSignOutCommand_1 = __nccwpck_require__(11240); +const AssociateSoftwareTokenCommand_1 = __nccwpck_require__(52819); +const ChangePasswordCommand_1 = __nccwpck_require__(65801); +const ConfirmDeviceCommand_1 = __nccwpck_require__(79275); +const ConfirmForgotPasswordCommand_1 = __nccwpck_require__(35665); +const ConfirmSignUpCommand_1 = __nccwpck_require__(18104); +const CreateGroupCommand_1 = __nccwpck_require__(81662); +const CreateIdentityProviderCommand_1 = __nccwpck_require__(81266); +const CreateResourceServerCommand_1 = __nccwpck_require__(54935); +const CreateUserImportJobCommand_1 = __nccwpck_require__(77974); +const CreateUserPoolClientCommand_1 = __nccwpck_require__(17824); +const CreateUserPoolCommand_1 = __nccwpck_require__(74938); +const CreateUserPoolDomainCommand_1 = __nccwpck_require__(58015); +const DeleteGroupCommand_1 = __nccwpck_require__(73307); +const DeleteIdentityProviderCommand_1 = __nccwpck_require__(7493); +const DeleteResourceServerCommand_1 = __nccwpck_require__(6049); +const DeleteUserAttributesCommand_1 = __nccwpck_require__(99475); +const DeleteUserCommand_1 = __nccwpck_require__(28421); +const DeleteUserPoolClientCommand_1 = __nccwpck_require__(3402); +const DeleteUserPoolCommand_1 = __nccwpck_require__(92314); +const DeleteUserPoolDomainCommand_1 = __nccwpck_require__(79680); +const DescribeIdentityProviderCommand_1 = __nccwpck_require__(96582); +const DescribeResourceServerCommand_1 = __nccwpck_require__(13045); +const DescribeRiskConfigurationCommand_1 = __nccwpck_require__(51063); +const DescribeUserImportJobCommand_1 = __nccwpck_require__(10902); +const DescribeUserPoolClientCommand_1 = __nccwpck_require__(25424); +const DescribeUserPoolCommand_1 = __nccwpck_require__(67125); +const DescribeUserPoolDomainCommand_1 = __nccwpck_require__(9253); +const ForgetDeviceCommand_1 = __nccwpck_require__(39305); +const ForgotPasswordCommand_1 = __nccwpck_require__(15806); +const GetCSVHeaderCommand_1 = __nccwpck_require__(59575); +const GetDeviceCommand_1 = __nccwpck_require__(95242); +const GetGroupCommand_1 = __nccwpck_require__(89462); +const GetIdentityProviderByIdentifierCommand_1 = __nccwpck_require__(29528); +const GetSigningCertificateCommand_1 = __nccwpck_require__(7884); +const GetUICustomizationCommand_1 = __nccwpck_require__(47556); +const GetUserAttributeVerificationCodeCommand_1 = __nccwpck_require__(1966); +const GetUserCommand_1 = __nccwpck_require__(33079); +const GetUserPoolMfaConfigCommand_1 = __nccwpck_require__(59598); +const GlobalSignOutCommand_1 = __nccwpck_require__(783); +const InitiateAuthCommand_1 = __nccwpck_require__(25210); +const ListDevicesCommand_1 = __nccwpck_require__(41445); +const ListGroupsCommand_1 = __nccwpck_require__(39386); +const ListIdentityProvidersCommand_1 = __nccwpck_require__(73419); +const ListResourceServersCommand_1 = __nccwpck_require__(93783); +const ListTagsForResourceCommand_1 = __nccwpck_require__(22658); +const ListUserImportJobsCommand_1 = __nccwpck_require__(86421); +const ListUserPoolClientsCommand_1 = __nccwpck_require__(87753); +const ListUserPoolsCommand_1 = __nccwpck_require__(51756); +const ListUsersCommand_1 = __nccwpck_require__(16854); +const ListUsersInGroupCommand_1 = __nccwpck_require__(51577); +const ResendConfirmationCodeCommand_1 = __nccwpck_require__(30730); +const RespondToAuthChallengeCommand_1 = __nccwpck_require__(36946); +const SetRiskConfigurationCommand_1 = __nccwpck_require__(54210); +const SetUICustomizationCommand_1 = __nccwpck_require__(41002); +const SetUserMFAPreferenceCommand_1 = __nccwpck_require__(59037); +const SetUserPoolMfaConfigCommand_1 = __nccwpck_require__(39776); +const SetUserSettingsCommand_1 = __nccwpck_require__(44103); +const SignUpCommand_1 = __nccwpck_require__(61298); +const StartUserImportJobCommand_1 = __nccwpck_require__(8066); +const StopUserImportJobCommand_1 = __nccwpck_require__(47546); +const TagResourceCommand_1 = __nccwpck_require__(13116); +const UntagResourceCommand_1 = __nccwpck_require__(93194); +const UpdateAuthEventFeedbackCommand_1 = __nccwpck_require__(45344); +const UpdateDeviceStatusCommand_1 = __nccwpck_require__(34181); +const UpdateGroupCommand_1 = __nccwpck_require__(17637); +const UpdateIdentityProviderCommand_1 = __nccwpck_require__(79222); +const UpdateResourceServerCommand_1 = __nccwpck_require__(42116); +const UpdateUserAttributesCommand_1 = __nccwpck_require__(77311); +const UpdateUserPoolClientCommand_1 = __nccwpck_require__(94287); +const UpdateUserPoolCommand_1 = __nccwpck_require__(70670); +const UpdateUserPoolDomainCommand_1 = __nccwpck_require__(16919); +const VerifySoftwareTokenCommand_1 = __nccwpck_require__(25918); +const VerifyUserAttributeCommand_1 = __nccwpck_require__(11850); +/** + *Using the Amazon Cognito User Pools API, you can create a user pool to manage + * directories and users. You can authenticate a user to obtain tokens related to user + * identity and access policies.
+ *This API reference provides information about user pools in Amazon Cognito User + * Pools.
+ *For more information, see the Amazon Cognito Documentation.
+ */ +class CognitoIdentityProvider extends CognitoIdentityProviderClient_1.CognitoIdentityProviderClient { + addCustomAttributes(args, optionsOrCb, cb) { + const command = new AddCustomAttributesCommand_1.AddCustomAttributesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminAddUserToGroup(args, optionsOrCb, cb) { + const command = new AdminAddUserToGroupCommand_1.AdminAddUserToGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminConfirmSignUp(args, optionsOrCb, cb) { + const command = new AdminConfirmSignUpCommand_1.AdminConfirmSignUpCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminCreateUser(args, optionsOrCb, cb) { + const command = new AdminCreateUserCommand_1.AdminCreateUserCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminDeleteUser(args, optionsOrCb, cb) { + const command = new AdminDeleteUserCommand_1.AdminDeleteUserCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminDeleteUserAttributes(args, optionsOrCb, cb) { + const command = new AdminDeleteUserAttributesCommand_1.AdminDeleteUserAttributesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminDisableProviderForUser(args, optionsOrCb, cb) { + const command = new AdminDisableProviderForUserCommand_1.AdminDisableProviderForUserCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminDisableUser(args, optionsOrCb, cb) { + const command = new AdminDisableUserCommand_1.AdminDisableUserCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminEnableUser(args, optionsOrCb, cb) { + const command = new AdminEnableUserCommand_1.AdminEnableUserCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminForgetDevice(args, optionsOrCb, cb) { + const command = new AdminForgetDeviceCommand_1.AdminForgetDeviceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminGetDevice(args, optionsOrCb, cb) { + const command = new AdminGetDeviceCommand_1.AdminGetDeviceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminGetUser(args, optionsOrCb, cb) { + const command = new AdminGetUserCommand_1.AdminGetUserCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminInitiateAuth(args, optionsOrCb, cb) { + const command = new AdminInitiateAuthCommand_1.AdminInitiateAuthCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminLinkProviderForUser(args, optionsOrCb, cb) { + const command = new AdminLinkProviderForUserCommand_1.AdminLinkProviderForUserCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminListDevices(args, optionsOrCb, cb) { + const command = new AdminListDevicesCommand_1.AdminListDevicesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminListGroupsForUser(args, optionsOrCb, cb) { + const command = new AdminListGroupsForUserCommand_1.AdminListGroupsForUserCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminListUserAuthEvents(args, optionsOrCb, cb) { + const command = new AdminListUserAuthEventsCommand_1.AdminListUserAuthEventsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminRemoveUserFromGroup(args, optionsOrCb, cb) { + const command = new AdminRemoveUserFromGroupCommand_1.AdminRemoveUserFromGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminResetUserPassword(args, optionsOrCb, cb) { + const command = new AdminResetUserPasswordCommand_1.AdminResetUserPasswordCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminRespondToAuthChallenge(args, optionsOrCb, cb) { + const command = new AdminRespondToAuthChallengeCommand_1.AdminRespondToAuthChallengeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminSetUserMFAPreference(args, optionsOrCb, cb) { + const command = new AdminSetUserMFAPreferenceCommand_1.AdminSetUserMFAPreferenceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminSetUserPassword(args, optionsOrCb, cb) { + const command = new AdminSetUserPasswordCommand_1.AdminSetUserPasswordCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminSetUserSettings(args, optionsOrCb, cb) { + const command = new AdminSetUserSettingsCommand_1.AdminSetUserSettingsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminUpdateAuthEventFeedback(args, optionsOrCb, cb) { + const command = new AdminUpdateAuthEventFeedbackCommand_1.AdminUpdateAuthEventFeedbackCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminUpdateDeviceStatus(args, optionsOrCb, cb) { + const command = new AdminUpdateDeviceStatusCommand_1.AdminUpdateDeviceStatusCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminUpdateUserAttributes(args, optionsOrCb, cb) { + const command = new AdminUpdateUserAttributesCommand_1.AdminUpdateUserAttributesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + adminUserGlobalSignOut(args, optionsOrCb, cb) { + const command = new AdminUserGlobalSignOutCommand_1.AdminUserGlobalSignOutCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + associateSoftwareToken(args, optionsOrCb, cb) { + const command = new AssociateSoftwareTokenCommand_1.AssociateSoftwareTokenCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + changePassword(args, optionsOrCb, cb) { + const command = new ChangePasswordCommand_1.ChangePasswordCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + confirmDevice(args, optionsOrCb, cb) { + const command = new ConfirmDeviceCommand_1.ConfirmDeviceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + confirmForgotPassword(args, optionsOrCb, cb) { + const command = new ConfirmForgotPasswordCommand_1.ConfirmForgotPasswordCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + confirmSignUp(args, optionsOrCb, cb) { + const command = new ConfirmSignUpCommand_1.ConfirmSignUpCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createGroup(args, optionsOrCb, cb) { + const command = new CreateGroupCommand_1.CreateGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createIdentityProvider(args, optionsOrCb, cb) { + const command = new CreateIdentityProviderCommand_1.CreateIdentityProviderCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createResourceServer(args, optionsOrCb, cb) { + const command = new CreateResourceServerCommand_1.CreateResourceServerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createUserImportJob(args, optionsOrCb, cb) { + const command = new CreateUserImportJobCommand_1.CreateUserImportJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createUserPool(args, optionsOrCb, cb) { + const command = new CreateUserPoolCommand_1.CreateUserPoolCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createUserPoolClient(args, optionsOrCb, cb) { + const command = new CreateUserPoolClientCommand_1.CreateUserPoolClientCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createUserPoolDomain(args, optionsOrCb, cb) { + const command = new CreateUserPoolDomainCommand_1.CreateUserPoolDomainCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteGroup(args, optionsOrCb, cb) { + const command = new DeleteGroupCommand_1.DeleteGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteIdentityProvider(args, optionsOrCb, cb) { + const command = new DeleteIdentityProviderCommand_1.DeleteIdentityProviderCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteResourceServer(args, optionsOrCb, cb) { + const command = new DeleteResourceServerCommand_1.DeleteResourceServerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteUser(args, optionsOrCb, cb) { + const command = new DeleteUserCommand_1.DeleteUserCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteUserAttributes(args, optionsOrCb, cb) { + const command = new DeleteUserAttributesCommand_1.DeleteUserAttributesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteUserPool(args, optionsOrCb, cb) { + const command = new DeleteUserPoolCommand_1.DeleteUserPoolCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteUserPoolClient(args, optionsOrCb, cb) { + const command = new DeleteUserPoolClientCommand_1.DeleteUserPoolClientCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteUserPoolDomain(args, optionsOrCb, cb) { + const command = new DeleteUserPoolDomainCommand_1.DeleteUserPoolDomainCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeIdentityProvider(args, optionsOrCb, cb) { + const command = new DescribeIdentityProviderCommand_1.DescribeIdentityProviderCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeResourceServer(args, optionsOrCb, cb) { + const command = new DescribeResourceServerCommand_1.DescribeResourceServerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeRiskConfiguration(args, optionsOrCb, cb) { + const command = new DescribeRiskConfigurationCommand_1.DescribeRiskConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeUserImportJob(args, optionsOrCb, cb) { + const command = new DescribeUserImportJobCommand_1.DescribeUserImportJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeUserPool(args, optionsOrCb, cb) { + const command = new DescribeUserPoolCommand_1.DescribeUserPoolCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeUserPoolClient(args, optionsOrCb, cb) { + const command = new DescribeUserPoolClientCommand_1.DescribeUserPoolClientCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeUserPoolDomain(args, optionsOrCb, cb) { + const command = new DescribeUserPoolDomainCommand_1.DescribeUserPoolDomainCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + forgetDevice(args, optionsOrCb, cb) { + const command = new ForgetDeviceCommand_1.ForgetDeviceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + forgotPassword(args, optionsOrCb, cb) { + const command = new ForgotPasswordCommand_1.ForgotPasswordCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getCSVHeader(args, optionsOrCb, cb) { + const command = new GetCSVHeaderCommand_1.GetCSVHeaderCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getDevice(args, optionsOrCb, cb) { + const command = new GetDeviceCommand_1.GetDeviceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getGroup(args, optionsOrCb, cb) { + const command = new GetGroupCommand_1.GetGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getIdentityProviderByIdentifier(args, optionsOrCb, cb) { + const command = new GetIdentityProviderByIdentifierCommand_1.GetIdentityProviderByIdentifierCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getSigningCertificate(args, optionsOrCb, cb) { + const command = new GetSigningCertificateCommand_1.GetSigningCertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getUICustomization(args, optionsOrCb, cb) { + const command = new GetUICustomizationCommand_1.GetUICustomizationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getUser(args, optionsOrCb, cb) { + const command = new GetUserCommand_1.GetUserCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getUserAttributeVerificationCode(args, optionsOrCb, cb) { + const command = new GetUserAttributeVerificationCodeCommand_1.GetUserAttributeVerificationCodeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getUserPoolMfaConfig(args, optionsOrCb, cb) { + const command = new GetUserPoolMfaConfigCommand_1.GetUserPoolMfaConfigCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + globalSignOut(args, optionsOrCb, cb) { + const command = new GlobalSignOutCommand_1.GlobalSignOutCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + initiateAuth(args, optionsOrCb, cb) { + const command = new InitiateAuthCommand_1.InitiateAuthCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listDevices(args, optionsOrCb, cb) { + const command = new ListDevicesCommand_1.ListDevicesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listGroups(args, optionsOrCb, cb) { + const command = new ListGroupsCommand_1.ListGroupsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listIdentityProviders(args, optionsOrCb, cb) { + const command = new ListIdentityProvidersCommand_1.ListIdentityProvidersCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listResourceServers(args, optionsOrCb, cb) { + const command = new ListResourceServersCommand_1.ListResourceServersCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listTagsForResource(args, optionsOrCb, cb) { + const command = new ListTagsForResourceCommand_1.ListTagsForResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listUserImportJobs(args, optionsOrCb, cb) { + const command = new ListUserImportJobsCommand_1.ListUserImportJobsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listUserPoolClients(args, optionsOrCb, cb) { + const command = new ListUserPoolClientsCommand_1.ListUserPoolClientsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listUserPools(args, optionsOrCb, cb) { + const command = new ListUserPoolsCommand_1.ListUserPoolsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listUsers(args, optionsOrCb, cb) { + const command = new ListUsersCommand_1.ListUsersCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listUsersInGroup(args, optionsOrCb, cb) { + const command = new ListUsersInGroupCommand_1.ListUsersInGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + resendConfirmationCode(args, optionsOrCb, cb) { + const command = new ResendConfirmationCodeCommand_1.ResendConfirmationCodeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + respondToAuthChallenge(args, optionsOrCb, cb) { + const command = new RespondToAuthChallengeCommand_1.RespondToAuthChallengeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setRiskConfiguration(args, optionsOrCb, cb) { + const command = new SetRiskConfigurationCommand_1.SetRiskConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setUICustomization(args, optionsOrCb, cb) { + const command = new SetUICustomizationCommand_1.SetUICustomizationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setUserMFAPreference(args, optionsOrCb, cb) { + const command = new SetUserMFAPreferenceCommand_1.SetUserMFAPreferenceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setUserPoolMfaConfig(args, optionsOrCb, cb) { + const command = new SetUserPoolMfaConfigCommand_1.SetUserPoolMfaConfigCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setUserSettings(args, optionsOrCb, cb) { + const command = new SetUserSettingsCommand_1.SetUserSettingsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + signUp(args, optionsOrCb, cb) { + const command = new SignUpCommand_1.SignUpCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + startUserImportJob(args, optionsOrCb, cb) { + const command = new StartUserImportJobCommand_1.StartUserImportJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + stopUserImportJob(args, optionsOrCb, cb) { + const command = new StopUserImportJobCommand_1.StopUserImportJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + tagResource(args, optionsOrCb, cb) { + const command = new TagResourceCommand_1.TagResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + untagResource(args, optionsOrCb, cb) { + const command = new UntagResourceCommand_1.UntagResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateAuthEventFeedback(args, optionsOrCb, cb) { + const command = new UpdateAuthEventFeedbackCommand_1.UpdateAuthEventFeedbackCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateDeviceStatus(args, optionsOrCb, cb) { + const command = new UpdateDeviceStatusCommand_1.UpdateDeviceStatusCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateGroup(args, optionsOrCb, cb) { + const command = new UpdateGroupCommand_1.UpdateGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateIdentityProvider(args, optionsOrCb, cb) { + const command = new UpdateIdentityProviderCommand_1.UpdateIdentityProviderCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateResourceServer(args, optionsOrCb, cb) { + const command = new UpdateResourceServerCommand_1.UpdateResourceServerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateUserAttributes(args, optionsOrCb, cb) { + const command = new UpdateUserAttributesCommand_1.UpdateUserAttributesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateUserPool(args, optionsOrCb, cb) { + const command = new UpdateUserPoolCommand_1.UpdateUserPoolCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateUserPoolClient(args, optionsOrCb, cb) { + const command = new UpdateUserPoolClientCommand_1.UpdateUserPoolClientCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateUserPoolDomain(args, optionsOrCb, cb) { + const command = new UpdateUserPoolDomainCommand_1.UpdateUserPoolDomainCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + verifySoftwareToken(args, optionsOrCb, cb) { + const command = new VerifySoftwareTokenCommand_1.VerifySoftwareTokenCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + verifyUserAttribute(args, optionsOrCb, cb) { + const command = new VerifyUserAttributeCommand_1.VerifyUserAttributeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } +} +exports.CognitoIdentityProvider = CognitoIdentityProvider; +//# sourceMappingURL=CognitoIdentityProvider.js.map + +/***/ }), + +/***/ 32756: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CognitoIdentityProviderClient = void 0; +const runtimeConfig_1 = __nccwpck_require__(45628); +const config_resolver_1 = __nccwpck_require__(87229); +const middleware_content_length_1 = __nccwpck_require__(69323); +const middleware_host_header_1 = __nccwpck_require__(58645); +const middleware_logger_1 = __nccwpck_require__(98685); +const middleware_retry_1 = __nccwpck_require__(7000); +const middleware_signing_1 = __nccwpck_require__(82487); +const middleware_user_agent_1 = __nccwpck_require__(55976); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Using the Amazon Cognito User Pools API, you can create a user pool to manage + * directories and users. You can authenticate a user to obtain tokens related to user + * identity and access policies.
+ *This API reference provides information about user pools in Amazon Cognito User + * Pools.
+ *For more information, see the Amazon Cognito Documentation.
+ */ +class CognitoIdentityProviderClient extends smithy_client_1.Client { + constructor(configuration) { + let _config_0 = { + ...runtimeConfig_1.ClientDefaultValues, + ...configuration, + }; + let _config_1 = config_resolver_1.resolveRegionConfig(_config_0); + let _config_2 = config_resolver_1.resolveEndpointsConfig(_config_1); + let _config_3 = middleware_signing_1.resolveAwsAuthConfig(_config_2); + let _config_4 = middleware_retry_1.resolveRetryConfig(_config_3); + let _config_5 = middleware_host_header_1.resolveHostHeaderConfig(_config_4); + let _config_6 = middleware_user_agent_1.resolveUserAgentConfig(_config_5); + super(_config_6); + this.config = _config_6; + this.middlewareStack.use(middleware_retry_1.getRetryPlugin(this.config)); + this.middlewareStack.use(middleware_content_length_1.getContentLengthPlugin(this.config)); + this.middlewareStack.use(middleware_host_header_1.getHostHeaderPlugin(this.config)); + this.middlewareStack.use(middleware_logger_1.getLoggerPlugin(this.config)); + this.middlewareStack.use(middleware_user_agent_1.getUserAgentPlugin(this.config)); + } + destroy() { + super.destroy(); + } +} +exports.CognitoIdentityProviderClient = CognitoIdentityProviderClient; +//# sourceMappingURL=CognitoIdentityProviderClient.js.map + +/***/ }), + +/***/ 2336: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AddCustomAttributesCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Adds additional user attributes to the user pool schema.
+ */ +class AddCustomAttributesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AddCustomAttributesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AddCustomAttributesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AddCustomAttributesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AddCustomAttributesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AddCustomAttributesCommand(output, context); + } +} +exports.AddCustomAttributesCommand = AddCustomAttributesCommand; +//# sourceMappingURL=AddCustomAttributesCommand.js.map + +/***/ }), + +/***/ 63030: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminAddUserToGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Adds the specified user to the specified group.
+ *Calling this action requires developer credentials.
+ */ +class AdminAddUserToGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminAddUserToGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminAddUserToGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminAddUserToGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminAddUserToGroupCommand(output, context); + } +} +exports.AdminAddUserToGroupCommand = AdminAddUserToGroupCommand; +//# sourceMappingURL=AdminAddUserToGroupCommand.js.map + +/***/ }), + +/***/ 8330: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminConfirmSignUpCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Confirms user registration as an admin without using a confirmation code. Works on any + * user.
+ *Calling this action requires developer credentials.
+ */ +class AdminConfirmSignUpCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminConfirmSignUpCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminConfirmSignUpRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminConfirmSignUpResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminConfirmSignUpCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminConfirmSignUpCommand(output, context); + } +} +exports.AdminConfirmSignUpCommand = AdminConfirmSignUpCommand; +//# sourceMappingURL=AdminConfirmSignUpCommand.js.map + +/***/ }), + +/***/ 18188: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminCreateUserCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a new user in the specified user pool.
+ *If MessageAction
is not set, the default is to send a welcome message via
+ * email or phone (SMS).
This message is based on a template that you configured in your call to create or + * update a user pool. This template includes your custom sign-up instructions and placeholders + * for user name and temporary password.
+ *Alternatively, you can call AdminCreateUser
with “SUPPRESS” for the
+ * MessageAction
parameter, and Amazon Cognito will not send any email.
In either case, the user will be in the FORCE_CHANGE_PASSWORD
state until
+ * they sign in and change their password.
+ * AdminCreateUser
requires developer credentials.
Deletes the user attributes in a user pool as an administrator. Works on any + * user.
+ *Calling this action requires developer credentials.
+ */ +class AdminDeleteUserAttributesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminDeleteUserAttributesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminDeleteUserAttributesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminDeleteUserAttributesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminDeleteUserAttributesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminDeleteUserAttributesCommand(output, context); + } +} +exports.AdminDeleteUserAttributesCommand = AdminDeleteUserAttributesCommand; +//# sourceMappingURL=AdminDeleteUserAttributesCommand.js.map + +/***/ }), + +/***/ 27623: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminDeleteUserCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a user as an administrator. Works on any user.
+ *Calling this action requires developer credentials.
+ */ +class AdminDeleteUserCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminDeleteUserCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminDeleteUserRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminDeleteUserCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminDeleteUserCommand(output, context); + } +} +exports.AdminDeleteUserCommand = AdminDeleteUserCommand; +//# sourceMappingURL=AdminDeleteUserCommand.js.map + +/***/ }), + +/***/ 24718: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminDisableProviderForUserCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Disables the user from signing in with the specified external (SAML or social)
+ * identity provider. If the user to disable is a Cognito User Pools native username +
+ * password user, they are not permitted to use their password to sign-in. If the user to
+ * disable is a linked external IdP user, any link between that user and an existing user
+ * is removed. The next time the external user (no longer attached to the previously linked
+ * DestinationUser
) signs in, they must create a new user account. See
+ * AdminLinkProviderForUser.
This action is enabled only for admin access and requires developer + * credentials.
+ *The ProviderName
must match the value specified when creating an IdP for
+ * the pool.
To disable a native username + password user, the ProviderName
value must
+ * be Cognito
and the ProviderAttributeName
must be
+ * Cognito_Subject
, with the ProviderAttributeValue
being the
+ * name that is used in the user pool for the user.
The ProviderAttributeName
must always be Cognito_Subject
for
+ * social identity providers. The ProviderAttributeValue
must always be the
+ * exact subject that was used when the user was originally linked as a source user.
For de-linking a SAML identity, there are two scenarios. If the linked identity has
+ * not yet been used to sign-in, the ProviderAttributeName
and
+ * ProviderAttributeValue
must be the same values that were used for the
+ * SourceUser
when the identities were originally linked using
+ * AdminLinkProviderForUser
call. (If the linking was done with
+ * ProviderAttributeName
set to Cognito_Subject
, the same
+ * applies here). However, if the user has already signed in, the
+ * ProviderAttributeName
must be Cognito_Subject
and
+ * ProviderAttributeValue
must be the subject of the SAML
+ * assertion.
Disables the specified user.
+ *Calling this action requires developer credentials.
+ */ +class AdminDisableUserCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminDisableUserCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminDisableUserRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminDisableUserResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminDisableUserCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminDisableUserCommand(output, context); + } +} +exports.AdminDisableUserCommand = AdminDisableUserCommand; +//# sourceMappingURL=AdminDisableUserCommand.js.map + +/***/ }), + +/***/ 78365: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminEnableUserCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Enables the specified user as an administrator. Works on any user.
+ *Calling this action requires developer credentials.
+ */ +class AdminEnableUserCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminEnableUserCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminEnableUserRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminEnableUserResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminEnableUserCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminEnableUserCommand(output, context); + } +} +exports.AdminEnableUserCommand = AdminEnableUserCommand; +//# sourceMappingURL=AdminEnableUserCommand.js.map + +/***/ }), + +/***/ 35436: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminForgetDeviceCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Forgets the device, as an administrator.
+ *Calling this action requires developer credentials.
+ */ +class AdminForgetDeviceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminForgetDeviceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminForgetDeviceRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminForgetDeviceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminForgetDeviceCommand(output, context); + } +} +exports.AdminForgetDeviceCommand = AdminForgetDeviceCommand; +//# sourceMappingURL=AdminForgetDeviceCommand.js.map + +/***/ }), + +/***/ 7451: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminGetDeviceCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the device, as an administrator.
+ *Calling this action requires developer credentials.
+ */ +class AdminGetDeviceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminGetDeviceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminGetDeviceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminGetDeviceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminGetDeviceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminGetDeviceCommand(output, context); + } +} +exports.AdminGetDeviceCommand = AdminGetDeviceCommand; +//# sourceMappingURL=AdminGetDeviceCommand.js.map + +/***/ }), + +/***/ 75054: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminGetUserCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the specified user by user name in a user pool as an administrator. Works on any + * user.
+ *Calling this action requires developer credentials.
+ */ +class AdminGetUserCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminGetUserCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminGetUserRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminGetUserResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminGetUserCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminGetUserCommand(output, context); + } +} +exports.AdminGetUserCommand = AdminGetUserCommand; +//# sourceMappingURL=AdminGetUserCommand.js.map + +/***/ }), + +/***/ 51153: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminInitiateAuthCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Initiates the authentication flow, as an administrator.
+ *Calling this action requires developer credentials.
+ */ +class AdminInitiateAuthCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminInitiateAuthCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminInitiateAuthRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminInitiateAuthResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminInitiateAuthCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminInitiateAuthCommand(output, context); + } +} +exports.AdminInitiateAuthCommand = AdminInitiateAuthCommand; +//# sourceMappingURL=AdminInitiateAuthCommand.js.map + +/***/ }), + +/***/ 31763: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminLinkProviderForUserCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Links an existing user account in a user pool (DestinationUser
) to an
+ * identity from an external identity provider (SourceUser
) based on a
+ * specified attribute name and value from the external identity provider. This allows you
+ * to create a link from the existing user account to an external federated user identity
+ * that has not yet been used to sign in, so that the federated user identity can be used
+ * to sign in as the existing user account.
For example, if there is an existing user with a username and password, this API + * links that user to a federated user identity, so that when the federated user identity + * is used, the user signs in as the existing user account.
+ *The maximum number of federated identities linked to a user is 5.
+ *Because this API allows a user with an external federated identity to sign in as + * an existing user in the user pool, it is critical that it only be used with external + * identity providers and provider attributes that have been trusted by the application + * owner.
+ *This action is enabled only for admin access and requires developer + * credentials.
+ */ +class AdminLinkProviderForUserCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminLinkProviderForUserCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminLinkProviderForUserRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminLinkProviderForUserResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminLinkProviderForUserCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminLinkProviderForUserCommand(output, context); + } +} +exports.AdminLinkProviderForUserCommand = AdminLinkProviderForUserCommand; +//# sourceMappingURL=AdminLinkProviderForUserCommand.js.map + +/***/ }), + +/***/ 18926: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminListDevicesCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists devices, as an administrator.
+ *Calling this action requires developer credentials.
+ */ +class AdminListDevicesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminListDevicesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminListDevicesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminListDevicesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminListDevicesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminListDevicesCommand(output, context); + } +} +exports.AdminListDevicesCommand = AdminListDevicesCommand; +//# sourceMappingURL=AdminListDevicesCommand.js.map + +/***/ }), + +/***/ 4199: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminListGroupsForUserCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the groups that the user belongs to.
+ *Calling this action requires developer credentials.
+ */ +class AdminListGroupsForUserCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminListGroupsForUserCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminListGroupsForUserRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminListGroupsForUserResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminListGroupsForUserCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminListGroupsForUserCommand(output, context); + } +} +exports.AdminListGroupsForUserCommand = AdminListGroupsForUserCommand; +//# sourceMappingURL=AdminListGroupsForUserCommand.js.map + +/***/ }), + +/***/ 76132: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminListUserAuthEventsCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists a history of user activity and any risks detected as part of Amazon Cognito + * advanced security.
+ */ +class AdminListUserAuthEventsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminListUserAuthEventsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminListUserAuthEventsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminListUserAuthEventsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminListUserAuthEventsCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminListUserAuthEventsCommand(output, context); + } +} +exports.AdminListUserAuthEventsCommand = AdminListUserAuthEventsCommand; +//# sourceMappingURL=AdminListUserAuthEventsCommand.js.map + +/***/ }), + +/***/ 9640: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminRemoveUserFromGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Removes the specified user from the specified group.
+ *Calling this action requires developer credentials.
+ */ +class AdminRemoveUserFromGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminRemoveUserFromGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminRemoveUserFromGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminRemoveUserFromGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminRemoveUserFromGroupCommand(output, context); + } +} +exports.AdminRemoveUserFromGroupCommand = AdminRemoveUserFromGroupCommand; +//# sourceMappingURL=AdminRemoveUserFromGroupCommand.js.map + +/***/ }), + +/***/ 12557: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminResetUserPasswordCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Resets the specified user's password in a user pool as an administrator. Works on any + * user.
+ *When a developer calls this API, the current password is invalidated, so it must be + * changed. If a user tries to sign in after the API is called, the app will get a + * PasswordResetRequiredException exception back and should direct the user down the flow + * to reset the password, which is the same as the forgot password flow. In addition, if + * the user pool has phone verification selected and a verified phone number exists for the + * user, or if email verification is selected and a verified email exists for the user, + * calling this API will also result in sending a message to the end user with the code to + * change their password.
+ *Calling this action requires developer credentials.
+ */ +class AdminResetUserPasswordCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminResetUserPasswordCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminResetUserPasswordRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminResetUserPasswordResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminResetUserPasswordCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminResetUserPasswordCommand(output, context); + } +} +exports.AdminResetUserPasswordCommand = AdminResetUserPasswordCommand; +//# sourceMappingURL=AdminResetUserPasswordCommand.js.map + +/***/ }), + +/***/ 21828: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminRespondToAuthChallengeCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Responds to an authentication challenge, as an administrator.
+ *Calling this action requires developer credentials.
+ */ +class AdminRespondToAuthChallengeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminRespondToAuthChallengeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminRespondToAuthChallengeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminRespondToAuthChallengeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminRespondToAuthChallengeCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminRespondToAuthChallengeCommand(output, context); + } +} +exports.AdminRespondToAuthChallengeCommand = AdminRespondToAuthChallengeCommand; +//# sourceMappingURL=AdminRespondToAuthChallengeCommand.js.map + +/***/ }), + +/***/ 13421: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminSetUserMFAPreferenceCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Sets the user's multi-factor authentication (MFA) preference, including which MFA + * options are enabled and if any are preferred. Only one factor can be set as preferred. + * The preferred MFA factor will be used to authenticate a user if multiple factors are + * enabled. If multiple options are enabled and no preference is set, a challenge to choose + * an MFA option will be returned during sign in.
+ */ +class AdminSetUserMFAPreferenceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminSetUserMFAPreferenceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminSetUserMFAPreferenceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminSetUserMFAPreferenceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminSetUserMFAPreferenceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminSetUserMFAPreferenceCommand(output, context); + } +} +exports.AdminSetUserMFAPreferenceCommand = AdminSetUserMFAPreferenceCommand; +//# sourceMappingURL=AdminSetUserMFAPreferenceCommand.js.map + +/***/ }), + +/***/ 75616: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminSetUserPasswordCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Sets the specified user's password in a user pool as an administrator. Works on any + * user.
+ *The password can be temporary or permanent. If it is temporary, the user status will
+ * be placed into the FORCE_CHANGE_PASSWORD
state. When the user next tries to
+ * sign in, the InitiateAuth/AdminInitiateAuth response will contain the
+ * NEW_PASSWORD_REQUIRED
challenge. If the user does not sign in before it
+ * expires, the user will not be able to sign in and their password will need to be reset
+ * by an administrator.
Once the user has set a new password, or the password is permanent, the user status
+ * will be set to Confirmed
.
+ * This action is no longer supported. You can use it to configure + * only SMS MFA. You can't use it to configure TOTP software token MFA. To configure either + * type of MFA, use AdminSetUserMFAPreference instead.
+ */ +class AdminSetUserSettingsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminSetUserSettingsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminSetUserSettingsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminSetUserSettingsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminSetUserSettingsCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminSetUserSettingsCommand(output, context); + } +} +exports.AdminSetUserSettingsCommand = AdminSetUserSettingsCommand; +//# sourceMappingURL=AdminSetUserSettingsCommand.js.map + +/***/ }), + +/***/ 57675: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminUpdateAuthEventFeedbackCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Provides feedback for an authentication event as to whether it was from a valid user. + * This feedback is used for improving the risk evaluation decision for the user pool as + * part of Amazon Cognito advanced security.
+ */ +class AdminUpdateAuthEventFeedbackCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminUpdateAuthEventFeedbackCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminUpdateAuthEventFeedbackRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminUpdateAuthEventFeedbackResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminUpdateAuthEventFeedbackCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminUpdateAuthEventFeedbackCommand(output, context); + } +} +exports.AdminUpdateAuthEventFeedbackCommand = AdminUpdateAuthEventFeedbackCommand; +//# sourceMappingURL=AdminUpdateAuthEventFeedbackCommand.js.map + +/***/ }), + +/***/ 18824: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminUpdateDeviceStatusCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the device status as an administrator.
+ *Calling this action requires developer credentials.
+ */ +class AdminUpdateDeviceStatusCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminUpdateDeviceStatusCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminUpdateDeviceStatusRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminUpdateDeviceStatusResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminUpdateDeviceStatusCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminUpdateDeviceStatusCommand(output, context); + } +} +exports.AdminUpdateDeviceStatusCommand = AdminUpdateDeviceStatusCommand; +//# sourceMappingURL=AdminUpdateDeviceStatusCommand.js.map + +/***/ }), + +/***/ 1541: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminUpdateUserAttributesCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the specified user's attributes, including developer attributes, as an + * administrator. Works on any user.
+ *For custom attributes, you must prepend the custom:
prefix to the
+ * attribute name.
In addition to updating user attributes, this API can also be used to mark phone and + * email as verified.
+ *Calling this action requires developer credentials.
+ */ +class AdminUpdateUserAttributesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminUpdateUserAttributesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminUpdateUserAttributesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminUpdateUserAttributesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminUpdateUserAttributesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminUpdateUserAttributesCommand(output, context); + } +} +exports.AdminUpdateUserAttributesCommand = AdminUpdateUserAttributesCommand; +//# sourceMappingURL=AdminUpdateUserAttributesCommand.js.map + +/***/ }), + +/***/ 11240: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminUserGlobalSignOutCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Signs out users from all devices, as an administrator. It also invalidates all refresh + * tokens issued to a user. The user's current access and Id tokens remain valid until + * their expiry. Access and Id tokens expire one hour after they are issued.
+ *Calling this action requires developer credentials.
+ */ +class AdminUserGlobalSignOutCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AdminUserGlobalSignOutCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AdminUserGlobalSignOutRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AdminUserGlobalSignOutResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AdminUserGlobalSignOutCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AdminUserGlobalSignOutCommand(output, context); + } +} +exports.AdminUserGlobalSignOutCommand = AdminUserGlobalSignOutCommand; +//# sourceMappingURL=AdminUserGlobalSignOutCommand.js.map + +/***/ }), + +/***/ 52819: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AssociateSoftwareTokenCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns a unique generated shared secret key code for the user account. The request + * takes an access token or a session string, but not both.
+ */ +class AssociateSoftwareTokenCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "AssociateSoftwareTokenCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AssociateSoftwareTokenRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AssociateSoftwareTokenResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1AssociateSoftwareTokenCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1AssociateSoftwareTokenCommand(output, context); + } +} +exports.AssociateSoftwareTokenCommand = AssociateSoftwareTokenCommand; +//# sourceMappingURL=AssociateSoftwareTokenCommand.js.map + +/***/ }), + +/***/ 65801: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ChangePasswordCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Changes the password for a specified user in a user pool.
+ */ +class ChangePasswordCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ChangePasswordCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ChangePasswordRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ChangePasswordResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ChangePasswordCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ChangePasswordCommand(output, context); + } +} +exports.ChangePasswordCommand = ChangePasswordCommand; +//# sourceMappingURL=ChangePasswordCommand.js.map + +/***/ }), + +/***/ 79275: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ConfirmDeviceCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Confirms tracking of the device. This API call is the call that begins device + * tracking.
+ */ +class ConfirmDeviceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ConfirmDeviceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ConfirmDeviceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ConfirmDeviceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ConfirmDeviceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ConfirmDeviceCommand(output, context); + } +} +exports.ConfirmDeviceCommand = ConfirmDeviceCommand; +//# sourceMappingURL=ConfirmDeviceCommand.js.map + +/***/ }), + +/***/ 35665: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ConfirmForgotPasswordCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Allows a user to enter a confirmation code to reset a forgotten password.
+ */ +class ConfirmForgotPasswordCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ConfirmForgotPasswordCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ConfirmForgotPasswordRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ConfirmForgotPasswordResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ConfirmForgotPasswordCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ConfirmForgotPasswordCommand(output, context); + } +} +exports.ConfirmForgotPasswordCommand = ConfirmForgotPasswordCommand; +//# sourceMappingURL=ConfirmForgotPasswordCommand.js.map + +/***/ }), + +/***/ 18104: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ConfirmSignUpCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Confirms registration of a user and handles the existing alias from a previous + * user.
+ */ +class ConfirmSignUpCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ConfirmSignUpCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ConfirmSignUpRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ConfirmSignUpResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ConfirmSignUpCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ConfirmSignUpCommand(output, context); + } +} +exports.ConfirmSignUpCommand = ConfirmSignUpCommand; +//# sourceMappingURL=ConfirmSignUpCommand.js.map + +/***/ }), + +/***/ 81662: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a new group in the specified user pool.
+ *Calling this action requires developer credentials.
+ */ +class CreateGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "CreateGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1CreateGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1CreateGroupCommand(output, context); + } +} +exports.CreateGroupCommand = CreateGroupCommand; +//# sourceMappingURL=CreateGroupCommand.js.map + +/***/ }), + +/***/ 81266: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateIdentityProviderCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates an identity provider for a user pool.
+ */ +class CreateIdentityProviderCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "CreateIdentityProviderCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateIdentityProviderRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateIdentityProviderResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1CreateIdentityProviderCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1CreateIdentityProviderCommand(output, context); + } +} +exports.CreateIdentityProviderCommand = CreateIdentityProviderCommand; +//# sourceMappingURL=CreateIdentityProviderCommand.js.map + +/***/ }), + +/***/ 54935: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateResourceServerCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a new OAuth2.0 resource server and defines custom scopes in it.
+ */ +class CreateResourceServerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "CreateResourceServerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateResourceServerRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateResourceServerResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1CreateResourceServerCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1CreateResourceServerCommand(output, context); + } +} +exports.CreateResourceServerCommand = CreateResourceServerCommand; +//# sourceMappingURL=CreateResourceServerCommand.js.map + +/***/ }), + +/***/ 77974: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateUserImportJobCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates the user import job.
+ */ +class CreateUserImportJobCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "CreateUserImportJobCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateUserImportJobRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateUserImportJobResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1CreateUserImportJobCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1CreateUserImportJobCommand(output, context); + } +} +exports.CreateUserImportJobCommand = CreateUserImportJobCommand; +//# sourceMappingURL=CreateUserImportJobCommand.js.map + +/***/ }), + +/***/ 17824: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateUserPoolClientCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates the user pool client.
+ */ +class CreateUserPoolClientCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "CreateUserPoolClientCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateUserPoolClientRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateUserPoolClientResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1CreateUserPoolClientCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1CreateUserPoolClientCommand(output, context); + } +} +exports.CreateUserPoolClientCommand = CreateUserPoolClientCommand; +//# sourceMappingURL=CreateUserPoolClientCommand.js.map + +/***/ }), + +/***/ 74938: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateUserPoolCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a new Amazon Cognito user pool and sets the password policy for the + * pool.
+ */ +class CreateUserPoolCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "CreateUserPoolCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateUserPoolRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateUserPoolResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1CreateUserPoolCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1CreateUserPoolCommand(output, context); + } +} +exports.CreateUserPoolCommand = CreateUserPoolCommand; +//# sourceMappingURL=CreateUserPoolCommand.js.map + +/***/ }), + +/***/ 58015: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateUserPoolDomainCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a new domain for a user pool.
+ */ +class CreateUserPoolDomainCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "CreateUserPoolDomainCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateUserPoolDomainRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateUserPoolDomainResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1CreateUserPoolDomainCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1CreateUserPoolDomainCommand(output, context); + } +} +exports.CreateUserPoolDomainCommand = CreateUserPoolDomainCommand; +//# sourceMappingURL=CreateUserPoolDomainCommand.js.map + +/***/ }), + +/***/ 73307: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a group. Currently only groups with no members can be deleted.
+ *Calling this action requires developer credentials.
+ */ +class DeleteGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DeleteGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DeleteGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DeleteGroupCommand(output, context); + } +} +exports.DeleteGroupCommand = DeleteGroupCommand; +//# sourceMappingURL=DeleteGroupCommand.js.map + +/***/ }), + +/***/ 7493: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteIdentityProviderCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes an identity provider for a user pool.
+ */ +class DeleteIdentityProviderCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DeleteIdentityProviderCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteIdentityProviderRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DeleteIdentityProviderCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DeleteIdentityProviderCommand(output, context); + } +} +exports.DeleteIdentityProviderCommand = DeleteIdentityProviderCommand; +//# sourceMappingURL=DeleteIdentityProviderCommand.js.map + +/***/ }), + +/***/ 6049: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteResourceServerCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a resource server.
+ */ +class DeleteResourceServerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DeleteResourceServerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteResourceServerRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DeleteResourceServerCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DeleteResourceServerCommand(output, context); + } +} +exports.DeleteResourceServerCommand = DeleteResourceServerCommand; +//# sourceMappingURL=DeleteResourceServerCommand.js.map + +/***/ }), + +/***/ 99475: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteUserAttributesCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the attributes for a user.
+ */ +class DeleteUserAttributesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DeleteUserAttributesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteUserAttributesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteUserAttributesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DeleteUserAttributesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DeleteUserAttributesCommand(output, context); + } +} +exports.DeleteUserAttributesCommand = DeleteUserAttributesCommand; +//# sourceMappingURL=DeleteUserAttributesCommand.js.map + +/***/ }), + +/***/ 28421: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteUserCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Allows a user to delete himself or herself.
+ */ +class DeleteUserCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DeleteUserCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteUserRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DeleteUserCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DeleteUserCommand(output, context); + } +} +exports.DeleteUserCommand = DeleteUserCommand; +//# sourceMappingURL=DeleteUserCommand.js.map + +/***/ }), + +/***/ 3402: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteUserPoolClientCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Allows the developer to delete the user pool client.
+ */ +class DeleteUserPoolClientCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DeleteUserPoolClientCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteUserPoolClientRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DeleteUserPoolClientCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DeleteUserPoolClientCommand(output, context); + } +} +exports.DeleteUserPoolClientCommand = DeleteUserPoolClientCommand; +//# sourceMappingURL=DeleteUserPoolClientCommand.js.map + +/***/ }), + +/***/ 92314: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteUserPoolCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the specified Amazon Cognito user pool.
+ */ +class DeleteUserPoolCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DeleteUserPoolCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteUserPoolRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DeleteUserPoolCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DeleteUserPoolCommand(output, context); + } +} +exports.DeleteUserPoolCommand = DeleteUserPoolCommand; +//# sourceMappingURL=DeleteUserPoolCommand.js.map + +/***/ }), + +/***/ 79680: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteUserPoolDomainCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a domain for a user pool.
+ */ +class DeleteUserPoolDomainCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DeleteUserPoolDomainCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteUserPoolDomainRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteUserPoolDomainResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DeleteUserPoolDomainCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DeleteUserPoolDomainCommand(output, context); + } +} +exports.DeleteUserPoolDomainCommand = DeleteUserPoolDomainCommand; +//# sourceMappingURL=DeleteUserPoolDomainCommand.js.map + +/***/ }), + +/***/ 96582: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeIdentityProviderCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about a specific identity provider.
+ */ +class DescribeIdentityProviderCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DescribeIdentityProviderCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeIdentityProviderRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeIdentityProviderResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DescribeIdentityProviderCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DescribeIdentityProviderCommand(output, context); + } +} +exports.DescribeIdentityProviderCommand = DescribeIdentityProviderCommand; +//# sourceMappingURL=DescribeIdentityProviderCommand.js.map + +/***/ }), + +/***/ 13045: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeResourceServerCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes a resource server.
+ */ +class DescribeResourceServerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DescribeResourceServerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeResourceServerRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeResourceServerResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DescribeResourceServerCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DescribeResourceServerCommand(output, context); + } +} +exports.DescribeResourceServerCommand = DescribeResourceServerCommand; +//# sourceMappingURL=DescribeResourceServerCommand.js.map + +/***/ }), + +/***/ 51063: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeRiskConfigurationCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes the risk configuration.
+ */ +class DescribeRiskConfigurationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DescribeRiskConfigurationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeRiskConfigurationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeRiskConfigurationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DescribeRiskConfigurationCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DescribeRiskConfigurationCommand(output, context); + } +} +exports.DescribeRiskConfigurationCommand = DescribeRiskConfigurationCommand; +//# sourceMappingURL=DescribeRiskConfigurationCommand.js.map + +/***/ }), + +/***/ 10902: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeUserImportJobCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes the user import job.
+ */ +class DescribeUserImportJobCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DescribeUserImportJobCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeUserImportJobRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeUserImportJobResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DescribeUserImportJobCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DescribeUserImportJobCommand(output, context); + } +} +exports.DescribeUserImportJobCommand = DescribeUserImportJobCommand; +//# sourceMappingURL=DescribeUserImportJobCommand.js.map + +/***/ }), + +/***/ 25424: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeUserPoolClientCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Client method for returning the configuration information and metadata of the + * specified user pool app client.
+ */ +class DescribeUserPoolClientCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DescribeUserPoolClientCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeUserPoolClientRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeUserPoolClientResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DescribeUserPoolClientCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DescribeUserPoolClientCommand(output, context); + } +} +exports.DescribeUserPoolClientCommand = DescribeUserPoolClientCommand; +//# sourceMappingURL=DescribeUserPoolClientCommand.js.map + +/***/ }), + +/***/ 67125: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeUserPoolCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns the configuration information and metadata of the specified user pool.
+ */ +class DescribeUserPoolCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DescribeUserPoolCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeUserPoolRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeUserPoolResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DescribeUserPoolCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DescribeUserPoolCommand(output, context); + } +} +exports.DescribeUserPoolCommand = DescribeUserPoolCommand; +//# sourceMappingURL=DescribeUserPoolCommand.js.map + +/***/ }), + +/***/ 9253: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeUserPoolDomainCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about a domain.
+ */ +class DescribeUserPoolDomainCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "DescribeUserPoolDomainCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeUserPoolDomainRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeUserPoolDomainResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DescribeUserPoolDomainCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DescribeUserPoolDomainCommand(output, context); + } +} +exports.DescribeUserPoolDomainCommand = DescribeUserPoolDomainCommand; +//# sourceMappingURL=DescribeUserPoolDomainCommand.js.map + +/***/ }), + +/***/ 39305: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ForgetDeviceCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Forgets the specified device.
+ */ +class ForgetDeviceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ForgetDeviceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ForgetDeviceRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ForgetDeviceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ForgetDeviceCommand(output, context); + } +} +exports.ForgetDeviceCommand = ForgetDeviceCommand; +//# sourceMappingURL=ForgetDeviceCommand.js.map + +/***/ }), + +/***/ 15806: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ForgotPasswordCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Calling this API causes a message to be sent to the end user with a confirmation code
+ * that is required to change the user's password. For the Username
parameter,
+ * you can use the username or user alias. The method used to send the confirmation code is
+ * sent according to the specified AccountRecoverySetting. For more information, see Recovering User Accounts in the Amazon Cognito Developer Guide.
+ * If neither a verified phone number nor a verified email exists, an
+ * InvalidParameterException
is thrown. To use the confirmation code for
+ * resetting the password, call ConfirmForgotPassword.
Gets the header information for the .csv file to be used as input for the user import + * job.
+ */ +class GetCSVHeaderCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "GetCSVHeaderCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetCSVHeaderRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetCSVHeaderResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetCSVHeaderCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetCSVHeaderCommand(output, context); + } +} +exports.GetCSVHeaderCommand = GetCSVHeaderCommand; +//# sourceMappingURL=GetCSVHeaderCommand.js.map + +/***/ }), + +/***/ 95242: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetDeviceCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the device.
+ */ +class GetDeviceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "GetDeviceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetDeviceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetDeviceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetDeviceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetDeviceCommand(output, context); + } +} +exports.GetDeviceCommand = GetDeviceCommand; +//# sourceMappingURL=GetDeviceCommand.js.map + +/***/ }), + +/***/ 89462: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets a group.
+ *Calling this action requires developer credentials.
+ */ +class GetGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "GetGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetGroupCommand(output, context); + } +} +exports.GetGroupCommand = GetGroupCommand; +//# sourceMappingURL=GetGroupCommand.js.map + +/***/ }), + +/***/ 29528: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetIdentityProviderByIdentifierCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the specified identity provider.
+ */ +class GetIdentityProviderByIdentifierCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "GetIdentityProviderByIdentifierCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetIdentityProviderByIdentifierRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetIdentityProviderByIdentifierResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetIdentityProviderByIdentifierCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetIdentityProviderByIdentifierCommand(output, context); + } +} +exports.GetIdentityProviderByIdentifierCommand = GetIdentityProviderByIdentifierCommand; +//# sourceMappingURL=GetIdentityProviderByIdentifierCommand.js.map + +/***/ }), + +/***/ 7884: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetSigningCertificateCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *This method takes a user pool ID, and returns the signing certificate.
+ */ +class GetSigningCertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "GetSigningCertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetSigningCertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetSigningCertificateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetSigningCertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetSigningCertificateCommand(output, context); + } +} +exports.GetSigningCertificateCommand = GetSigningCertificateCommand; +//# sourceMappingURL=GetSigningCertificateCommand.js.map + +/***/ }), + +/***/ 47556: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetUICustomizationCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the UI Customization information for a particular app client's app UI, if there
+ * is something set. If nothing is set for the particular client, but there is an existing
+ * pool level customization (app clientId
will be ALL
), then that
+ * is returned. If nothing is present, then an empty shape is returned.
Gets the user attribute verification code for the specified attribute name.
+ */ +class GetUserAttributeVerificationCodeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "GetUserAttributeVerificationCodeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetUserAttributeVerificationCodeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetUserAttributeVerificationCodeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetUserAttributeVerificationCodeCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetUserAttributeVerificationCodeCommand(output, context); + } +} +exports.GetUserAttributeVerificationCodeCommand = GetUserAttributeVerificationCodeCommand; +//# sourceMappingURL=GetUserAttributeVerificationCodeCommand.js.map + +/***/ }), + +/***/ 33079: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetUserCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the user attributes and metadata for a user.
+ */ +class GetUserCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "GetUserCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetUserRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetUserResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetUserCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetUserCommand(output, context); + } +} +exports.GetUserCommand = GetUserCommand; +//# sourceMappingURL=GetUserCommand.js.map + +/***/ }), + +/***/ 59598: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetUserPoolMfaConfigCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the user pool multi-factor authentication (MFA) configuration.
+ */ +class GetUserPoolMfaConfigCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "GetUserPoolMfaConfigCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetUserPoolMfaConfigRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetUserPoolMfaConfigResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetUserPoolMfaConfigCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetUserPoolMfaConfigCommand(output, context); + } +} +exports.GetUserPoolMfaConfigCommand = GetUserPoolMfaConfigCommand; +//# sourceMappingURL=GetUserPoolMfaConfigCommand.js.map + +/***/ }), + +/***/ 783: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GlobalSignOutCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Signs out users from all devices. It also invalidates all refresh tokens issued to a + * user. The user's current access and Id tokens remain valid until their expiry. Access + * and Id tokens expire one hour after they are issued.
+ */ +class GlobalSignOutCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "GlobalSignOutCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GlobalSignOutRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GlobalSignOutResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GlobalSignOutCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GlobalSignOutCommand(output, context); + } +} +exports.GlobalSignOutCommand = GlobalSignOutCommand; +//# sourceMappingURL=GlobalSignOutCommand.js.map + +/***/ }), + +/***/ 25210: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.InitiateAuthCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Initiates the authentication flow.
+ */ +class InitiateAuthCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "InitiateAuthCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.InitiateAuthRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.InitiateAuthResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1InitiateAuthCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1InitiateAuthCommand(output, context); + } +} +exports.InitiateAuthCommand = InitiateAuthCommand; +//# sourceMappingURL=InitiateAuthCommand.js.map + +/***/ }), + +/***/ 41445: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListDevicesCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the devices.
+ */ +class ListDevicesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ListDevicesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListDevicesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListDevicesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListDevicesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListDevicesCommand(output, context); + } +} +exports.ListDevicesCommand = ListDevicesCommand; +//# sourceMappingURL=ListDevicesCommand.js.map + +/***/ }), + +/***/ 39386: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListGroupsCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the groups associated with a user pool.
+ *Calling this action requires developer credentials.
+ */ +class ListGroupsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ListGroupsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListGroupsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListGroupsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListGroupsCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListGroupsCommand(output, context); + } +} +exports.ListGroupsCommand = ListGroupsCommand; +//# sourceMappingURL=ListGroupsCommand.js.map + +/***/ }), + +/***/ 73419: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListIdentityProvidersCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists information about all identity providers for a user pool.
+ */ +class ListIdentityProvidersCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ListIdentityProvidersCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListIdentityProvidersRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListIdentityProvidersResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListIdentityProvidersCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListIdentityProvidersCommand(output, context); + } +} +exports.ListIdentityProvidersCommand = ListIdentityProvidersCommand; +//# sourceMappingURL=ListIdentityProvidersCommand.js.map + +/***/ }), + +/***/ 93783: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListResourceServersCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the resource servers for a user pool.
+ */ +class ListResourceServersCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ListResourceServersCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListResourceServersRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListResourceServersResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListResourceServersCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListResourceServersCommand(output, context); + } +} +exports.ListResourceServersCommand = ListResourceServersCommand; +//# sourceMappingURL=ListResourceServersCommand.js.map + +/***/ }), + +/***/ 22658: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListTagsForResourceCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the tags that are assigned to an Amazon Cognito user pool.
+ *A tag is a label that you can apply to user pools to categorize and manage them in + * different ways, such as by purpose, owner, environment, or other criteria.
+ *You can use this action up to 10 times per second, per account.
+ */ +class ListTagsForResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ListTagsForResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListTagsForResourceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListTagsForResourceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListTagsForResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListTagsForResourceCommand(output, context); + } +} +exports.ListTagsForResourceCommand = ListTagsForResourceCommand; +//# sourceMappingURL=ListTagsForResourceCommand.js.map + +/***/ }), + +/***/ 86421: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListUserImportJobsCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the user import jobs.
+ */ +class ListUserImportJobsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ListUserImportJobsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListUserImportJobsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListUserImportJobsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListUserImportJobsCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListUserImportJobsCommand(output, context); + } +} +exports.ListUserImportJobsCommand = ListUserImportJobsCommand; +//# sourceMappingURL=ListUserImportJobsCommand.js.map + +/***/ }), + +/***/ 87753: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListUserPoolClientsCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the clients that have been created for the specified user pool.
+ */ +class ListUserPoolClientsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ListUserPoolClientsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListUserPoolClientsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListUserPoolClientsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListUserPoolClientsCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListUserPoolClientsCommand(output, context); + } +} +exports.ListUserPoolClientsCommand = ListUserPoolClientsCommand; +//# sourceMappingURL=ListUserPoolClientsCommand.js.map + +/***/ }), + +/***/ 51756: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListUserPoolsCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the user pools associated with an AWS account.
+ */ +class ListUserPoolsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ListUserPoolsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListUserPoolsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListUserPoolsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListUserPoolsCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListUserPoolsCommand(output, context); + } +} +exports.ListUserPoolsCommand = ListUserPoolsCommand; +//# sourceMappingURL=ListUserPoolsCommand.js.map + +/***/ }), + +/***/ 16854: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListUsersCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the users in the Amazon Cognito user pool.
+ */ +class ListUsersCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ListUsersCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListUsersRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListUsersResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListUsersCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListUsersCommand(output, context); + } +} +exports.ListUsersCommand = ListUsersCommand; +//# sourceMappingURL=ListUsersCommand.js.map + +/***/ }), + +/***/ 51577: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListUsersInGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the users in the specified group.
+ *Calling this action requires developer credentials.
+ */ +class ListUsersInGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ListUsersInGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListUsersInGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListUsersInGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListUsersInGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListUsersInGroupCommand(output, context); + } +} +exports.ListUsersInGroupCommand = ListUsersInGroupCommand; +//# sourceMappingURL=ListUsersInGroupCommand.js.map + +/***/ }), + +/***/ 30730: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ResendConfirmationCodeCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Resends the confirmation (for confirmation of registration) to a specific user in the + * user pool.
+ */ +class ResendConfirmationCodeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "ResendConfirmationCodeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ResendConfirmationCodeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ResendConfirmationCodeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ResendConfirmationCodeCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ResendConfirmationCodeCommand(output, context); + } +} +exports.ResendConfirmationCodeCommand = ResendConfirmationCodeCommand; +//# sourceMappingURL=ResendConfirmationCodeCommand.js.map + +/***/ }), + +/***/ 36946: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.RespondToAuthChallengeCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Responds to the authentication challenge.
+ */ +class RespondToAuthChallengeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "RespondToAuthChallengeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.RespondToAuthChallengeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.RespondToAuthChallengeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1RespondToAuthChallengeCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1RespondToAuthChallengeCommand(output, context); + } +} +exports.RespondToAuthChallengeCommand = RespondToAuthChallengeCommand; +//# sourceMappingURL=RespondToAuthChallengeCommand.js.map + +/***/ }), + +/***/ 54210: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SetRiskConfigurationCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Configures actions on detected risks. To delete the risk configuration for
+ * UserPoolId
or ClientId
, pass null values for all four
+ * configuration types.
To enable Amazon Cognito advanced security features, update the user pool to include
+ * the UserPoolAddOns
keyAdvancedSecurityMode
.
Sets the UI customization information for a user pool's built-in app UI.
+ *You can specify app UI customization settings for a single client (with a specific
+ * clientId
) or for all clients (by setting the clientId
to
+ * ALL
). If you specify ALL
, the default configuration will
+ * be used for every client that has no UI customization set previously. If you specify UI
+ * customization settings for a particular client, it will no longer fall back to the
+ * ALL
configuration.
To use this API, your user pool must have a domain associated with it. Otherwise, + * there is no place to host the app's pages, and the service will throw an + * error.
+ *Set the user's multi-factor authentication (MFA) method preference, including which + * MFA factors are enabled and if any are preferred. Only one factor can be set as + * preferred. The preferred MFA factor will be used to authenticate a user if multiple + * factors are enabled. If multiple options are enabled and no preference is set, a + * challenge to choose an MFA option will be returned during sign in. If an MFA type is enabled for a user, the user will be prompted for MFA during all sign in attempts, + * unless device tracking is turned on and the device has been trusted. + * If you would like MFA to be applied selectively based on the assessed risk level of sign in attempts, disable MFA for users and turn on Adaptive Authentication for the user pool.
+ */ +class SetUserMFAPreferenceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "SetUserMFAPreferenceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.SetUserMFAPreferenceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.SetUserMFAPreferenceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1SetUserMFAPreferenceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1SetUserMFAPreferenceCommand(output, context); + } +} +exports.SetUserMFAPreferenceCommand = SetUserMFAPreferenceCommand; +//# sourceMappingURL=SetUserMFAPreferenceCommand.js.map + +/***/ }), + +/***/ 39776: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SetUserPoolMfaConfigCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Set the user pool multi-factor authentication (MFA) configuration.
+ */ +class SetUserPoolMfaConfigCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "SetUserPoolMfaConfigCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.SetUserPoolMfaConfigRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.SetUserPoolMfaConfigResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1SetUserPoolMfaConfigCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1SetUserPoolMfaConfigCommand(output, context); + } +} +exports.SetUserPoolMfaConfigCommand = SetUserPoolMfaConfigCommand; +//# sourceMappingURL=SetUserPoolMfaConfigCommand.js.map + +/***/ }), + +/***/ 44103: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SetUserSettingsCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *+ * This action is no longer supported. You can use it to configure + * only SMS MFA. You can't use it to configure TOTP software token MFA. To configure either + * type of MFA, use SetUserMFAPreference instead.
+ */ +class SetUserSettingsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "SetUserSettingsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.SetUserSettingsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.SetUserSettingsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1SetUserSettingsCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1SetUserSettingsCommand(output, context); + } +} +exports.SetUserSettingsCommand = SetUserSettingsCommand; +//# sourceMappingURL=SetUserSettingsCommand.js.map + +/***/ }), + +/***/ 61298: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SignUpCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Registers the user in the specified user pool and creates a user name, password, and + * user attributes.
+ */ +class SignUpCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "SignUpCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.SignUpRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.SignUpResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1SignUpCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1SignUpCommand(output, context); + } +} +exports.SignUpCommand = SignUpCommand; +//# sourceMappingURL=SignUpCommand.js.map + +/***/ }), + +/***/ 8066: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.StartUserImportJobCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Starts the user import.
+ */ +class StartUserImportJobCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "StartUserImportJobCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.StartUserImportJobRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.StartUserImportJobResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1StartUserImportJobCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1StartUserImportJobCommand(output, context); + } +} +exports.StartUserImportJobCommand = StartUserImportJobCommand; +//# sourceMappingURL=StartUserImportJobCommand.js.map + +/***/ }), + +/***/ 47546: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.StopUserImportJobCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Stops the user import job.
+ */ +class StopUserImportJobCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "StopUserImportJobCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.StopUserImportJobRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.StopUserImportJobResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1StopUserImportJobCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1StopUserImportJobCommand(output, context); + } +} +exports.StopUserImportJobCommand = StopUserImportJobCommand; +//# sourceMappingURL=StopUserImportJobCommand.js.map + +/***/ }), + +/***/ 13116: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.TagResourceCommand = void 0; +const models_0_1 = __nccwpck_require__(38771); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Assigns a set of tags to an Amazon Cognito user pool. A tag is a label that you can + * use to categorize and manage user pools in different ways, such as by purpose, owner, + * environment, or other criteria.
+ *Each tag consists of a key and value, both of which you define. A key is a general
+ * category for more specific values. For example, if you have two versions of a user pool,
+ * one for testing and another for production, you might assign an Environment
+ * tag key to both user pools. The value of this key might be Test
for one
+ * user pool and Production
for the other.
Tags are useful for cost tracking and access control. You can activate your tags so + * that they appear on the Billing and Cost Management console, where you can track the + * costs associated with your user pools. In an IAM policy, you can constrain permissions + * for user pools based on specific tags or tag values.
+ *You can use this action up to 5 times per second, per account. A user pool can have as + * many as 50 tags.
+ */ +class TagResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "TagResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.TagResourceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.TagResourceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1TagResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1TagResourceCommand(output, context); + } +} +exports.TagResourceCommand = TagResourceCommand; +//# sourceMappingURL=TagResourceCommand.js.map + +/***/ }), + +/***/ 93194: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UntagResourceCommand = void 0; +const models_1_1 = __nccwpck_require__(1086); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Removes the specified tags from an Amazon Cognito user pool. You can use this action + * up to 5 times per second, per account
+ */ +class UntagResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "UntagResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.UntagResourceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.UntagResourceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1UntagResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1UntagResourceCommand(output, context); + } +} +exports.UntagResourceCommand = UntagResourceCommand; +//# sourceMappingURL=UntagResourceCommand.js.map + +/***/ }), + +/***/ 45344: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateAuthEventFeedbackCommand = void 0; +const models_1_1 = __nccwpck_require__(1086); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Provides the feedback for an authentication event whether it was from a valid user or + * not. This feedback is used for improving the risk evaluation decision for the user pool + * as part of Amazon Cognito advanced security.
+ */ +class UpdateAuthEventFeedbackCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "UpdateAuthEventFeedbackCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.UpdateAuthEventFeedbackRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.UpdateAuthEventFeedbackResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1UpdateAuthEventFeedbackCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1UpdateAuthEventFeedbackCommand(output, context); + } +} +exports.UpdateAuthEventFeedbackCommand = UpdateAuthEventFeedbackCommand; +//# sourceMappingURL=UpdateAuthEventFeedbackCommand.js.map + +/***/ }), + +/***/ 34181: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateDeviceStatusCommand = void 0; +const models_1_1 = __nccwpck_require__(1086); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the device status.
+ */ +class UpdateDeviceStatusCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "UpdateDeviceStatusCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.UpdateDeviceStatusRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.UpdateDeviceStatusResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1UpdateDeviceStatusCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1UpdateDeviceStatusCommand(output, context); + } +} +exports.UpdateDeviceStatusCommand = UpdateDeviceStatusCommand; +//# sourceMappingURL=UpdateDeviceStatusCommand.js.map + +/***/ }), + +/***/ 17637: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateGroupCommand = void 0; +const models_1_1 = __nccwpck_require__(1086); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the specified group with the specified attributes.
+ *Calling this action requires developer credentials.
+ *If you don't provide a value for an attribute, it will be set to the default + * value.
+ *Updates identity provider information for a user pool.
+ */ +class UpdateIdentityProviderCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "UpdateIdentityProviderCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.UpdateIdentityProviderRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.UpdateIdentityProviderResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1UpdateIdentityProviderCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1UpdateIdentityProviderCommand(output, context); + } +} +exports.UpdateIdentityProviderCommand = UpdateIdentityProviderCommand; +//# sourceMappingURL=UpdateIdentityProviderCommand.js.map + +/***/ }), + +/***/ 42116: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateResourceServerCommand = void 0; +const models_1_1 = __nccwpck_require__(1086); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the name and scopes of resource server. All other fields are read-only.
+ *If you don't provide a value for an attribute, it will be set to the default + * value.
+ *Allows a user to update a specific attribute (one at a time).
+ */ +class UpdateUserAttributesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "UpdateUserAttributesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.UpdateUserAttributesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.UpdateUserAttributesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1UpdateUserAttributesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1UpdateUserAttributesCommand(output, context); + } +} +exports.UpdateUserAttributesCommand = UpdateUserAttributesCommand; +//# sourceMappingURL=UpdateUserAttributesCommand.js.map + +/***/ }), + +/***/ 94287: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateUserPoolClientCommand = void 0; +const models_1_1 = __nccwpck_require__(1086); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the specified user pool app client with the specified attributes. You can get + * a list of the current user pool app client settings using DescribeUserPoolClient.
+ *If you don't provide a value for an attribute, it will be set to the default + * value.
+ *Updates the specified user pool with the specified attributes. You can get a list of + * the current user pool settings using DescribeUserPool.
+ *If you don't provide a value for an attribute, it will be set to the default + * value.
+ *Updates the Secure Sockets Layer (SSL) certificate for the custom domain for your user + * pool.
+ *You can use this operation to provide the Amazon Resource Name (ARN) of a new + * certificate to Amazon Cognito. You cannot use it to change the domain for a user + * pool.
+ *A custom domain is used to host the Amazon Cognito hosted UI, which provides sign-up + * and sign-in pages for your application. When you set up a custom domain, you provide a + * certificate that you manage with AWS Certificate Manager (ACM). When necessary, you can + * use this operation to change the certificate that you applied to your custom + * domain.
+ *Usually, this is unnecessary following routine certificate renewal with ACM. When you + * renew your existing certificate in ACM, the ARN for your certificate remains the same, + * and your custom domain uses the new certificate automatically.
+ *However, if you replace your existing certificate with a new one, ACM gives the new + * certificate a new ARN. To apply the new certificate to your custom domain, you must + * provide this ARN to Amazon Cognito.
+ *When you add your new certificate in ACM, you must choose US East (N. Virginia) as the + * AWS Region.
+ *After you submit your request, Amazon Cognito requires up to 1 hour to distribute your + * new certificate to your custom domain.
+ *For more information about adding a custom domain to your user pool, see Using Your Own Domain for the Hosted UI.
+ */ +class UpdateUserPoolDomainCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "UpdateUserPoolDomainCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.UpdateUserPoolDomainRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.UpdateUserPoolDomainResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1UpdateUserPoolDomainCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1UpdateUserPoolDomainCommand(output, context); + } +} +exports.UpdateUserPoolDomainCommand = UpdateUserPoolDomainCommand; +//# sourceMappingURL=UpdateUserPoolDomainCommand.js.map + +/***/ }), + +/***/ 25918: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.VerifySoftwareTokenCommand = void 0; +const models_1_1 = __nccwpck_require__(1086); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Use this API to register a user's entered TOTP code and mark the user's software token + * MFA status as "verified" if successful. The request takes an access token or a session + * string, but not both.
+ */ +class VerifySoftwareTokenCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "VerifySoftwareTokenCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.VerifySoftwareTokenRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.VerifySoftwareTokenResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1VerifySoftwareTokenCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1VerifySoftwareTokenCommand(output, context); + } +} +exports.VerifySoftwareTokenCommand = VerifySoftwareTokenCommand; +//# sourceMappingURL=VerifySoftwareTokenCommand.js.map + +/***/ }), + +/***/ 11850: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.VerifyUserAttributeCommand = void 0; +const models_1_1 = __nccwpck_require__(1086); +const Aws_json1_1_1 = __nccwpck_require__(91522); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Verifies the specified user attributes in the user pool.
+ */ +class VerifyUserAttributeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityProviderClient"; + const commandName = "VerifyUserAttributeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.VerifyUserAttributeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.VerifyUserAttributeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1VerifyUserAttributeCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1VerifyUserAttributeCommand(output, context); + } +} +exports.VerifyUserAttributeCommand = VerifyUserAttributeCommand; +//# sourceMappingURL=VerifyUserAttributeCommand.js.map + +/***/ }), + +/***/ 96941: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.defaultRegionInfoProvider = void 0; +// Partition default templates +const AWS_TEMPLATE = "cognito-idp.{region}.amazonaws.com"; +const AWS_CN_TEMPLATE = "cognito-idp.{region}.amazonaws.com.cn"; +const AWS_ISO_TEMPLATE = "cognito-idp.{region}.c2s.ic.gov"; +const AWS_ISO_B_TEMPLATE = "cognito-idp.{region}.sc2s.sgov.gov"; +const AWS_US_GOV_TEMPLATE = "cognito-idp.{region}.amazonaws.com"; +// Partition regions +const AWS_REGIONS = new Set([ + "af-south-1", + "ap-east-1", + "ap-northeast-1", + "ap-northeast-2", + "ap-south-1", + "ap-southeast-1", + "ap-southeast-2", + "ca-central-1", + "eu-central-1", + "eu-north-1", + "eu-south-1", + "eu-west-1", + "eu-west-2", + "eu-west-3", + "me-south-1", + "sa-east-1", + "us-east-1", + "us-east-2", + "us-west-1", + "us-west-2", +]); +const AWS_CN_REGIONS = new Set(["cn-north-1", "cn-northwest-1"]); +const AWS_ISO_REGIONS = new Set(["us-iso-east-1"]); +const AWS_ISO_B_REGIONS = new Set(["us-isob-east-1"]); +const AWS_US_GOV_REGIONS = new Set(["us-gov-east-1", "us-gov-west-1"]); +const defaultRegionInfoProvider = (region, options) => { + let regionInfo = undefined; + switch (region) { + // First, try to match exact region names. + case "ap-northeast-1": + regionInfo = { + hostname: "cognito-idp.ap-northeast-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-northeast-2": + regionInfo = { + hostname: "cognito-idp.ap-northeast-2.amazonaws.com", + partition: "aws", + }; + break; + case "ap-south-1": + regionInfo = { + hostname: "cognito-idp.ap-south-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-southeast-1": + regionInfo = { + hostname: "cognito-idp.ap-southeast-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-southeast-2": + regionInfo = { + hostname: "cognito-idp.ap-southeast-2.amazonaws.com", + partition: "aws", + }; + break; + case "ca-central-1": + regionInfo = { + hostname: "cognito-idp.ca-central-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-central-1": + regionInfo = { + hostname: "cognito-idp.eu-central-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-north-1": + regionInfo = { + hostname: "cognito-idp.eu-north-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-west-1": + regionInfo = { + hostname: "cognito-idp.eu-west-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-west-2": + regionInfo = { + hostname: "cognito-idp.eu-west-2.amazonaws.com", + partition: "aws", + }; + break; + case "eu-west-3": + regionInfo = { + hostname: "cognito-idp.eu-west-3.amazonaws.com", + partition: "aws", + }; + break; + case "fips-us-east-1": + regionInfo = { + hostname: "cognito-idp-fips.us-east-1.amazonaws.com", + partition: "aws", + signingRegion: "us-east-1", + }; + break; + case "fips-us-east-2": + regionInfo = { + hostname: "cognito-idp-fips.us-east-2.amazonaws.com", + partition: "aws", + signingRegion: "us-east-2", + }; + break; + case "fips-us-gov-west-1": + regionInfo = { + hostname: "cognito-idp-fips.us-gov-west-1.amazonaws.com", + partition: "aws-us-gov", + signingRegion: "us-gov-west-1", + }; + break; + case "fips-us-west-2": + regionInfo = { + hostname: "cognito-idp-fips.us-west-2.amazonaws.com", + partition: "aws", + signingRegion: "us-west-2", + }; + break; + case "sa-east-1": + regionInfo = { + hostname: "cognito-idp.sa-east-1.amazonaws.com", + partition: "aws", + }; + break; + case "us-east-1": + regionInfo = { + hostname: "cognito-idp.us-east-1.amazonaws.com", + partition: "aws", + }; + break; + case "us-east-2": + regionInfo = { + hostname: "cognito-idp.us-east-2.amazonaws.com", + partition: "aws", + }; + break; + case "us-gov-west-1": + regionInfo = { + hostname: "cognito-idp.us-gov-west-1.amazonaws.com", + partition: "aws-us-gov", + }; + break; + case "us-west-1": + regionInfo = { + hostname: "cognito-idp.us-west-1.amazonaws.com", + partition: "aws", + }; + break; + case "us-west-2": + regionInfo = { + hostname: "cognito-idp.us-west-2.amazonaws.com", + partition: "aws", + }; + break; + // Next, try to match partition endpoints. + default: + if (AWS_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_TEMPLATE.replace("{region}", region), + partition: "aws", + }; + } + if (AWS_CN_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_CN_TEMPLATE.replace("{region}", region), + partition: "aws-cn", + }; + } + if (AWS_ISO_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_ISO_TEMPLATE.replace("{region}", region), + partition: "aws-iso", + }; + } + if (AWS_ISO_B_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_ISO_B_TEMPLATE.replace("{region}", region), + partition: "aws-iso-b", + }; + } + if (AWS_US_GOV_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_US_GOV_TEMPLATE.replace("{region}", region), + partition: "aws-us-gov", + }; + } + // Finally, assume it's an AWS partition endpoint. + if (regionInfo === undefined) { + regionInfo = { + hostname: AWS_TEMPLATE.replace("{region}", region), + partition: "aws", + }; + } + } + return Promise.resolve({ signingService: "cognito-idp", ...regionInfo }); +}; +exports.defaultRegionInfoProvider = defaultRegionInfoProvider; +//# sourceMappingURL=endpoints.js.map + +/***/ }), + +/***/ 69508: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +const tslib_1 = __nccwpck_require__(37706); +tslib_1.__exportStar(__nccwpck_require__(32756), exports); +tslib_1.__exportStar(__nccwpck_require__(63436), exports); +tslib_1.__exportStar(__nccwpck_require__(2336), exports); +tslib_1.__exportStar(__nccwpck_require__(63030), exports); +tslib_1.__exportStar(__nccwpck_require__(8330), exports); +tslib_1.__exportStar(__nccwpck_require__(18188), exports); +tslib_1.__exportStar(__nccwpck_require__(27623), exports); +tslib_1.__exportStar(__nccwpck_require__(49653), exports); +tslib_1.__exportStar(__nccwpck_require__(24718), exports); +tslib_1.__exportStar(__nccwpck_require__(31989), exports); +tslib_1.__exportStar(__nccwpck_require__(78365), exports); +tslib_1.__exportStar(__nccwpck_require__(35436), exports); +tslib_1.__exportStar(__nccwpck_require__(7451), exports); +tslib_1.__exportStar(__nccwpck_require__(75054), exports); +tslib_1.__exportStar(__nccwpck_require__(51153), exports); +tslib_1.__exportStar(__nccwpck_require__(31763), exports); +tslib_1.__exportStar(__nccwpck_require__(18926), exports); +tslib_1.__exportStar(__nccwpck_require__(4199), exports); +tslib_1.__exportStar(__nccwpck_require__(71298), exports); +tslib_1.__exportStar(__nccwpck_require__(76132), exports); +tslib_1.__exportStar(__nccwpck_require__(91606), exports); +tslib_1.__exportStar(__nccwpck_require__(9640), exports); +tslib_1.__exportStar(__nccwpck_require__(12557), exports); +tslib_1.__exportStar(__nccwpck_require__(21828), exports); +tslib_1.__exportStar(__nccwpck_require__(13421), exports); +tslib_1.__exportStar(__nccwpck_require__(75616), exports); +tslib_1.__exportStar(__nccwpck_require__(36217), exports); +tslib_1.__exportStar(__nccwpck_require__(57675), exports); +tslib_1.__exportStar(__nccwpck_require__(18824), exports); +tslib_1.__exportStar(__nccwpck_require__(1541), exports); +tslib_1.__exportStar(__nccwpck_require__(11240), exports); +tslib_1.__exportStar(__nccwpck_require__(52819), exports); +tslib_1.__exportStar(__nccwpck_require__(65801), exports); +tslib_1.__exportStar(__nccwpck_require__(79275), exports); +tslib_1.__exportStar(__nccwpck_require__(35665), exports); +tslib_1.__exportStar(__nccwpck_require__(18104), exports); +tslib_1.__exportStar(__nccwpck_require__(81662), exports); +tslib_1.__exportStar(__nccwpck_require__(81266), exports); +tslib_1.__exportStar(__nccwpck_require__(54935), exports); +tslib_1.__exportStar(__nccwpck_require__(77974), exports); +tslib_1.__exportStar(__nccwpck_require__(74938), exports); +tslib_1.__exportStar(__nccwpck_require__(17824), exports); +tslib_1.__exportStar(__nccwpck_require__(58015), exports); +tslib_1.__exportStar(__nccwpck_require__(73307), exports); +tslib_1.__exportStar(__nccwpck_require__(7493), exports); +tslib_1.__exportStar(__nccwpck_require__(6049), exports); +tslib_1.__exportStar(__nccwpck_require__(28421), exports); +tslib_1.__exportStar(__nccwpck_require__(99475), exports); +tslib_1.__exportStar(__nccwpck_require__(92314), exports); +tslib_1.__exportStar(__nccwpck_require__(3402), exports); +tslib_1.__exportStar(__nccwpck_require__(79680), exports); +tslib_1.__exportStar(__nccwpck_require__(96582), exports); +tslib_1.__exportStar(__nccwpck_require__(13045), exports); +tslib_1.__exportStar(__nccwpck_require__(51063), exports); +tslib_1.__exportStar(__nccwpck_require__(10902), exports); +tslib_1.__exportStar(__nccwpck_require__(67125), exports); +tslib_1.__exportStar(__nccwpck_require__(25424), exports); +tslib_1.__exportStar(__nccwpck_require__(9253), exports); +tslib_1.__exportStar(__nccwpck_require__(39305), exports); +tslib_1.__exportStar(__nccwpck_require__(15806), exports); +tslib_1.__exportStar(__nccwpck_require__(59575), exports); +tslib_1.__exportStar(__nccwpck_require__(95242), exports); +tslib_1.__exportStar(__nccwpck_require__(89462), exports); +tslib_1.__exportStar(__nccwpck_require__(29528), exports); +tslib_1.__exportStar(__nccwpck_require__(7884), exports); +tslib_1.__exportStar(__nccwpck_require__(47556), exports); +tslib_1.__exportStar(__nccwpck_require__(33079), exports); +tslib_1.__exportStar(__nccwpck_require__(1966), exports); +tslib_1.__exportStar(__nccwpck_require__(59598), exports); +tslib_1.__exportStar(__nccwpck_require__(783), exports); +tslib_1.__exportStar(__nccwpck_require__(25210), exports); +tslib_1.__exportStar(__nccwpck_require__(41445), exports); +tslib_1.__exportStar(__nccwpck_require__(39386), exports); +tslib_1.__exportStar(__nccwpck_require__(42484), exports); +tslib_1.__exportStar(__nccwpck_require__(73419), exports); +tslib_1.__exportStar(__nccwpck_require__(24624), exports); +tslib_1.__exportStar(__nccwpck_require__(93783), exports); +tslib_1.__exportStar(__nccwpck_require__(56595), exports); +tslib_1.__exportStar(__nccwpck_require__(22658), exports); +tslib_1.__exportStar(__nccwpck_require__(86421), exports); +tslib_1.__exportStar(__nccwpck_require__(87753), exports); +tslib_1.__exportStar(__nccwpck_require__(64835), exports); +tslib_1.__exportStar(__nccwpck_require__(51756), exports); +tslib_1.__exportStar(__nccwpck_require__(79983), exports); +tslib_1.__exportStar(__nccwpck_require__(16854), exports); +tslib_1.__exportStar(__nccwpck_require__(23221), exports); +tslib_1.__exportStar(__nccwpck_require__(51577), exports); +tslib_1.__exportStar(__nccwpck_require__(24558), exports); +tslib_1.__exportStar(__nccwpck_require__(30730), exports); +tslib_1.__exportStar(__nccwpck_require__(36946), exports); +tslib_1.__exportStar(__nccwpck_require__(54210), exports); +tslib_1.__exportStar(__nccwpck_require__(41002), exports); +tslib_1.__exportStar(__nccwpck_require__(59037), exports); +tslib_1.__exportStar(__nccwpck_require__(39776), exports); +tslib_1.__exportStar(__nccwpck_require__(44103), exports); +tslib_1.__exportStar(__nccwpck_require__(61298), exports); +tslib_1.__exportStar(__nccwpck_require__(8066), exports); +tslib_1.__exportStar(__nccwpck_require__(47546), exports); +tslib_1.__exportStar(__nccwpck_require__(13116), exports); +tslib_1.__exportStar(__nccwpck_require__(93194), exports); +tslib_1.__exportStar(__nccwpck_require__(45344), exports); +tslib_1.__exportStar(__nccwpck_require__(34181), exports); +tslib_1.__exportStar(__nccwpck_require__(17637), exports); +tslib_1.__exportStar(__nccwpck_require__(79222), exports); +tslib_1.__exportStar(__nccwpck_require__(42116), exports); +tslib_1.__exportStar(__nccwpck_require__(77311), exports); +tslib_1.__exportStar(__nccwpck_require__(70670), exports); +tslib_1.__exportStar(__nccwpck_require__(94287), exports); +tslib_1.__exportStar(__nccwpck_require__(16919), exports); +tslib_1.__exportStar(__nccwpck_require__(25918), exports); +tslib_1.__exportStar(__nccwpck_require__(11850), exports); +tslib_1.__exportStar(__nccwpck_require__(14865), exports); +tslib_1.__exportStar(__nccwpck_require__(44523), exports); +//# sourceMappingURL=index.js.map + +/***/ }), + +/***/ 44523: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +const tslib_1 = __nccwpck_require__(37706); +tslib_1.__exportStar(__nccwpck_require__(38771), exports); +tslib_1.__exportStar(__nccwpck_require__(1086), exports); +//# sourceMappingURL=index.js.map + +/***/ }), + +/***/ 38771: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AdminDeleteUserAttributesResponse = exports.AdminDeleteUserAttributesRequest = exports.AdminDeleteUserRequest = exports.AdminCreateUserConfigType = exports.MessageTemplateType = exports.UsernameExistsException = exports.UnsupportedUserStateException = exports.PreconditionNotMetException = exports.InvalidSmsRoleTrustRelationshipException = exports.InvalidSmsRoleAccessPolicyException = exports.InvalidPasswordException = exports.CodeDeliveryFailureException = exports.AdminCreateUserResponse = exports.UserType = exports.UserStatusType = exports.MFAOptionType = exports.AdminCreateUserRequest = exports.AttributeType = exports.MessageActionType = exports.DeliveryMediumType = exports.UserLambdaValidationException = exports.UnexpectedLambdaException = exports.TooManyFailedAttemptsException = exports.LimitExceededException = exports.InvalidLambdaResponseException = exports.AdminConfirmSignUpResponse = exports.AdminConfirmSignUpRequest = exports.UserNotFoundException = exports.AdminAddUserToGroupRequest = exports.UserImportInProgressException = exports.TooManyRequestsException = exports.ResourceNotFoundException = exports.NotAuthorizedException = exports.InvalidParameterException = exports.InternalErrorException = exports.AddCustomAttributesResponse = exports.AddCustomAttributesRequest = exports.SchemaAttributeType = exports.StringAttributeConstraintsType = exports.NumberAttributeConstraintsType = exports.AttributeDataType = exports.AccountTakeoverRiskConfigurationType = exports.NotifyConfigurationType = exports.NotifyEmailType = exports.AccountTakeoverActionsType = exports.AccountTakeoverActionType = exports.AccountTakeoverEventActionType = exports.AccountRecoverySettingType = exports.RecoveryOptionType = exports.RecoveryOptionNameType = void 0; +exports.AdminRemoveUserFromGroupRequest = exports.UserPoolAddOnNotEnabledException = exports.AdminListUserAuthEventsResponse = exports.AuthEventType = exports.EventType = exports.EventRiskType = exports.RiskLevelType = exports.RiskDecisionType = exports.EventResponseType = exports.EventFeedbackType = exports.FeedbackValueType = exports.EventContextDataType = exports.ChallengeResponseType = exports.ChallengeResponse = exports.ChallengeName = exports.AdminListUserAuthEventsRequest = exports.AdminListGroupsForUserResponse = exports.GroupType = exports.AdminListGroupsForUserRequest = exports.AdminListDevicesResponse = exports.AdminListDevicesRequest = exports.AdminLinkProviderForUserResponse = exports.AdminLinkProviderForUserRequest = exports.UserNotConfirmedException = exports.PasswordResetRequiredException = exports.MFAMethodNotFoundException = exports.AdminInitiateAuthResponse = exports.ChallengeNameType = exports.AuthenticationResultType = exports.NewDeviceMetadataType = exports.AdminInitiateAuthRequest = exports.ContextDataType = exports.HttpHeader = exports.AuthFlowType = exports.AnalyticsMetadataType = exports.AdminGetUserResponse = exports.AdminGetUserRequest = exports.AdminGetDeviceResponse = exports.DeviceType = exports.AdminGetDeviceRequest = exports.InvalidUserPoolConfigurationException = exports.AdminForgetDeviceRequest = exports.AdminEnableUserResponse = exports.AdminEnableUserRequest = exports.AdminDisableUserResponse = exports.AdminDisableUserRequest = exports.AliasExistsException = exports.AdminDisableProviderForUserResponse = exports.AdminDisableProviderForUserRequest = exports.ProviderUserIdentifierType = void 0; +exports.ResourceServerScopeType = exports.DuplicateProviderException = exports.CreateIdentityProviderResponse = exports.IdentityProviderType = exports.CreateIdentityProviderRequest = exports.IdentityProviderTypeType = exports.GroupExistsException = exports.CreateGroupResponse = exports.CreateGroupRequest = exports.ConfirmSignUpResponse = exports.ConfirmSignUpRequest = exports.ConfirmForgotPasswordResponse = exports.ConfirmForgotPasswordRequest = exports.UserContextDataType = exports.ConfirmDeviceResponse = exports.ConfirmDeviceRequest = exports.DeviceSecretVerifierConfigType = exports.ChangePasswordResponse = exports.ChangePasswordRequest = exports.ConcurrentModificationException = exports.AssociateSoftwareTokenResponse = exports.AssociateSoftwareTokenRequest = exports.AnalyticsConfigurationType = exports.AliasAttributeType = exports.AdvancedSecurityModeType = exports.AdminUserGlobalSignOutResponse = exports.AdminUserGlobalSignOutRequest = exports.AdminUpdateUserAttributesResponse = exports.AdminUpdateUserAttributesRequest = exports.AdminUpdateDeviceStatusResponse = exports.AdminUpdateDeviceStatusRequest = exports.DeviceRememberedStatusType = exports.AdminUpdateAuthEventFeedbackResponse = exports.AdminUpdateAuthEventFeedbackRequest = exports.AdminSetUserSettingsResponse = exports.AdminSetUserSettingsRequest = exports.AdminSetUserPasswordResponse = exports.AdminSetUserPasswordRequest = exports.AdminSetUserMFAPreferenceResponse = exports.AdminSetUserMFAPreferenceRequest = exports.SoftwareTokenMfaSettingsType = exports.SMSMfaSettingsType = exports.SoftwareTokenMFANotFoundException = exports.ExpiredCodeException = exports.CodeMismatchException = exports.AdminRespondToAuthChallengeResponse = exports.AdminRespondToAuthChallengeRequest = exports.InvalidEmailRoleAccessPolicyException = exports.AdminResetUserPasswordResponse = exports.AdminResetUserPasswordRequest = void 0; +exports.DeleteUserAttributesResponse = exports.DeleteUserAttributesRequest = exports.DeleteUserRequest = exports.DeleteResourceServerRequest = exports.UnsupportedIdentityProviderException = exports.DeleteIdentityProviderRequest = exports.DeleteGroupRequest = exports.CreateUserPoolDomainResponse = exports.CreateUserPoolDomainRequest = exports.CustomDomainConfigType = exports.ScopeDoesNotExistException = exports.InvalidOAuthFlowException = exports.CreateUserPoolClientResponse = exports.UserPoolClientType = exports.CreateUserPoolClientRequest = exports.TokenValidityUnitsType = exports.TimeUnitsType = exports.PreventUserExistenceErrorTypes = exports.ExplicitAuthFlowsType = exports.OAuthFlowType = exports.UserPoolTaggingException = exports.CreateUserPoolResponse = exports.UserPoolType = exports.StatusType = exports.CreateUserPoolRequest = exports.VerificationMessageTemplateType = exports.DefaultEmailOptionType = exports.UserPoolAddOnsType = exports.UsernameConfigurationType = exports.UsernameAttributeType = exports.SmsConfigurationType = exports.UserPoolPolicyType = exports.PasswordPolicyType = exports.UserPoolMfaType = exports.LambdaConfigType = exports.CustomSMSLambdaVersionConfigType = exports.CustomSMSSenderLambdaVersionType = exports.CustomEmailLambdaVersionConfigType = exports.CustomEmailSenderLambdaVersionType = exports.EmailConfigurationType = exports.EmailSendingAccountType = exports.DeviceConfigurationType = exports.VerifiedAttributeType = exports.CreateUserImportJobResponse = exports.UserImportJobType = exports.UserImportJobStatusType = exports.CreateUserImportJobRequest = exports.CreateResourceServerResponse = exports.ResourceServerType = exports.CreateResourceServerRequest = void 0; +exports.SoftwareTokenMfaConfigType = exports.SmsMfaConfigType = exports.GetUserPoolMfaConfigRequest = exports.GetUserAttributeVerificationCodeResponse = exports.GetUserAttributeVerificationCodeRequest = exports.GetUserResponse = exports.GetUserRequest = exports.GetUICustomizationResponse = exports.UICustomizationType = exports.GetUICustomizationRequest = exports.GetSigningCertificateResponse = exports.GetSigningCertificateRequest = exports.GetIdentityProviderByIdentifierResponse = exports.GetIdentityProviderByIdentifierRequest = exports.GetGroupResponse = exports.GetGroupRequest = exports.GetDeviceResponse = exports.GetDeviceRequest = exports.GetCSVHeaderResponse = exports.GetCSVHeaderRequest = exports.ForgotPasswordResponse = exports.CodeDeliveryDetailsType = exports.ForgotPasswordRequest = exports.ForgetDeviceRequest = exports.DescribeUserPoolDomainResponse = exports.DomainDescriptionType = exports.DomainStatusType = exports.DescribeUserPoolDomainRequest = exports.DescribeUserPoolClientResponse = exports.DescribeUserPoolClientRequest = exports.DescribeUserPoolResponse = exports.DescribeUserPoolRequest = exports.DescribeUserImportJobResponse = exports.DescribeUserImportJobRequest = exports.DescribeRiskConfigurationResponse = exports.RiskConfigurationType = exports.RiskExceptionConfigurationType = exports.CompromisedCredentialsRiskConfigurationType = exports.EventFilterType = exports.CompromisedCredentialsActionsType = exports.CompromisedCredentialsEventActionType = exports.DescribeRiskConfigurationRequest = exports.DescribeResourceServerResponse = exports.DescribeResourceServerRequest = exports.DescribeIdentityProviderResponse = exports.DescribeIdentityProviderRequest = exports.DeleteUserPoolDomainResponse = exports.DeleteUserPoolDomainRequest = exports.DeleteUserPoolClientRequest = exports.DeleteUserPoolRequest = void 0; +exports.TagResourceResponse = exports.TagResourceRequest = exports.StopUserImportJobResponse = exports.StopUserImportJobRequest = exports.StartUserImportJobResponse = exports.StartUserImportJobRequest = exports.SignUpResponse = exports.SignUpRequest = exports.SetUserSettingsResponse = exports.SetUserSettingsRequest = exports.SetUserPoolMfaConfigResponse = exports.SetUserPoolMfaConfigRequest = exports.SetUserMFAPreferenceResponse = exports.SetUserMFAPreferenceRequest = exports.SetUICustomizationResponse = exports.SetUICustomizationRequest = exports.SetRiskConfigurationResponse = exports.SetRiskConfigurationRequest = exports.RespondToAuthChallengeResponse = exports.RespondToAuthChallengeRequest = exports.ResendConfirmationCodeResponse = exports.ResendConfirmationCodeRequest = exports.ListUsersInGroupResponse = exports.ListUsersInGroupRequest = exports.ListUsersResponse = exports.ListUsersRequest = exports.ListUserPoolsResponse = exports.UserPoolDescriptionType = exports.ListUserPoolsRequest = exports.ListUserPoolClientsResponse = exports.UserPoolClientDescription = exports.ListUserPoolClientsRequest = exports.ListUserImportJobsResponse = exports.ListUserImportJobsRequest = exports.ListTagsForResourceResponse = exports.ListTagsForResourceRequest = exports.ListResourceServersResponse = exports.ListResourceServersRequest = exports.ListIdentityProvidersResponse = exports.ProviderDescription = exports.ListIdentityProvidersRequest = exports.ListGroupsResponse = exports.ListGroupsRequest = exports.ListDevicesResponse = exports.ListDevicesRequest = exports.InitiateAuthResponse = exports.InitiateAuthRequest = exports.GlobalSignOutResponse = exports.GlobalSignOutRequest = exports.GetUserPoolMfaConfigResponse = void 0; +const smithy_client_1 = __nccwpck_require__(84060); +var RecoveryOptionNameType; +(function (RecoveryOptionNameType) { + RecoveryOptionNameType["ADMIN_ONLY"] = "admin_only"; + RecoveryOptionNameType["VERIFIED_EMAIL"] = "verified_email"; + RecoveryOptionNameType["VERIFIED_PHONE_NUMBER"] = "verified_phone_number"; +})(RecoveryOptionNameType = exports.RecoveryOptionNameType || (exports.RecoveryOptionNameType = {})); +var RecoveryOptionType; +(function (RecoveryOptionType) { + RecoveryOptionType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RecoveryOptionType = exports.RecoveryOptionType || (exports.RecoveryOptionType = {})); +var AccountRecoverySettingType; +(function (AccountRecoverySettingType) { + AccountRecoverySettingType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AccountRecoverySettingType = exports.AccountRecoverySettingType || (exports.AccountRecoverySettingType = {})); +var AccountTakeoverEventActionType; +(function (AccountTakeoverEventActionType) { + AccountTakeoverEventActionType["BLOCK"] = "BLOCK"; + AccountTakeoverEventActionType["MFA_IF_CONFIGURED"] = "MFA_IF_CONFIGURED"; + AccountTakeoverEventActionType["MFA_REQUIRED"] = "MFA_REQUIRED"; + AccountTakeoverEventActionType["NO_ACTION"] = "NO_ACTION"; +})(AccountTakeoverEventActionType = exports.AccountTakeoverEventActionType || (exports.AccountTakeoverEventActionType = {})); +var AccountTakeoverActionType; +(function (AccountTakeoverActionType) { + AccountTakeoverActionType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AccountTakeoverActionType = exports.AccountTakeoverActionType || (exports.AccountTakeoverActionType = {})); +var AccountTakeoverActionsType; +(function (AccountTakeoverActionsType) { + AccountTakeoverActionsType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AccountTakeoverActionsType = exports.AccountTakeoverActionsType || (exports.AccountTakeoverActionsType = {})); +var NotifyEmailType; +(function (NotifyEmailType) { + NotifyEmailType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(NotifyEmailType = exports.NotifyEmailType || (exports.NotifyEmailType = {})); +var NotifyConfigurationType; +(function (NotifyConfigurationType) { + NotifyConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(NotifyConfigurationType = exports.NotifyConfigurationType || (exports.NotifyConfigurationType = {})); +var AccountTakeoverRiskConfigurationType; +(function (AccountTakeoverRiskConfigurationType) { + AccountTakeoverRiskConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AccountTakeoverRiskConfigurationType = exports.AccountTakeoverRiskConfigurationType || (exports.AccountTakeoverRiskConfigurationType = {})); +var AttributeDataType; +(function (AttributeDataType) { + AttributeDataType["BOOLEAN"] = "Boolean"; + AttributeDataType["DATETIME"] = "DateTime"; + AttributeDataType["NUMBER"] = "Number"; + AttributeDataType["STRING"] = "String"; +})(AttributeDataType = exports.AttributeDataType || (exports.AttributeDataType = {})); +var NumberAttributeConstraintsType; +(function (NumberAttributeConstraintsType) { + NumberAttributeConstraintsType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(NumberAttributeConstraintsType = exports.NumberAttributeConstraintsType || (exports.NumberAttributeConstraintsType = {})); +var StringAttributeConstraintsType; +(function (StringAttributeConstraintsType) { + StringAttributeConstraintsType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StringAttributeConstraintsType = exports.StringAttributeConstraintsType || (exports.StringAttributeConstraintsType = {})); +var SchemaAttributeType; +(function (SchemaAttributeType) { + SchemaAttributeType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SchemaAttributeType = exports.SchemaAttributeType || (exports.SchemaAttributeType = {})); +var AddCustomAttributesRequest; +(function (AddCustomAttributesRequest) { + AddCustomAttributesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AddCustomAttributesRequest = exports.AddCustomAttributesRequest || (exports.AddCustomAttributesRequest = {})); +var AddCustomAttributesResponse; +(function (AddCustomAttributesResponse) { + AddCustomAttributesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AddCustomAttributesResponse = exports.AddCustomAttributesResponse || (exports.AddCustomAttributesResponse = {})); +var InternalErrorException; +(function (InternalErrorException) { + InternalErrorException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InternalErrorException = exports.InternalErrorException || (exports.InternalErrorException = {})); +var InvalidParameterException; +(function (InvalidParameterException) { + InvalidParameterException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidParameterException = exports.InvalidParameterException || (exports.InvalidParameterException = {})); +var NotAuthorizedException; +(function (NotAuthorizedException) { + NotAuthorizedException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(NotAuthorizedException = exports.NotAuthorizedException || (exports.NotAuthorizedException = {})); +var ResourceNotFoundException; +(function (ResourceNotFoundException) { + ResourceNotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceNotFoundException = exports.ResourceNotFoundException || (exports.ResourceNotFoundException = {})); +var TooManyRequestsException; +(function (TooManyRequestsException) { + TooManyRequestsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TooManyRequestsException = exports.TooManyRequestsException || (exports.TooManyRequestsException = {})); +var UserImportInProgressException; +(function (UserImportInProgressException) { + UserImportInProgressException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserImportInProgressException = exports.UserImportInProgressException || (exports.UserImportInProgressException = {})); +var AdminAddUserToGroupRequest; +(function (AdminAddUserToGroupRequest) { + AdminAddUserToGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminAddUserToGroupRequest = exports.AdminAddUserToGroupRequest || (exports.AdminAddUserToGroupRequest = {})); +var UserNotFoundException; +(function (UserNotFoundException) { + UserNotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserNotFoundException = exports.UserNotFoundException || (exports.UserNotFoundException = {})); +var AdminConfirmSignUpRequest; +(function (AdminConfirmSignUpRequest) { + AdminConfirmSignUpRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminConfirmSignUpRequest = exports.AdminConfirmSignUpRequest || (exports.AdminConfirmSignUpRequest = {})); +var AdminConfirmSignUpResponse; +(function (AdminConfirmSignUpResponse) { + AdminConfirmSignUpResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminConfirmSignUpResponse = exports.AdminConfirmSignUpResponse || (exports.AdminConfirmSignUpResponse = {})); +var InvalidLambdaResponseException; +(function (InvalidLambdaResponseException) { + InvalidLambdaResponseException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidLambdaResponseException = exports.InvalidLambdaResponseException || (exports.InvalidLambdaResponseException = {})); +var LimitExceededException; +(function (LimitExceededException) { + LimitExceededException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LimitExceededException = exports.LimitExceededException || (exports.LimitExceededException = {})); +var TooManyFailedAttemptsException; +(function (TooManyFailedAttemptsException) { + TooManyFailedAttemptsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TooManyFailedAttemptsException = exports.TooManyFailedAttemptsException || (exports.TooManyFailedAttemptsException = {})); +var UnexpectedLambdaException; +(function (UnexpectedLambdaException) { + UnexpectedLambdaException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UnexpectedLambdaException = exports.UnexpectedLambdaException || (exports.UnexpectedLambdaException = {})); +var UserLambdaValidationException; +(function (UserLambdaValidationException) { + UserLambdaValidationException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserLambdaValidationException = exports.UserLambdaValidationException || (exports.UserLambdaValidationException = {})); +var DeliveryMediumType; +(function (DeliveryMediumType) { + DeliveryMediumType["EMAIL"] = "EMAIL"; + DeliveryMediumType["SMS"] = "SMS"; +})(DeliveryMediumType = exports.DeliveryMediumType || (exports.DeliveryMediumType = {})); +var MessageActionType; +(function (MessageActionType) { + MessageActionType["RESEND"] = "RESEND"; + MessageActionType["SUPPRESS"] = "SUPPRESS"; +})(MessageActionType = exports.MessageActionType || (exports.MessageActionType = {})); +var AttributeType; +(function (AttributeType) { + AttributeType.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Value && { Value: smithy_client_1.SENSITIVE_STRING }), + }); +})(AttributeType = exports.AttributeType || (exports.AttributeType = {})); +var AdminCreateUserRequest; +(function (AdminCreateUserRequest) { + AdminCreateUserRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + ...(obj.UserAttributes && { + UserAttributes: obj.UserAttributes.map((item) => AttributeType.filterSensitiveLog(item)), + }), + ...(obj.ValidationData && { + ValidationData: obj.ValidationData.map((item) => AttributeType.filterSensitiveLog(item)), + }), + ...(obj.TemporaryPassword && { TemporaryPassword: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminCreateUserRequest = exports.AdminCreateUserRequest || (exports.AdminCreateUserRequest = {})); +var MFAOptionType; +(function (MFAOptionType) { + MFAOptionType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MFAOptionType = exports.MFAOptionType || (exports.MFAOptionType = {})); +var UserStatusType; +(function (UserStatusType) { + UserStatusType["ARCHIVED"] = "ARCHIVED"; + UserStatusType["COMPROMISED"] = "COMPROMISED"; + UserStatusType["CONFIRMED"] = "CONFIRMED"; + UserStatusType["FORCE_CHANGE_PASSWORD"] = "FORCE_CHANGE_PASSWORD"; + UserStatusType["RESET_REQUIRED"] = "RESET_REQUIRED"; + UserStatusType["UNCONFIRMED"] = "UNCONFIRMED"; + UserStatusType["UNKNOWN"] = "UNKNOWN"; +})(UserStatusType = exports.UserStatusType || (exports.UserStatusType = {})); +var UserType; +(function (UserType) { + UserType.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + ...(obj.Attributes && { Attributes: obj.Attributes.map((item) => AttributeType.filterSensitiveLog(item)) }), + }); +})(UserType = exports.UserType || (exports.UserType = {})); +var AdminCreateUserResponse; +(function (AdminCreateUserResponse) { + AdminCreateUserResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.User && { User: UserType.filterSensitiveLog(obj.User) }), + }); +})(AdminCreateUserResponse = exports.AdminCreateUserResponse || (exports.AdminCreateUserResponse = {})); +var CodeDeliveryFailureException; +(function (CodeDeliveryFailureException) { + CodeDeliveryFailureException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CodeDeliveryFailureException = exports.CodeDeliveryFailureException || (exports.CodeDeliveryFailureException = {})); +var InvalidPasswordException; +(function (InvalidPasswordException) { + InvalidPasswordException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidPasswordException = exports.InvalidPasswordException || (exports.InvalidPasswordException = {})); +var InvalidSmsRoleAccessPolicyException; +(function (InvalidSmsRoleAccessPolicyException) { + InvalidSmsRoleAccessPolicyException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidSmsRoleAccessPolicyException = exports.InvalidSmsRoleAccessPolicyException || (exports.InvalidSmsRoleAccessPolicyException = {})); +var InvalidSmsRoleTrustRelationshipException; +(function (InvalidSmsRoleTrustRelationshipException) { + InvalidSmsRoleTrustRelationshipException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidSmsRoleTrustRelationshipException = exports.InvalidSmsRoleTrustRelationshipException || (exports.InvalidSmsRoleTrustRelationshipException = {})); +var PreconditionNotMetException; +(function (PreconditionNotMetException) { + PreconditionNotMetException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PreconditionNotMetException = exports.PreconditionNotMetException || (exports.PreconditionNotMetException = {})); +var UnsupportedUserStateException; +(function (UnsupportedUserStateException) { + UnsupportedUserStateException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UnsupportedUserStateException = exports.UnsupportedUserStateException || (exports.UnsupportedUserStateException = {})); +var UsernameExistsException; +(function (UsernameExistsException) { + UsernameExistsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UsernameExistsException = exports.UsernameExistsException || (exports.UsernameExistsException = {})); +var MessageTemplateType; +(function (MessageTemplateType) { + MessageTemplateType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MessageTemplateType = exports.MessageTemplateType || (exports.MessageTemplateType = {})); +var AdminCreateUserConfigType; +(function (AdminCreateUserConfigType) { + AdminCreateUserConfigType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminCreateUserConfigType = exports.AdminCreateUserConfigType || (exports.AdminCreateUserConfigType = {})); +var AdminDeleteUserRequest; +(function (AdminDeleteUserRequest) { + AdminDeleteUserRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminDeleteUserRequest = exports.AdminDeleteUserRequest || (exports.AdminDeleteUserRequest = {})); +var AdminDeleteUserAttributesRequest; +(function (AdminDeleteUserAttributesRequest) { + AdminDeleteUserAttributesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminDeleteUserAttributesRequest = exports.AdminDeleteUserAttributesRequest || (exports.AdminDeleteUserAttributesRequest = {})); +var AdminDeleteUserAttributesResponse; +(function (AdminDeleteUserAttributesResponse) { + AdminDeleteUserAttributesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminDeleteUserAttributesResponse = exports.AdminDeleteUserAttributesResponse || (exports.AdminDeleteUserAttributesResponse = {})); +var ProviderUserIdentifierType; +(function (ProviderUserIdentifierType) { + ProviderUserIdentifierType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ProviderUserIdentifierType = exports.ProviderUserIdentifierType || (exports.ProviderUserIdentifierType = {})); +var AdminDisableProviderForUserRequest; +(function (AdminDisableProviderForUserRequest) { + AdminDisableProviderForUserRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminDisableProviderForUserRequest = exports.AdminDisableProviderForUserRequest || (exports.AdminDisableProviderForUserRequest = {})); +var AdminDisableProviderForUserResponse; +(function (AdminDisableProviderForUserResponse) { + AdminDisableProviderForUserResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminDisableProviderForUserResponse = exports.AdminDisableProviderForUserResponse || (exports.AdminDisableProviderForUserResponse = {})); +var AliasExistsException; +(function (AliasExistsException) { + AliasExistsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AliasExistsException = exports.AliasExistsException || (exports.AliasExistsException = {})); +var AdminDisableUserRequest; +(function (AdminDisableUserRequest) { + AdminDisableUserRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminDisableUserRequest = exports.AdminDisableUserRequest || (exports.AdminDisableUserRequest = {})); +var AdminDisableUserResponse; +(function (AdminDisableUserResponse) { + AdminDisableUserResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminDisableUserResponse = exports.AdminDisableUserResponse || (exports.AdminDisableUserResponse = {})); +var AdminEnableUserRequest; +(function (AdminEnableUserRequest) { + AdminEnableUserRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminEnableUserRequest = exports.AdminEnableUserRequest || (exports.AdminEnableUserRequest = {})); +var AdminEnableUserResponse; +(function (AdminEnableUserResponse) { + AdminEnableUserResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminEnableUserResponse = exports.AdminEnableUserResponse || (exports.AdminEnableUserResponse = {})); +var AdminForgetDeviceRequest; +(function (AdminForgetDeviceRequest) { + AdminForgetDeviceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminForgetDeviceRequest = exports.AdminForgetDeviceRequest || (exports.AdminForgetDeviceRequest = {})); +var InvalidUserPoolConfigurationException; +(function (InvalidUserPoolConfigurationException) { + InvalidUserPoolConfigurationException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidUserPoolConfigurationException = exports.InvalidUserPoolConfigurationException || (exports.InvalidUserPoolConfigurationException = {})); +var AdminGetDeviceRequest; +(function (AdminGetDeviceRequest) { + AdminGetDeviceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminGetDeviceRequest = exports.AdminGetDeviceRequest || (exports.AdminGetDeviceRequest = {})); +var DeviceType; +(function (DeviceType) { + DeviceType.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.DeviceAttributes && { + DeviceAttributes: obj.DeviceAttributes.map((item) => AttributeType.filterSensitiveLog(item)), + }), + }); +})(DeviceType = exports.DeviceType || (exports.DeviceType = {})); +var AdminGetDeviceResponse; +(function (AdminGetDeviceResponse) { + AdminGetDeviceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Device && { Device: DeviceType.filterSensitiveLog(obj.Device) }), + }); +})(AdminGetDeviceResponse = exports.AdminGetDeviceResponse || (exports.AdminGetDeviceResponse = {})); +var AdminGetUserRequest; +(function (AdminGetUserRequest) { + AdminGetUserRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminGetUserRequest = exports.AdminGetUserRequest || (exports.AdminGetUserRequest = {})); +var AdminGetUserResponse; +(function (AdminGetUserResponse) { + AdminGetUserResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + ...(obj.UserAttributes && { + UserAttributes: obj.UserAttributes.map((item) => AttributeType.filterSensitiveLog(item)), + }), + }); +})(AdminGetUserResponse = exports.AdminGetUserResponse || (exports.AdminGetUserResponse = {})); +var AnalyticsMetadataType; +(function (AnalyticsMetadataType) { + AnalyticsMetadataType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AnalyticsMetadataType = exports.AnalyticsMetadataType || (exports.AnalyticsMetadataType = {})); +var AuthFlowType; +(function (AuthFlowType) { + AuthFlowType["ADMIN_NO_SRP_AUTH"] = "ADMIN_NO_SRP_AUTH"; + AuthFlowType["ADMIN_USER_PASSWORD_AUTH"] = "ADMIN_USER_PASSWORD_AUTH"; + AuthFlowType["CUSTOM_AUTH"] = "CUSTOM_AUTH"; + AuthFlowType["REFRESH_TOKEN"] = "REFRESH_TOKEN"; + AuthFlowType["REFRESH_TOKEN_AUTH"] = "REFRESH_TOKEN_AUTH"; + AuthFlowType["USER_PASSWORD_AUTH"] = "USER_PASSWORD_AUTH"; + AuthFlowType["USER_SRP_AUTH"] = "USER_SRP_AUTH"; +})(AuthFlowType = exports.AuthFlowType || (exports.AuthFlowType = {})); +var HttpHeader; +(function (HttpHeader) { + HttpHeader.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(HttpHeader = exports.HttpHeader || (exports.HttpHeader = {})); +var ContextDataType; +(function (ContextDataType) { + ContextDataType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ContextDataType = exports.ContextDataType || (exports.ContextDataType = {})); +var AdminInitiateAuthRequest; +(function (AdminInitiateAuthRequest) { + AdminInitiateAuthRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + ...(obj.AuthParameters && { AuthParameters: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminInitiateAuthRequest = exports.AdminInitiateAuthRequest || (exports.AdminInitiateAuthRequest = {})); +var NewDeviceMetadataType; +(function (NewDeviceMetadataType) { + NewDeviceMetadataType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(NewDeviceMetadataType = exports.NewDeviceMetadataType || (exports.NewDeviceMetadataType = {})); +var AuthenticationResultType; +(function (AuthenticationResultType) { + AuthenticationResultType.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + ...(obj.RefreshToken && { RefreshToken: smithy_client_1.SENSITIVE_STRING }), + ...(obj.IdToken && { IdToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(AuthenticationResultType = exports.AuthenticationResultType || (exports.AuthenticationResultType = {})); +var ChallengeNameType; +(function (ChallengeNameType) { + ChallengeNameType["ADMIN_NO_SRP_AUTH"] = "ADMIN_NO_SRP_AUTH"; + ChallengeNameType["CUSTOM_CHALLENGE"] = "CUSTOM_CHALLENGE"; + ChallengeNameType["DEVICE_PASSWORD_VERIFIER"] = "DEVICE_PASSWORD_VERIFIER"; + ChallengeNameType["DEVICE_SRP_AUTH"] = "DEVICE_SRP_AUTH"; + ChallengeNameType["MFA_SETUP"] = "MFA_SETUP"; + ChallengeNameType["NEW_PASSWORD_REQUIRED"] = "NEW_PASSWORD_REQUIRED"; + ChallengeNameType["PASSWORD_VERIFIER"] = "PASSWORD_VERIFIER"; + ChallengeNameType["SELECT_MFA_TYPE"] = "SELECT_MFA_TYPE"; + ChallengeNameType["SMS_MFA"] = "SMS_MFA"; + ChallengeNameType["SOFTWARE_TOKEN_MFA"] = "SOFTWARE_TOKEN_MFA"; +})(ChallengeNameType = exports.ChallengeNameType || (exports.ChallengeNameType = {})); +var AdminInitiateAuthResponse; +(function (AdminInitiateAuthResponse) { + AdminInitiateAuthResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AuthenticationResult && { + AuthenticationResult: AuthenticationResultType.filterSensitiveLog(obj.AuthenticationResult), + }), + }); +})(AdminInitiateAuthResponse = exports.AdminInitiateAuthResponse || (exports.AdminInitiateAuthResponse = {})); +var MFAMethodNotFoundException; +(function (MFAMethodNotFoundException) { + MFAMethodNotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MFAMethodNotFoundException = exports.MFAMethodNotFoundException || (exports.MFAMethodNotFoundException = {})); +var PasswordResetRequiredException; +(function (PasswordResetRequiredException) { + PasswordResetRequiredException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PasswordResetRequiredException = exports.PasswordResetRequiredException || (exports.PasswordResetRequiredException = {})); +var UserNotConfirmedException; +(function (UserNotConfirmedException) { + UserNotConfirmedException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserNotConfirmedException = exports.UserNotConfirmedException || (exports.UserNotConfirmedException = {})); +var AdminLinkProviderForUserRequest; +(function (AdminLinkProviderForUserRequest) { + AdminLinkProviderForUserRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminLinkProviderForUserRequest = exports.AdminLinkProviderForUserRequest || (exports.AdminLinkProviderForUserRequest = {})); +var AdminLinkProviderForUserResponse; +(function (AdminLinkProviderForUserResponse) { + AdminLinkProviderForUserResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminLinkProviderForUserResponse = exports.AdminLinkProviderForUserResponse || (exports.AdminLinkProviderForUserResponse = {})); +var AdminListDevicesRequest; +(function (AdminListDevicesRequest) { + AdminListDevicesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminListDevicesRequest = exports.AdminListDevicesRequest || (exports.AdminListDevicesRequest = {})); +var AdminListDevicesResponse; +(function (AdminListDevicesResponse) { + AdminListDevicesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminListDevicesResponse = exports.AdminListDevicesResponse || (exports.AdminListDevicesResponse = {})); +var AdminListGroupsForUserRequest; +(function (AdminListGroupsForUserRequest) { + AdminListGroupsForUserRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminListGroupsForUserRequest = exports.AdminListGroupsForUserRequest || (exports.AdminListGroupsForUserRequest = {})); +var GroupType; +(function (GroupType) { + GroupType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GroupType = exports.GroupType || (exports.GroupType = {})); +var AdminListGroupsForUserResponse; +(function (AdminListGroupsForUserResponse) { + AdminListGroupsForUserResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminListGroupsForUserResponse = exports.AdminListGroupsForUserResponse || (exports.AdminListGroupsForUserResponse = {})); +var AdminListUserAuthEventsRequest; +(function (AdminListUserAuthEventsRequest) { + AdminListUserAuthEventsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminListUserAuthEventsRequest = exports.AdminListUserAuthEventsRequest || (exports.AdminListUserAuthEventsRequest = {})); +var ChallengeName; +(function (ChallengeName) { + ChallengeName["Mfa"] = "Mfa"; + ChallengeName["Password"] = "Password"; +})(ChallengeName = exports.ChallengeName || (exports.ChallengeName = {})); +var ChallengeResponse; +(function (ChallengeResponse) { + ChallengeResponse["Failure"] = "Failure"; + ChallengeResponse["Success"] = "Success"; +})(ChallengeResponse = exports.ChallengeResponse || (exports.ChallengeResponse = {})); +var ChallengeResponseType; +(function (ChallengeResponseType) { + ChallengeResponseType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ChallengeResponseType = exports.ChallengeResponseType || (exports.ChallengeResponseType = {})); +var EventContextDataType; +(function (EventContextDataType) { + EventContextDataType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(EventContextDataType = exports.EventContextDataType || (exports.EventContextDataType = {})); +var FeedbackValueType; +(function (FeedbackValueType) { + FeedbackValueType["INVALID"] = "Invalid"; + FeedbackValueType["VALID"] = "Valid"; +})(FeedbackValueType = exports.FeedbackValueType || (exports.FeedbackValueType = {})); +var EventFeedbackType; +(function (EventFeedbackType) { + EventFeedbackType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(EventFeedbackType = exports.EventFeedbackType || (exports.EventFeedbackType = {})); +var EventResponseType; +(function (EventResponseType) { + EventResponseType["Failure"] = "Failure"; + EventResponseType["Success"] = "Success"; +})(EventResponseType = exports.EventResponseType || (exports.EventResponseType = {})); +var RiskDecisionType; +(function (RiskDecisionType) { + RiskDecisionType["AccountTakeover"] = "AccountTakeover"; + RiskDecisionType["Block"] = "Block"; + RiskDecisionType["NoRisk"] = "NoRisk"; +})(RiskDecisionType = exports.RiskDecisionType || (exports.RiskDecisionType = {})); +var RiskLevelType; +(function (RiskLevelType) { + RiskLevelType["High"] = "High"; + RiskLevelType["Low"] = "Low"; + RiskLevelType["Medium"] = "Medium"; +})(RiskLevelType = exports.RiskLevelType || (exports.RiskLevelType = {})); +var EventRiskType; +(function (EventRiskType) { + EventRiskType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(EventRiskType = exports.EventRiskType || (exports.EventRiskType = {})); +var EventType; +(function (EventType) { + EventType["ForgotPassword"] = "ForgotPassword"; + EventType["SignIn"] = "SignIn"; + EventType["SignUp"] = "SignUp"; +})(EventType = exports.EventType || (exports.EventType = {})); +var AuthEventType; +(function (AuthEventType) { + AuthEventType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuthEventType = exports.AuthEventType || (exports.AuthEventType = {})); +var AdminListUserAuthEventsResponse; +(function (AdminListUserAuthEventsResponse) { + AdminListUserAuthEventsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminListUserAuthEventsResponse = exports.AdminListUserAuthEventsResponse || (exports.AdminListUserAuthEventsResponse = {})); +var UserPoolAddOnNotEnabledException; +(function (UserPoolAddOnNotEnabledException) { + UserPoolAddOnNotEnabledException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserPoolAddOnNotEnabledException = exports.UserPoolAddOnNotEnabledException || (exports.UserPoolAddOnNotEnabledException = {})); +var AdminRemoveUserFromGroupRequest; +(function (AdminRemoveUserFromGroupRequest) { + AdminRemoveUserFromGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminRemoveUserFromGroupRequest = exports.AdminRemoveUserFromGroupRequest || (exports.AdminRemoveUserFromGroupRequest = {})); +var AdminResetUserPasswordRequest; +(function (AdminResetUserPasswordRequest) { + AdminResetUserPasswordRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminResetUserPasswordRequest = exports.AdminResetUserPasswordRequest || (exports.AdminResetUserPasswordRequest = {})); +var AdminResetUserPasswordResponse; +(function (AdminResetUserPasswordResponse) { + AdminResetUserPasswordResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminResetUserPasswordResponse = exports.AdminResetUserPasswordResponse || (exports.AdminResetUserPasswordResponse = {})); +var InvalidEmailRoleAccessPolicyException; +(function (InvalidEmailRoleAccessPolicyException) { + InvalidEmailRoleAccessPolicyException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidEmailRoleAccessPolicyException = exports.InvalidEmailRoleAccessPolicyException || (exports.InvalidEmailRoleAccessPolicyException = {})); +var AdminRespondToAuthChallengeRequest; +(function (AdminRespondToAuthChallengeRequest) { + AdminRespondToAuthChallengeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminRespondToAuthChallengeRequest = exports.AdminRespondToAuthChallengeRequest || (exports.AdminRespondToAuthChallengeRequest = {})); +var AdminRespondToAuthChallengeResponse; +(function (AdminRespondToAuthChallengeResponse) { + AdminRespondToAuthChallengeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AuthenticationResult && { + AuthenticationResult: AuthenticationResultType.filterSensitiveLog(obj.AuthenticationResult), + }), + }); +})(AdminRespondToAuthChallengeResponse = exports.AdminRespondToAuthChallengeResponse || (exports.AdminRespondToAuthChallengeResponse = {})); +var CodeMismatchException; +(function (CodeMismatchException) { + CodeMismatchException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CodeMismatchException = exports.CodeMismatchException || (exports.CodeMismatchException = {})); +var ExpiredCodeException; +(function (ExpiredCodeException) { + ExpiredCodeException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ExpiredCodeException = exports.ExpiredCodeException || (exports.ExpiredCodeException = {})); +var SoftwareTokenMFANotFoundException; +(function (SoftwareTokenMFANotFoundException) { + SoftwareTokenMFANotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SoftwareTokenMFANotFoundException = exports.SoftwareTokenMFANotFoundException || (exports.SoftwareTokenMFANotFoundException = {})); +var SMSMfaSettingsType; +(function (SMSMfaSettingsType) { + SMSMfaSettingsType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SMSMfaSettingsType = exports.SMSMfaSettingsType || (exports.SMSMfaSettingsType = {})); +var SoftwareTokenMfaSettingsType; +(function (SoftwareTokenMfaSettingsType) { + SoftwareTokenMfaSettingsType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SoftwareTokenMfaSettingsType = exports.SoftwareTokenMfaSettingsType || (exports.SoftwareTokenMfaSettingsType = {})); +var AdminSetUserMFAPreferenceRequest; +(function (AdminSetUserMFAPreferenceRequest) { + AdminSetUserMFAPreferenceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminSetUserMFAPreferenceRequest = exports.AdminSetUserMFAPreferenceRequest || (exports.AdminSetUserMFAPreferenceRequest = {})); +var AdminSetUserMFAPreferenceResponse; +(function (AdminSetUserMFAPreferenceResponse) { + AdminSetUserMFAPreferenceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminSetUserMFAPreferenceResponse = exports.AdminSetUserMFAPreferenceResponse || (exports.AdminSetUserMFAPreferenceResponse = {})); +var AdminSetUserPasswordRequest; +(function (AdminSetUserPasswordRequest) { + AdminSetUserPasswordRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + ...(obj.Password && { Password: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminSetUserPasswordRequest = exports.AdminSetUserPasswordRequest || (exports.AdminSetUserPasswordRequest = {})); +var AdminSetUserPasswordResponse; +(function (AdminSetUserPasswordResponse) { + AdminSetUserPasswordResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminSetUserPasswordResponse = exports.AdminSetUserPasswordResponse || (exports.AdminSetUserPasswordResponse = {})); +var AdminSetUserSettingsRequest; +(function (AdminSetUserSettingsRequest) { + AdminSetUserSettingsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminSetUserSettingsRequest = exports.AdminSetUserSettingsRequest || (exports.AdminSetUserSettingsRequest = {})); +var AdminSetUserSettingsResponse; +(function (AdminSetUserSettingsResponse) { + AdminSetUserSettingsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminSetUserSettingsResponse = exports.AdminSetUserSettingsResponse || (exports.AdminSetUserSettingsResponse = {})); +var AdminUpdateAuthEventFeedbackRequest; +(function (AdminUpdateAuthEventFeedbackRequest) { + AdminUpdateAuthEventFeedbackRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminUpdateAuthEventFeedbackRequest = exports.AdminUpdateAuthEventFeedbackRequest || (exports.AdminUpdateAuthEventFeedbackRequest = {})); +var AdminUpdateAuthEventFeedbackResponse; +(function (AdminUpdateAuthEventFeedbackResponse) { + AdminUpdateAuthEventFeedbackResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminUpdateAuthEventFeedbackResponse = exports.AdminUpdateAuthEventFeedbackResponse || (exports.AdminUpdateAuthEventFeedbackResponse = {})); +var DeviceRememberedStatusType; +(function (DeviceRememberedStatusType) { + DeviceRememberedStatusType["NOT_REMEMBERED"] = "not_remembered"; + DeviceRememberedStatusType["REMEMBERED"] = "remembered"; +})(DeviceRememberedStatusType = exports.DeviceRememberedStatusType || (exports.DeviceRememberedStatusType = {})); +var AdminUpdateDeviceStatusRequest; +(function (AdminUpdateDeviceStatusRequest) { + AdminUpdateDeviceStatusRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminUpdateDeviceStatusRequest = exports.AdminUpdateDeviceStatusRequest || (exports.AdminUpdateDeviceStatusRequest = {})); +var AdminUpdateDeviceStatusResponse; +(function (AdminUpdateDeviceStatusResponse) { + AdminUpdateDeviceStatusResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminUpdateDeviceStatusResponse = exports.AdminUpdateDeviceStatusResponse || (exports.AdminUpdateDeviceStatusResponse = {})); +var AdminUpdateUserAttributesRequest; +(function (AdminUpdateUserAttributesRequest) { + AdminUpdateUserAttributesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + ...(obj.UserAttributes && { + UserAttributes: obj.UserAttributes.map((item) => AttributeType.filterSensitiveLog(item)), + }), + }); +})(AdminUpdateUserAttributesRequest = exports.AdminUpdateUserAttributesRequest || (exports.AdminUpdateUserAttributesRequest = {})); +var AdminUpdateUserAttributesResponse; +(function (AdminUpdateUserAttributesResponse) { + AdminUpdateUserAttributesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminUpdateUserAttributesResponse = exports.AdminUpdateUserAttributesResponse || (exports.AdminUpdateUserAttributesResponse = {})); +var AdminUserGlobalSignOutRequest; +(function (AdminUserGlobalSignOutRequest) { + AdminUserGlobalSignOutRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(AdminUserGlobalSignOutRequest = exports.AdminUserGlobalSignOutRequest || (exports.AdminUserGlobalSignOutRequest = {})); +var AdminUserGlobalSignOutResponse; +(function (AdminUserGlobalSignOutResponse) { + AdminUserGlobalSignOutResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AdminUserGlobalSignOutResponse = exports.AdminUserGlobalSignOutResponse || (exports.AdminUserGlobalSignOutResponse = {})); +var AdvancedSecurityModeType; +(function (AdvancedSecurityModeType) { + AdvancedSecurityModeType["AUDIT"] = "AUDIT"; + AdvancedSecurityModeType["ENFORCED"] = "ENFORCED"; + AdvancedSecurityModeType["OFF"] = "OFF"; +})(AdvancedSecurityModeType = exports.AdvancedSecurityModeType || (exports.AdvancedSecurityModeType = {})); +var AliasAttributeType; +(function (AliasAttributeType) { + AliasAttributeType["EMAIL"] = "email"; + AliasAttributeType["PHONE_NUMBER"] = "phone_number"; + AliasAttributeType["PREFERRED_USERNAME"] = "preferred_username"; +})(AliasAttributeType = exports.AliasAttributeType || (exports.AliasAttributeType = {})); +var AnalyticsConfigurationType; +(function (AnalyticsConfigurationType) { + AnalyticsConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AnalyticsConfigurationType = exports.AnalyticsConfigurationType || (exports.AnalyticsConfigurationType = {})); +var AssociateSoftwareTokenRequest; +(function (AssociateSoftwareTokenRequest) { + AssociateSoftwareTokenRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(AssociateSoftwareTokenRequest = exports.AssociateSoftwareTokenRequest || (exports.AssociateSoftwareTokenRequest = {})); +var AssociateSoftwareTokenResponse; +(function (AssociateSoftwareTokenResponse) { + AssociateSoftwareTokenResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.SecretCode && { SecretCode: smithy_client_1.SENSITIVE_STRING }), + }); +})(AssociateSoftwareTokenResponse = exports.AssociateSoftwareTokenResponse || (exports.AssociateSoftwareTokenResponse = {})); +var ConcurrentModificationException; +(function (ConcurrentModificationException) { + ConcurrentModificationException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ConcurrentModificationException = exports.ConcurrentModificationException || (exports.ConcurrentModificationException = {})); +var ChangePasswordRequest; +(function (ChangePasswordRequest) { + ChangePasswordRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.PreviousPassword && { PreviousPassword: smithy_client_1.SENSITIVE_STRING }), + ...(obj.ProposedPassword && { ProposedPassword: smithy_client_1.SENSITIVE_STRING }), + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(ChangePasswordRequest = exports.ChangePasswordRequest || (exports.ChangePasswordRequest = {})); +var ChangePasswordResponse; +(function (ChangePasswordResponse) { + ChangePasswordResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ChangePasswordResponse = exports.ChangePasswordResponse || (exports.ChangePasswordResponse = {})); +var DeviceSecretVerifierConfigType; +(function (DeviceSecretVerifierConfigType) { + DeviceSecretVerifierConfigType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeviceSecretVerifierConfigType = exports.DeviceSecretVerifierConfigType || (exports.DeviceSecretVerifierConfigType = {})); +var ConfirmDeviceRequest; +(function (ConfirmDeviceRequest) { + ConfirmDeviceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(ConfirmDeviceRequest = exports.ConfirmDeviceRequest || (exports.ConfirmDeviceRequest = {})); +var ConfirmDeviceResponse; +(function (ConfirmDeviceResponse) { + ConfirmDeviceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ConfirmDeviceResponse = exports.ConfirmDeviceResponse || (exports.ConfirmDeviceResponse = {})); +var UserContextDataType; +(function (UserContextDataType) { + UserContextDataType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserContextDataType = exports.UserContextDataType || (exports.UserContextDataType = {})); +var ConfirmForgotPasswordRequest; +(function (ConfirmForgotPasswordRequest) { + ConfirmForgotPasswordRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + ...(obj.SecretHash && { SecretHash: smithy_client_1.SENSITIVE_STRING }), + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + ...(obj.Password && { Password: smithy_client_1.SENSITIVE_STRING }), + }); +})(ConfirmForgotPasswordRequest = exports.ConfirmForgotPasswordRequest || (exports.ConfirmForgotPasswordRequest = {})); +var ConfirmForgotPasswordResponse; +(function (ConfirmForgotPasswordResponse) { + ConfirmForgotPasswordResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ConfirmForgotPasswordResponse = exports.ConfirmForgotPasswordResponse || (exports.ConfirmForgotPasswordResponse = {})); +var ConfirmSignUpRequest; +(function (ConfirmSignUpRequest) { + ConfirmSignUpRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + ...(obj.SecretHash && { SecretHash: smithy_client_1.SENSITIVE_STRING }), + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(ConfirmSignUpRequest = exports.ConfirmSignUpRequest || (exports.ConfirmSignUpRequest = {})); +var ConfirmSignUpResponse; +(function (ConfirmSignUpResponse) { + ConfirmSignUpResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ConfirmSignUpResponse = exports.ConfirmSignUpResponse || (exports.ConfirmSignUpResponse = {})); +var CreateGroupRequest; +(function (CreateGroupRequest) { + CreateGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateGroupRequest = exports.CreateGroupRequest || (exports.CreateGroupRequest = {})); +var CreateGroupResponse; +(function (CreateGroupResponse) { + CreateGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateGroupResponse = exports.CreateGroupResponse || (exports.CreateGroupResponse = {})); +var GroupExistsException; +(function (GroupExistsException) { + GroupExistsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GroupExistsException = exports.GroupExistsException || (exports.GroupExistsException = {})); +var IdentityProviderTypeType; +(function (IdentityProviderTypeType) { + IdentityProviderTypeType["Facebook"] = "Facebook"; + IdentityProviderTypeType["Google"] = "Google"; + IdentityProviderTypeType["LoginWithAmazon"] = "LoginWithAmazon"; + IdentityProviderTypeType["OIDC"] = "OIDC"; + IdentityProviderTypeType["SAML"] = "SAML"; + IdentityProviderTypeType["SignInWithApple"] = "SignInWithApple"; +})(IdentityProviderTypeType = exports.IdentityProviderTypeType || (exports.IdentityProviderTypeType = {})); +var CreateIdentityProviderRequest; +(function (CreateIdentityProviderRequest) { + CreateIdentityProviderRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateIdentityProviderRequest = exports.CreateIdentityProviderRequest || (exports.CreateIdentityProviderRequest = {})); +var IdentityProviderType; +(function (IdentityProviderType) { + IdentityProviderType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(IdentityProviderType = exports.IdentityProviderType || (exports.IdentityProviderType = {})); +var CreateIdentityProviderResponse; +(function (CreateIdentityProviderResponse) { + CreateIdentityProviderResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateIdentityProviderResponse = exports.CreateIdentityProviderResponse || (exports.CreateIdentityProviderResponse = {})); +var DuplicateProviderException; +(function (DuplicateProviderException) { + DuplicateProviderException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DuplicateProviderException = exports.DuplicateProviderException || (exports.DuplicateProviderException = {})); +var ResourceServerScopeType; +(function (ResourceServerScopeType) { + ResourceServerScopeType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceServerScopeType = exports.ResourceServerScopeType || (exports.ResourceServerScopeType = {})); +var CreateResourceServerRequest; +(function (CreateResourceServerRequest) { + CreateResourceServerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateResourceServerRequest = exports.CreateResourceServerRequest || (exports.CreateResourceServerRequest = {})); +var ResourceServerType; +(function (ResourceServerType) { + ResourceServerType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceServerType = exports.ResourceServerType || (exports.ResourceServerType = {})); +var CreateResourceServerResponse; +(function (CreateResourceServerResponse) { + CreateResourceServerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateResourceServerResponse = exports.CreateResourceServerResponse || (exports.CreateResourceServerResponse = {})); +var CreateUserImportJobRequest; +(function (CreateUserImportJobRequest) { + CreateUserImportJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateUserImportJobRequest = exports.CreateUserImportJobRequest || (exports.CreateUserImportJobRequest = {})); +var UserImportJobStatusType; +(function (UserImportJobStatusType) { + UserImportJobStatusType["Created"] = "Created"; + UserImportJobStatusType["Expired"] = "Expired"; + UserImportJobStatusType["Failed"] = "Failed"; + UserImportJobStatusType["InProgress"] = "InProgress"; + UserImportJobStatusType["Pending"] = "Pending"; + UserImportJobStatusType["Stopped"] = "Stopped"; + UserImportJobStatusType["Stopping"] = "Stopping"; + UserImportJobStatusType["Succeeded"] = "Succeeded"; +})(UserImportJobStatusType = exports.UserImportJobStatusType || (exports.UserImportJobStatusType = {})); +var UserImportJobType; +(function (UserImportJobType) { + UserImportJobType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserImportJobType = exports.UserImportJobType || (exports.UserImportJobType = {})); +var CreateUserImportJobResponse; +(function (CreateUserImportJobResponse) { + CreateUserImportJobResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateUserImportJobResponse = exports.CreateUserImportJobResponse || (exports.CreateUserImportJobResponse = {})); +var VerifiedAttributeType; +(function (VerifiedAttributeType) { + VerifiedAttributeType["EMAIL"] = "email"; + VerifiedAttributeType["PHONE_NUMBER"] = "phone_number"; +})(VerifiedAttributeType = exports.VerifiedAttributeType || (exports.VerifiedAttributeType = {})); +var DeviceConfigurationType; +(function (DeviceConfigurationType) { + DeviceConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeviceConfigurationType = exports.DeviceConfigurationType || (exports.DeviceConfigurationType = {})); +var EmailSendingAccountType; +(function (EmailSendingAccountType) { + EmailSendingAccountType["COGNITO_DEFAULT"] = "COGNITO_DEFAULT"; + EmailSendingAccountType["DEVELOPER"] = "DEVELOPER"; +})(EmailSendingAccountType = exports.EmailSendingAccountType || (exports.EmailSendingAccountType = {})); +var EmailConfigurationType; +(function (EmailConfigurationType) { + EmailConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(EmailConfigurationType = exports.EmailConfigurationType || (exports.EmailConfigurationType = {})); +var CustomEmailSenderLambdaVersionType; +(function (CustomEmailSenderLambdaVersionType) { + CustomEmailSenderLambdaVersionType["V1_0"] = "V1_0"; +})(CustomEmailSenderLambdaVersionType = exports.CustomEmailSenderLambdaVersionType || (exports.CustomEmailSenderLambdaVersionType = {})); +var CustomEmailLambdaVersionConfigType; +(function (CustomEmailLambdaVersionConfigType) { + CustomEmailLambdaVersionConfigType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CustomEmailLambdaVersionConfigType = exports.CustomEmailLambdaVersionConfigType || (exports.CustomEmailLambdaVersionConfigType = {})); +var CustomSMSSenderLambdaVersionType; +(function (CustomSMSSenderLambdaVersionType) { + CustomSMSSenderLambdaVersionType["V1_0"] = "V1_0"; +})(CustomSMSSenderLambdaVersionType = exports.CustomSMSSenderLambdaVersionType || (exports.CustomSMSSenderLambdaVersionType = {})); +var CustomSMSLambdaVersionConfigType; +(function (CustomSMSLambdaVersionConfigType) { + CustomSMSLambdaVersionConfigType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CustomSMSLambdaVersionConfigType = exports.CustomSMSLambdaVersionConfigType || (exports.CustomSMSLambdaVersionConfigType = {})); +var LambdaConfigType; +(function (LambdaConfigType) { + LambdaConfigType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LambdaConfigType = exports.LambdaConfigType || (exports.LambdaConfigType = {})); +var UserPoolMfaType; +(function (UserPoolMfaType) { + UserPoolMfaType["OFF"] = "OFF"; + UserPoolMfaType["ON"] = "ON"; + UserPoolMfaType["OPTIONAL"] = "OPTIONAL"; +})(UserPoolMfaType = exports.UserPoolMfaType || (exports.UserPoolMfaType = {})); +var PasswordPolicyType; +(function (PasswordPolicyType) { + PasswordPolicyType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PasswordPolicyType = exports.PasswordPolicyType || (exports.PasswordPolicyType = {})); +var UserPoolPolicyType; +(function (UserPoolPolicyType) { + UserPoolPolicyType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserPoolPolicyType = exports.UserPoolPolicyType || (exports.UserPoolPolicyType = {})); +var SmsConfigurationType; +(function (SmsConfigurationType) { + SmsConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SmsConfigurationType = exports.SmsConfigurationType || (exports.SmsConfigurationType = {})); +var UsernameAttributeType; +(function (UsernameAttributeType) { + UsernameAttributeType["EMAIL"] = "email"; + UsernameAttributeType["PHONE_NUMBER"] = "phone_number"; +})(UsernameAttributeType = exports.UsernameAttributeType || (exports.UsernameAttributeType = {})); +var UsernameConfigurationType; +(function (UsernameConfigurationType) { + UsernameConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UsernameConfigurationType = exports.UsernameConfigurationType || (exports.UsernameConfigurationType = {})); +var UserPoolAddOnsType; +(function (UserPoolAddOnsType) { + UserPoolAddOnsType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserPoolAddOnsType = exports.UserPoolAddOnsType || (exports.UserPoolAddOnsType = {})); +var DefaultEmailOptionType; +(function (DefaultEmailOptionType) { + DefaultEmailOptionType["CONFIRM_WITH_CODE"] = "CONFIRM_WITH_CODE"; + DefaultEmailOptionType["CONFIRM_WITH_LINK"] = "CONFIRM_WITH_LINK"; +})(DefaultEmailOptionType = exports.DefaultEmailOptionType || (exports.DefaultEmailOptionType = {})); +var VerificationMessageTemplateType; +(function (VerificationMessageTemplateType) { + VerificationMessageTemplateType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(VerificationMessageTemplateType = exports.VerificationMessageTemplateType || (exports.VerificationMessageTemplateType = {})); +var CreateUserPoolRequest; +(function (CreateUserPoolRequest) { + CreateUserPoolRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateUserPoolRequest = exports.CreateUserPoolRequest || (exports.CreateUserPoolRequest = {})); +var StatusType; +(function (StatusType) { + StatusType["Disabled"] = "Disabled"; + StatusType["Enabled"] = "Enabled"; +})(StatusType = exports.StatusType || (exports.StatusType = {})); +var UserPoolType; +(function (UserPoolType) { + UserPoolType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserPoolType = exports.UserPoolType || (exports.UserPoolType = {})); +var CreateUserPoolResponse; +(function (CreateUserPoolResponse) { + CreateUserPoolResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateUserPoolResponse = exports.CreateUserPoolResponse || (exports.CreateUserPoolResponse = {})); +var UserPoolTaggingException; +(function (UserPoolTaggingException) { + UserPoolTaggingException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserPoolTaggingException = exports.UserPoolTaggingException || (exports.UserPoolTaggingException = {})); +var OAuthFlowType; +(function (OAuthFlowType) { + OAuthFlowType["client_credentials"] = "client_credentials"; + OAuthFlowType["code"] = "code"; + OAuthFlowType["implicit"] = "implicit"; +})(OAuthFlowType = exports.OAuthFlowType || (exports.OAuthFlowType = {})); +var ExplicitAuthFlowsType; +(function (ExplicitAuthFlowsType) { + ExplicitAuthFlowsType["ADMIN_NO_SRP_AUTH"] = "ADMIN_NO_SRP_AUTH"; + ExplicitAuthFlowsType["ALLOW_ADMIN_USER_PASSWORD_AUTH"] = "ALLOW_ADMIN_USER_PASSWORD_AUTH"; + ExplicitAuthFlowsType["ALLOW_CUSTOM_AUTH"] = "ALLOW_CUSTOM_AUTH"; + ExplicitAuthFlowsType["ALLOW_REFRESH_TOKEN_AUTH"] = "ALLOW_REFRESH_TOKEN_AUTH"; + ExplicitAuthFlowsType["ALLOW_USER_PASSWORD_AUTH"] = "ALLOW_USER_PASSWORD_AUTH"; + ExplicitAuthFlowsType["ALLOW_USER_SRP_AUTH"] = "ALLOW_USER_SRP_AUTH"; + ExplicitAuthFlowsType["CUSTOM_AUTH_FLOW_ONLY"] = "CUSTOM_AUTH_FLOW_ONLY"; + ExplicitAuthFlowsType["USER_PASSWORD_AUTH"] = "USER_PASSWORD_AUTH"; +})(ExplicitAuthFlowsType = exports.ExplicitAuthFlowsType || (exports.ExplicitAuthFlowsType = {})); +var PreventUserExistenceErrorTypes; +(function (PreventUserExistenceErrorTypes) { + PreventUserExistenceErrorTypes["ENABLED"] = "ENABLED"; + PreventUserExistenceErrorTypes["LEGACY"] = "LEGACY"; +})(PreventUserExistenceErrorTypes = exports.PreventUserExistenceErrorTypes || (exports.PreventUserExistenceErrorTypes = {})); +var TimeUnitsType; +(function (TimeUnitsType) { + TimeUnitsType["DAYS"] = "days"; + TimeUnitsType["HOURS"] = "hours"; + TimeUnitsType["MINUTES"] = "minutes"; + TimeUnitsType["SECONDS"] = "seconds"; +})(TimeUnitsType = exports.TimeUnitsType || (exports.TimeUnitsType = {})); +var TokenValidityUnitsType; +(function (TokenValidityUnitsType) { + TokenValidityUnitsType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TokenValidityUnitsType = exports.TokenValidityUnitsType || (exports.TokenValidityUnitsType = {})); +var CreateUserPoolClientRequest; +(function (CreateUserPoolClientRequest) { + CreateUserPoolClientRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateUserPoolClientRequest = exports.CreateUserPoolClientRequest || (exports.CreateUserPoolClientRequest = {})); +var UserPoolClientType; +(function (UserPoolClientType) { + UserPoolClientType.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + ...(obj.ClientSecret && { ClientSecret: smithy_client_1.SENSITIVE_STRING }), + }); +})(UserPoolClientType = exports.UserPoolClientType || (exports.UserPoolClientType = {})); +var CreateUserPoolClientResponse; +(function (CreateUserPoolClientResponse) { + CreateUserPoolClientResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.UserPoolClient && { UserPoolClient: UserPoolClientType.filterSensitiveLog(obj.UserPoolClient) }), + }); +})(CreateUserPoolClientResponse = exports.CreateUserPoolClientResponse || (exports.CreateUserPoolClientResponse = {})); +var InvalidOAuthFlowException; +(function (InvalidOAuthFlowException) { + InvalidOAuthFlowException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidOAuthFlowException = exports.InvalidOAuthFlowException || (exports.InvalidOAuthFlowException = {})); +var ScopeDoesNotExistException; +(function (ScopeDoesNotExistException) { + ScopeDoesNotExistException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ScopeDoesNotExistException = exports.ScopeDoesNotExistException || (exports.ScopeDoesNotExistException = {})); +var CustomDomainConfigType; +(function (CustomDomainConfigType) { + CustomDomainConfigType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CustomDomainConfigType = exports.CustomDomainConfigType || (exports.CustomDomainConfigType = {})); +var CreateUserPoolDomainRequest; +(function (CreateUserPoolDomainRequest) { + CreateUserPoolDomainRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateUserPoolDomainRequest = exports.CreateUserPoolDomainRequest || (exports.CreateUserPoolDomainRequest = {})); +var CreateUserPoolDomainResponse; +(function (CreateUserPoolDomainResponse) { + CreateUserPoolDomainResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateUserPoolDomainResponse = exports.CreateUserPoolDomainResponse || (exports.CreateUserPoolDomainResponse = {})); +var DeleteGroupRequest; +(function (DeleteGroupRequest) { + DeleteGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteGroupRequest = exports.DeleteGroupRequest || (exports.DeleteGroupRequest = {})); +var DeleteIdentityProviderRequest; +(function (DeleteIdentityProviderRequest) { + DeleteIdentityProviderRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteIdentityProviderRequest = exports.DeleteIdentityProviderRequest || (exports.DeleteIdentityProviderRequest = {})); +var UnsupportedIdentityProviderException; +(function (UnsupportedIdentityProviderException) { + UnsupportedIdentityProviderException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UnsupportedIdentityProviderException = exports.UnsupportedIdentityProviderException || (exports.UnsupportedIdentityProviderException = {})); +var DeleteResourceServerRequest; +(function (DeleteResourceServerRequest) { + DeleteResourceServerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteResourceServerRequest = exports.DeleteResourceServerRequest || (exports.DeleteResourceServerRequest = {})); +var DeleteUserRequest; +(function (DeleteUserRequest) { + DeleteUserRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(DeleteUserRequest = exports.DeleteUserRequest || (exports.DeleteUserRequest = {})); +var DeleteUserAttributesRequest; +(function (DeleteUserAttributesRequest) { + DeleteUserAttributesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(DeleteUserAttributesRequest = exports.DeleteUserAttributesRequest || (exports.DeleteUserAttributesRequest = {})); +var DeleteUserAttributesResponse; +(function (DeleteUserAttributesResponse) { + DeleteUserAttributesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteUserAttributesResponse = exports.DeleteUserAttributesResponse || (exports.DeleteUserAttributesResponse = {})); +var DeleteUserPoolRequest; +(function (DeleteUserPoolRequest) { + DeleteUserPoolRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteUserPoolRequest = exports.DeleteUserPoolRequest || (exports.DeleteUserPoolRequest = {})); +var DeleteUserPoolClientRequest; +(function (DeleteUserPoolClientRequest) { + DeleteUserPoolClientRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(DeleteUserPoolClientRequest = exports.DeleteUserPoolClientRequest || (exports.DeleteUserPoolClientRequest = {})); +var DeleteUserPoolDomainRequest; +(function (DeleteUserPoolDomainRequest) { + DeleteUserPoolDomainRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteUserPoolDomainRequest = exports.DeleteUserPoolDomainRequest || (exports.DeleteUserPoolDomainRequest = {})); +var DeleteUserPoolDomainResponse; +(function (DeleteUserPoolDomainResponse) { + DeleteUserPoolDomainResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteUserPoolDomainResponse = exports.DeleteUserPoolDomainResponse || (exports.DeleteUserPoolDomainResponse = {})); +var DescribeIdentityProviderRequest; +(function (DescribeIdentityProviderRequest) { + DescribeIdentityProviderRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeIdentityProviderRequest = exports.DescribeIdentityProviderRequest || (exports.DescribeIdentityProviderRequest = {})); +var DescribeIdentityProviderResponse; +(function (DescribeIdentityProviderResponse) { + DescribeIdentityProviderResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeIdentityProviderResponse = exports.DescribeIdentityProviderResponse || (exports.DescribeIdentityProviderResponse = {})); +var DescribeResourceServerRequest; +(function (DescribeResourceServerRequest) { + DescribeResourceServerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeResourceServerRequest = exports.DescribeResourceServerRequest || (exports.DescribeResourceServerRequest = {})); +var DescribeResourceServerResponse; +(function (DescribeResourceServerResponse) { + DescribeResourceServerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeResourceServerResponse = exports.DescribeResourceServerResponse || (exports.DescribeResourceServerResponse = {})); +var DescribeRiskConfigurationRequest; +(function (DescribeRiskConfigurationRequest) { + DescribeRiskConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(DescribeRiskConfigurationRequest = exports.DescribeRiskConfigurationRequest || (exports.DescribeRiskConfigurationRequest = {})); +var CompromisedCredentialsEventActionType; +(function (CompromisedCredentialsEventActionType) { + CompromisedCredentialsEventActionType["BLOCK"] = "BLOCK"; + CompromisedCredentialsEventActionType["NO_ACTION"] = "NO_ACTION"; +})(CompromisedCredentialsEventActionType = exports.CompromisedCredentialsEventActionType || (exports.CompromisedCredentialsEventActionType = {})); +var CompromisedCredentialsActionsType; +(function (CompromisedCredentialsActionsType) { + CompromisedCredentialsActionsType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CompromisedCredentialsActionsType = exports.CompromisedCredentialsActionsType || (exports.CompromisedCredentialsActionsType = {})); +var EventFilterType; +(function (EventFilterType) { + EventFilterType["PASSWORD_CHANGE"] = "PASSWORD_CHANGE"; + EventFilterType["SIGN_IN"] = "SIGN_IN"; + EventFilterType["SIGN_UP"] = "SIGN_UP"; +})(EventFilterType = exports.EventFilterType || (exports.EventFilterType = {})); +var CompromisedCredentialsRiskConfigurationType; +(function (CompromisedCredentialsRiskConfigurationType) { + CompromisedCredentialsRiskConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CompromisedCredentialsRiskConfigurationType = exports.CompromisedCredentialsRiskConfigurationType || (exports.CompromisedCredentialsRiskConfigurationType = {})); +var RiskExceptionConfigurationType; +(function (RiskExceptionConfigurationType) { + RiskExceptionConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RiskExceptionConfigurationType = exports.RiskExceptionConfigurationType || (exports.RiskExceptionConfigurationType = {})); +var RiskConfigurationType; +(function (RiskConfigurationType) { + RiskConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(RiskConfigurationType = exports.RiskConfigurationType || (exports.RiskConfigurationType = {})); +var DescribeRiskConfigurationResponse; +(function (DescribeRiskConfigurationResponse) { + DescribeRiskConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.RiskConfiguration && { + RiskConfiguration: RiskConfigurationType.filterSensitiveLog(obj.RiskConfiguration), + }), + }); +})(DescribeRiskConfigurationResponse = exports.DescribeRiskConfigurationResponse || (exports.DescribeRiskConfigurationResponse = {})); +var DescribeUserImportJobRequest; +(function (DescribeUserImportJobRequest) { + DescribeUserImportJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeUserImportJobRequest = exports.DescribeUserImportJobRequest || (exports.DescribeUserImportJobRequest = {})); +var DescribeUserImportJobResponse; +(function (DescribeUserImportJobResponse) { + DescribeUserImportJobResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeUserImportJobResponse = exports.DescribeUserImportJobResponse || (exports.DescribeUserImportJobResponse = {})); +var DescribeUserPoolRequest; +(function (DescribeUserPoolRequest) { + DescribeUserPoolRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeUserPoolRequest = exports.DescribeUserPoolRequest || (exports.DescribeUserPoolRequest = {})); +var DescribeUserPoolResponse; +(function (DescribeUserPoolResponse) { + DescribeUserPoolResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeUserPoolResponse = exports.DescribeUserPoolResponse || (exports.DescribeUserPoolResponse = {})); +var DescribeUserPoolClientRequest; +(function (DescribeUserPoolClientRequest) { + DescribeUserPoolClientRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(DescribeUserPoolClientRequest = exports.DescribeUserPoolClientRequest || (exports.DescribeUserPoolClientRequest = {})); +var DescribeUserPoolClientResponse; +(function (DescribeUserPoolClientResponse) { + DescribeUserPoolClientResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.UserPoolClient && { UserPoolClient: UserPoolClientType.filterSensitiveLog(obj.UserPoolClient) }), + }); +})(DescribeUserPoolClientResponse = exports.DescribeUserPoolClientResponse || (exports.DescribeUserPoolClientResponse = {})); +var DescribeUserPoolDomainRequest; +(function (DescribeUserPoolDomainRequest) { + DescribeUserPoolDomainRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeUserPoolDomainRequest = exports.DescribeUserPoolDomainRequest || (exports.DescribeUserPoolDomainRequest = {})); +var DomainStatusType; +(function (DomainStatusType) { + DomainStatusType["ACTIVE"] = "ACTIVE"; + DomainStatusType["CREATING"] = "CREATING"; + DomainStatusType["DELETING"] = "DELETING"; + DomainStatusType["FAILED"] = "FAILED"; + DomainStatusType["UPDATING"] = "UPDATING"; +})(DomainStatusType = exports.DomainStatusType || (exports.DomainStatusType = {})); +var DomainDescriptionType; +(function (DomainDescriptionType) { + DomainDescriptionType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DomainDescriptionType = exports.DomainDescriptionType || (exports.DomainDescriptionType = {})); +var DescribeUserPoolDomainResponse; +(function (DescribeUserPoolDomainResponse) { + DescribeUserPoolDomainResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeUserPoolDomainResponse = exports.DescribeUserPoolDomainResponse || (exports.DescribeUserPoolDomainResponse = {})); +var ForgetDeviceRequest; +(function (ForgetDeviceRequest) { + ForgetDeviceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(ForgetDeviceRequest = exports.ForgetDeviceRequest || (exports.ForgetDeviceRequest = {})); +var ForgotPasswordRequest; +(function (ForgotPasswordRequest) { + ForgotPasswordRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + ...(obj.SecretHash && { SecretHash: smithy_client_1.SENSITIVE_STRING }), + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(ForgotPasswordRequest = exports.ForgotPasswordRequest || (exports.ForgotPasswordRequest = {})); +var CodeDeliveryDetailsType; +(function (CodeDeliveryDetailsType) { + CodeDeliveryDetailsType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CodeDeliveryDetailsType = exports.CodeDeliveryDetailsType || (exports.CodeDeliveryDetailsType = {})); +var ForgotPasswordResponse; +(function (ForgotPasswordResponse) { + ForgotPasswordResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ForgotPasswordResponse = exports.ForgotPasswordResponse || (exports.ForgotPasswordResponse = {})); +var GetCSVHeaderRequest; +(function (GetCSVHeaderRequest) { + GetCSVHeaderRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetCSVHeaderRequest = exports.GetCSVHeaderRequest || (exports.GetCSVHeaderRequest = {})); +var GetCSVHeaderResponse; +(function (GetCSVHeaderResponse) { + GetCSVHeaderResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetCSVHeaderResponse = exports.GetCSVHeaderResponse || (exports.GetCSVHeaderResponse = {})); +var GetDeviceRequest; +(function (GetDeviceRequest) { + GetDeviceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(GetDeviceRequest = exports.GetDeviceRequest || (exports.GetDeviceRequest = {})); +var GetDeviceResponse; +(function (GetDeviceResponse) { + GetDeviceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Device && { Device: DeviceType.filterSensitiveLog(obj.Device) }), + }); +})(GetDeviceResponse = exports.GetDeviceResponse || (exports.GetDeviceResponse = {})); +var GetGroupRequest; +(function (GetGroupRequest) { + GetGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetGroupRequest = exports.GetGroupRequest || (exports.GetGroupRequest = {})); +var GetGroupResponse; +(function (GetGroupResponse) { + GetGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetGroupResponse = exports.GetGroupResponse || (exports.GetGroupResponse = {})); +var GetIdentityProviderByIdentifierRequest; +(function (GetIdentityProviderByIdentifierRequest) { + GetIdentityProviderByIdentifierRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetIdentityProviderByIdentifierRequest = exports.GetIdentityProviderByIdentifierRequest || (exports.GetIdentityProviderByIdentifierRequest = {})); +var GetIdentityProviderByIdentifierResponse; +(function (GetIdentityProviderByIdentifierResponse) { + GetIdentityProviderByIdentifierResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetIdentityProviderByIdentifierResponse = exports.GetIdentityProviderByIdentifierResponse || (exports.GetIdentityProviderByIdentifierResponse = {})); +var GetSigningCertificateRequest; +(function (GetSigningCertificateRequest) { + GetSigningCertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetSigningCertificateRequest = exports.GetSigningCertificateRequest || (exports.GetSigningCertificateRequest = {})); +var GetSigningCertificateResponse; +(function (GetSigningCertificateResponse) { + GetSigningCertificateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetSigningCertificateResponse = exports.GetSigningCertificateResponse || (exports.GetSigningCertificateResponse = {})); +var GetUICustomizationRequest; +(function (GetUICustomizationRequest) { + GetUICustomizationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(GetUICustomizationRequest = exports.GetUICustomizationRequest || (exports.GetUICustomizationRequest = {})); +var UICustomizationType; +(function (UICustomizationType) { + UICustomizationType.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(UICustomizationType = exports.UICustomizationType || (exports.UICustomizationType = {})); +var GetUICustomizationResponse; +(function (GetUICustomizationResponse) { + GetUICustomizationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.UICustomization && { UICustomization: UICustomizationType.filterSensitiveLog(obj.UICustomization) }), + }); +})(GetUICustomizationResponse = exports.GetUICustomizationResponse || (exports.GetUICustomizationResponse = {})); +var GetUserRequest; +(function (GetUserRequest) { + GetUserRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(GetUserRequest = exports.GetUserRequest || (exports.GetUserRequest = {})); +var GetUserResponse; +(function (GetUserResponse) { + GetUserResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + ...(obj.UserAttributes && { + UserAttributes: obj.UserAttributes.map((item) => AttributeType.filterSensitiveLog(item)), + }), + }); +})(GetUserResponse = exports.GetUserResponse || (exports.GetUserResponse = {})); +var GetUserAttributeVerificationCodeRequest; +(function (GetUserAttributeVerificationCodeRequest) { + GetUserAttributeVerificationCodeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(GetUserAttributeVerificationCodeRequest = exports.GetUserAttributeVerificationCodeRequest || (exports.GetUserAttributeVerificationCodeRequest = {})); +var GetUserAttributeVerificationCodeResponse; +(function (GetUserAttributeVerificationCodeResponse) { + GetUserAttributeVerificationCodeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetUserAttributeVerificationCodeResponse = exports.GetUserAttributeVerificationCodeResponse || (exports.GetUserAttributeVerificationCodeResponse = {})); +var GetUserPoolMfaConfigRequest; +(function (GetUserPoolMfaConfigRequest) { + GetUserPoolMfaConfigRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetUserPoolMfaConfigRequest = exports.GetUserPoolMfaConfigRequest || (exports.GetUserPoolMfaConfigRequest = {})); +var SmsMfaConfigType; +(function (SmsMfaConfigType) { + SmsMfaConfigType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SmsMfaConfigType = exports.SmsMfaConfigType || (exports.SmsMfaConfigType = {})); +var SoftwareTokenMfaConfigType; +(function (SoftwareTokenMfaConfigType) { + SoftwareTokenMfaConfigType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SoftwareTokenMfaConfigType = exports.SoftwareTokenMfaConfigType || (exports.SoftwareTokenMfaConfigType = {})); +var GetUserPoolMfaConfigResponse; +(function (GetUserPoolMfaConfigResponse) { + GetUserPoolMfaConfigResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetUserPoolMfaConfigResponse = exports.GetUserPoolMfaConfigResponse || (exports.GetUserPoolMfaConfigResponse = {})); +var GlobalSignOutRequest; +(function (GlobalSignOutRequest) { + GlobalSignOutRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(GlobalSignOutRequest = exports.GlobalSignOutRequest || (exports.GlobalSignOutRequest = {})); +var GlobalSignOutResponse; +(function (GlobalSignOutResponse) { + GlobalSignOutResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GlobalSignOutResponse = exports.GlobalSignOutResponse || (exports.GlobalSignOutResponse = {})); +var InitiateAuthRequest; +(function (InitiateAuthRequest) { + InitiateAuthRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AuthParameters && { AuthParameters: smithy_client_1.SENSITIVE_STRING }), + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(InitiateAuthRequest = exports.InitiateAuthRequest || (exports.InitiateAuthRequest = {})); +var InitiateAuthResponse; +(function (InitiateAuthResponse) { + InitiateAuthResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AuthenticationResult && { + AuthenticationResult: AuthenticationResultType.filterSensitiveLog(obj.AuthenticationResult), + }), + }); +})(InitiateAuthResponse = exports.InitiateAuthResponse || (exports.InitiateAuthResponse = {})); +var ListDevicesRequest; +(function (ListDevicesRequest) { + ListDevicesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(ListDevicesRequest = exports.ListDevicesRequest || (exports.ListDevicesRequest = {})); +var ListDevicesResponse; +(function (ListDevicesResponse) { + ListDevicesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListDevicesResponse = exports.ListDevicesResponse || (exports.ListDevicesResponse = {})); +var ListGroupsRequest; +(function (ListGroupsRequest) { + ListGroupsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListGroupsRequest = exports.ListGroupsRequest || (exports.ListGroupsRequest = {})); +var ListGroupsResponse; +(function (ListGroupsResponse) { + ListGroupsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListGroupsResponse = exports.ListGroupsResponse || (exports.ListGroupsResponse = {})); +var ListIdentityProvidersRequest; +(function (ListIdentityProvidersRequest) { + ListIdentityProvidersRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListIdentityProvidersRequest = exports.ListIdentityProvidersRequest || (exports.ListIdentityProvidersRequest = {})); +var ProviderDescription; +(function (ProviderDescription) { + ProviderDescription.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ProviderDescription = exports.ProviderDescription || (exports.ProviderDescription = {})); +var ListIdentityProvidersResponse; +(function (ListIdentityProvidersResponse) { + ListIdentityProvidersResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListIdentityProvidersResponse = exports.ListIdentityProvidersResponse || (exports.ListIdentityProvidersResponse = {})); +var ListResourceServersRequest; +(function (ListResourceServersRequest) { + ListResourceServersRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListResourceServersRequest = exports.ListResourceServersRequest || (exports.ListResourceServersRequest = {})); +var ListResourceServersResponse; +(function (ListResourceServersResponse) { + ListResourceServersResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListResourceServersResponse = exports.ListResourceServersResponse || (exports.ListResourceServersResponse = {})); +var ListTagsForResourceRequest; +(function (ListTagsForResourceRequest) { + ListTagsForResourceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTagsForResourceRequest = exports.ListTagsForResourceRequest || (exports.ListTagsForResourceRequest = {})); +var ListTagsForResourceResponse; +(function (ListTagsForResourceResponse) { + ListTagsForResourceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTagsForResourceResponse = exports.ListTagsForResourceResponse || (exports.ListTagsForResourceResponse = {})); +var ListUserImportJobsRequest; +(function (ListUserImportJobsRequest) { + ListUserImportJobsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListUserImportJobsRequest = exports.ListUserImportJobsRequest || (exports.ListUserImportJobsRequest = {})); +var ListUserImportJobsResponse; +(function (ListUserImportJobsResponse) { + ListUserImportJobsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListUserImportJobsResponse = exports.ListUserImportJobsResponse || (exports.ListUserImportJobsResponse = {})); +var ListUserPoolClientsRequest; +(function (ListUserPoolClientsRequest) { + ListUserPoolClientsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListUserPoolClientsRequest = exports.ListUserPoolClientsRequest || (exports.ListUserPoolClientsRequest = {})); +var UserPoolClientDescription; +(function (UserPoolClientDescription) { + UserPoolClientDescription.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(UserPoolClientDescription = exports.UserPoolClientDescription || (exports.UserPoolClientDescription = {})); +var ListUserPoolClientsResponse; +(function (ListUserPoolClientsResponse) { + ListUserPoolClientsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.UserPoolClients && { + UserPoolClients: obj.UserPoolClients.map((item) => UserPoolClientDescription.filterSensitiveLog(item)), + }), + }); +})(ListUserPoolClientsResponse = exports.ListUserPoolClientsResponse || (exports.ListUserPoolClientsResponse = {})); +var ListUserPoolsRequest; +(function (ListUserPoolsRequest) { + ListUserPoolsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListUserPoolsRequest = exports.ListUserPoolsRequest || (exports.ListUserPoolsRequest = {})); +var UserPoolDescriptionType; +(function (UserPoolDescriptionType) { + UserPoolDescriptionType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UserPoolDescriptionType = exports.UserPoolDescriptionType || (exports.UserPoolDescriptionType = {})); +var ListUserPoolsResponse; +(function (ListUserPoolsResponse) { + ListUserPoolsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListUserPoolsResponse = exports.ListUserPoolsResponse || (exports.ListUserPoolsResponse = {})); +var ListUsersRequest; +(function (ListUsersRequest) { + ListUsersRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListUsersRequest = exports.ListUsersRequest || (exports.ListUsersRequest = {})); +var ListUsersResponse; +(function (ListUsersResponse) { + ListUsersResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Users && { Users: obj.Users.map((item) => UserType.filterSensitiveLog(item)) }), + }); +})(ListUsersResponse = exports.ListUsersResponse || (exports.ListUsersResponse = {})); +var ListUsersInGroupRequest; +(function (ListUsersInGroupRequest) { + ListUsersInGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListUsersInGroupRequest = exports.ListUsersInGroupRequest || (exports.ListUsersInGroupRequest = {})); +var ListUsersInGroupResponse; +(function (ListUsersInGroupResponse) { + ListUsersInGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Users && { Users: obj.Users.map((item) => UserType.filterSensitiveLog(item)) }), + }); +})(ListUsersInGroupResponse = exports.ListUsersInGroupResponse || (exports.ListUsersInGroupResponse = {})); +var ResendConfirmationCodeRequest; +(function (ResendConfirmationCodeRequest) { + ResendConfirmationCodeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + ...(obj.SecretHash && { SecretHash: smithy_client_1.SENSITIVE_STRING }), + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + }); +})(ResendConfirmationCodeRequest = exports.ResendConfirmationCodeRequest || (exports.ResendConfirmationCodeRequest = {})); +var ResendConfirmationCodeResponse; +(function (ResendConfirmationCodeResponse) { + ResendConfirmationCodeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResendConfirmationCodeResponse = exports.ResendConfirmationCodeResponse || (exports.ResendConfirmationCodeResponse = {})); +var RespondToAuthChallengeRequest; +(function (RespondToAuthChallengeRequest) { + RespondToAuthChallengeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(RespondToAuthChallengeRequest = exports.RespondToAuthChallengeRequest || (exports.RespondToAuthChallengeRequest = {})); +var RespondToAuthChallengeResponse; +(function (RespondToAuthChallengeResponse) { + RespondToAuthChallengeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AuthenticationResult && { + AuthenticationResult: AuthenticationResultType.filterSensitiveLog(obj.AuthenticationResult), + }), + }); +})(RespondToAuthChallengeResponse = exports.RespondToAuthChallengeResponse || (exports.RespondToAuthChallengeResponse = {})); +var SetRiskConfigurationRequest; +(function (SetRiskConfigurationRequest) { + SetRiskConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(SetRiskConfigurationRequest = exports.SetRiskConfigurationRequest || (exports.SetRiskConfigurationRequest = {})); +var SetRiskConfigurationResponse; +(function (SetRiskConfigurationResponse) { + SetRiskConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.RiskConfiguration && { + RiskConfiguration: RiskConfigurationType.filterSensitiveLog(obj.RiskConfiguration), + }), + }); +})(SetRiskConfigurationResponse = exports.SetRiskConfigurationResponse || (exports.SetRiskConfigurationResponse = {})); +var SetUICustomizationRequest; +(function (SetUICustomizationRequest) { + SetUICustomizationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(SetUICustomizationRequest = exports.SetUICustomizationRequest || (exports.SetUICustomizationRequest = {})); +var SetUICustomizationResponse; +(function (SetUICustomizationResponse) { + SetUICustomizationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.UICustomization && { UICustomization: UICustomizationType.filterSensitiveLog(obj.UICustomization) }), + }); +})(SetUICustomizationResponse = exports.SetUICustomizationResponse || (exports.SetUICustomizationResponse = {})); +var SetUserMFAPreferenceRequest; +(function (SetUserMFAPreferenceRequest) { + SetUserMFAPreferenceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(SetUserMFAPreferenceRequest = exports.SetUserMFAPreferenceRequest || (exports.SetUserMFAPreferenceRequest = {})); +var SetUserMFAPreferenceResponse; +(function (SetUserMFAPreferenceResponse) { + SetUserMFAPreferenceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetUserMFAPreferenceResponse = exports.SetUserMFAPreferenceResponse || (exports.SetUserMFAPreferenceResponse = {})); +var SetUserPoolMfaConfigRequest; +(function (SetUserPoolMfaConfigRequest) { + SetUserPoolMfaConfigRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetUserPoolMfaConfigRequest = exports.SetUserPoolMfaConfigRequest || (exports.SetUserPoolMfaConfigRequest = {})); +var SetUserPoolMfaConfigResponse; +(function (SetUserPoolMfaConfigResponse) { + SetUserPoolMfaConfigResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetUserPoolMfaConfigResponse = exports.SetUserPoolMfaConfigResponse || (exports.SetUserPoolMfaConfigResponse = {})); +var SetUserSettingsRequest; +(function (SetUserSettingsRequest) { + SetUserSettingsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(SetUserSettingsRequest = exports.SetUserSettingsRequest || (exports.SetUserSettingsRequest = {})); +var SetUserSettingsResponse; +(function (SetUserSettingsResponse) { + SetUserSettingsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetUserSettingsResponse = exports.SetUserSettingsResponse || (exports.SetUserSettingsResponse = {})); +var SignUpRequest; +(function (SignUpRequest) { + SignUpRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + ...(obj.SecretHash && { SecretHash: smithy_client_1.SENSITIVE_STRING }), + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + ...(obj.Password && { Password: smithy_client_1.SENSITIVE_STRING }), + ...(obj.UserAttributes && { + UserAttributes: obj.UserAttributes.map((item) => AttributeType.filterSensitiveLog(item)), + }), + ...(obj.ValidationData && { + ValidationData: obj.ValidationData.map((item) => AttributeType.filterSensitiveLog(item)), + }), + }); +})(SignUpRequest = exports.SignUpRequest || (exports.SignUpRequest = {})); +var SignUpResponse; +(function (SignUpResponse) { + SignUpResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SignUpResponse = exports.SignUpResponse || (exports.SignUpResponse = {})); +var StartUserImportJobRequest; +(function (StartUserImportJobRequest) { + StartUserImportJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StartUserImportJobRequest = exports.StartUserImportJobRequest || (exports.StartUserImportJobRequest = {})); +var StartUserImportJobResponse; +(function (StartUserImportJobResponse) { + StartUserImportJobResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StartUserImportJobResponse = exports.StartUserImportJobResponse || (exports.StartUserImportJobResponse = {})); +var StopUserImportJobRequest; +(function (StopUserImportJobRequest) { + StopUserImportJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StopUserImportJobRequest = exports.StopUserImportJobRequest || (exports.StopUserImportJobRequest = {})); +var StopUserImportJobResponse; +(function (StopUserImportJobResponse) { + StopUserImportJobResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StopUserImportJobResponse = exports.StopUserImportJobResponse || (exports.StopUserImportJobResponse = {})); +var TagResourceRequest; +(function (TagResourceRequest) { + TagResourceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TagResourceRequest = exports.TagResourceRequest || (exports.TagResourceRequest = {})); +var TagResourceResponse; +(function (TagResourceResponse) { + TagResourceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TagResourceResponse = exports.TagResourceResponse || (exports.TagResourceResponse = {})); +//# sourceMappingURL=models_0.js.map + +/***/ }), + +/***/ 1086: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.VerifyUserAttributeResponse = exports.VerifyUserAttributeRequest = exports.VerifySoftwareTokenResponse = exports.VerifySoftwareTokenResponseType = exports.VerifySoftwareTokenRequest = exports.EnableSoftwareTokenMFAException = exports.UpdateUserPoolDomainResponse = exports.UpdateUserPoolDomainRequest = exports.UpdateUserPoolClientResponse = exports.UpdateUserPoolClientRequest = exports.UpdateUserPoolResponse = exports.UpdateUserPoolRequest = exports.UpdateUserAttributesResponse = exports.UpdateUserAttributesRequest = exports.UpdateResourceServerResponse = exports.UpdateResourceServerRequest = exports.UpdateIdentityProviderResponse = exports.UpdateIdentityProviderRequest = exports.UpdateGroupResponse = exports.UpdateGroupRequest = exports.UpdateDeviceStatusResponse = exports.UpdateDeviceStatusRequest = exports.UpdateAuthEventFeedbackResponse = exports.UpdateAuthEventFeedbackRequest = exports.UntagResourceResponse = exports.UntagResourceRequest = void 0; +const models_0_1 = __nccwpck_require__(38771); +const smithy_client_1 = __nccwpck_require__(84060); +var UntagResourceRequest; +(function (UntagResourceRequest) { + UntagResourceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UntagResourceRequest = exports.UntagResourceRequest || (exports.UntagResourceRequest = {})); +var UntagResourceResponse; +(function (UntagResourceResponse) { + UntagResourceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UntagResourceResponse = exports.UntagResourceResponse || (exports.UntagResourceResponse = {})); +var UpdateAuthEventFeedbackRequest; +(function (UpdateAuthEventFeedbackRequest) { + UpdateAuthEventFeedbackRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.Username && { Username: smithy_client_1.SENSITIVE_STRING }), + ...(obj.FeedbackToken && { FeedbackToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(UpdateAuthEventFeedbackRequest = exports.UpdateAuthEventFeedbackRequest || (exports.UpdateAuthEventFeedbackRequest = {})); +var UpdateAuthEventFeedbackResponse; +(function (UpdateAuthEventFeedbackResponse) { + UpdateAuthEventFeedbackResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateAuthEventFeedbackResponse = exports.UpdateAuthEventFeedbackResponse || (exports.UpdateAuthEventFeedbackResponse = {})); +var UpdateDeviceStatusRequest; +(function (UpdateDeviceStatusRequest) { + UpdateDeviceStatusRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(UpdateDeviceStatusRequest = exports.UpdateDeviceStatusRequest || (exports.UpdateDeviceStatusRequest = {})); +var UpdateDeviceStatusResponse; +(function (UpdateDeviceStatusResponse) { + UpdateDeviceStatusResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateDeviceStatusResponse = exports.UpdateDeviceStatusResponse || (exports.UpdateDeviceStatusResponse = {})); +var UpdateGroupRequest; +(function (UpdateGroupRequest) { + UpdateGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateGroupRequest = exports.UpdateGroupRequest || (exports.UpdateGroupRequest = {})); +var UpdateGroupResponse; +(function (UpdateGroupResponse) { + UpdateGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateGroupResponse = exports.UpdateGroupResponse || (exports.UpdateGroupResponse = {})); +var UpdateIdentityProviderRequest; +(function (UpdateIdentityProviderRequest) { + UpdateIdentityProviderRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateIdentityProviderRequest = exports.UpdateIdentityProviderRequest || (exports.UpdateIdentityProviderRequest = {})); +var UpdateIdentityProviderResponse; +(function (UpdateIdentityProviderResponse) { + UpdateIdentityProviderResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateIdentityProviderResponse = exports.UpdateIdentityProviderResponse || (exports.UpdateIdentityProviderResponse = {})); +var UpdateResourceServerRequest; +(function (UpdateResourceServerRequest) { + UpdateResourceServerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateResourceServerRequest = exports.UpdateResourceServerRequest || (exports.UpdateResourceServerRequest = {})); +var UpdateResourceServerResponse; +(function (UpdateResourceServerResponse) { + UpdateResourceServerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateResourceServerResponse = exports.UpdateResourceServerResponse || (exports.UpdateResourceServerResponse = {})); +var UpdateUserAttributesRequest; +(function (UpdateUserAttributesRequest) { + UpdateUserAttributesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.UserAttributes && { + UserAttributes: obj.UserAttributes.map((item) => models_0_1.AttributeType.filterSensitiveLog(item)), + }), + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(UpdateUserAttributesRequest = exports.UpdateUserAttributesRequest || (exports.UpdateUserAttributesRequest = {})); +var UpdateUserAttributesResponse; +(function (UpdateUserAttributesResponse) { + UpdateUserAttributesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateUserAttributesResponse = exports.UpdateUserAttributesResponse || (exports.UpdateUserAttributesResponse = {})); +var UpdateUserPoolRequest; +(function (UpdateUserPoolRequest) { + UpdateUserPoolRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateUserPoolRequest = exports.UpdateUserPoolRequest || (exports.UpdateUserPoolRequest = {})); +var UpdateUserPoolResponse; +(function (UpdateUserPoolResponse) { + UpdateUserPoolResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateUserPoolResponse = exports.UpdateUserPoolResponse || (exports.UpdateUserPoolResponse = {})); +var UpdateUserPoolClientRequest; +(function (UpdateUserPoolClientRequest) { + UpdateUserPoolClientRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.ClientId && { ClientId: smithy_client_1.SENSITIVE_STRING }), + }); +})(UpdateUserPoolClientRequest = exports.UpdateUserPoolClientRequest || (exports.UpdateUserPoolClientRequest = {})); +var UpdateUserPoolClientResponse; +(function (UpdateUserPoolClientResponse) { + UpdateUserPoolClientResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.UserPoolClient && { UserPoolClient: models_0_1.UserPoolClientType.filterSensitiveLog(obj.UserPoolClient) }), + }); +})(UpdateUserPoolClientResponse = exports.UpdateUserPoolClientResponse || (exports.UpdateUserPoolClientResponse = {})); +var UpdateUserPoolDomainRequest; +(function (UpdateUserPoolDomainRequest) { + UpdateUserPoolDomainRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateUserPoolDomainRequest = exports.UpdateUserPoolDomainRequest || (exports.UpdateUserPoolDomainRequest = {})); +var UpdateUserPoolDomainResponse; +(function (UpdateUserPoolDomainResponse) { + UpdateUserPoolDomainResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateUserPoolDomainResponse = exports.UpdateUserPoolDomainResponse || (exports.UpdateUserPoolDomainResponse = {})); +var EnableSoftwareTokenMFAException; +(function (EnableSoftwareTokenMFAException) { + EnableSoftwareTokenMFAException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(EnableSoftwareTokenMFAException = exports.EnableSoftwareTokenMFAException || (exports.EnableSoftwareTokenMFAException = {})); +var VerifySoftwareTokenRequest; +(function (VerifySoftwareTokenRequest) { + VerifySoftwareTokenRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(VerifySoftwareTokenRequest = exports.VerifySoftwareTokenRequest || (exports.VerifySoftwareTokenRequest = {})); +var VerifySoftwareTokenResponseType; +(function (VerifySoftwareTokenResponseType) { + VerifySoftwareTokenResponseType["ERROR"] = "ERROR"; + VerifySoftwareTokenResponseType["SUCCESS"] = "SUCCESS"; +})(VerifySoftwareTokenResponseType = exports.VerifySoftwareTokenResponseType || (exports.VerifySoftwareTokenResponseType = {})); +var VerifySoftwareTokenResponse; +(function (VerifySoftwareTokenResponse) { + VerifySoftwareTokenResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(VerifySoftwareTokenResponse = exports.VerifySoftwareTokenResponse || (exports.VerifySoftwareTokenResponse = {})); +var VerifyUserAttributeRequest; +(function (VerifyUserAttributeRequest) { + VerifyUserAttributeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.AccessToken && { AccessToken: smithy_client_1.SENSITIVE_STRING }), + }); +})(VerifyUserAttributeRequest = exports.VerifyUserAttributeRequest || (exports.VerifyUserAttributeRequest = {})); +var VerifyUserAttributeResponse; +(function (VerifyUserAttributeResponse) { + VerifyUserAttributeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(VerifyUserAttributeResponse = exports.VerifyUserAttributeResponse || (exports.VerifyUserAttributeResponse = {})); +//# sourceMappingURL=models_1.js.map + +/***/ }), + +/***/ 71298: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateAdminListGroupsForUser = void 0; +const CognitoIdentityProvider_1 = __nccwpck_require__(63436); +const CognitoIdentityProviderClient_1 = __nccwpck_require__(32756); +const AdminListGroupsForUserCommand_1 = __nccwpck_require__(4199); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new AdminListGroupsForUserCommand_1.AdminListGroupsForUserCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.adminListGroupsForUser(input, ...args); +}; +async function* paginateAdminListGroupsForUser(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["Limit"] = config.pageSize; + if (config.client instanceof CognitoIdentityProvider_1.CognitoIdentityProvider) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CognitoIdentityProviderClient_1.CognitoIdentityProviderClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CognitoIdentityProvider | CognitoIdentityProviderClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateAdminListGroupsForUser = paginateAdminListGroupsForUser; +//# sourceMappingURL=AdminListGroupsForUserPaginator.js.map + +/***/ }), + +/***/ 91606: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateAdminListUserAuthEvents = void 0; +const CognitoIdentityProvider_1 = __nccwpck_require__(63436); +const CognitoIdentityProviderClient_1 = __nccwpck_require__(32756); +const AdminListUserAuthEventsCommand_1 = __nccwpck_require__(76132); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new AdminListUserAuthEventsCommand_1.AdminListUserAuthEventsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.adminListUserAuthEvents(input, ...args); +}; +async function* paginateAdminListUserAuthEvents(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CognitoIdentityProvider_1.CognitoIdentityProvider) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CognitoIdentityProviderClient_1.CognitoIdentityProviderClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CognitoIdentityProvider | CognitoIdentityProviderClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateAdminListUserAuthEvents = paginateAdminListUserAuthEvents; +//# sourceMappingURL=AdminListUserAuthEventsPaginator.js.map + +/***/ }), + +/***/ 14865: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +//# sourceMappingURL=Interfaces.js.map + +/***/ }), + +/***/ 42484: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListGroups = void 0; +const CognitoIdentityProvider_1 = __nccwpck_require__(63436); +const CognitoIdentityProviderClient_1 = __nccwpck_require__(32756); +const ListGroupsCommand_1 = __nccwpck_require__(39386); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListGroupsCommand_1.ListGroupsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listGroups(input, ...args); +}; +async function* paginateListGroups(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["Limit"] = config.pageSize; + if (config.client instanceof CognitoIdentityProvider_1.CognitoIdentityProvider) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CognitoIdentityProviderClient_1.CognitoIdentityProviderClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CognitoIdentityProvider | CognitoIdentityProviderClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListGroups = paginateListGroups; +//# sourceMappingURL=ListGroupsPaginator.js.map + +/***/ }), + +/***/ 24624: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListIdentityProviders = void 0; +const CognitoIdentityProvider_1 = __nccwpck_require__(63436); +const CognitoIdentityProviderClient_1 = __nccwpck_require__(32756); +const ListIdentityProvidersCommand_1 = __nccwpck_require__(73419); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListIdentityProvidersCommand_1.ListIdentityProvidersCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listIdentityProviders(input, ...args); +}; +async function* paginateListIdentityProviders(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CognitoIdentityProvider_1.CognitoIdentityProvider) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CognitoIdentityProviderClient_1.CognitoIdentityProviderClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CognitoIdentityProvider | CognitoIdentityProviderClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListIdentityProviders = paginateListIdentityProviders; +//# sourceMappingURL=ListIdentityProvidersPaginator.js.map + +/***/ }), + +/***/ 56595: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListResourceServers = void 0; +const CognitoIdentityProvider_1 = __nccwpck_require__(63436); +const CognitoIdentityProviderClient_1 = __nccwpck_require__(32756); +const ListResourceServersCommand_1 = __nccwpck_require__(93783); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListResourceServersCommand_1.ListResourceServersCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listResourceServers(input, ...args); +}; +async function* paginateListResourceServers(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CognitoIdentityProvider_1.CognitoIdentityProvider) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CognitoIdentityProviderClient_1.CognitoIdentityProviderClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CognitoIdentityProvider | CognitoIdentityProviderClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListResourceServers = paginateListResourceServers; +//# sourceMappingURL=ListResourceServersPaginator.js.map + +/***/ }), + +/***/ 64835: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListUserPoolClients = void 0; +const CognitoIdentityProvider_1 = __nccwpck_require__(63436); +const CognitoIdentityProviderClient_1 = __nccwpck_require__(32756); +const ListUserPoolClientsCommand_1 = __nccwpck_require__(87753); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListUserPoolClientsCommand_1.ListUserPoolClientsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listUserPoolClients(input, ...args); +}; +async function* paginateListUserPoolClients(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CognitoIdentityProvider_1.CognitoIdentityProvider) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CognitoIdentityProviderClient_1.CognitoIdentityProviderClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CognitoIdentityProvider | CognitoIdentityProviderClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListUserPoolClients = paginateListUserPoolClients; +//# sourceMappingURL=ListUserPoolClientsPaginator.js.map + +/***/ }), + +/***/ 79983: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListUserPools = void 0; +const CognitoIdentityProvider_1 = __nccwpck_require__(63436); +const CognitoIdentityProviderClient_1 = __nccwpck_require__(32756); +const ListUserPoolsCommand_1 = __nccwpck_require__(51756); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListUserPoolsCommand_1.ListUserPoolsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listUserPools(input, ...args); +}; +async function* paginateListUserPools(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CognitoIdentityProvider_1.CognitoIdentityProvider) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CognitoIdentityProviderClient_1.CognitoIdentityProviderClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CognitoIdentityProvider | CognitoIdentityProviderClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListUserPools = paginateListUserPools; +//# sourceMappingURL=ListUserPoolsPaginator.js.map + +/***/ }), + +/***/ 24558: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListUsersInGroup = void 0; +const CognitoIdentityProvider_1 = __nccwpck_require__(63436); +const CognitoIdentityProviderClient_1 = __nccwpck_require__(32756); +const ListUsersInGroupCommand_1 = __nccwpck_require__(51577); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListUsersInGroupCommand_1.ListUsersInGroupCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listUsersInGroup(input, ...args); +}; +async function* paginateListUsersInGroup(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["Limit"] = config.pageSize; + if (config.client instanceof CognitoIdentityProvider_1.CognitoIdentityProvider) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CognitoIdentityProviderClient_1.CognitoIdentityProviderClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CognitoIdentityProvider | CognitoIdentityProviderClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListUsersInGroup = paginateListUsersInGroup; +//# sourceMappingURL=ListUsersInGroupPaginator.js.map + +/***/ }), + +/***/ 23221: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListUsers = void 0; +const CognitoIdentityProvider_1 = __nccwpck_require__(63436); +const CognitoIdentityProviderClient_1 = __nccwpck_require__(32756); +const ListUsersCommand_1 = __nccwpck_require__(16854); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListUsersCommand_1.ListUsersCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listUsers(input, ...args); +}; +async function* paginateListUsers(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.PaginationToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.PaginationToken = token; + input["Limit"] = config.pageSize; + if (config.client instanceof CognitoIdentityProvider_1.CognitoIdentityProvider) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CognitoIdentityProviderClient_1.CognitoIdentityProviderClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CognitoIdentityProvider | CognitoIdentityProviderClient"); + } + yield page; + token = page.PaginationToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListUsers = paginateListUsers; +//# sourceMappingURL=ListUsersPaginator.js.map + +/***/ }), + +/***/ 91522: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.serializeAws_json1_1DescribeRiskConfigurationCommand = exports.serializeAws_json1_1DescribeResourceServerCommand = exports.serializeAws_json1_1DescribeIdentityProviderCommand = exports.serializeAws_json1_1DeleteUserPoolDomainCommand = exports.serializeAws_json1_1DeleteUserPoolClientCommand = exports.serializeAws_json1_1DeleteUserPoolCommand = exports.serializeAws_json1_1DeleteUserAttributesCommand = exports.serializeAws_json1_1DeleteUserCommand = exports.serializeAws_json1_1DeleteResourceServerCommand = exports.serializeAws_json1_1DeleteIdentityProviderCommand = exports.serializeAws_json1_1DeleteGroupCommand = exports.serializeAws_json1_1CreateUserPoolDomainCommand = exports.serializeAws_json1_1CreateUserPoolClientCommand = exports.serializeAws_json1_1CreateUserPoolCommand = exports.serializeAws_json1_1CreateUserImportJobCommand = exports.serializeAws_json1_1CreateResourceServerCommand = exports.serializeAws_json1_1CreateIdentityProviderCommand = exports.serializeAws_json1_1CreateGroupCommand = exports.serializeAws_json1_1ConfirmSignUpCommand = exports.serializeAws_json1_1ConfirmForgotPasswordCommand = exports.serializeAws_json1_1ConfirmDeviceCommand = exports.serializeAws_json1_1ChangePasswordCommand = exports.serializeAws_json1_1AssociateSoftwareTokenCommand = exports.serializeAws_json1_1AdminUserGlobalSignOutCommand = exports.serializeAws_json1_1AdminUpdateUserAttributesCommand = exports.serializeAws_json1_1AdminUpdateDeviceStatusCommand = exports.serializeAws_json1_1AdminUpdateAuthEventFeedbackCommand = exports.serializeAws_json1_1AdminSetUserSettingsCommand = exports.serializeAws_json1_1AdminSetUserPasswordCommand = exports.serializeAws_json1_1AdminSetUserMFAPreferenceCommand = exports.serializeAws_json1_1AdminRespondToAuthChallengeCommand = exports.serializeAws_json1_1AdminResetUserPasswordCommand = exports.serializeAws_json1_1AdminRemoveUserFromGroupCommand = exports.serializeAws_json1_1AdminListUserAuthEventsCommand = exports.serializeAws_json1_1AdminListGroupsForUserCommand = exports.serializeAws_json1_1AdminListDevicesCommand = exports.serializeAws_json1_1AdminLinkProviderForUserCommand = exports.serializeAws_json1_1AdminInitiateAuthCommand = exports.serializeAws_json1_1AdminGetUserCommand = exports.serializeAws_json1_1AdminGetDeviceCommand = exports.serializeAws_json1_1AdminForgetDeviceCommand = exports.serializeAws_json1_1AdminEnableUserCommand = exports.serializeAws_json1_1AdminDisableUserCommand = exports.serializeAws_json1_1AdminDisableProviderForUserCommand = exports.serializeAws_json1_1AdminDeleteUserAttributesCommand = exports.serializeAws_json1_1AdminDeleteUserCommand = exports.serializeAws_json1_1AdminCreateUserCommand = exports.serializeAws_json1_1AdminConfirmSignUpCommand = exports.serializeAws_json1_1AdminAddUserToGroupCommand = exports.serializeAws_json1_1AddCustomAttributesCommand = void 0; +exports.serializeAws_json1_1VerifyUserAttributeCommand = exports.serializeAws_json1_1VerifySoftwareTokenCommand = exports.serializeAws_json1_1UpdateUserPoolDomainCommand = exports.serializeAws_json1_1UpdateUserPoolClientCommand = exports.serializeAws_json1_1UpdateUserPoolCommand = exports.serializeAws_json1_1UpdateUserAttributesCommand = exports.serializeAws_json1_1UpdateResourceServerCommand = exports.serializeAws_json1_1UpdateIdentityProviderCommand = exports.serializeAws_json1_1UpdateGroupCommand = exports.serializeAws_json1_1UpdateDeviceStatusCommand = exports.serializeAws_json1_1UpdateAuthEventFeedbackCommand = exports.serializeAws_json1_1UntagResourceCommand = exports.serializeAws_json1_1TagResourceCommand = exports.serializeAws_json1_1StopUserImportJobCommand = exports.serializeAws_json1_1StartUserImportJobCommand = exports.serializeAws_json1_1SignUpCommand = exports.serializeAws_json1_1SetUserSettingsCommand = exports.serializeAws_json1_1SetUserPoolMfaConfigCommand = exports.serializeAws_json1_1SetUserMFAPreferenceCommand = exports.serializeAws_json1_1SetUICustomizationCommand = exports.serializeAws_json1_1SetRiskConfigurationCommand = exports.serializeAws_json1_1RespondToAuthChallengeCommand = exports.serializeAws_json1_1ResendConfirmationCodeCommand = exports.serializeAws_json1_1ListUsersInGroupCommand = exports.serializeAws_json1_1ListUsersCommand = exports.serializeAws_json1_1ListUserPoolsCommand = exports.serializeAws_json1_1ListUserPoolClientsCommand = exports.serializeAws_json1_1ListUserImportJobsCommand = exports.serializeAws_json1_1ListTagsForResourceCommand = exports.serializeAws_json1_1ListResourceServersCommand = exports.serializeAws_json1_1ListIdentityProvidersCommand = exports.serializeAws_json1_1ListGroupsCommand = exports.serializeAws_json1_1ListDevicesCommand = exports.serializeAws_json1_1InitiateAuthCommand = exports.serializeAws_json1_1GlobalSignOutCommand = exports.serializeAws_json1_1GetUserPoolMfaConfigCommand = exports.serializeAws_json1_1GetUserAttributeVerificationCodeCommand = exports.serializeAws_json1_1GetUserCommand = exports.serializeAws_json1_1GetUICustomizationCommand = exports.serializeAws_json1_1GetSigningCertificateCommand = exports.serializeAws_json1_1GetIdentityProviderByIdentifierCommand = exports.serializeAws_json1_1GetGroupCommand = exports.serializeAws_json1_1GetDeviceCommand = exports.serializeAws_json1_1GetCSVHeaderCommand = exports.serializeAws_json1_1ForgotPasswordCommand = exports.serializeAws_json1_1ForgetDeviceCommand = exports.serializeAws_json1_1DescribeUserPoolDomainCommand = exports.serializeAws_json1_1DescribeUserPoolClientCommand = exports.serializeAws_json1_1DescribeUserPoolCommand = exports.serializeAws_json1_1DescribeUserImportJobCommand = void 0; +exports.deserializeAws_json1_1DescribeRiskConfigurationCommand = exports.deserializeAws_json1_1DescribeResourceServerCommand = exports.deserializeAws_json1_1DescribeIdentityProviderCommand = exports.deserializeAws_json1_1DeleteUserPoolDomainCommand = exports.deserializeAws_json1_1DeleteUserPoolClientCommand = exports.deserializeAws_json1_1DeleteUserPoolCommand = exports.deserializeAws_json1_1DeleteUserAttributesCommand = exports.deserializeAws_json1_1DeleteUserCommand = exports.deserializeAws_json1_1DeleteResourceServerCommand = exports.deserializeAws_json1_1DeleteIdentityProviderCommand = exports.deserializeAws_json1_1DeleteGroupCommand = exports.deserializeAws_json1_1CreateUserPoolDomainCommand = exports.deserializeAws_json1_1CreateUserPoolClientCommand = exports.deserializeAws_json1_1CreateUserPoolCommand = exports.deserializeAws_json1_1CreateUserImportJobCommand = exports.deserializeAws_json1_1CreateResourceServerCommand = exports.deserializeAws_json1_1CreateIdentityProviderCommand = exports.deserializeAws_json1_1CreateGroupCommand = exports.deserializeAws_json1_1ConfirmSignUpCommand = exports.deserializeAws_json1_1ConfirmForgotPasswordCommand = exports.deserializeAws_json1_1ConfirmDeviceCommand = exports.deserializeAws_json1_1ChangePasswordCommand = exports.deserializeAws_json1_1AssociateSoftwareTokenCommand = exports.deserializeAws_json1_1AdminUserGlobalSignOutCommand = exports.deserializeAws_json1_1AdminUpdateUserAttributesCommand = exports.deserializeAws_json1_1AdminUpdateDeviceStatusCommand = exports.deserializeAws_json1_1AdminUpdateAuthEventFeedbackCommand = exports.deserializeAws_json1_1AdminSetUserSettingsCommand = exports.deserializeAws_json1_1AdminSetUserPasswordCommand = exports.deserializeAws_json1_1AdminSetUserMFAPreferenceCommand = exports.deserializeAws_json1_1AdminRespondToAuthChallengeCommand = exports.deserializeAws_json1_1AdminResetUserPasswordCommand = exports.deserializeAws_json1_1AdminRemoveUserFromGroupCommand = exports.deserializeAws_json1_1AdminListUserAuthEventsCommand = exports.deserializeAws_json1_1AdminListGroupsForUserCommand = exports.deserializeAws_json1_1AdminListDevicesCommand = exports.deserializeAws_json1_1AdminLinkProviderForUserCommand = exports.deserializeAws_json1_1AdminInitiateAuthCommand = exports.deserializeAws_json1_1AdminGetUserCommand = exports.deserializeAws_json1_1AdminGetDeviceCommand = exports.deserializeAws_json1_1AdminForgetDeviceCommand = exports.deserializeAws_json1_1AdminEnableUserCommand = exports.deserializeAws_json1_1AdminDisableUserCommand = exports.deserializeAws_json1_1AdminDisableProviderForUserCommand = exports.deserializeAws_json1_1AdminDeleteUserAttributesCommand = exports.deserializeAws_json1_1AdminDeleteUserCommand = exports.deserializeAws_json1_1AdminCreateUserCommand = exports.deserializeAws_json1_1AdminConfirmSignUpCommand = exports.deserializeAws_json1_1AdminAddUserToGroupCommand = exports.deserializeAws_json1_1AddCustomAttributesCommand = void 0; +exports.deserializeAws_json1_1VerifyUserAttributeCommand = exports.deserializeAws_json1_1VerifySoftwareTokenCommand = exports.deserializeAws_json1_1UpdateUserPoolDomainCommand = exports.deserializeAws_json1_1UpdateUserPoolClientCommand = exports.deserializeAws_json1_1UpdateUserPoolCommand = exports.deserializeAws_json1_1UpdateUserAttributesCommand = exports.deserializeAws_json1_1UpdateResourceServerCommand = exports.deserializeAws_json1_1UpdateIdentityProviderCommand = exports.deserializeAws_json1_1UpdateGroupCommand = exports.deserializeAws_json1_1UpdateDeviceStatusCommand = exports.deserializeAws_json1_1UpdateAuthEventFeedbackCommand = exports.deserializeAws_json1_1UntagResourceCommand = exports.deserializeAws_json1_1TagResourceCommand = exports.deserializeAws_json1_1StopUserImportJobCommand = exports.deserializeAws_json1_1StartUserImportJobCommand = exports.deserializeAws_json1_1SignUpCommand = exports.deserializeAws_json1_1SetUserSettingsCommand = exports.deserializeAws_json1_1SetUserPoolMfaConfigCommand = exports.deserializeAws_json1_1SetUserMFAPreferenceCommand = exports.deserializeAws_json1_1SetUICustomizationCommand = exports.deserializeAws_json1_1SetRiskConfigurationCommand = exports.deserializeAws_json1_1RespondToAuthChallengeCommand = exports.deserializeAws_json1_1ResendConfirmationCodeCommand = exports.deserializeAws_json1_1ListUsersInGroupCommand = exports.deserializeAws_json1_1ListUsersCommand = exports.deserializeAws_json1_1ListUserPoolsCommand = exports.deserializeAws_json1_1ListUserPoolClientsCommand = exports.deserializeAws_json1_1ListUserImportJobsCommand = exports.deserializeAws_json1_1ListTagsForResourceCommand = exports.deserializeAws_json1_1ListResourceServersCommand = exports.deserializeAws_json1_1ListIdentityProvidersCommand = exports.deserializeAws_json1_1ListGroupsCommand = exports.deserializeAws_json1_1ListDevicesCommand = exports.deserializeAws_json1_1InitiateAuthCommand = exports.deserializeAws_json1_1GlobalSignOutCommand = exports.deserializeAws_json1_1GetUserPoolMfaConfigCommand = exports.deserializeAws_json1_1GetUserAttributeVerificationCodeCommand = exports.deserializeAws_json1_1GetUserCommand = exports.deserializeAws_json1_1GetUICustomizationCommand = exports.deserializeAws_json1_1GetSigningCertificateCommand = exports.deserializeAws_json1_1GetIdentityProviderByIdentifierCommand = exports.deserializeAws_json1_1GetGroupCommand = exports.deserializeAws_json1_1GetDeviceCommand = exports.deserializeAws_json1_1GetCSVHeaderCommand = exports.deserializeAws_json1_1ForgotPasswordCommand = exports.deserializeAws_json1_1ForgetDeviceCommand = exports.deserializeAws_json1_1DescribeUserPoolDomainCommand = exports.deserializeAws_json1_1DescribeUserPoolClientCommand = exports.deserializeAws_json1_1DescribeUserPoolCommand = exports.deserializeAws_json1_1DescribeUserImportJobCommand = void 0; +const protocol_http_1 = __nccwpck_require__(67498); +const serializeAws_json1_1AddCustomAttributesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AddCustomAttributes", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AddCustomAttributesRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AddCustomAttributesCommand = serializeAws_json1_1AddCustomAttributesCommand; +const serializeAws_json1_1AdminAddUserToGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminAddUserToGroup", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminAddUserToGroupRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminAddUserToGroupCommand = serializeAws_json1_1AdminAddUserToGroupCommand; +const serializeAws_json1_1AdminConfirmSignUpCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminConfirmSignUp", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminConfirmSignUpRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminConfirmSignUpCommand = serializeAws_json1_1AdminConfirmSignUpCommand; +const serializeAws_json1_1AdminCreateUserCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminCreateUser", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminCreateUserRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminCreateUserCommand = serializeAws_json1_1AdminCreateUserCommand; +const serializeAws_json1_1AdminDeleteUserCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminDeleteUser", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminDeleteUserRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminDeleteUserCommand = serializeAws_json1_1AdminDeleteUserCommand; +const serializeAws_json1_1AdminDeleteUserAttributesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminDeleteUserAttributes", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminDeleteUserAttributesRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminDeleteUserAttributesCommand = serializeAws_json1_1AdminDeleteUserAttributesCommand; +const serializeAws_json1_1AdminDisableProviderForUserCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminDisableProviderForUser", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminDisableProviderForUserRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminDisableProviderForUserCommand = serializeAws_json1_1AdminDisableProviderForUserCommand; +const serializeAws_json1_1AdminDisableUserCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminDisableUser", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminDisableUserRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminDisableUserCommand = serializeAws_json1_1AdminDisableUserCommand; +const serializeAws_json1_1AdminEnableUserCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminEnableUser", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminEnableUserRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminEnableUserCommand = serializeAws_json1_1AdminEnableUserCommand; +const serializeAws_json1_1AdminForgetDeviceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminForgetDevice", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminForgetDeviceRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminForgetDeviceCommand = serializeAws_json1_1AdminForgetDeviceCommand; +const serializeAws_json1_1AdminGetDeviceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminGetDevice", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminGetDeviceRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminGetDeviceCommand = serializeAws_json1_1AdminGetDeviceCommand; +const serializeAws_json1_1AdminGetUserCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminGetUser", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminGetUserRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminGetUserCommand = serializeAws_json1_1AdminGetUserCommand; +const serializeAws_json1_1AdminInitiateAuthCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminInitiateAuth", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminInitiateAuthRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminInitiateAuthCommand = serializeAws_json1_1AdminInitiateAuthCommand; +const serializeAws_json1_1AdminLinkProviderForUserCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminLinkProviderForUser", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminLinkProviderForUserRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminLinkProviderForUserCommand = serializeAws_json1_1AdminLinkProviderForUserCommand; +const serializeAws_json1_1AdminListDevicesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminListDevices", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminListDevicesRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminListDevicesCommand = serializeAws_json1_1AdminListDevicesCommand; +const serializeAws_json1_1AdminListGroupsForUserCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminListGroupsForUser", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminListGroupsForUserRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminListGroupsForUserCommand = serializeAws_json1_1AdminListGroupsForUserCommand; +const serializeAws_json1_1AdminListUserAuthEventsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminListUserAuthEvents", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminListUserAuthEventsRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminListUserAuthEventsCommand = serializeAws_json1_1AdminListUserAuthEventsCommand; +const serializeAws_json1_1AdminRemoveUserFromGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminRemoveUserFromGroup", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminRemoveUserFromGroupRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminRemoveUserFromGroupCommand = serializeAws_json1_1AdminRemoveUserFromGroupCommand; +const serializeAws_json1_1AdminResetUserPasswordCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminResetUserPassword", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminResetUserPasswordRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminResetUserPasswordCommand = serializeAws_json1_1AdminResetUserPasswordCommand; +const serializeAws_json1_1AdminRespondToAuthChallengeCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminRespondToAuthChallenge", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminRespondToAuthChallengeRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminRespondToAuthChallengeCommand = serializeAws_json1_1AdminRespondToAuthChallengeCommand; +const serializeAws_json1_1AdminSetUserMFAPreferenceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminSetUserMFAPreference", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminSetUserMFAPreferenceRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminSetUserMFAPreferenceCommand = serializeAws_json1_1AdminSetUserMFAPreferenceCommand; +const serializeAws_json1_1AdminSetUserPasswordCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminSetUserPassword", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminSetUserPasswordRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminSetUserPasswordCommand = serializeAws_json1_1AdminSetUserPasswordCommand; +const serializeAws_json1_1AdminSetUserSettingsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminSetUserSettings", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminSetUserSettingsRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminSetUserSettingsCommand = serializeAws_json1_1AdminSetUserSettingsCommand; +const serializeAws_json1_1AdminUpdateAuthEventFeedbackCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminUpdateAuthEventFeedback", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminUpdateAuthEventFeedbackRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminUpdateAuthEventFeedbackCommand = serializeAws_json1_1AdminUpdateAuthEventFeedbackCommand; +const serializeAws_json1_1AdminUpdateDeviceStatusCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminUpdateDeviceStatus", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminUpdateDeviceStatusRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminUpdateDeviceStatusCommand = serializeAws_json1_1AdminUpdateDeviceStatusCommand; +const serializeAws_json1_1AdminUpdateUserAttributesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminUpdateUserAttributes", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminUpdateUserAttributesRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminUpdateUserAttributesCommand = serializeAws_json1_1AdminUpdateUserAttributesCommand; +const serializeAws_json1_1AdminUserGlobalSignOutCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AdminUserGlobalSignOut", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AdminUserGlobalSignOutRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AdminUserGlobalSignOutCommand = serializeAws_json1_1AdminUserGlobalSignOutCommand; +const serializeAws_json1_1AssociateSoftwareTokenCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.AssociateSoftwareToken", + }; + let body; + body = JSON.stringify(serializeAws_json1_1AssociateSoftwareTokenRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1AssociateSoftwareTokenCommand = serializeAws_json1_1AssociateSoftwareTokenCommand; +const serializeAws_json1_1ChangePasswordCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ChangePassword", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ChangePasswordRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ChangePasswordCommand = serializeAws_json1_1ChangePasswordCommand; +const serializeAws_json1_1ConfirmDeviceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ConfirmDevice", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ConfirmDeviceRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ConfirmDeviceCommand = serializeAws_json1_1ConfirmDeviceCommand; +const serializeAws_json1_1ConfirmForgotPasswordCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ConfirmForgotPassword", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ConfirmForgotPasswordRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ConfirmForgotPasswordCommand = serializeAws_json1_1ConfirmForgotPasswordCommand; +const serializeAws_json1_1ConfirmSignUpCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ConfirmSignUp", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ConfirmSignUpRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ConfirmSignUpCommand = serializeAws_json1_1ConfirmSignUpCommand; +const serializeAws_json1_1CreateGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.CreateGroup", + }; + let body; + body = JSON.stringify(serializeAws_json1_1CreateGroupRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1CreateGroupCommand = serializeAws_json1_1CreateGroupCommand; +const serializeAws_json1_1CreateIdentityProviderCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.CreateIdentityProvider", + }; + let body; + body = JSON.stringify(serializeAws_json1_1CreateIdentityProviderRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1CreateIdentityProviderCommand = serializeAws_json1_1CreateIdentityProviderCommand; +const serializeAws_json1_1CreateResourceServerCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.CreateResourceServer", + }; + let body; + body = JSON.stringify(serializeAws_json1_1CreateResourceServerRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1CreateResourceServerCommand = serializeAws_json1_1CreateResourceServerCommand; +const serializeAws_json1_1CreateUserImportJobCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.CreateUserImportJob", + }; + let body; + body = JSON.stringify(serializeAws_json1_1CreateUserImportJobRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1CreateUserImportJobCommand = serializeAws_json1_1CreateUserImportJobCommand; +const serializeAws_json1_1CreateUserPoolCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.CreateUserPool", + }; + let body; + body = JSON.stringify(serializeAws_json1_1CreateUserPoolRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1CreateUserPoolCommand = serializeAws_json1_1CreateUserPoolCommand; +const serializeAws_json1_1CreateUserPoolClientCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.CreateUserPoolClient", + }; + let body; + body = JSON.stringify(serializeAws_json1_1CreateUserPoolClientRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1CreateUserPoolClientCommand = serializeAws_json1_1CreateUserPoolClientCommand; +const serializeAws_json1_1CreateUserPoolDomainCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.CreateUserPoolDomain", + }; + let body; + body = JSON.stringify(serializeAws_json1_1CreateUserPoolDomainRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1CreateUserPoolDomainCommand = serializeAws_json1_1CreateUserPoolDomainCommand; +const serializeAws_json1_1DeleteGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DeleteGroup", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DeleteGroupRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DeleteGroupCommand = serializeAws_json1_1DeleteGroupCommand; +const serializeAws_json1_1DeleteIdentityProviderCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DeleteIdentityProvider", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DeleteIdentityProviderRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DeleteIdentityProviderCommand = serializeAws_json1_1DeleteIdentityProviderCommand; +const serializeAws_json1_1DeleteResourceServerCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DeleteResourceServer", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DeleteResourceServerRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DeleteResourceServerCommand = serializeAws_json1_1DeleteResourceServerCommand; +const serializeAws_json1_1DeleteUserCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DeleteUser", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DeleteUserRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DeleteUserCommand = serializeAws_json1_1DeleteUserCommand; +const serializeAws_json1_1DeleteUserAttributesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DeleteUserAttributes", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DeleteUserAttributesRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DeleteUserAttributesCommand = serializeAws_json1_1DeleteUserAttributesCommand; +const serializeAws_json1_1DeleteUserPoolCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DeleteUserPool", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DeleteUserPoolRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DeleteUserPoolCommand = serializeAws_json1_1DeleteUserPoolCommand; +const serializeAws_json1_1DeleteUserPoolClientCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DeleteUserPoolClient", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DeleteUserPoolClientRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DeleteUserPoolClientCommand = serializeAws_json1_1DeleteUserPoolClientCommand; +const serializeAws_json1_1DeleteUserPoolDomainCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DeleteUserPoolDomain", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DeleteUserPoolDomainRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DeleteUserPoolDomainCommand = serializeAws_json1_1DeleteUserPoolDomainCommand; +const serializeAws_json1_1DescribeIdentityProviderCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DescribeIdentityProvider", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DescribeIdentityProviderRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DescribeIdentityProviderCommand = serializeAws_json1_1DescribeIdentityProviderCommand; +const serializeAws_json1_1DescribeResourceServerCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DescribeResourceServer", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DescribeResourceServerRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DescribeResourceServerCommand = serializeAws_json1_1DescribeResourceServerCommand; +const serializeAws_json1_1DescribeRiskConfigurationCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DescribeRiskConfiguration", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DescribeRiskConfigurationRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DescribeRiskConfigurationCommand = serializeAws_json1_1DescribeRiskConfigurationCommand; +const serializeAws_json1_1DescribeUserImportJobCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DescribeUserImportJob", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DescribeUserImportJobRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DescribeUserImportJobCommand = serializeAws_json1_1DescribeUserImportJobCommand; +const serializeAws_json1_1DescribeUserPoolCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DescribeUserPool", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DescribeUserPoolRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DescribeUserPoolCommand = serializeAws_json1_1DescribeUserPoolCommand; +const serializeAws_json1_1DescribeUserPoolClientCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DescribeUserPoolClient", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DescribeUserPoolClientRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DescribeUserPoolClientCommand = serializeAws_json1_1DescribeUserPoolClientCommand; +const serializeAws_json1_1DescribeUserPoolDomainCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.DescribeUserPoolDomain", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DescribeUserPoolDomainRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DescribeUserPoolDomainCommand = serializeAws_json1_1DescribeUserPoolDomainCommand; +const serializeAws_json1_1ForgetDeviceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ForgetDevice", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ForgetDeviceRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ForgetDeviceCommand = serializeAws_json1_1ForgetDeviceCommand; +const serializeAws_json1_1ForgotPasswordCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ForgotPassword", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ForgotPasswordRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ForgotPasswordCommand = serializeAws_json1_1ForgotPasswordCommand; +const serializeAws_json1_1GetCSVHeaderCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.GetCSVHeader", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetCSVHeaderRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetCSVHeaderCommand = serializeAws_json1_1GetCSVHeaderCommand; +const serializeAws_json1_1GetDeviceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.GetDevice", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetDeviceRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetDeviceCommand = serializeAws_json1_1GetDeviceCommand; +const serializeAws_json1_1GetGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.GetGroup", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetGroupRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetGroupCommand = serializeAws_json1_1GetGroupCommand; +const serializeAws_json1_1GetIdentityProviderByIdentifierCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.GetIdentityProviderByIdentifier", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetIdentityProviderByIdentifierRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetIdentityProviderByIdentifierCommand = serializeAws_json1_1GetIdentityProviderByIdentifierCommand; +const serializeAws_json1_1GetSigningCertificateCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.GetSigningCertificate", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetSigningCertificateRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetSigningCertificateCommand = serializeAws_json1_1GetSigningCertificateCommand; +const serializeAws_json1_1GetUICustomizationCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.GetUICustomization", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetUICustomizationRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetUICustomizationCommand = serializeAws_json1_1GetUICustomizationCommand; +const serializeAws_json1_1GetUserCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.GetUser", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetUserRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetUserCommand = serializeAws_json1_1GetUserCommand; +const serializeAws_json1_1GetUserAttributeVerificationCodeCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.GetUserAttributeVerificationCode", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetUserAttributeVerificationCodeRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetUserAttributeVerificationCodeCommand = serializeAws_json1_1GetUserAttributeVerificationCodeCommand; +const serializeAws_json1_1GetUserPoolMfaConfigCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.GetUserPoolMfaConfig", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetUserPoolMfaConfigRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetUserPoolMfaConfigCommand = serializeAws_json1_1GetUserPoolMfaConfigCommand; +const serializeAws_json1_1GlobalSignOutCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.GlobalSignOut", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GlobalSignOutRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GlobalSignOutCommand = serializeAws_json1_1GlobalSignOutCommand; +const serializeAws_json1_1InitiateAuthCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.InitiateAuth", + }; + let body; + body = JSON.stringify(serializeAws_json1_1InitiateAuthRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1InitiateAuthCommand = serializeAws_json1_1InitiateAuthCommand; +const serializeAws_json1_1ListDevicesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ListDevices", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListDevicesRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListDevicesCommand = serializeAws_json1_1ListDevicesCommand; +const serializeAws_json1_1ListGroupsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ListGroups", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListGroupsRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListGroupsCommand = serializeAws_json1_1ListGroupsCommand; +const serializeAws_json1_1ListIdentityProvidersCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ListIdentityProviders", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListIdentityProvidersRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListIdentityProvidersCommand = serializeAws_json1_1ListIdentityProvidersCommand; +const serializeAws_json1_1ListResourceServersCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ListResourceServers", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListResourceServersRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListResourceServersCommand = serializeAws_json1_1ListResourceServersCommand; +const serializeAws_json1_1ListTagsForResourceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ListTagsForResource", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListTagsForResourceRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListTagsForResourceCommand = serializeAws_json1_1ListTagsForResourceCommand; +const serializeAws_json1_1ListUserImportJobsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ListUserImportJobs", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListUserImportJobsRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListUserImportJobsCommand = serializeAws_json1_1ListUserImportJobsCommand; +const serializeAws_json1_1ListUserPoolClientsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ListUserPoolClients", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListUserPoolClientsRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListUserPoolClientsCommand = serializeAws_json1_1ListUserPoolClientsCommand; +const serializeAws_json1_1ListUserPoolsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ListUserPools", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListUserPoolsRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListUserPoolsCommand = serializeAws_json1_1ListUserPoolsCommand; +const serializeAws_json1_1ListUsersCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ListUsers", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListUsersRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListUsersCommand = serializeAws_json1_1ListUsersCommand; +const serializeAws_json1_1ListUsersInGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ListUsersInGroup", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListUsersInGroupRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListUsersInGroupCommand = serializeAws_json1_1ListUsersInGroupCommand; +const serializeAws_json1_1ResendConfirmationCodeCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.ResendConfirmationCode", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ResendConfirmationCodeRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ResendConfirmationCodeCommand = serializeAws_json1_1ResendConfirmationCodeCommand; +const serializeAws_json1_1RespondToAuthChallengeCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.RespondToAuthChallenge", + }; + let body; + body = JSON.stringify(serializeAws_json1_1RespondToAuthChallengeRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1RespondToAuthChallengeCommand = serializeAws_json1_1RespondToAuthChallengeCommand; +const serializeAws_json1_1SetRiskConfigurationCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.SetRiskConfiguration", + }; + let body; + body = JSON.stringify(serializeAws_json1_1SetRiskConfigurationRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1SetRiskConfigurationCommand = serializeAws_json1_1SetRiskConfigurationCommand; +const serializeAws_json1_1SetUICustomizationCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.SetUICustomization", + }; + let body; + body = JSON.stringify(serializeAws_json1_1SetUICustomizationRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1SetUICustomizationCommand = serializeAws_json1_1SetUICustomizationCommand; +const serializeAws_json1_1SetUserMFAPreferenceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.SetUserMFAPreference", + }; + let body; + body = JSON.stringify(serializeAws_json1_1SetUserMFAPreferenceRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1SetUserMFAPreferenceCommand = serializeAws_json1_1SetUserMFAPreferenceCommand; +const serializeAws_json1_1SetUserPoolMfaConfigCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.SetUserPoolMfaConfig", + }; + let body; + body = JSON.stringify(serializeAws_json1_1SetUserPoolMfaConfigRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1SetUserPoolMfaConfigCommand = serializeAws_json1_1SetUserPoolMfaConfigCommand; +const serializeAws_json1_1SetUserSettingsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.SetUserSettings", + }; + let body; + body = JSON.stringify(serializeAws_json1_1SetUserSettingsRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1SetUserSettingsCommand = serializeAws_json1_1SetUserSettingsCommand; +const serializeAws_json1_1SignUpCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.SignUp", + }; + let body; + body = JSON.stringify(serializeAws_json1_1SignUpRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1SignUpCommand = serializeAws_json1_1SignUpCommand; +const serializeAws_json1_1StartUserImportJobCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.StartUserImportJob", + }; + let body; + body = JSON.stringify(serializeAws_json1_1StartUserImportJobRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1StartUserImportJobCommand = serializeAws_json1_1StartUserImportJobCommand; +const serializeAws_json1_1StopUserImportJobCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.StopUserImportJob", + }; + let body; + body = JSON.stringify(serializeAws_json1_1StopUserImportJobRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1StopUserImportJobCommand = serializeAws_json1_1StopUserImportJobCommand; +const serializeAws_json1_1TagResourceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.TagResource", + }; + let body; + body = JSON.stringify(serializeAws_json1_1TagResourceRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1TagResourceCommand = serializeAws_json1_1TagResourceCommand; +const serializeAws_json1_1UntagResourceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.UntagResource", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UntagResourceRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UntagResourceCommand = serializeAws_json1_1UntagResourceCommand; +const serializeAws_json1_1UpdateAuthEventFeedbackCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.UpdateAuthEventFeedback", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UpdateAuthEventFeedbackRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UpdateAuthEventFeedbackCommand = serializeAws_json1_1UpdateAuthEventFeedbackCommand; +const serializeAws_json1_1UpdateDeviceStatusCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.UpdateDeviceStatus", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UpdateDeviceStatusRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UpdateDeviceStatusCommand = serializeAws_json1_1UpdateDeviceStatusCommand; +const serializeAws_json1_1UpdateGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.UpdateGroup", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UpdateGroupRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UpdateGroupCommand = serializeAws_json1_1UpdateGroupCommand; +const serializeAws_json1_1UpdateIdentityProviderCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.UpdateIdentityProvider", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UpdateIdentityProviderRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UpdateIdentityProviderCommand = serializeAws_json1_1UpdateIdentityProviderCommand; +const serializeAws_json1_1UpdateResourceServerCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.UpdateResourceServer", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UpdateResourceServerRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UpdateResourceServerCommand = serializeAws_json1_1UpdateResourceServerCommand; +const serializeAws_json1_1UpdateUserAttributesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.UpdateUserAttributes", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UpdateUserAttributesRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UpdateUserAttributesCommand = serializeAws_json1_1UpdateUserAttributesCommand; +const serializeAws_json1_1UpdateUserPoolCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.UpdateUserPool", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UpdateUserPoolRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UpdateUserPoolCommand = serializeAws_json1_1UpdateUserPoolCommand; +const serializeAws_json1_1UpdateUserPoolClientCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.UpdateUserPoolClient", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UpdateUserPoolClientRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UpdateUserPoolClientCommand = serializeAws_json1_1UpdateUserPoolClientCommand; +const serializeAws_json1_1UpdateUserPoolDomainCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.UpdateUserPoolDomain", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UpdateUserPoolDomainRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UpdateUserPoolDomainCommand = serializeAws_json1_1UpdateUserPoolDomainCommand; +const serializeAws_json1_1VerifySoftwareTokenCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.VerifySoftwareToken", + }; + let body; + body = JSON.stringify(serializeAws_json1_1VerifySoftwareTokenRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1VerifySoftwareTokenCommand = serializeAws_json1_1VerifySoftwareTokenCommand; +const serializeAws_json1_1VerifyUserAttributeCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityProviderService.VerifyUserAttribute", + }; + let body; + body = JSON.stringify(serializeAws_json1_1VerifyUserAttributeRequest(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1VerifyUserAttributeCommand = serializeAws_json1_1VerifyUserAttributeCommand; +const deserializeAws_json1_1AddCustomAttributesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AddCustomAttributesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AddCustomAttributesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AddCustomAttributesCommand = deserializeAws_json1_1AddCustomAttributesCommand; +const deserializeAws_json1_1AddCustomAttributesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserImportInProgressException": + case "com.amazonaws.cognitoidentityprovider#UserImportInProgressException": + response = { + ...(await deserializeAws_json1_1UserImportInProgressExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminAddUserToGroupCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminAddUserToGroupCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminAddUserToGroupCommand = deserializeAws_json1_1AdminAddUserToGroupCommand; +const deserializeAws_json1_1AdminAddUserToGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminConfirmSignUpCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminConfirmSignUpCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminConfirmSignUpResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminConfirmSignUpCommand = deserializeAws_json1_1AdminConfirmSignUpCommand; +const deserializeAws_json1_1AdminConfirmSignUpCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyFailedAttemptsException": + case "com.amazonaws.cognitoidentityprovider#TooManyFailedAttemptsException": + response = { + ...(await deserializeAws_json1_1TooManyFailedAttemptsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminCreateUserCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminCreateUserCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminCreateUserResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminCreateUserCommand = deserializeAws_json1_1AdminCreateUserCommand; +const deserializeAws_json1_1AdminCreateUserCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CodeDeliveryFailureException": + case "com.amazonaws.cognitoidentityprovider#CodeDeliveryFailureException": + response = { + ...(await deserializeAws_json1_1CodeDeliveryFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidPasswordException": + case "com.amazonaws.cognitoidentityprovider#InvalidPasswordException": + response = { + ...(await deserializeAws_json1_1InvalidPasswordExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PreconditionNotMetException": + case "com.amazonaws.cognitoidentityprovider#PreconditionNotMetException": + response = { + ...(await deserializeAws_json1_1PreconditionNotMetExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnsupportedUserStateException": + case "com.amazonaws.cognitoidentityprovider#UnsupportedUserStateException": + response = { + ...(await deserializeAws_json1_1UnsupportedUserStateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UsernameExistsException": + case "com.amazonaws.cognitoidentityprovider#UsernameExistsException": + response = { + ...(await deserializeAws_json1_1UsernameExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminDeleteUserCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminDeleteUserCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminDeleteUserCommand = deserializeAws_json1_1AdminDeleteUserCommand; +const deserializeAws_json1_1AdminDeleteUserCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminDeleteUserAttributesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminDeleteUserAttributesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminDeleteUserAttributesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminDeleteUserAttributesCommand = deserializeAws_json1_1AdminDeleteUserAttributesCommand; +const deserializeAws_json1_1AdminDeleteUserAttributesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminDisableProviderForUserCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminDisableProviderForUserCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminDisableProviderForUserResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminDisableProviderForUserCommand = deserializeAws_json1_1AdminDisableProviderForUserCommand; +const deserializeAws_json1_1AdminDisableProviderForUserCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "AliasExistsException": + case "com.amazonaws.cognitoidentityprovider#AliasExistsException": + response = { + ...(await deserializeAws_json1_1AliasExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminDisableUserCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminDisableUserCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminDisableUserResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminDisableUserCommand = deserializeAws_json1_1AdminDisableUserCommand; +const deserializeAws_json1_1AdminDisableUserCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminEnableUserCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminEnableUserCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminEnableUserResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminEnableUserCommand = deserializeAws_json1_1AdminEnableUserCommand; +const deserializeAws_json1_1AdminEnableUserCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminForgetDeviceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminForgetDeviceCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminForgetDeviceCommand = deserializeAws_json1_1AdminForgetDeviceCommand; +const deserializeAws_json1_1AdminForgetDeviceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminGetDeviceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminGetDeviceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminGetDeviceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminGetDeviceCommand = deserializeAws_json1_1AdminGetDeviceCommand; +const deserializeAws_json1_1AdminGetDeviceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminGetUserCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminGetUserCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminGetUserResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminGetUserCommand = deserializeAws_json1_1AdminGetUserCommand; +const deserializeAws_json1_1AdminGetUserCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminInitiateAuthCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminInitiateAuthCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminInitiateAuthResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminInitiateAuthCommand = deserializeAws_json1_1AdminInitiateAuthCommand; +const deserializeAws_json1_1AdminInitiateAuthCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "MFAMethodNotFoundException": + case "com.amazonaws.cognitoidentityprovider#MFAMethodNotFoundException": + response = { + ...(await deserializeAws_json1_1MFAMethodNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminLinkProviderForUserCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminLinkProviderForUserCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminLinkProviderForUserResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminLinkProviderForUserCommand = deserializeAws_json1_1AdminLinkProviderForUserCommand; +const deserializeAws_json1_1AdminLinkProviderForUserCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "AliasExistsException": + case "com.amazonaws.cognitoidentityprovider#AliasExistsException": + response = { + ...(await deserializeAws_json1_1AliasExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminListDevicesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminListDevicesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminListDevicesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminListDevicesCommand = deserializeAws_json1_1AdminListDevicesCommand; +const deserializeAws_json1_1AdminListDevicesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminListGroupsForUserCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminListGroupsForUserCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminListGroupsForUserResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminListGroupsForUserCommand = deserializeAws_json1_1AdminListGroupsForUserCommand; +const deserializeAws_json1_1AdminListGroupsForUserCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminListUserAuthEventsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminListUserAuthEventsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminListUserAuthEventsResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminListUserAuthEventsCommand = deserializeAws_json1_1AdminListUserAuthEventsCommand; +const deserializeAws_json1_1AdminListUserAuthEventsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserPoolAddOnNotEnabledException": + case "com.amazonaws.cognitoidentityprovider#UserPoolAddOnNotEnabledException": + response = { + ...(await deserializeAws_json1_1UserPoolAddOnNotEnabledExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminRemoveUserFromGroupCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminRemoveUserFromGroupCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminRemoveUserFromGroupCommand = deserializeAws_json1_1AdminRemoveUserFromGroupCommand; +const deserializeAws_json1_1AdminRemoveUserFromGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminResetUserPasswordCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminResetUserPasswordCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminResetUserPasswordResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminResetUserPasswordCommand = deserializeAws_json1_1AdminResetUserPasswordCommand; +const deserializeAws_json1_1AdminResetUserPasswordCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidEmailRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidEmailRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminRespondToAuthChallengeCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminRespondToAuthChallengeCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminRespondToAuthChallengeResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminRespondToAuthChallengeCommand = deserializeAws_json1_1AdminRespondToAuthChallengeCommand; +const deserializeAws_json1_1AdminRespondToAuthChallengeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "AliasExistsException": + case "com.amazonaws.cognitoidentityprovider#AliasExistsException": + response = { + ...(await deserializeAws_json1_1AliasExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "CodeMismatchException": + case "com.amazonaws.cognitoidentityprovider#CodeMismatchException": + response = { + ...(await deserializeAws_json1_1CodeMismatchExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ExpiredCodeException": + case "com.amazonaws.cognitoidentityprovider#ExpiredCodeException": + response = { + ...(await deserializeAws_json1_1ExpiredCodeExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidPasswordException": + case "com.amazonaws.cognitoidentityprovider#InvalidPasswordException": + response = { + ...(await deserializeAws_json1_1InvalidPasswordExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "MFAMethodNotFoundException": + case "com.amazonaws.cognitoidentityprovider#MFAMethodNotFoundException": + response = { + ...(await deserializeAws_json1_1MFAMethodNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "SoftwareTokenMFANotFoundException": + case "com.amazonaws.cognitoidentityprovider#SoftwareTokenMFANotFoundException": + response = { + ...(await deserializeAws_json1_1SoftwareTokenMFANotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminSetUserMFAPreferenceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminSetUserMFAPreferenceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminSetUserMFAPreferenceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminSetUserMFAPreferenceCommand = deserializeAws_json1_1AdminSetUserMFAPreferenceCommand; +const deserializeAws_json1_1AdminSetUserMFAPreferenceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminSetUserPasswordCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminSetUserPasswordCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminSetUserPasswordResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminSetUserPasswordCommand = deserializeAws_json1_1AdminSetUserPasswordCommand; +const deserializeAws_json1_1AdminSetUserPasswordCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidPasswordException": + case "com.amazonaws.cognitoidentityprovider#InvalidPasswordException": + response = { + ...(await deserializeAws_json1_1InvalidPasswordExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminSetUserSettingsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminSetUserSettingsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminSetUserSettingsResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminSetUserSettingsCommand = deserializeAws_json1_1AdminSetUserSettingsCommand; +const deserializeAws_json1_1AdminSetUserSettingsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminUpdateAuthEventFeedbackCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminUpdateAuthEventFeedbackCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminUpdateAuthEventFeedbackResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminUpdateAuthEventFeedbackCommand = deserializeAws_json1_1AdminUpdateAuthEventFeedbackCommand; +const deserializeAws_json1_1AdminUpdateAuthEventFeedbackCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserPoolAddOnNotEnabledException": + case "com.amazonaws.cognitoidentityprovider#UserPoolAddOnNotEnabledException": + response = { + ...(await deserializeAws_json1_1UserPoolAddOnNotEnabledExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminUpdateDeviceStatusCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminUpdateDeviceStatusCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminUpdateDeviceStatusResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminUpdateDeviceStatusCommand = deserializeAws_json1_1AdminUpdateDeviceStatusCommand; +const deserializeAws_json1_1AdminUpdateDeviceStatusCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminUpdateUserAttributesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminUpdateUserAttributesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminUpdateUserAttributesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminUpdateUserAttributesCommand = deserializeAws_json1_1AdminUpdateUserAttributesCommand; +const deserializeAws_json1_1AdminUpdateUserAttributesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "AliasExistsException": + case "com.amazonaws.cognitoidentityprovider#AliasExistsException": + response = { + ...(await deserializeAws_json1_1AliasExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidEmailRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidEmailRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AdminUserGlobalSignOutCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AdminUserGlobalSignOutCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AdminUserGlobalSignOutResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AdminUserGlobalSignOutCommand = deserializeAws_json1_1AdminUserGlobalSignOutCommand; +const deserializeAws_json1_1AdminUserGlobalSignOutCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AssociateSoftwareTokenCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1AssociateSoftwareTokenCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1AssociateSoftwareTokenResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1AssociateSoftwareTokenCommand = deserializeAws_json1_1AssociateSoftwareTokenCommand; +const deserializeAws_json1_1AssociateSoftwareTokenCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConcurrentModificationException": + case "com.amazonaws.cognitoidentityprovider#ConcurrentModificationException": + response = { + ...(await deserializeAws_json1_1ConcurrentModificationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "SoftwareTokenMFANotFoundException": + case "com.amazonaws.cognitoidentityprovider#SoftwareTokenMFANotFoundException": + response = { + ...(await deserializeAws_json1_1SoftwareTokenMFANotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ChangePasswordCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ChangePasswordCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ChangePasswordResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ChangePasswordCommand = deserializeAws_json1_1ChangePasswordCommand; +const deserializeAws_json1_1ChangePasswordCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidPasswordException": + case "com.amazonaws.cognitoidentityprovider#InvalidPasswordException": + response = { + ...(await deserializeAws_json1_1InvalidPasswordExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ConfirmDeviceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ConfirmDeviceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ConfirmDeviceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ConfirmDeviceCommand = deserializeAws_json1_1ConfirmDeviceCommand; +const deserializeAws_json1_1ConfirmDeviceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidPasswordException": + case "com.amazonaws.cognitoidentityprovider#InvalidPasswordException": + response = { + ...(await deserializeAws_json1_1InvalidPasswordExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UsernameExistsException": + case "com.amazonaws.cognitoidentityprovider#UsernameExistsException": + response = { + ...(await deserializeAws_json1_1UsernameExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ConfirmForgotPasswordCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ConfirmForgotPasswordCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ConfirmForgotPasswordResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ConfirmForgotPasswordCommand = deserializeAws_json1_1ConfirmForgotPasswordCommand; +const deserializeAws_json1_1ConfirmForgotPasswordCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CodeMismatchException": + case "com.amazonaws.cognitoidentityprovider#CodeMismatchException": + response = { + ...(await deserializeAws_json1_1CodeMismatchExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ExpiredCodeException": + case "com.amazonaws.cognitoidentityprovider#ExpiredCodeException": + response = { + ...(await deserializeAws_json1_1ExpiredCodeExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidPasswordException": + case "com.amazonaws.cognitoidentityprovider#InvalidPasswordException": + response = { + ...(await deserializeAws_json1_1InvalidPasswordExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyFailedAttemptsException": + case "com.amazonaws.cognitoidentityprovider#TooManyFailedAttemptsException": + response = { + ...(await deserializeAws_json1_1TooManyFailedAttemptsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ConfirmSignUpCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ConfirmSignUpCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ConfirmSignUpResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ConfirmSignUpCommand = deserializeAws_json1_1ConfirmSignUpCommand; +const deserializeAws_json1_1ConfirmSignUpCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "AliasExistsException": + case "com.amazonaws.cognitoidentityprovider#AliasExistsException": + response = { + ...(await deserializeAws_json1_1AliasExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "CodeMismatchException": + case "com.amazonaws.cognitoidentityprovider#CodeMismatchException": + response = { + ...(await deserializeAws_json1_1CodeMismatchExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ExpiredCodeException": + case "com.amazonaws.cognitoidentityprovider#ExpiredCodeException": + response = { + ...(await deserializeAws_json1_1ExpiredCodeExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyFailedAttemptsException": + case "com.amazonaws.cognitoidentityprovider#TooManyFailedAttemptsException": + response = { + ...(await deserializeAws_json1_1TooManyFailedAttemptsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1CreateGroupCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1CreateGroupCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1CreateGroupResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1CreateGroupCommand = deserializeAws_json1_1CreateGroupCommand; +const deserializeAws_json1_1CreateGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "GroupExistsException": + case "com.amazonaws.cognitoidentityprovider#GroupExistsException": + response = { + ...(await deserializeAws_json1_1GroupExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1CreateIdentityProviderCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1CreateIdentityProviderCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1CreateIdentityProviderResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1CreateIdentityProviderCommand = deserializeAws_json1_1CreateIdentityProviderCommand; +const deserializeAws_json1_1CreateIdentityProviderCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "DuplicateProviderException": + case "com.amazonaws.cognitoidentityprovider#DuplicateProviderException": + response = { + ...(await deserializeAws_json1_1DuplicateProviderExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1CreateResourceServerCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1CreateResourceServerCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1CreateResourceServerResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1CreateResourceServerCommand = deserializeAws_json1_1CreateResourceServerCommand; +const deserializeAws_json1_1CreateResourceServerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1CreateUserImportJobCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1CreateUserImportJobCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1CreateUserImportJobResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1CreateUserImportJobCommand = deserializeAws_json1_1CreateUserImportJobCommand; +const deserializeAws_json1_1CreateUserImportJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PreconditionNotMetException": + case "com.amazonaws.cognitoidentityprovider#PreconditionNotMetException": + response = { + ...(await deserializeAws_json1_1PreconditionNotMetExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1CreateUserPoolCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1CreateUserPoolCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1CreateUserPoolResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1CreateUserPoolCommand = deserializeAws_json1_1CreateUserPoolCommand; +const deserializeAws_json1_1CreateUserPoolCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidEmailRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidEmailRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserPoolTaggingException": + case "com.amazonaws.cognitoidentityprovider#UserPoolTaggingException": + response = { + ...(await deserializeAws_json1_1UserPoolTaggingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1CreateUserPoolClientCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1CreateUserPoolClientCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1CreateUserPoolClientResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1CreateUserPoolClientCommand = deserializeAws_json1_1CreateUserPoolClientCommand; +const deserializeAws_json1_1CreateUserPoolClientCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidOAuthFlowException": + case "com.amazonaws.cognitoidentityprovider#InvalidOAuthFlowException": + response = { + ...(await deserializeAws_json1_1InvalidOAuthFlowExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ScopeDoesNotExistException": + case "com.amazonaws.cognitoidentityprovider#ScopeDoesNotExistException": + response = { + ...(await deserializeAws_json1_1ScopeDoesNotExistExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1CreateUserPoolDomainCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1CreateUserPoolDomainCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1CreateUserPoolDomainResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1CreateUserPoolDomainCommand = deserializeAws_json1_1CreateUserPoolDomainCommand; +const deserializeAws_json1_1CreateUserPoolDomainCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DeleteGroupCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DeleteGroupCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DeleteGroupCommand = deserializeAws_json1_1DeleteGroupCommand; +const deserializeAws_json1_1DeleteGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DeleteIdentityProviderCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DeleteIdentityProviderCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DeleteIdentityProviderCommand = deserializeAws_json1_1DeleteIdentityProviderCommand; +const deserializeAws_json1_1DeleteIdentityProviderCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnsupportedIdentityProviderException": + case "com.amazonaws.cognitoidentityprovider#UnsupportedIdentityProviderException": + response = { + ...(await deserializeAws_json1_1UnsupportedIdentityProviderExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DeleteResourceServerCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DeleteResourceServerCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DeleteResourceServerCommand = deserializeAws_json1_1DeleteResourceServerCommand; +const deserializeAws_json1_1DeleteResourceServerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DeleteUserCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DeleteUserCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DeleteUserCommand = deserializeAws_json1_1DeleteUserCommand; +const deserializeAws_json1_1DeleteUserCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DeleteUserAttributesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DeleteUserAttributesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1DeleteUserAttributesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DeleteUserAttributesCommand = deserializeAws_json1_1DeleteUserAttributesCommand; +const deserializeAws_json1_1DeleteUserAttributesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DeleteUserPoolCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DeleteUserPoolCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DeleteUserPoolCommand = deserializeAws_json1_1DeleteUserPoolCommand; +const deserializeAws_json1_1DeleteUserPoolCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserImportInProgressException": + case "com.amazonaws.cognitoidentityprovider#UserImportInProgressException": + response = { + ...(await deserializeAws_json1_1UserImportInProgressExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DeleteUserPoolClientCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DeleteUserPoolClientCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DeleteUserPoolClientCommand = deserializeAws_json1_1DeleteUserPoolClientCommand; +const deserializeAws_json1_1DeleteUserPoolClientCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DeleteUserPoolDomainCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DeleteUserPoolDomainCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1DeleteUserPoolDomainResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DeleteUserPoolDomainCommand = deserializeAws_json1_1DeleteUserPoolDomainCommand; +const deserializeAws_json1_1DeleteUserPoolDomainCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DescribeIdentityProviderCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DescribeIdentityProviderCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1DescribeIdentityProviderResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DescribeIdentityProviderCommand = deserializeAws_json1_1DescribeIdentityProviderCommand; +const deserializeAws_json1_1DescribeIdentityProviderCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DescribeResourceServerCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DescribeResourceServerCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1DescribeResourceServerResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DescribeResourceServerCommand = deserializeAws_json1_1DescribeResourceServerCommand; +const deserializeAws_json1_1DescribeResourceServerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DescribeRiskConfigurationCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DescribeRiskConfigurationCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1DescribeRiskConfigurationResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DescribeRiskConfigurationCommand = deserializeAws_json1_1DescribeRiskConfigurationCommand; +const deserializeAws_json1_1DescribeRiskConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserPoolAddOnNotEnabledException": + case "com.amazonaws.cognitoidentityprovider#UserPoolAddOnNotEnabledException": + response = { + ...(await deserializeAws_json1_1UserPoolAddOnNotEnabledExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DescribeUserImportJobCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DescribeUserImportJobCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1DescribeUserImportJobResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DescribeUserImportJobCommand = deserializeAws_json1_1DescribeUserImportJobCommand; +const deserializeAws_json1_1DescribeUserImportJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DescribeUserPoolCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DescribeUserPoolCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1DescribeUserPoolResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DescribeUserPoolCommand = deserializeAws_json1_1DescribeUserPoolCommand; +const deserializeAws_json1_1DescribeUserPoolCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserPoolTaggingException": + case "com.amazonaws.cognitoidentityprovider#UserPoolTaggingException": + response = { + ...(await deserializeAws_json1_1UserPoolTaggingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DescribeUserPoolClientCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DescribeUserPoolClientCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1DescribeUserPoolClientResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DescribeUserPoolClientCommand = deserializeAws_json1_1DescribeUserPoolClientCommand; +const deserializeAws_json1_1DescribeUserPoolClientCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DescribeUserPoolDomainCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DescribeUserPoolDomainCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1DescribeUserPoolDomainResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DescribeUserPoolDomainCommand = deserializeAws_json1_1DescribeUserPoolDomainCommand; +const deserializeAws_json1_1DescribeUserPoolDomainCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ForgetDeviceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ForgetDeviceCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ForgetDeviceCommand = deserializeAws_json1_1ForgetDeviceCommand; +const deserializeAws_json1_1ForgetDeviceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ForgotPasswordCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ForgotPasswordCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ForgotPasswordResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ForgotPasswordCommand = deserializeAws_json1_1ForgotPasswordCommand; +const deserializeAws_json1_1ForgotPasswordCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CodeDeliveryFailureException": + case "com.amazonaws.cognitoidentityprovider#CodeDeliveryFailureException": + response = { + ...(await deserializeAws_json1_1CodeDeliveryFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidEmailRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidEmailRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetCSVHeaderCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetCSVHeaderCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetCSVHeaderResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetCSVHeaderCommand = deserializeAws_json1_1GetCSVHeaderCommand; +const deserializeAws_json1_1GetCSVHeaderCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetDeviceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetDeviceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetDeviceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetDeviceCommand = deserializeAws_json1_1GetDeviceCommand; +const deserializeAws_json1_1GetDeviceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetGroupCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetGroupCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetGroupResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetGroupCommand = deserializeAws_json1_1GetGroupCommand; +const deserializeAws_json1_1GetGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetIdentityProviderByIdentifierCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetIdentityProviderByIdentifierCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetIdentityProviderByIdentifierResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetIdentityProviderByIdentifierCommand = deserializeAws_json1_1GetIdentityProviderByIdentifierCommand; +const deserializeAws_json1_1GetIdentityProviderByIdentifierCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetSigningCertificateCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetSigningCertificateCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetSigningCertificateResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetSigningCertificateCommand = deserializeAws_json1_1GetSigningCertificateCommand; +const deserializeAws_json1_1GetSigningCertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetUICustomizationCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetUICustomizationCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetUICustomizationResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetUICustomizationCommand = deserializeAws_json1_1GetUICustomizationCommand; +const deserializeAws_json1_1GetUICustomizationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetUserCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetUserCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetUserResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetUserCommand = deserializeAws_json1_1GetUserCommand; +const deserializeAws_json1_1GetUserCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetUserAttributeVerificationCodeCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetUserAttributeVerificationCodeCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetUserAttributeVerificationCodeResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetUserAttributeVerificationCodeCommand = deserializeAws_json1_1GetUserAttributeVerificationCodeCommand; +const deserializeAws_json1_1GetUserAttributeVerificationCodeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CodeDeliveryFailureException": + case "com.amazonaws.cognitoidentityprovider#CodeDeliveryFailureException": + response = { + ...(await deserializeAws_json1_1CodeDeliveryFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidEmailRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidEmailRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetUserPoolMfaConfigCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetUserPoolMfaConfigCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetUserPoolMfaConfigResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetUserPoolMfaConfigCommand = deserializeAws_json1_1GetUserPoolMfaConfigCommand; +const deserializeAws_json1_1GetUserPoolMfaConfigCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GlobalSignOutCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GlobalSignOutCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GlobalSignOutResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GlobalSignOutCommand = deserializeAws_json1_1GlobalSignOutCommand; +const deserializeAws_json1_1GlobalSignOutCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1InitiateAuthCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1InitiateAuthCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1InitiateAuthResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1InitiateAuthCommand = deserializeAws_json1_1InitiateAuthCommand; +const deserializeAws_json1_1InitiateAuthCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListDevicesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListDevicesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListDevicesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListDevicesCommand = deserializeAws_json1_1ListDevicesCommand; +const deserializeAws_json1_1ListDevicesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListGroupsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListGroupsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListGroupsResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListGroupsCommand = deserializeAws_json1_1ListGroupsCommand; +const deserializeAws_json1_1ListGroupsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListIdentityProvidersCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListIdentityProvidersCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListIdentityProvidersResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListIdentityProvidersCommand = deserializeAws_json1_1ListIdentityProvidersCommand; +const deserializeAws_json1_1ListIdentityProvidersCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListResourceServersCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListResourceServersCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListResourceServersResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListResourceServersCommand = deserializeAws_json1_1ListResourceServersCommand; +const deserializeAws_json1_1ListResourceServersCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListTagsForResourceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListTagsForResourceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListTagsForResourceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListTagsForResourceCommand = deserializeAws_json1_1ListTagsForResourceCommand; +const deserializeAws_json1_1ListTagsForResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListUserImportJobsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListUserImportJobsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListUserImportJobsResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListUserImportJobsCommand = deserializeAws_json1_1ListUserImportJobsCommand; +const deserializeAws_json1_1ListUserImportJobsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListUserPoolClientsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListUserPoolClientsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListUserPoolClientsResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListUserPoolClientsCommand = deserializeAws_json1_1ListUserPoolClientsCommand; +const deserializeAws_json1_1ListUserPoolClientsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListUserPoolsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListUserPoolsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListUserPoolsResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListUserPoolsCommand = deserializeAws_json1_1ListUserPoolsCommand; +const deserializeAws_json1_1ListUserPoolsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListUsersCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListUsersCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListUsersResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListUsersCommand = deserializeAws_json1_1ListUsersCommand; +const deserializeAws_json1_1ListUsersCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListUsersInGroupCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListUsersInGroupCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListUsersInGroupResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListUsersInGroupCommand = deserializeAws_json1_1ListUsersInGroupCommand; +const deserializeAws_json1_1ListUsersInGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ResendConfirmationCodeCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ResendConfirmationCodeCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ResendConfirmationCodeResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ResendConfirmationCodeCommand = deserializeAws_json1_1ResendConfirmationCodeCommand; +const deserializeAws_json1_1ResendConfirmationCodeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CodeDeliveryFailureException": + case "com.amazonaws.cognitoidentityprovider#CodeDeliveryFailureException": + response = { + ...(await deserializeAws_json1_1CodeDeliveryFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidEmailRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidEmailRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1RespondToAuthChallengeCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1RespondToAuthChallengeCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1RespondToAuthChallengeResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1RespondToAuthChallengeCommand = deserializeAws_json1_1RespondToAuthChallengeCommand; +const deserializeAws_json1_1RespondToAuthChallengeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "AliasExistsException": + case "com.amazonaws.cognitoidentityprovider#AliasExistsException": + response = { + ...(await deserializeAws_json1_1AliasExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "CodeMismatchException": + case "com.amazonaws.cognitoidentityprovider#CodeMismatchException": + response = { + ...(await deserializeAws_json1_1CodeMismatchExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ExpiredCodeException": + case "com.amazonaws.cognitoidentityprovider#ExpiredCodeException": + response = { + ...(await deserializeAws_json1_1ExpiredCodeExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidPasswordException": + case "com.amazonaws.cognitoidentityprovider#InvalidPasswordException": + response = { + ...(await deserializeAws_json1_1InvalidPasswordExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "MFAMethodNotFoundException": + case "com.amazonaws.cognitoidentityprovider#MFAMethodNotFoundException": + response = { + ...(await deserializeAws_json1_1MFAMethodNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "SoftwareTokenMFANotFoundException": + case "com.amazonaws.cognitoidentityprovider#SoftwareTokenMFANotFoundException": + response = { + ...(await deserializeAws_json1_1SoftwareTokenMFANotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1SetRiskConfigurationCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1SetRiskConfigurationCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1SetRiskConfigurationResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1SetRiskConfigurationCommand = deserializeAws_json1_1SetRiskConfigurationCommand; +const deserializeAws_json1_1SetRiskConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CodeDeliveryFailureException": + case "com.amazonaws.cognitoidentityprovider#CodeDeliveryFailureException": + response = { + ...(await deserializeAws_json1_1CodeDeliveryFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidEmailRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidEmailRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserPoolAddOnNotEnabledException": + case "com.amazonaws.cognitoidentityprovider#UserPoolAddOnNotEnabledException": + response = { + ...(await deserializeAws_json1_1UserPoolAddOnNotEnabledExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1SetUICustomizationCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1SetUICustomizationCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1SetUICustomizationResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1SetUICustomizationCommand = deserializeAws_json1_1SetUICustomizationCommand; +const deserializeAws_json1_1SetUICustomizationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1SetUserMFAPreferenceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1SetUserMFAPreferenceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1SetUserMFAPreferenceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1SetUserMFAPreferenceCommand = deserializeAws_json1_1SetUserMFAPreferenceCommand; +const deserializeAws_json1_1SetUserMFAPreferenceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1SetUserPoolMfaConfigCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1SetUserPoolMfaConfigCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1SetUserPoolMfaConfigResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1SetUserPoolMfaConfigCommand = deserializeAws_json1_1SetUserPoolMfaConfigCommand; +const deserializeAws_json1_1SetUserPoolMfaConfigCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1SetUserSettingsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1SetUserSettingsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1SetUserSettingsResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1SetUserSettingsCommand = deserializeAws_json1_1SetUserSettingsCommand; +const deserializeAws_json1_1SetUserSettingsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1SignUpCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1SignUpCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1SignUpResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1SignUpCommand = deserializeAws_json1_1SignUpCommand; +const deserializeAws_json1_1SignUpCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CodeDeliveryFailureException": + case "com.amazonaws.cognitoidentityprovider#CodeDeliveryFailureException": + response = { + ...(await deserializeAws_json1_1CodeDeliveryFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidEmailRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidEmailRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidPasswordException": + case "com.amazonaws.cognitoidentityprovider#InvalidPasswordException": + response = { + ...(await deserializeAws_json1_1InvalidPasswordExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UsernameExistsException": + case "com.amazonaws.cognitoidentityprovider#UsernameExistsException": + response = { + ...(await deserializeAws_json1_1UsernameExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1StartUserImportJobCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1StartUserImportJobCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1StartUserImportJobResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1StartUserImportJobCommand = deserializeAws_json1_1StartUserImportJobCommand; +const deserializeAws_json1_1StartUserImportJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PreconditionNotMetException": + case "com.amazonaws.cognitoidentityprovider#PreconditionNotMetException": + response = { + ...(await deserializeAws_json1_1PreconditionNotMetExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1StopUserImportJobCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1StopUserImportJobCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1StopUserImportJobResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1StopUserImportJobCommand = deserializeAws_json1_1StopUserImportJobCommand; +const deserializeAws_json1_1StopUserImportJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PreconditionNotMetException": + case "com.amazonaws.cognitoidentityprovider#PreconditionNotMetException": + response = { + ...(await deserializeAws_json1_1PreconditionNotMetExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1TagResourceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1TagResourceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1TagResourceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1TagResourceCommand = deserializeAws_json1_1TagResourceCommand; +const deserializeAws_json1_1TagResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UntagResourceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UntagResourceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UntagResourceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UntagResourceCommand = deserializeAws_json1_1UntagResourceCommand; +const deserializeAws_json1_1UntagResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UpdateAuthEventFeedbackCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UpdateAuthEventFeedbackCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UpdateAuthEventFeedbackResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UpdateAuthEventFeedbackCommand = deserializeAws_json1_1UpdateAuthEventFeedbackCommand; +const deserializeAws_json1_1UpdateAuthEventFeedbackCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserPoolAddOnNotEnabledException": + case "com.amazonaws.cognitoidentityprovider#UserPoolAddOnNotEnabledException": + response = { + ...(await deserializeAws_json1_1UserPoolAddOnNotEnabledExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UpdateDeviceStatusCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UpdateDeviceStatusCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UpdateDeviceStatusResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UpdateDeviceStatusCommand = deserializeAws_json1_1UpdateDeviceStatusCommand; +const deserializeAws_json1_1UpdateDeviceStatusCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UpdateGroupCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UpdateGroupCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UpdateGroupResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UpdateGroupCommand = deserializeAws_json1_1UpdateGroupCommand; +const deserializeAws_json1_1UpdateGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UpdateIdentityProviderCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UpdateIdentityProviderCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UpdateIdentityProviderResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UpdateIdentityProviderCommand = deserializeAws_json1_1UpdateIdentityProviderCommand; +const deserializeAws_json1_1UpdateIdentityProviderCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnsupportedIdentityProviderException": + case "com.amazonaws.cognitoidentityprovider#UnsupportedIdentityProviderException": + response = { + ...(await deserializeAws_json1_1UnsupportedIdentityProviderExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UpdateResourceServerCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UpdateResourceServerCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UpdateResourceServerResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UpdateResourceServerCommand = deserializeAws_json1_1UpdateResourceServerCommand; +const deserializeAws_json1_1UpdateResourceServerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UpdateUserAttributesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UpdateUserAttributesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UpdateUserAttributesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UpdateUserAttributesCommand = deserializeAws_json1_1UpdateUserAttributesCommand; +const deserializeAws_json1_1UpdateUserAttributesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "AliasExistsException": + case "com.amazonaws.cognitoidentityprovider#AliasExistsException": + response = { + ...(await deserializeAws_json1_1AliasExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "CodeDeliveryFailureException": + case "com.amazonaws.cognitoidentityprovider#CodeDeliveryFailureException": + response = { + ...(await deserializeAws_json1_1CodeDeliveryFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "CodeMismatchException": + case "com.amazonaws.cognitoidentityprovider#CodeMismatchException": + response = { + ...(await deserializeAws_json1_1CodeMismatchExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ExpiredCodeException": + case "com.amazonaws.cognitoidentityprovider#ExpiredCodeException": + response = { + ...(await deserializeAws_json1_1ExpiredCodeExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidEmailRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidEmailRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidLambdaResponseException": + case "com.amazonaws.cognitoidentityprovider#InvalidLambdaResponseException": + response = { + ...(await deserializeAws_json1_1InvalidLambdaResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnexpectedLambdaException": + case "com.amazonaws.cognitoidentityprovider#UnexpectedLambdaException": + response = { + ...(await deserializeAws_json1_1UnexpectedLambdaExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserLambdaValidationException": + case "com.amazonaws.cognitoidentityprovider#UserLambdaValidationException": + response = { + ...(await deserializeAws_json1_1UserLambdaValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UpdateUserPoolCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UpdateUserPoolCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UpdateUserPoolResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UpdateUserPoolCommand = deserializeAws_json1_1UpdateUserPoolCommand; +const deserializeAws_json1_1UpdateUserPoolCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConcurrentModificationException": + case "com.amazonaws.cognitoidentityprovider#ConcurrentModificationException": + response = { + ...(await deserializeAws_json1_1ConcurrentModificationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidEmailRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidEmailRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleAccessPolicyException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleAccessPolicyException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidSmsRoleTrustRelationshipException": + case "com.amazonaws.cognitoidentityprovider#InvalidSmsRoleTrustRelationshipException": + response = { + ...(await deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserImportInProgressException": + case "com.amazonaws.cognitoidentityprovider#UserImportInProgressException": + response = { + ...(await deserializeAws_json1_1UserImportInProgressExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserPoolTaggingException": + case "com.amazonaws.cognitoidentityprovider#UserPoolTaggingException": + response = { + ...(await deserializeAws_json1_1UserPoolTaggingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UpdateUserPoolClientCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UpdateUserPoolClientCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UpdateUserPoolClientResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UpdateUserPoolClientCommand = deserializeAws_json1_1UpdateUserPoolClientCommand; +const deserializeAws_json1_1UpdateUserPoolClientCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConcurrentModificationException": + case "com.amazonaws.cognitoidentityprovider#ConcurrentModificationException": + response = { + ...(await deserializeAws_json1_1ConcurrentModificationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidOAuthFlowException": + case "com.amazonaws.cognitoidentityprovider#InvalidOAuthFlowException": + response = { + ...(await deserializeAws_json1_1InvalidOAuthFlowExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ScopeDoesNotExistException": + case "com.amazonaws.cognitoidentityprovider#ScopeDoesNotExistException": + response = { + ...(await deserializeAws_json1_1ScopeDoesNotExistExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UpdateUserPoolDomainCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UpdateUserPoolDomainCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UpdateUserPoolDomainResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UpdateUserPoolDomainCommand = deserializeAws_json1_1UpdateUserPoolDomainCommand; +const deserializeAws_json1_1UpdateUserPoolDomainCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1VerifySoftwareTokenCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1VerifySoftwareTokenCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1VerifySoftwareTokenResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1VerifySoftwareTokenCommand = deserializeAws_json1_1VerifySoftwareTokenCommand; +const deserializeAws_json1_1VerifySoftwareTokenCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CodeMismatchException": + case "com.amazonaws.cognitoidentityprovider#CodeMismatchException": + response = { + ...(await deserializeAws_json1_1CodeMismatchExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "EnableSoftwareTokenMFAException": + case "com.amazonaws.cognitoidentityprovider#EnableSoftwareTokenMFAException": + response = { + ...(await deserializeAws_json1_1EnableSoftwareTokenMFAExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidUserPoolConfigurationException": + case "com.amazonaws.cognitoidentityprovider#InvalidUserPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "SoftwareTokenMFANotFoundException": + case "com.amazonaws.cognitoidentityprovider#SoftwareTokenMFANotFoundException": + response = { + ...(await deserializeAws_json1_1SoftwareTokenMFANotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1VerifyUserAttributeCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1VerifyUserAttributeCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1VerifyUserAttributeResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1VerifyUserAttributeCommand = deserializeAws_json1_1VerifyUserAttributeCommand; +const deserializeAws_json1_1VerifyUserAttributeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CodeMismatchException": + case "com.amazonaws.cognitoidentityprovider#CodeMismatchException": + response = { + ...(await deserializeAws_json1_1CodeMismatchExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ExpiredCodeException": + case "com.amazonaws.cognitoidentityprovider#ExpiredCodeException": + response = { + ...(await deserializeAws_json1_1ExpiredCodeExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentityprovider#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentityprovider#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentityprovider#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentityprovider#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "PasswordResetRequiredException": + case "com.amazonaws.cognitoidentityprovider#PasswordResetRequiredException": + response = { + ...(await deserializeAws_json1_1PasswordResetRequiredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentityprovider#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentityprovider#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotConfirmedException": + case "com.amazonaws.cognitoidentityprovider#UserNotConfirmedException": + response = { + ...(await deserializeAws_json1_1UserNotConfirmedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UserNotFoundException": + case "com.amazonaws.cognitoidentityprovider#UserNotFoundException": + response = { + ...(await deserializeAws_json1_1UserNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1AliasExistsExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1AliasExistsException(body, context); + const contents = { + name: "AliasExistsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1CodeDeliveryFailureExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1CodeDeliveryFailureException(body, context); + const contents = { + name: "CodeDeliveryFailureException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1CodeMismatchExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1CodeMismatchException(body, context); + const contents = { + name: "CodeMismatchException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1ConcurrentModificationExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1ConcurrentModificationException(body, context); + const contents = { + name: "ConcurrentModificationException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1DuplicateProviderExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1DuplicateProviderException(body, context); + const contents = { + name: "DuplicateProviderException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1EnableSoftwareTokenMFAExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1EnableSoftwareTokenMFAException(body, context); + const contents = { + name: "EnableSoftwareTokenMFAException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1ExpiredCodeExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1ExpiredCodeException(body, context); + const contents = { + name: "ExpiredCodeException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1GroupExistsExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1GroupExistsException(body, context); + const contents = { + name: "GroupExistsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InternalErrorExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InternalErrorException(body, context); + const contents = { + name: "InternalErrorException", + $fault: "server", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InvalidEmailRoleAccessPolicyExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InvalidEmailRoleAccessPolicyException(body, context); + const contents = { + name: "InvalidEmailRoleAccessPolicyException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InvalidLambdaResponseExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InvalidLambdaResponseException(body, context); + const contents = { + name: "InvalidLambdaResponseException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InvalidOAuthFlowExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InvalidOAuthFlowException(body, context); + const contents = { + name: "InvalidOAuthFlowException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InvalidParameterExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InvalidParameterException(body, context); + const contents = { + name: "InvalidParameterException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InvalidPasswordExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InvalidPasswordException(body, context); + const contents = { + name: "InvalidPasswordException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InvalidSmsRoleAccessPolicyExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InvalidSmsRoleAccessPolicyException(body, context); + const contents = { + name: "InvalidSmsRoleAccessPolicyException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InvalidSmsRoleTrustRelationshipExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InvalidSmsRoleTrustRelationshipException(body, context); + const contents = { + name: "InvalidSmsRoleTrustRelationshipException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InvalidUserPoolConfigurationExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InvalidUserPoolConfigurationException(body, context); + const contents = { + name: "InvalidUserPoolConfigurationException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1LimitExceededExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1LimitExceededException(body, context); + const contents = { + name: "LimitExceededException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1MFAMethodNotFoundExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1MFAMethodNotFoundException(body, context); + const contents = { + name: "MFAMethodNotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1NotAuthorizedExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1NotAuthorizedException(body, context); + const contents = { + name: "NotAuthorizedException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1PasswordResetRequiredExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1PasswordResetRequiredException(body, context); + const contents = { + name: "PasswordResetRequiredException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1PreconditionNotMetExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1PreconditionNotMetException(body, context); + const contents = { + name: "PreconditionNotMetException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1ResourceNotFoundExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1ResourceNotFoundException(body, context); + const contents = { + name: "ResourceNotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1ScopeDoesNotExistExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1ScopeDoesNotExistException(body, context); + const contents = { + name: "ScopeDoesNotExistException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1SoftwareTokenMFANotFoundExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1SoftwareTokenMFANotFoundException(body, context); + const contents = { + name: "SoftwareTokenMFANotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1TooManyFailedAttemptsExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1TooManyFailedAttemptsException(body, context); + const contents = { + name: "TooManyFailedAttemptsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1TooManyRequestsExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1TooManyRequestsException(body, context); + const contents = { + name: "TooManyRequestsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1UnexpectedLambdaExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1UnexpectedLambdaException(body, context); + const contents = { + name: "UnexpectedLambdaException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1UnsupportedIdentityProviderExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1UnsupportedIdentityProviderException(body, context); + const contents = { + name: "UnsupportedIdentityProviderException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1UnsupportedUserStateExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1UnsupportedUserStateException(body, context); + const contents = { + name: "UnsupportedUserStateException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1UserImportInProgressExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1UserImportInProgressException(body, context); + const contents = { + name: "UserImportInProgressException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1UserLambdaValidationExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1UserLambdaValidationException(body, context); + const contents = { + name: "UserLambdaValidationException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1UsernameExistsExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1UsernameExistsException(body, context); + const contents = { + name: "UsernameExistsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1UserNotConfirmedExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1UserNotConfirmedException(body, context); + const contents = { + name: "UserNotConfirmedException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1UserNotFoundExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1UserNotFoundException(body, context); + const contents = { + name: "UserNotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1UserPoolAddOnNotEnabledExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1UserPoolAddOnNotEnabledException(body, context); + const contents = { + name: "UserPoolAddOnNotEnabledException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1UserPoolTaggingExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1UserPoolTaggingException(body, context); + const contents = { + name: "UserPoolTaggingException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const serializeAws_json1_1AccountRecoverySettingType = (input, context) => { + return { + ...(input.RecoveryMechanisms !== undefined && + input.RecoveryMechanisms !== null && { + RecoveryMechanisms: serializeAws_json1_1RecoveryMechanismsType(input.RecoveryMechanisms, context), + }), + }; +}; +const serializeAws_json1_1AccountTakeoverActionsType = (input, context) => { + return { + ...(input.HighAction !== undefined && + input.HighAction !== null && { + HighAction: serializeAws_json1_1AccountTakeoverActionType(input.HighAction, context), + }), + ...(input.LowAction !== undefined && + input.LowAction !== null && { + LowAction: serializeAws_json1_1AccountTakeoverActionType(input.LowAction, context), + }), + ...(input.MediumAction !== undefined && + input.MediumAction !== null && { + MediumAction: serializeAws_json1_1AccountTakeoverActionType(input.MediumAction, context), + }), + }; +}; +const serializeAws_json1_1AccountTakeoverActionType = (input, context) => { + return { + ...(input.EventAction !== undefined && input.EventAction !== null && { EventAction: input.EventAction }), + ...(input.Notify !== undefined && input.Notify !== null && { Notify: input.Notify }), + }; +}; +const serializeAws_json1_1AccountTakeoverRiskConfigurationType = (input, context) => { + return { + ...(input.Actions !== undefined && + input.Actions !== null && { Actions: serializeAws_json1_1AccountTakeoverActionsType(input.Actions, context) }), + ...(input.NotifyConfiguration !== undefined && + input.NotifyConfiguration !== null && { + NotifyConfiguration: serializeAws_json1_1NotifyConfigurationType(input.NotifyConfiguration, context), + }), + }; +}; +const serializeAws_json1_1AddCustomAttributesRequest = (input, context) => { + return { + ...(input.CustomAttributes !== undefined && + input.CustomAttributes !== null && { + CustomAttributes: serializeAws_json1_1CustomAttributesListType(input.CustomAttributes, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1AdminAddUserToGroupRequest = (input, context) => { + return { + ...(input.GroupName !== undefined && input.GroupName !== null && { GroupName: input.GroupName }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminConfirmSignUpRequest = (input, context) => { + return { + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminCreateUserConfigType = (input, context) => { + return { + ...(input.AllowAdminCreateUserOnly !== undefined && + input.AllowAdminCreateUserOnly !== null && { AllowAdminCreateUserOnly: input.AllowAdminCreateUserOnly }), + ...(input.InviteMessageTemplate !== undefined && + input.InviteMessageTemplate !== null && { + InviteMessageTemplate: serializeAws_json1_1MessageTemplateType(input.InviteMessageTemplate, context), + }), + ...(input.UnusedAccountValidityDays !== undefined && + input.UnusedAccountValidityDays !== null && { UnusedAccountValidityDays: input.UnusedAccountValidityDays }), + }; +}; +const serializeAws_json1_1AdminCreateUserRequest = (input, context) => { + return { + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.DesiredDeliveryMediums !== undefined && + input.DesiredDeliveryMediums !== null && { + DesiredDeliveryMediums: serializeAws_json1_1DeliveryMediumListType(input.DesiredDeliveryMediums, context), + }), + ...(input.ForceAliasCreation !== undefined && + input.ForceAliasCreation !== null && { ForceAliasCreation: input.ForceAliasCreation }), + ...(input.MessageAction !== undefined && input.MessageAction !== null && { MessageAction: input.MessageAction }), + ...(input.TemporaryPassword !== undefined && + input.TemporaryPassword !== null && { TemporaryPassword: input.TemporaryPassword }), + ...(input.UserAttributes !== undefined && + input.UserAttributes !== null && { + UserAttributes: serializeAws_json1_1AttributeListType(input.UserAttributes, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + ...(input.ValidationData !== undefined && + input.ValidationData !== null && { + ValidationData: serializeAws_json1_1AttributeListType(input.ValidationData, context), + }), + }; +}; +const serializeAws_json1_1AdminDeleteUserAttributesRequest = (input, context) => { + return { + ...(input.UserAttributeNames !== undefined && + input.UserAttributeNames !== null && { + UserAttributeNames: serializeAws_json1_1AttributeNameListType(input.UserAttributeNames, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminDeleteUserRequest = (input, context) => { + return { + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminDisableProviderForUserRequest = (input, context) => { + return { + ...(input.User !== undefined && + input.User !== null && { User: serializeAws_json1_1ProviderUserIdentifierType(input.User, context) }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1AdminDisableUserRequest = (input, context) => { + return { + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminEnableUserRequest = (input, context) => { + return { + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminForgetDeviceRequest = (input, context) => { + return { + ...(input.DeviceKey !== undefined && input.DeviceKey !== null && { DeviceKey: input.DeviceKey }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminGetDeviceRequest = (input, context) => { + return { + ...(input.DeviceKey !== undefined && input.DeviceKey !== null && { DeviceKey: input.DeviceKey }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminGetUserRequest = (input, context) => { + return { + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminInitiateAuthRequest = (input, context) => { + return { + ...(input.AnalyticsMetadata !== undefined && + input.AnalyticsMetadata !== null && { + AnalyticsMetadata: serializeAws_json1_1AnalyticsMetadataType(input.AnalyticsMetadata, context), + }), + ...(input.AuthFlow !== undefined && input.AuthFlow !== null && { AuthFlow: input.AuthFlow }), + ...(input.AuthParameters !== undefined && + input.AuthParameters !== null && { + AuthParameters: serializeAws_json1_1AuthParametersType(input.AuthParameters, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.ContextData !== undefined && + input.ContextData !== null && { ContextData: serializeAws_json1_1ContextDataType(input.ContextData, context) }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1AdminLinkProviderForUserRequest = (input, context) => { + return { + ...(input.DestinationUser !== undefined && + input.DestinationUser !== null && { + DestinationUser: serializeAws_json1_1ProviderUserIdentifierType(input.DestinationUser, context), + }), + ...(input.SourceUser !== undefined && + input.SourceUser !== null && { + SourceUser: serializeAws_json1_1ProviderUserIdentifierType(input.SourceUser, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1AdminListDevicesRequest = (input, context) => { + return { + ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }), + ...(input.PaginationToken !== undefined && + input.PaginationToken !== null && { PaginationToken: input.PaginationToken }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminListGroupsForUserRequest = (input, context) => { + return { + ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminListUserAuthEventsRequest = (input, context) => { + return { + ...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminRemoveUserFromGroupRequest = (input, context) => { + return { + ...(input.GroupName !== undefined && input.GroupName !== null && { GroupName: input.GroupName }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminResetUserPasswordRequest = (input, context) => { + return { + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminRespondToAuthChallengeRequest = (input, context) => { + return { + ...(input.AnalyticsMetadata !== undefined && + input.AnalyticsMetadata !== null && { + AnalyticsMetadata: serializeAws_json1_1AnalyticsMetadataType(input.AnalyticsMetadata, context), + }), + ...(input.ChallengeName !== undefined && input.ChallengeName !== null && { ChallengeName: input.ChallengeName }), + ...(input.ChallengeResponses !== undefined && + input.ChallengeResponses !== null && { + ChallengeResponses: serializeAws_json1_1ChallengeResponsesType(input.ChallengeResponses, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.ContextData !== undefined && + input.ContextData !== null && { ContextData: serializeAws_json1_1ContextDataType(input.ContextData, context) }), + ...(input.Session !== undefined && input.Session !== null && { Session: input.Session }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1AdminSetUserMFAPreferenceRequest = (input, context) => { + return { + ...(input.SMSMfaSettings !== undefined && + input.SMSMfaSettings !== null && { + SMSMfaSettings: serializeAws_json1_1SMSMfaSettingsType(input.SMSMfaSettings, context), + }), + ...(input.SoftwareTokenMfaSettings !== undefined && + input.SoftwareTokenMfaSettings !== null && { + SoftwareTokenMfaSettings: serializeAws_json1_1SoftwareTokenMfaSettingsType(input.SoftwareTokenMfaSettings, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminSetUserPasswordRequest = (input, context) => { + return { + ...(input.Password !== undefined && input.Password !== null && { Password: input.Password }), + ...(input.Permanent !== undefined && input.Permanent !== null && { Permanent: input.Permanent }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminSetUserSettingsRequest = (input, context) => { + return { + ...(input.MFAOptions !== undefined && + input.MFAOptions !== null && { MFAOptions: serializeAws_json1_1MFAOptionListType(input.MFAOptions, context) }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminUpdateAuthEventFeedbackRequest = (input, context) => { + return { + ...(input.EventId !== undefined && input.EventId !== null && { EventId: input.EventId }), + ...(input.FeedbackValue !== undefined && input.FeedbackValue !== null && { FeedbackValue: input.FeedbackValue }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminUpdateDeviceStatusRequest = (input, context) => { + return { + ...(input.DeviceKey !== undefined && input.DeviceKey !== null && { DeviceKey: input.DeviceKey }), + ...(input.DeviceRememberedStatus !== undefined && + input.DeviceRememberedStatus !== null && { DeviceRememberedStatus: input.DeviceRememberedStatus }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminUpdateUserAttributesRequest = (input, context) => { + return { + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.UserAttributes !== undefined && + input.UserAttributes !== null && { + UserAttributes: serializeAws_json1_1AttributeListType(input.UserAttributes, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AdminUserGlobalSignOutRequest = (input, context) => { + return { + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1AliasAttributesListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1AnalyticsConfigurationType = (input, context) => { + return { + ...(input.ApplicationArn !== undefined && + input.ApplicationArn !== null && { ApplicationArn: input.ApplicationArn }), + ...(input.ApplicationId !== undefined && input.ApplicationId !== null && { ApplicationId: input.ApplicationId }), + ...(input.ExternalId !== undefined && input.ExternalId !== null && { ExternalId: input.ExternalId }), + ...(input.RoleArn !== undefined && input.RoleArn !== null && { RoleArn: input.RoleArn }), + ...(input.UserDataShared !== undefined && + input.UserDataShared !== null && { UserDataShared: input.UserDataShared }), + }; +}; +const serializeAws_json1_1AnalyticsMetadataType = (input, context) => { + return { + ...(input.AnalyticsEndpointId !== undefined && + input.AnalyticsEndpointId !== null && { AnalyticsEndpointId: input.AnalyticsEndpointId }), + }; +}; +const serializeAws_json1_1AssociateSoftwareTokenRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.Session !== undefined && input.Session !== null && { Session: input.Session }), + }; +}; +const serializeAws_json1_1AttributeListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_json1_1AttributeType(entry, context); + }); +}; +const serializeAws_json1_1AttributeMappingType = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_json1_1AttributeNameListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1AttributeType = (input, context) => { + return { + ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }), + ...(input.Value !== undefined && input.Value !== null && { Value: input.Value }), + }; +}; +const serializeAws_json1_1AuthParametersType = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_json1_1BlockedIPRangeListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1CallbackURLsListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1ChallengeResponsesType = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_json1_1ChangePasswordRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.PreviousPassword !== undefined && + input.PreviousPassword !== null && { PreviousPassword: input.PreviousPassword }), + ...(input.ProposedPassword !== undefined && + input.ProposedPassword !== null && { ProposedPassword: input.ProposedPassword }), + }; +}; +const serializeAws_json1_1ClientMetadataType = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_json1_1ClientPermissionListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1CompromisedCredentialsActionsType = (input, context) => { + return { + ...(input.EventAction !== undefined && input.EventAction !== null && { EventAction: input.EventAction }), + }; +}; +const serializeAws_json1_1CompromisedCredentialsRiskConfigurationType = (input, context) => { + return { + ...(input.Actions !== undefined && + input.Actions !== null && { + Actions: serializeAws_json1_1CompromisedCredentialsActionsType(input.Actions, context), + }), + ...(input.EventFilter !== undefined && + input.EventFilter !== null && { EventFilter: serializeAws_json1_1EventFiltersType(input.EventFilter, context) }), + }; +}; +const serializeAws_json1_1ConfirmDeviceRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.DeviceKey !== undefined && input.DeviceKey !== null && { DeviceKey: input.DeviceKey }), + ...(input.DeviceName !== undefined && input.DeviceName !== null && { DeviceName: input.DeviceName }), + ...(input.DeviceSecretVerifierConfig !== undefined && + input.DeviceSecretVerifierConfig !== null && { + DeviceSecretVerifierConfig: serializeAws_json1_1DeviceSecretVerifierConfigType(input.DeviceSecretVerifierConfig, context), + }), + }; +}; +const serializeAws_json1_1ConfirmForgotPasswordRequest = (input, context) => { + return { + ...(input.AnalyticsMetadata !== undefined && + input.AnalyticsMetadata !== null && { + AnalyticsMetadata: serializeAws_json1_1AnalyticsMetadataType(input.AnalyticsMetadata, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.ConfirmationCode !== undefined && + input.ConfirmationCode !== null && { ConfirmationCode: input.ConfirmationCode }), + ...(input.Password !== undefined && input.Password !== null && { Password: input.Password }), + ...(input.SecretHash !== undefined && input.SecretHash !== null && { SecretHash: input.SecretHash }), + ...(input.UserContextData !== undefined && + input.UserContextData !== null && { + UserContextData: serializeAws_json1_1UserContextDataType(input.UserContextData, context), + }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1ConfirmSignUpRequest = (input, context) => { + return { + ...(input.AnalyticsMetadata !== undefined && + input.AnalyticsMetadata !== null && { + AnalyticsMetadata: serializeAws_json1_1AnalyticsMetadataType(input.AnalyticsMetadata, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.ConfirmationCode !== undefined && + input.ConfirmationCode !== null && { ConfirmationCode: input.ConfirmationCode }), + ...(input.ForceAliasCreation !== undefined && + input.ForceAliasCreation !== null && { ForceAliasCreation: input.ForceAliasCreation }), + ...(input.SecretHash !== undefined && input.SecretHash !== null && { SecretHash: input.SecretHash }), + ...(input.UserContextData !== undefined && + input.UserContextData !== null && { + UserContextData: serializeAws_json1_1UserContextDataType(input.UserContextData, context), + }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1ContextDataType = (input, context) => { + return { + ...(input.EncodedData !== undefined && input.EncodedData !== null && { EncodedData: input.EncodedData }), + ...(input.HttpHeaders !== undefined && + input.HttpHeaders !== null && { HttpHeaders: serializeAws_json1_1HttpHeaderList(input.HttpHeaders, context) }), + ...(input.IpAddress !== undefined && input.IpAddress !== null && { IpAddress: input.IpAddress }), + ...(input.ServerName !== undefined && input.ServerName !== null && { ServerName: input.ServerName }), + ...(input.ServerPath !== undefined && input.ServerPath !== null && { ServerPath: input.ServerPath }), + }; +}; +const serializeAws_json1_1CreateGroupRequest = (input, context) => { + return { + ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }), + ...(input.GroupName !== undefined && input.GroupName !== null && { GroupName: input.GroupName }), + ...(input.Precedence !== undefined && input.Precedence !== null && { Precedence: input.Precedence }), + ...(input.RoleArn !== undefined && input.RoleArn !== null && { RoleArn: input.RoleArn }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1CreateIdentityProviderRequest = (input, context) => { + return { + ...(input.AttributeMapping !== undefined && + input.AttributeMapping !== null && { + AttributeMapping: serializeAws_json1_1AttributeMappingType(input.AttributeMapping, context), + }), + ...(input.IdpIdentifiers !== undefined && + input.IdpIdentifiers !== null && { + IdpIdentifiers: serializeAws_json1_1IdpIdentifiersListType(input.IdpIdentifiers, context), + }), + ...(input.ProviderDetails !== undefined && + input.ProviderDetails !== null && { + ProviderDetails: serializeAws_json1_1ProviderDetailsType(input.ProviderDetails, context), + }), + ...(input.ProviderName !== undefined && input.ProviderName !== null && { ProviderName: input.ProviderName }), + ...(input.ProviderType !== undefined && input.ProviderType !== null && { ProviderType: input.ProviderType }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1CreateResourceServerRequest = (input, context) => { + return { + ...(input.Identifier !== undefined && input.Identifier !== null && { Identifier: input.Identifier }), + ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }), + ...(input.Scopes !== undefined && + input.Scopes !== null && { Scopes: serializeAws_json1_1ResourceServerScopeListType(input.Scopes, context) }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1CreateUserImportJobRequest = (input, context) => { + return { + ...(input.CloudWatchLogsRoleArn !== undefined && + input.CloudWatchLogsRoleArn !== null && { CloudWatchLogsRoleArn: input.CloudWatchLogsRoleArn }), + ...(input.JobName !== undefined && input.JobName !== null && { JobName: input.JobName }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1CreateUserPoolClientRequest = (input, context) => { + return { + ...(input.AccessTokenValidity !== undefined && + input.AccessTokenValidity !== null && { AccessTokenValidity: input.AccessTokenValidity }), + ...(input.AllowedOAuthFlows !== undefined && + input.AllowedOAuthFlows !== null && { + AllowedOAuthFlows: serializeAws_json1_1OAuthFlowsType(input.AllowedOAuthFlows, context), + }), + ...(input.AllowedOAuthFlowsUserPoolClient !== undefined && + input.AllowedOAuthFlowsUserPoolClient !== null && { + AllowedOAuthFlowsUserPoolClient: input.AllowedOAuthFlowsUserPoolClient, + }), + ...(input.AllowedOAuthScopes !== undefined && + input.AllowedOAuthScopes !== null && { + AllowedOAuthScopes: serializeAws_json1_1ScopeListType(input.AllowedOAuthScopes, context), + }), + ...(input.AnalyticsConfiguration !== undefined && + input.AnalyticsConfiguration !== null && { + AnalyticsConfiguration: serializeAws_json1_1AnalyticsConfigurationType(input.AnalyticsConfiguration, context), + }), + ...(input.CallbackURLs !== undefined && + input.CallbackURLs !== null && { + CallbackURLs: serializeAws_json1_1CallbackURLsListType(input.CallbackURLs, context), + }), + ...(input.ClientName !== undefined && input.ClientName !== null && { ClientName: input.ClientName }), + ...(input.DefaultRedirectURI !== undefined && + input.DefaultRedirectURI !== null && { DefaultRedirectURI: input.DefaultRedirectURI }), + ...(input.ExplicitAuthFlows !== undefined && + input.ExplicitAuthFlows !== null && { + ExplicitAuthFlows: serializeAws_json1_1ExplicitAuthFlowsListType(input.ExplicitAuthFlows, context), + }), + ...(input.GenerateSecret !== undefined && + input.GenerateSecret !== null && { GenerateSecret: input.GenerateSecret }), + ...(input.IdTokenValidity !== undefined && + input.IdTokenValidity !== null && { IdTokenValidity: input.IdTokenValidity }), + ...(input.LogoutURLs !== undefined && + input.LogoutURLs !== null && { LogoutURLs: serializeAws_json1_1LogoutURLsListType(input.LogoutURLs, context) }), + ...(input.PreventUserExistenceErrors !== undefined && + input.PreventUserExistenceErrors !== null && { PreventUserExistenceErrors: input.PreventUserExistenceErrors }), + ...(input.ReadAttributes !== undefined && + input.ReadAttributes !== null && { + ReadAttributes: serializeAws_json1_1ClientPermissionListType(input.ReadAttributes, context), + }), + ...(input.RefreshTokenValidity !== undefined && + input.RefreshTokenValidity !== null && { RefreshTokenValidity: input.RefreshTokenValidity }), + ...(input.SupportedIdentityProviders !== undefined && + input.SupportedIdentityProviders !== null && { + SupportedIdentityProviders: serializeAws_json1_1SupportedIdentityProvidersListType(input.SupportedIdentityProviders, context), + }), + ...(input.TokenValidityUnits !== undefined && + input.TokenValidityUnits !== null && { + TokenValidityUnits: serializeAws_json1_1TokenValidityUnitsType(input.TokenValidityUnits, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.WriteAttributes !== undefined && + input.WriteAttributes !== null && { + WriteAttributes: serializeAws_json1_1ClientPermissionListType(input.WriteAttributes, context), + }), + }; +}; +const serializeAws_json1_1CreateUserPoolDomainRequest = (input, context) => { + return { + ...(input.CustomDomainConfig !== undefined && + input.CustomDomainConfig !== null && { + CustomDomainConfig: serializeAws_json1_1CustomDomainConfigType(input.CustomDomainConfig, context), + }), + ...(input.Domain !== undefined && input.Domain !== null && { Domain: input.Domain }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1CreateUserPoolRequest = (input, context) => { + return { + ...(input.AccountRecoverySetting !== undefined && + input.AccountRecoverySetting !== null && { + AccountRecoverySetting: serializeAws_json1_1AccountRecoverySettingType(input.AccountRecoverySetting, context), + }), + ...(input.AdminCreateUserConfig !== undefined && + input.AdminCreateUserConfig !== null && { + AdminCreateUserConfig: serializeAws_json1_1AdminCreateUserConfigType(input.AdminCreateUserConfig, context), + }), + ...(input.AliasAttributes !== undefined && + input.AliasAttributes !== null && { + AliasAttributes: serializeAws_json1_1AliasAttributesListType(input.AliasAttributes, context), + }), + ...(input.AutoVerifiedAttributes !== undefined && + input.AutoVerifiedAttributes !== null && { + AutoVerifiedAttributes: serializeAws_json1_1VerifiedAttributesListType(input.AutoVerifiedAttributes, context), + }), + ...(input.DeviceConfiguration !== undefined && + input.DeviceConfiguration !== null && { + DeviceConfiguration: serializeAws_json1_1DeviceConfigurationType(input.DeviceConfiguration, context), + }), + ...(input.EmailConfiguration !== undefined && + input.EmailConfiguration !== null && { + EmailConfiguration: serializeAws_json1_1EmailConfigurationType(input.EmailConfiguration, context), + }), + ...(input.EmailVerificationMessage !== undefined && + input.EmailVerificationMessage !== null && { EmailVerificationMessage: input.EmailVerificationMessage }), + ...(input.EmailVerificationSubject !== undefined && + input.EmailVerificationSubject !== null && { EmailVerificationSubject: input.EmailVerificationSubject }), + ...(input.LambdaConfig !== undefined && + input.LambdaConfig !== null && { + LambdaConfig: serializeAws_json1_1LambdaConfigType(input.LambdaConfig, context), + }), + ...(input.MfaConfiguration !== undefined && + input.MfaConfiguration !== null && { MfaConfiguration: input.MfaConfiguration }), + ...(input.Policies !== undefined && + input.Policies !== null && { Policies: serializeAws_json1_1UserPoolPolicyType(input.Policies, context) }), + ...(input.PoolName !== undefined && input.PoolName !== null && { PoolName: input.PoolName }), + ...(input.Schema !== undefined && + input.Schema !== null && { Schema: serializeAws_json1_1SchemaAttributesListType(input.Schema, context) }), + ...(input.SmsAuthenticationMessage !== undefined && + input.SmsAuthenticationMessage !== null && { SmsAuthenticationMessage: input.SmsAuthenticationMessage }), + ...(input.SmsConfiguration !== undefined && + input.SmsConfiguration !== null && { + SmsConfiguration: serializeAws_json1_1SmsConfigurationType(input.SmsConfiguration, context), + }), + ...(input.SmsVerificationMessage !== undefined && + input.SmsVerificationMessage !== null && { SmsVerificationMessage: input.SmsVerificationMessage }), + ...(input.UserPoolAddOns !== undefined && + input.UserPoolAddOns !== null && { + UserPoolAddOns: serializeAws_json1_1UserPoolAddOnsType(input.UserPoolAddOns, context), + }), + ...(input.UserPoolTags !== undefined && + input.UserPoolTags !== null && { + UserPoolTags: serializeAws_json1_1UserPoolTagsType(input.UserPoolTags, context), + }), + ...(input.UsernameAttributes !== undefined && + input.UsernameAttributes !== null && { + UsernameAttributes: serializeAws_json1_1UsernameAttributesListType(input.UsernameAttributes, context), + }), + ...(input.UsernameConfiguration !== undefined && + input.UsernameConfiguration !== null && { + UsernameConfiguration: serializeAws_json1_1UsernameConfigurationType(input.UsernameConfiguration, context), + }), + ...(input.VerificationMessageTemplate !== undefined && + input.VerificationMessageTemplate !== null && { + VerificationMessageTemplate: serializeAws_json1_1VerificationMessageTemplateType(input.VerificationMessageTemplate, context), + }), + }; +}; +const serializeAws_json1_1CustomAttributesListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_json1_1SchemaAttributeType(entry, context); + }); +}; +const serializeAws_json1_1CustomDomainConfigType = (input, context) => { + return { + ...(input.CertificateArn !== undefined && + input.CertificateArn !== null && { CertificateArn: input.CertificateArn }), + }; +}; +const serializeAws_json1_1CustomEmailLambdaVersionConfigType = (input, context) => { + return { + ...(input.LambdaArn !== undefined && input.LambdaArn !== null && { LambdaArn: input.LambdaArn }), + ...(input.LambdaVersion !== undefined && input.LambdaVersion !== null && { LambdaVersion: input.LambdaVersion }), + }; +}; +const serializeAws_json1_1CustomSMSLambdaVersionConfigType = (input, context) => { + return { + ...(input.LambdaArn !== undefined && input.LambdaArn !== null && { LambdaArn: input.LambdaArn }), + ...(input.LambdaVersion !== undefined && input.LambdaVersion !== null && { LambdaVersion: input.LambdaVersion }), + }; +}; +const serializeAws_json1_1DeleteGroupRequest = (input, context) => { + return { + ...(input.GroupName !== undefined && input.GroupName !== null && { GroupName: input.GroupName }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DeleteIdentityProviderRequest = (input, context) => { + return { + ...(input.ProviderName !== undefined && input.ProviderName !== null && { ProviderName: input.ProviderName }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DeleteResourceServerRequest = (input, context) => { + return { + ...(input.Identifier !== undefined && input.Identifier !== null && { Identifier: input.Identifier }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DeleteUserAttributesRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.UserAttributeNames !== undefined && + input.UserAttributeNames !== null && { + UserAttributeNames: serializeAws_json1_1AttributeNameListType(input.UserAttributeNames, context), + }), + }; +}; +const serializeAws_json1_1DeleteUserPoolClientRequest = (input, context) => { + return { + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DeleteUserPoolDomainRequest = (input, context) => { + return { + ...(input.Domain !== undefined && input.Domain !== null && { Domain: input.Domain }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DeleteUserPoolRequest = (input, context) => { + return { + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DeleteUserRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + }; +}; +const serializeAws_json1_1DeliveryMediumListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1DescribeIdentityProviderRequest = (input, context) => { + return { + ...(input.ProviderName !== undefined && input.ProviderName !== null && { ProviderName: input.ProviderName }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DescribeResourceServerRequest = (input, context) => { + return { + ...(input.Identifier !== undefined && input.Identifier !== null && { Identifier: input.Identifier }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DescribeRiskConfigurationRequest = (input, context) => { + return { + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DescribeUserImportJobRequest = (input, context) => { + return { + ...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DescribeUserPoolClientRequest = (input, context) => { + return { + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DescribeUserPoolDomainRequest = (input, context) => { + return { + ...(input.Domain !== undefined && input.Domain !== null && { Domain: input.Domain }), + }; +}; +const serializeAws_json1_1DescribeUserPoolRequest = (input, context) => { + return { + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1DeviceConfigurationType = (input, context) => { + return { + ...(input.ChallengeRequiredOnNewDevice !== undefined && + input.ChallengeRequiredOnNewDevice !== null && { + ChallengeRequiredOnNewDevice: input.ChallengeRequiredOnNewDevice, + }), + ...(input.DeviceOnlyRememberedOnUserPrompt !== undefined && + input.DeviceOnlyRememberedOnUserPrompt !== null && { + DeviceOnlyRememberedOnUserPrompt: input.DeviceOnlyRememberedOnUserPrompt, + }), + }; +}; +const serializeAws_json1_1DeviceSecretVerifierConfigType = (input, context) => { + return { + ...(input.PasswordVerifier !== undefined && + input.PasswordVerifier !== null && { PasswordVerifier: input.PasswordVerifier }), + ...(input.Salt !== undefined && input.Salt !== null && { Salt: input.Salt }), + }; +}; +const serializeAws_json1_1EmailConfigurationType = (input, context) => { + return { + ...(input.ConfigurationSet !== undefined && + input.ConfigurationSet !== null && { ConfigurationSet: input.ConfigurationSet }), + ...(input.EmailSendingAccount !== undefined && + input.EmailSendingAccount !== null && { EmailSendingAccount: input.EmailSendingAccount }), + ...(input.From !== undefined && input.From !== null && { From: input.From }), + ...(input.ReplyToEmailAddress !== undefined && + input.ReplyToEmailAddress !== null && { ReplyToEmailAddress: input.ReplyToEmailAddress }), + ...(input.SourceArn !== undefined && input.SourceArn !== null && { SourceArn: input.SourceArn }), + }; +}; +const serializeAws_json1_1EventFiltersType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1ExplicitAuthFlowsListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1ForgetDeviceRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.DeviceKey !== undefined && input.DeviceKey !== null && { DeviceKey: input.DeviceKey }), + }; +}; +const serializeAws_json1_1ForgotPasswordRequest = (input, context) => { + return { + ...(input.AnalyticsMetadata !== undefined && + input.AnalyticsMetadata !== null && { + AnalyticsMetadata: serializeAws_json1_1AnalyticsMetadataType(input.AnalyticsMetadata, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.SecretHash !== undefined && input.SecretHash !== null && { SecretHash: input.SecretHash }), + ...(input.UserContextData !== undefined && + input.UserContextData !== null && { + UserContextData: serializeAws_json1_1UserContextDataType(input.UserContextData, context), + }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1GetCSVHeaderRequest = (input, context) => { + return { + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1GetDeviceRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.DeviceKey !== undefined && input.DeviceKey !== null && { DeviceKey: input.DeviceKey }), + }; +}; +const serializeAws_json1_1GetGroupRequest = (input, context) => { + return { + ...(input.GroupName !== undefined && input.GroupName !== null && { GroupName: input.GroupName }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1GetIdentityProviderByIdentifierRequest = (input, context) => { + return { + ...(input.IdpIdentifier !== undefined && input.IdpIdentifier !== null && { IdpIdentifier: input.IdpIdentifier }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1GetSigningCertificateRequest = (input, context) => { + return { + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1GetUICustomizationRequest = (input, context) => { + return { + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1GetUserAttributeVerificationCodeRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.AttributeName !== undefined && input.AttributeName !== null && { AttributeName: input.AttributeName }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + }; +}; +const serializeAws_json1_1GetUserPoolMfaConfigRequest = (input, context) => { + return { + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1GetUserRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + }; +}; +const serializeAws_json1_1GlobalSignOutRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + }; +}; +const serializeAws_json1_1HttpHeader = (input, context) => { + return { + ...(input.headerName !== undefined && input.headerName !== null && { headerName: input.headerName }), + ...(input.headerValue !== undefined && input.headerValue !== null && { headerValue: input.headerValue }), + }; +}; +const serializeAws_json1_1HttpHeaderList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_json1_1HttpHeader(entry, context); + }); +}; +const serializeAws_json1_1IdpIdentifiersListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1InitiateAuthRequest = (input, context) => { + return { + ...(input.AnalyticsMetadata !== undefined && + input.AnalyticsMetadata !== null && { + AnalyticsMetadata: serializeAws_json1_1AnalyticsMetadataType(input.AnalyticsMetadata, context), + }), + ...(input.AuthFlow !== undefined && input.AuthFlow !== null && { AuthFlow: input.AuthFlow }), + ...(input.AuthParameters !== undefined && + input.AuthParameters !== null && { + AuthParameters: serializeAws_json1_1AuthParametersType(input.AuthParameters, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.UserContextData !== undefined && + input.UserContextData !== null && { + UserContextData: serializeAws_json1_1UserContextDataType(input.UserContextData, context), + }), + }; +}; +const serializeAws_json1_1LambdaConfigType = (input, context) => { + return { + ...(input.CreateAuthChallenge !== undefined && + input.CreateAuthChallenge !== null && { CreateAuthChallenge: input.CreateAuthChallenge }), + ...(input.CustomEmailSender !== undefined && + input.CustomEmailSender !== null && { + CustomEmailSender: serializeAws_json1_1CustomEmailLambdaVersionConfigType(input.CustomEmailSender, context), + }), + ...(input.CustomMessage !== undefined && input.CustomMessage !== null && { CustomMessage: input.CustomMessage }), + ...(input.CustomSMSSender !== undefined && + input.CustomSMSSender !== null && { + CustomSMSSender: serializeAws_json1_1CustomSMSLambdaVersionConfigType(input.CustomSMSSender, context), + }), + ...(input.DefineAuthChallenge !== undefined && + input.DefineAuthChallenge !== null && { DefineAuthChallenge: input.DefineAuthChallenge }), + ...(input.KMSKeyID !== undefined && input.KMSKeyID !== null && { KMSKeyID: input.KMSKeyID }), + ...(input.PostAuthentication !== undefined && + input.PostAuthentication !== null && { PostAuthentication: input.PostAuthentication }), + ...(input.PostConfirmation !== undefined && + input.PostConfirmation !== null && { PostConfirmation: input.PostConfirmation }), + ...(input.PreAuthentication !== undefined && + input.PreAuthentication !== null && { PreAuthentication: input.PreAuthentication }), + ...(input.PreSignUp !== undefined && input.PreSignUp !== null && { PreSignUp: input.PreSignUp }), + ...(input.PreTokenGeneration !== undefined && + input.PreTokenGeneration !== null && { PreTokenGeneration: input.PreTokenGeneration }), + ...(input.UserMigration !== undefined && input.UserMigration !== null && { UserMigration: input.UserMigration }), + ...(input.VerifyAuthChallengeResponse !== undefined && + input.VerifyAuthChallengeResponse !== null && { VerifyAuthChallengeResponse: input.VerifyAuthChallengeResponse }), + }; +}; +const serializeAws_json1_1ListDevicesRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }), + ...(input.PaginationToken !== undefined && + input.PaginationToken !== null && { PaginationToken: input.PaginationToken }), + }; +}; +const serializeAws_json1_1ListGroupsRequest = (input, context) => { + return { + ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1ListIdentityProvidersRequest = (input, context) => { + return { + ...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1ListResourceServersRequest = (input, context) => { + return { + ...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1ListTagsForResourceRequest = (input, context) => { + return { + ...(input.ResourceArn !== undefined && input.ResourceArn !== null && { ResourceArn: input.ResourceArn }), + }; +}; +const serializeAws_json1_1ListUserImportJobsRequest = (input, context) => { + return { + ...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }), + ...(input.PaginationToken !== undefined && + input.PaginationToken !== null && { PaginationToken: input.PaginationToken }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1ListUserPoolClientsRequest = (input, context) => { + return { + ...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1ListUserPoolsRequest = (input, context) => { + return { + ...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + }; +}; +const serializeAws_json1_1ListUsersInGroupRequest = (input, context) => { + return { + ...(input.GroupName !== undefined && input.GroupName !== null && { GroupName: input.GroupName }), + ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1ListUsersRequest = (input, context) => { + return { + ...(input.AttributesToGet !== undefined && + input.AttributesToGet !== null && { + AttributesToGet: serializeAws_json1_1SearchedAttributeNamesListType(input.AttributesToGet, context), + }), + ...(input.Filter !== undefined && input.Filter !== null && { Filter: input.Filter }), + ...(input.Limit !== undefined && input.Limit !== null && { Limit: input.Limit }), + ...(input.PaginationToken !== undefined && + input.PaginationToken !== null && { PaginationToken: input.PaginationToken }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1LogoutURLsListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1MessageTemplateType = (input, context) => { + return { + ...(input.EmailMessage !== undefined && input.EmailMessage !== null && { EmailMessage: input.EmailMessage }), + ...(input.EmailSubject !== undefined && input.EmailSubject !== null && { EmailSubject: input.EmailSubject }), + ...(input.SMSMessage !== undefined && input.SMSMessage !== null && { SMSMessage: input.SMSMessage }), + }; +}; +const serializeAws_json1_1MFAOptionListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_json1_1MFAOptionType(entry, context); + }); +}; +const serializeAws_json1_1MFAOptionType = (input, context) => { + return { + ...(input.AttributeName !== undefined && input.AttributeName !== null && { AttributeName: input.AttributeName }), + ...(input.DeliveryMedium !== undefined && + input.DeliveryMedium !== null && { DeliveryMedium: input.DeliveryMedium }), + }; +}; +const serializeAws_json1_1NotifyConfigurationType = (input, context) => { + return { + ...(input.BlockEmail !== undefined && + input.BlockEmail !== null && { BlockEmail: serializeAws_json1_1NotifyEmailType(input.BlockEmail, context) }), + ...(input.From !== undefined && input.From !== null && { From: input.From }), + ...(input.MfaEmail !== undefined && + input.MfaEmail !== null && { MfaEmail: serializeAws_json1_1NotifyEmailType(input.MfaEmail, context) }), + ...(input.NoActionEmail !== undefined && + input.NoActionEmail !== null && { + NoActionEmail: serializeAws_json1_1NotifyEmailType(input.NoActionEmail, context), + }), + ...(input.ReplyTo !== undefined && input.ReplyTo !== null && { ReplyTo: input.ReplyTo }), + ...(input.SourceArn !== undefined && input.SourceArn !== null && { SourceArn: input.SourceArn }), + }; +}; +const serializeAws_json1_1NotifyEmailType = (input, context) => { + return { + ...(input.HtmlBody !== undefined && input.HtmlBody !== null && { HtmlBody: input.HtmlBody }), + ...(input.Subject !== undefined && input.Subject !== null && { Subject: input.Subject }), + ...(input.TextBody !== undefined && input.TextBody !== null && { TextBody: input.TextBody }), + }; +}; +const serializeAws_json1_1NumberAttributeConstraintsType = (input, context) => { + return { + ...(input.MaxValue !== undefined && input.MaxValue !== null && { MaxValue: input.MaxValue }), + ...(input.MinValue !== undefined && input.MinValue !== null && { MinValue: input.MinValue }), + }; +}; +const serializeAws_json1_1OAuthFlowsType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1PasswordPolicyType = (input, context) => { + return { + ...(input.MinimumLength !== undefined && input.MinimumLength !== null && { MinimumLength: input.MinimumLength }), + ...(input.RequireLowercase !== undefined && + input.RequireLowercase !== null && { RequireLowercase: input.RequireLowercase }), + ...(input.RequireNumbers !== undefined && + input.RequireNumbers !== null && { RequireNumbers: input.RequireNumbers }), + ...(input.RequireSymbols !== undefined && + input.RequireSymbols !== null && { RequireSymbols: input.RequireSymbols }), + ...(input.RequireUppercase !== undefined && + input.RequireUppercase !== null && { RequireUppercase: input.RequireUppercase }), + ...(input.TemporaryPasswordValidityDays !== undefined && + input.TemporaryPasswordValidityDays !== null && { + TemporaryPasswordValidityDays: input.TemporaryPasswordValidityDays, + }), + }; +}; +const serializeAws_json1_1ProviderDetailsType = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_json1_1ProviderUserIdentifierType = (input, context) => { + return { + ...(input.ProviderAttributeName !== undefined && + input.ProviderAttributeName !== null && { ProviderAttributeName: input.ProviderAttributeName }), + ...(input.ProviderAttributeValue !== undefined && + input.ProviderAttributeValue !== null && { ProviderAttributeValue: input.ProviderAttributeValue }), + ...(input.ProviderName !== undefined && input.ProviderName !== null && { ProviderName: input.ProviderName }), + }; +}; +const serializeAws_json1_1RecoveryMechanismsType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_json1_1RecoveryOptionType(entry, context); + }); +}; +const serializeAws_json1_1RecoveryOptionType = (input, context) => { + return { + ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }), + ...(input.Priority !== undefined && input.Priority !== null && { Priority: input.Priority }), + }; +}; +const serializeAws_json1_1ResendConfirmationCodeRequest = (input, context) => { + return { + ...(input.AnalyticsMetadata !== undefined && + input.AnalyticsMetadata !== null && { + AnalyticsMetadata: serializeAws_json1_1AnalyticsMetadataType(input.AnalyticsMetadata, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.SecretHash !== undefined && input.SecretHash !== null && { SecretHash: input.SecretHash }), + ...(input.UserContextData !== undefined && + input.UserContextData !== null && { + UserContextData: serializeAws_json1_1UserContextDataType(input.UserContextData, context), + }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1ResourceServerScopeListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_json1_1ResourceServerScopeType(entry, context); + }); +}; +const serializeAws_json1_1ResourceServerScopeType = (input, context) => { + return { + ...(input.ScopeDescription !== undefined && + input.ScopeDescription !== null && { ScopeDescription: input.ScopeDescription }), + ...(input.ScopeName !== undefined && input.ScopeName !== null && { ScopeName: input.ScopeName }), + }; +}; +const serializeAws_json1_1RespondToAuthChallengeRequest = (input, context) => { + return { + ...(input.AnalyticsMetadata !== undefined && + input.AnalyticsMetadata !== null && { + AnalyticsMetadata: serializeAws_json1_1AnalyticsMetadataType(input.AnalyticsMetadata, context), + }), + ...(input.ChallengeName !== undefined && input.ChallengeName !== null && { ChallengeName: input.ChallengeName }), + ...(input.ChallengeResponses !== undefined && + input.ChallengeResponses !== null && { + ChallengeResponses: serializeAws_json1_1ChallengeResponsesType(input.ChallengeResponses, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.Session !== undefined && input.Session !== null && { Session: input.Session }), + ...(input.UserContextData !== undefined && + input.UserContextData !== null && { + UserContextData: serializeAws_json1_1UserContextDataType(input.UserContextData, context), + }), + }; +}; +const serializeAws_json1_1RiskExceptionConfigurationType = (input, context) => { + return { + ...(input.BlockedIPRangeList !== undefined && + input.BlockedIPRangeList !== null && { + BlockedIPRangeList: serializeAws_json1_1BlockedIPRangeListType(input.BlockedIPRangeList, context), + }), + ...(input.SkippedIPRangeList !== undefined && + input.SkippedIPRangeList !== null && { + SkippedIPRangeList: serializeAws_json1_1SkippedIPRangeListType(input.SkippedIPRangeList, context), + }), + }; +}; +const serializeAws_json1_1SchemaAttributesListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_json1_1SchemaAttributeType(entry, context); + }); +}; +const serializeAws_json1_1SchemaAttributeType = (input, context) => { + return { + ...(input.AttributeDataType !== undefined && + input.AttributeDataType !== null && { AttributeDataType: input.AttributeDataType }), + ...(input.DeveloperOnlyAttribute !== undefined && + input.DeveloperOnlyAttribute !== null && { DeveloperOnlyAttribute: input.DeveloperOnlyAttribute }), + ...(input.Mutable !== undefined && input.Mutable !== null && { Mutable: input.Mutable }), + ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }), + ...(input.NumberAttributeConstraints !== undefined && + input.NumberAttributeConstraints !== null && { + NumberAttributeConstraints: serializeAws_json1_1NumberAttributeConstraintsType(input.NumberAttributeConstraints, context), + }), + ...(input.Required !== undefined && input.Required !== null && { Required: input.Required }), + ...(input.StringAttributeConstraints !== undefined && + input.StringAttributeConstraints !== null && { + StringAttributeConstraints: serializeAws_json1_1StringAttributeConstraintsType(input.StringAttributeConstraints, context), + }), + }; +}; +const serializeAws_json1_1ScopeListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1SearchedAttributeNamesListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1SetRiskConfigurationRequest = (input, context) => { + return { + ...(input.AccountTakeoverRiskConfiguration !== undefined && + input.AccountTakeoverRiskConfiguration !== null && { + AccountTakeoverRiskConfiguration: serializeAws_json1_1AccountTakeoverRiskConfigurationType(input.AccountTakeoverRiskConfiguration, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.CompromisedCredentialsRiskConfiguration !== undefined && + input.CompromisedCredentialsRiskConfiguration !== null && { + CompromisedCredentialsRiskConfiguration: serializeAws_json1_1CompromisedCredentialsRiskConfigurationType(input.CompromisedCredentialsRiskConfiguration, context), + }), + ...(input.RiskExceptionConfiguration !== undefined && + input.RiskExceptionConfiguration !== null && { + RiskExceptionConfiguration: serializeAws_json1_1RiskExceptionConfigurationType(input.RiskExceptionConfiguration, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1SetUICustomizationRequest = (input, context) => { + return { + ...(input.CSS !== undefined && input.CSS !== null && { CSS: input.CSS }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ImageFile !== undefined && + input.ImageFile !== null && { ImageFile: context.base64Encoder(input.ImageFile) }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1SetUserMFAPreferenceRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.SMSMfaSettings !== undefined && + input.SMSMfaSettings !== null && { + SMSMfaSettings: serializeAws_json1_1SMSMfaSettingsType(input.SMSMfaSettings, context), + }), + ...(input.SoftwareTokenMfaSettings !== undefined && + input.SoftwareTokenMfaSettings !== null && { + SoftwareTokenMfaSettings: serializeAws_json1_1SoftwareTokenMfaSettingsType(input.SoftwareTokenMfaSettings, context), + }), + }; +}; +const serializeAws_json1_1SetUserPoolMfaConfigRequest = (input, context) => { + return { + ...(input.MfaConfiguration !== undefined && + input.MfaConfiguration !== null && { MfaConfiguration: input.MfaConfiguration }), + ...(input.SmsMfaConfiguration !== undefined && + input.SmsMfaConfiguration !== null && { + SmsMfaConfiguration: serializeAws_json1_1SmsMfaConfigType(input.SmsMfaConfiguration, context), + }), + ...(input.SoftwareTokenMfaConfiguration !== undefined && + input.SoftwareTokenMfaConfiguration !== null && { + SoftwareTokenMfaConfiguration: serializeAws_json1_1SoftwareTokenMfaConfigType(input.SoftwareTokenMfaConfiguration, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1SetUserSettingsRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.MFAOptions !== undefined && + input.MFAOptions !== null && { MFAOptions: serializeAws_json1_1MFAOptionListType(input.MFAOptions, context) }), + }; +}; +const serializeAws_json1_1SignUpRequest = (input, context) => { + return { + ...(input.AnalyticsMetadata !== undefined && + input.AnalyticsMetadata !== null && { + AnalyticsMetadata: serializeAws_json1_1AnalyticsMetadataType(input.AnalyticsMetadata, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.Password !== undefined && input.Password !== null && { Password: input.Password }), + ...(input.SecretHash !== undefined && input.SecretHash !== null && { SecretHash: input.SecretHash }), + ...(input.UserAttributes !== undefined && + input.UserAttributes !== null && { + UserAttributes: serializeAws_json1_1AttributeListType(input.UserAttributes, context), + }), + ...(input.UserContextData !== undefined && + input.UserContextData !== null && { + UserContextData: serializeAws_json1_1UserContextDataType(input.UserContextData, context), + }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + ...(input.ValidationData !== undefined && + input.ValidationData !== null && { + ValidationData: serializeAws_json1_1AttributeListType(input.ValidationData, context), + }), + }; +}; +const serializeAws_json1_1SkippedIPRangeListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1SmsConfigurationType = (input, context) => { + return { + ...(input.ExternalId !== undefined && input.ExternalId !== null && { ExternalId: input.ExternalId }), + ...(input.SnsCallerArn !== undefined && input.SnsCallerArn !== null && { SnsCallerArn: input.SnsCallerArn }), + }; +}; +const serializeAws_json1_1SmsMfaConfigType = (input, context) => { + return { + ...(input.SmsAuthenticationMessage !== undefined && + input.SmsAuthenticationMessage !== null && { SmsAuthenticationMessage: input.SmsAuthenticationMessage }), + ...(input.SmsConfiguration !== undefined && + input.SmsConfiguration !== null && { + SmsConfiguration: serializeAws_json1_1SmsConfigurationType(input.SmsConfiguration, context), + }), + }; +}; +const serializeAws_json1_1SMSMfaSettingsType = (input, context) => { + return { + ...(input.Enabled !== undefined && input.Enabled !== null && { Enabled: input.Enabled }), + ...(input.PreferredMfa !== undefined && input.PreferredMfa !== null && { PreferredMfa: input.PreferredMfa }), + }; +}; +const serializeAws_json1_1SoftwareTokenMfaConfigType = (input, context) => { + return { + ...(input.Enabled !== undefined && input.Enabled !== null && { Enabled: input.Enabled }), + }; +}; +const serializeAws_json1_1SoftwareTokenMfaSettingsType = (input, context) => { + return { + ...(input.Enabled !== undefined && input.Enabled !== null && { Enabled: input.Enabled }), + ...(input.PreferredMfa !== undefined && input.PreferredMfa !== null && { PreferredMfa: input.PreferredMfa }), + }; +}; +const serializeAws_json1_1StartUserImportJobRequest = (input, context) => { + return { + ...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1StopUserImportJobRequest = (input, context) => { + return { + ...(input.JobId !== undefined && input.JobId !== null && { JobId: input.JobId }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1StringAttributeConstraintsType = (input, context) => { + return { + ...(input.MaxLength !== undefined && input.MaxLength !== null && { MaxLength: input.MaxLength }), + ...(input.MinLength !== undefined && input.MinLength !== null && { MinLength: input.MinLength }), + }; +}; +const serializeAws_json1_1SupportedIdentityProvidersListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1TagResourceRequest = (input, context) => { + return { + ...(input.ResourceArn !== undefined && input.ResourceArn !== null && { ResourceArn: input.ResourceArn }), + ...(input.Tags !== undefined && + input.Tags !== null && { Tags: serializeAws_json1_1UserPoolTagsType(input.Tags, context) }), + }; +}; +const serializeAws_json1_1TokenValidityUnitsType = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.IdToken !== undefined && input.IdToken !== null && { IdToken: input.IdToken }), + ...(input.RefreshToken !== undefined && input.RefreshToken !== null && { RefreshToken: input.RefreshToken }), + }; +}; +const serializeAws_json1_1UntagResourceRequest = (input, context) => { + return { + ...(input.ResourceArn !== undefined && input.ResourceArn !== null && { ResourceArn: input.ResourceArn }), + ...(input.TagKeys !== undefined && + input.TagKeys !== null && { TagKeys: serializeAws_json1_1UserPoolTagsListType(input.TagKeys, context) }), + }; +}; +const serializeAws_json1_1UpdateAuthEventFeedbackRequest = (input, context) => { + return { + ...(input.EventId !== undefined && input.EventId !== null && { EventId: input.EventId }), + ...(input.FeedbackToken !== undefined && input.FeedbackToken !== null && { FeedbackToken: input.FeedbackToken }), + ...(input.FeedbackValue !== undefined && input.FeedbackValue !== null && { FeedbackValue: input.FeedbackValue }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.Username !== undefined && input.Username !== null && { Username: input.Username }), + }; +}; +const serializeAws_json1_1UpdateDeviceStatusRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.DeviceKey !== undefined && input.DeviceKey !== null && { DeviceKey: input.DeviceKey }), + ...(input.DeviceRememberedStatus !== undefined && + input.DeviceRememberedStatus !== null && { DeviceRememberedStatus: input.DeviceRememberedStatus }), + }; +}; +const serializeAws_json1_1UpdateGroupRequest = (input, context) => { + return { + ...(input.Description !== undefined && input.Description !== null && { Description: input.Description }), + ...(input.GroupName !== undefined && input.GroupName !== null && { GroupName: input.GroupName }), + ...(input.Precedence !== undefined && input.Precedence !== null && { Precedence: input.Precedence }), + ...(input.RoleArn !== undefined && input.RoleArn !== null && { RoleArn: input.RoleArn }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1UpdateIdentityProviderRequest = (input, context) => { + return { + ...(input.AttributeMapping !== undefined && + input.AttributeMapping !== null && { + AttributeMapping: serializeAws_json1_1AttributeMappingType(input.AttributeMapping, context), + }), + ...(input.IdpIdentifiers !== undefined && + input.IdpIdentifiers !== null && { + IdpIdentifiers: serializeAws_json1_1IdpIdentifiersListType(input.IdpIdentifiers, context), + }), + ...(input.ProviderDetails !== undefined && + input.ProviderDetails !== null && { + ProviderDetails: serializeAws_json1_1ProviderDetailsType(input.ProviderDetails, context), + }), + ...(input.ProviderName !== undefined && input.ProviderName !== null && { ProviderName: input.ProviderName }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1UpdateResourceServerRequest = (input, context) => { + return { + ...(input.Identifier !== undefined && input.Identifier !== null && { Identifier: input.Identifier }), + ...(input.Name !== undefined && input.Name !== null && { Name: input.Name }), + ...(input.Scopes !== undefined && + input.Scopes !== null && { Scopes: serializeAws_json1_1ResourceServerScopeListType(input.Scopes, context) }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1UpdateUserAttributesRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.ClientMetadata !== undefined && + input.ClientMetadata !== null && { + ClientMetadata: serializeAws_json1_1ClientMetadataType(input.ClientMetadata, context), + }), + ...(input.UserAttributes !== undefined && + input.UserAttributes !== null && { + UserAttributes: serializeAws_json1_1AttributeListType(input.UserAttributes, context), + }), + }; +}; +const serializeAws_json1_1UpdateUserPoolClientRequest = (input, context) => { + return { + ...(input.AccessTokenValidity !== undefined && + input.AccessTokenValidity !== null && { AccessTokenValidity: input.AccessTokenValidity }), + ...(input.AllowedOAuthFlows !== undefined && + input.AllowedOAuthFlows !== null && { + AllowedOAuthFlows: serializeAws_json1_1OAuthFlowsType(input.AllowedOAuthFlows, context), + }), + ...(input.AllowedOAuthFlowsUserPoolClient !== undefined && + input.AllowedOAuthFlowsUserPoolClient !== null && { + AllowedOAuthFlowsUserPoolClient: input.AllowedOAuthFlowsUserPoolClient, + }), + ...(input.AllowedOAuthScopes !== undefined && + input.AllowedOAuthScopes !== null && { + AllowedOAuthScopes: serializeAws_json1_1ScopeListType(input.AllowedOAuthScopes, context), + }), + ...(input.AnalyticsConfiguration !== undefined && + input.AnalyticsConfiguration !== null && { + AnalyticsConfiguration: serializeAws_json1_1AnalyticsConfigurationType(input.AnalyticsConfiguration, context), + }), + ...(input.CallbackURLs !== undefined && + input.CallbackURLs !== null && { + CallbackURLs: serializeAws_json1_1CallbackURLsListType(input.CallbackURLs, context), + }), + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ClientName !== undefined && input.ClientName !== null && { ClientName: input.ClientName }), + ...(input.DefaultRedirectURI !== undefined && + input.DefaultRedirectURI !== null && { DefaultRedirectURI: input.DefaultRedirectURI }), + ...(input.ExplicitAuthFlows !== undefined && + input.ExplicitAuthFlows !== null && { + ExplicitAuthFlows: serializeAws_json1_1ExplicitAuthFlowsListType(input.ExplicitAuthFlows, context), + }), + ...(input.IdTokenValidity !== undefined && + input.IdTokenValidity !== null && { IdTokenValidity: input.IdTokenValidity }), + ...(input.LogoutURLs !== undefined && + input.LogoutURLs !== null && { LogoutURLs: serializeAws_json1_1LogoutURLsListType(input.LogoutURLs, context) }), + ...(input.PreventUserExistenceErrors !== undefined && + input.PreventUserExistenceErrors !== null && { PreventUserExistenceErrors: input.PreventUserExistenceErrors }), + ...(input.ReadAttributes !== undefined && + input.ReadAttributes !== null && { + ReadAttributes: serializeAws_json1_1ClientPermissionListType(input.ReadAttributes, context), + }), + ...(input.RefreshTokenValidity !== undefined && + input.RefreshTokenValidity !== null && { RefreshTokenValidity: input.RefreshTokenValidity }), + ...(input.SupportedIdentityProviders !== undefined && + input.SupportedIdentityProviders !== null && { + SupportedIdentityProviders: serializeAws_json1_1SupportedIdentityProvidersListType(input.SupportedIdentityProviders, context), + }), + ...(input.TokenValidityUnits !== undefined && + input.TokenValidityUnits !== null && { + TokenValidityUnits: serializeAws_json1_1TokenValidityUnitsType(input.TokenValidityUnits, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.WriteAttributes !== undefined && + input.WriteAttributes !== null && { + WriteAttributes: serializeAws_json1_1ClientPermissionListType(input.WriteAttributes, context), + }), + }; +}; +const serializeAws_json1_1UpdateUserPoolDomainRequest = (input, context) => { + return { + ...(input.CustomDomainConfig !== undefined && + input.CustomDomainConfig !== null && { + CustomDomainConfig: serializeAws_json1_1CustomDomainConfigType(input.CustomDomainConfig, context), + }), + ...(input.Domain !== undefined && input.Domain !== null && { Domain: input.Domain }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + }; +}; +const serializeAws_json1_1UpdateUserPoolRequest = (input, context) => { + return { + ...(input.AccountRecoverySetting !== undefined && + input.AccountRecoverySetting !== null && { + AccountRecoverySetting: serializeAws_json1_1AccountRecoverySettingType(input.AccountRecoverySetting, context), + }), + ...(input.AdminCreateUserConfig !== undefined && + input.AdminCreateUserConfig !== null && { + AdminCreateUserConfig: serializeAws_json1_1AdminCreateUserConfigType(input.AdminCreateUserConfig, context), + }), + ...(input.AutoVerifiedAttributes !== undefined && + input.AutoVerifiedAttributes !== null && { + AutoVerifiedAttributes: serializeAws_json1_1VerifiedAttributesListType(input.AutoVerifiedAttributes, context), + }), + ...(input.DeviceConfiguration !== undefined && + input.DeviceConfiguration !== null && { + DeviceConfiguration: serializeAws_json1_1DeviceConfigurationType(input.DeviceConfiguration, context), + }), + ...(input.EmailConfiguration !== undefined && + input.EmailConfiguration !== null && { + EmailConfiguration: serializeAws_json1_1EmailConfigurationType(input.EmailConfiguration, context), + }), + ...(input.EmailVerificationMessage !== undefined && + input.EmailVerificationMessage !== null && { EmailVerificationMessage: input.EmailVerificationMessage }), + ...(input.EmailVerificationSubject !== undefined && + input.EmailVerificationSubject !== null && { EmailVerificationSubject: input.EmailVerificationSubject }), + ...(input.LambdaConfig !== undefined && + input.LambdaConfig !== null && { + LambdaConfig: serializeAws_json1_1LambdaConfigType(input.LambdaConfig, context), + }), + ...(input.MfaConfiguration !== undefined && + input.MfaConfiguration !== null && { MfaConfiguration: input.MfaConfiguration }), + ...(input.Policies !== undefined && + input.Policies !== null && { Policies: serializeAws_json1_1UserPoolPolicyType(input.Policies, context) }), + ...(input.SmsAuthenticationMessage !== undefined && + input.SmsAuthenticationMessage !== null && { SmsAuthenticationMessage: input.SmsAuthenticationMessage }), + ...(input.SmsConfiguration !== undefined && + input.SmsConfiguration !== null && { + SmsConfiguration: serializeAws_json1_1SmsConfigurationType(input.SmsConfiguration, context), + }), + ...(input.SmsVerificationMessage !== undefined && + input.SmsVerificationMessage !== null && { SmsVerificationMessage: input.SmsVerificationMessage }), + ...(input.UserPoolAddOns !== undefined && + input.UserPoolAddOns !== null && { + UserPoolAddOns: serializeAws_json1_1UserPoolAddOnsType(input.UserPoolAddOns, context), + }), + ...(input.UserPoolId !== undefined && input.UserPoolId !== null && { UserPoolId: input.UserPoolId }), + ...(input.UserPoolTags !== undefined && + input.UserPoolTags !== null && { + UserPoolTags: serializeAws_json1_1UserPoolTagsType(input.UserPoolTags, context), + }), + ...(input.VerificationMessageTemplate !== undefined && + input.VerificationMessageTemplate !== null && { + VerificationMessageTemplate: serializeAws_json1_1VerificationMessageTemplateType(input.VerificationMessageTemplate, context), + }), + }; +}; +const serializeAws_json1_1UserContextDataType = (input, context) => { + return { + ...(input.EncodedData !== undefined && input.EncodedData !== null && { EncodedData: input.EncodedData }), + }; +}; +const serializeAws_json1_1UsernameAttributesListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1UsernameConfigurationType = (input, context) => { + return { + ...(input.CaseSensitive !== undefined && input.CaseSensitive !== null && { CaseSensitive: input.CaseSensitive }), + }; +}; +const serializeAws_json1_1UserPoolAddOnsType = (input, context) => { + return { + ...(input.AdvancedSecurityMode !== undefined && + input.AdvancedSecurityMode !== null && { AdvancedSecurityMode: input.AdvancedSecurityMode }), + }; +}; +const serializeAws_json1_1UserPoolPolicyType = (input, context) => { + return { + ...(input.PasswordPolicy !== undefined && + input.PasswordPolicy !== null && { + PasswordPolicy: serializeAws_json1_1PasswordPolicyType(input.PasswordPolicy, context), + }), + }; +}; +const serializeAws_json1_1UserPoolTagsListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1UserPoolTagsType = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_json1_1VerificationMessageTemplateType = (input, context) => { + return { + ...(input.DefaultEmailOption !== undefined && + input.DefaultEmailOption !== null && { DefaultEmailOption: input.DefaultEmailOption }), + ...(input.EmailMessage !== undefined && input.EmailMessage !== null && { EmailMessage: input.EmailMessage }), + ...(input.EmailMessageByLink !== undefined && + input.EmailMessageByLink !== null && { EmailMessageByLink: input.EmailMessageByLink }), + ...(input.EmailSubject !== undefined && input.EmailSubject !== null && { EmailSubject: input.EmailSubject }), + ...(input.EmailSubjectByLink !== undefined && + input.EmailSubjectByLink !== null && { EmailSubjectByLink: input.EmailSubjectByLink }), + ...(input.SmsMessage !== undefined && input.SmsMessage !== null && { SmsMessage: input.SmsMessage }), + }; +}; +const serializeAws_json1_1VerifiedAttributesListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1VerifySoftwareTokenRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.FriendlyDeviceName !== undefined && + input.FriendlyDeviceName !== null && { FriendlyDeviceName: input.FriendlyDeviceName }), + ...(input.Session !== undefined && input.Session !== null && { Session: input.Session }), + ...(input.UserCode !== undefined && input.UserCode !== null && { UserCode: input.UserCode }), + }; +}; +const serializeAws_json1_1VerifyUserAttributeRequest = (input, context) => { + return { + ...(input.AccessToken !== undefined && input.AccessToken !== null && { AccessToken: input.AccessToken }), + ...(input.AttributeName !== undefined && input.AttributeName !== null && { AttributeName: input.AttributeName }), + ...(input.Code !== undefined && input.Code !== null && { Code: input.Code }), + }; +}; +const deserializeAws_json1_1AccountRecoverySettingType = (output, context) => { + return { + RecoveryMechanisms: output.RecoveryMechanisms !== undefined && output.RecoveryMechanisms !== null + ? deserializeAws_json1_1RecoveryMechanismsType(output.RecoveryMechanisms, context) + : undefined, + }; +}; +const deserializeAws_json1_1AccountTakeoverActionsType = (output, context) => { + return { + HighAction: output.HighAction !== undefined && output.HighAction !== null + ? deserializeAws_json1_1AccountTakeoverActionType(output.HighAction, context) + : undefined, + LowAction: output.LowAction !== undefined && output.LowAction !== null + ? deserializeAws_json1_1AccountTakeoverActionType(output.LowAction, context) + : undefined, + MediumAction: output.MediumAction !== undefined && output.MediumAction !== null + ? deserializeAws_json1_1AccountTakeoverActionType(output.MediumAction, context) + : undefined, + }; +}; +const deserializeAws_json1_1AccountTakeoverActionType = (output, context) => { + return { + EventAction: output.EventAction !== undefined && output.EventAction !== null ? output.EventAction : undefined, + Notify: output.Notify !== undefined && output.Notify !== null ? output.Notify : undefined, + }; +}; +const deserializeAws_json1_1AccountTakeoverRiskConfigurationType = (output, context) => { + return { + Actions: output.Actions !== undefined && output.Actions !== null + ? deserializeAws_json1_1AccountTakeoverActionsType(output.Actions, context) + : undefined, + NotifyConfiguration: output.NotifyConfiguration !== undefined && output.NotifyConfiguration !== null + ? deserializeAws_json1_1NotifyConfigurationType(output.NotifyConfiguration, context) + : undefined, + }; +}; +const deserializeAws_json1_1AddCustomAttributesResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminConfirmSignUpResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminCreateUserConfigType = (output, context) => { + return { + AllowAdminCreateUserOnly: output.AllowAdminCreateUserOnly !== undefined && output.AllowAdminCreateUserOnly !== null + ? output.AllowAdminCreateUserOnly + : undefined, + InviteMessageTemplate: output.InviteMessageTemplate !== undefined && output.InviteMessageTemplate !== null + ? deserializeAws_json1_1MessageTemplateType(output.InviteMessageTemplate, context) + : undefined, + UnusedAccountValidityDays: output.UnusedAccountValidityDays !== undefined && output.UnusedAccountValidityDays !== null + ? output.UnusedAccountValidityDays + : undefined, + }; +}; +const deserializeAws_json1_1AdminCreateUserResponse = (output, context) => { + return { + User: output.User !== undefined && output.User !== null + ? deserializeAws_json1_1UserType(output.User, context) + : undefined, + }; +}; +const deserializeAws_json1_1AdminDeleteUserAttributesResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminDisableProviderForUserResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminDisableUserResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminEnableUserResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminGetDeviceResponse = (output, context) => { + return { + Device: output.Device !== undefined && output.Device !== null + ? deserializeAws_json1_1DeviceType(output.Device, context) + : undefined, + }; +}; +const deserializeAws_json1_1AdminGetUserResponse = (output, context) => { + return { + Enabled: output.Enabled !== undefined && output.Enabled !== null ? output.Enabled : undefined, + MFAOptions: output.MFAOptions !== undefined && output.MFAOptions !== null + ? deserializeAws_json1_1MFAOptionListType(output.MFAOptions, context) + : undefined, + PreferredMfaSetting: output.PreferredMfaSetting !== undefined && output.PreferredMfaSetting !== null + ? output.PreferredMfaSetting + : undefined, + UserAttributes: output.UserAttributes !== undefined && output.UserAttributes !== null + ? deserializeAws_json1_1AttributeListType(output.UserAttributes, context) + : undefined, + UserCreateDate: output.UserCreateDate !== undefined && output.UserCreateDate !== null + ? new Date(Math.round(output.UserCreateDate * 1000)) + : undefined, + UserLastModifiedDate: output.UserLastModifiedDate !== undefined && output.UserLastModifiedDate !== null + ? new Date(Math.round(output.UserLastModifiedDate * 1000)) + : undefined, + UserMFASettingList: output.UserMFASettingList !== undefined && output.UserMFASettingList !== null + ? deserializeAws_json1_1UserMFASettingListType(output.UserMFASettingList, context) + : undefined, + UserStatus: output.UserStatus !== undefined && output.UserStatus !== null ? output.UserStatus : undefined, + Username: output.Username !== undefined && output.Username !== null ? output.Username : undefined, + }; +}; +const deserializeAws_json1_1AdminInitiateAuthResponse = (output, context) => { + return { + AuthenticationResult: output.AuthenticationResult !== undefined && output.AuthenticationResult !== null + ? deserializeAws_json1_1AuthenticationResultType(output.AuthenticationResult, context) + : undefined, + ChallengeName: output.ChallengeName !== undefined && output.ChallengeName !== null ? output.ChallengeName : undefined, + ChallengeParameters: output.ChallengeParameters !== undefined && output.ChallengeParameters !== null + ? deserializeAws_json1_1ChallengeParametersType(output.ChallengeParameters, context) + : undefined, + Session: output.Session !== undefined && output.Session !== null ? output.Session : undefined, + }; +}; +const deserializeAws_json1_1AdminLinkProviderForUserResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminListDevicesResponse = (output, context) => { + return { + Devices: output.Devices !== undefined && output.Devices !== null + ? deserializeAws_json1_1DeviceListType(output.Devices, context) + : undefined, + PaginationToken: output.PaginationToken !== undefined && output.PaginationToken !== null ? output.PaginationToken : undefined, + }; +}; +const deserializeAws_json1_1AdminListGroupsForUserResponse = (output, context) => { + return { + Groups: output.Groups !== undefined && output.Groups !== null + ? deserializeAws_json1_1GroupListType(output.Groups, context) + : undefined, + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + }; +}; +const deserializeAws_json1_1AdminListUserAuthEventsResponse = (output, context) => { + return { + AuthEvents: output.AuthEvents !== undefined && output.AuthEvents !== null + ? deserializeAws_json1_1AuthEventsType(output.AuthEvents, context) + : undefined, + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + }; +}; +const deserializeAws_json1_1AdminResetUserPasswordResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminRespondToAuthChallengeResponse = (output, context) => { + return { + AuthenticationResult: output.AuthenticationResult !== undefined && output.AuthenticationResult !== null + ? deserializeAws_json1_1AuthenticationResultType(output.AuthenticationResult, context) + : undefined, + ChallengeName: output.ChallengeName !== undefined && output.ChallengeName !== null ? output.ChallengeName : undefined, + ChallengeParameters: output.ChallengeParameters !== undefined && output.ChallengeParameters !== null + ? deserializeAws_json1_1ChallengeParametersType(output.ChallengeParameters, context) + : undefined, + Session: output.Session !== undefined && output.Session !== null ? output.Session : undefined, + }; +}; +const deserializeAws_json1_1AdminSetUserMFAPreferenceResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminSetUserPasswordResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminSetUserSettingsResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminUpdateAuthEventFeedbackResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminUpdateDeviceStatusResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminUpdateUserAttributesResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AdminUserGlobalSignOutResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1AliasAttributesListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1AliasExistsException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1AnalyticsConfigurationType = (output, context) => { + return { + ApplicationArn: output.ApplicationArn !== undefined && output.ApplicationArn !== null ? output.ApplicationArn : undefined, + ApplicationId: output.ApplicationId !== undefined && output.ApplicationId !== null ? output.ApplicationId : undefined, + ExternalId: output.ExternalId !== undefined && output.ExternalId !== null ? output.ExternalId : undefined, + RoleArn: output.RoleArn !== undefined && output.RoleArn !== null ? output.RoleArn : undefined, + UserDataShared: output.UserDataShared !== undefined && output.UserDataShared !== null ? output.UserDataShared : undefined, + }; +}; +const deserializeAws_json1_1AssociateSoftwareTokenResponse = (output, context) => { + return { + SecretCode: output.SecretCode !== undefined && output.SecretCode !== null ? output.SecretCode : undefined, + Session: output.Session !== undefined && output.Session !== null ? output.Session : undefined, + }; +}; +const deserializeAws_json1_1AttributeListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1AttributeType(entry, context); + }); +}; +const deserializeAws_json1_1AttributeMappingType = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_json1_1AttributeType = (output, context) => { + return { + Name: output.Name !== undefined && output.Name !== null ? output.Name : undefined, + Value: output.Value !== undefined && output.Value !== null ? output.Value : undefined, + }; +}; +const deserializeAws_json1_1AuthenticationResultType = (output, context) => { + return { + AccessToken: output.AccessToken !== undefined && output.AccessToken !== null ? output.AccessToken : undefined, + ExpiresIn: output.ExpiresIn !== undefined && output.ExpiresIn !== null ? output.ExpiresIn : undefined, + IdToken: output.IdToken !== undefined && output.IdToken !== null ? output.IdToken : undefined, + NewDeviceMetadata: output.NewDeviceMetadata !== undefined && output.NewDeviceMetadata !== null + ? deserializeAws_json1_1NewDeviceMetadataType(output.NewDeviceMetadata, context) + : undefined, + RefreshToken: output.RefreshToken !== undefined && output.RefreshToken !== null ? output.RefreshToken : undefined, + TokenType: output.TokenType !== undefined && output.TokenType !== null ? output.TokenType : undefined, + }; +}; +const deserializeAws_json1_1AuthEventsType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1AuthEventType(entry, context); + }); +}; +const deserializeAws_json1_1AuthEventType = (output, context) => { + return { + ChallengeResponses: output.ChallengeResponses !== undefined && output.ChallengeResponses !== null + ? deserializeAws_json1_1ChallengeResponseListType(output.ChallengeResponses, context) + : undefined, + CreationDate: output.CreationDate !== undefined && output.CreationDate !== null + ? new Date(Math.round(output.CreationDate * 1000)) + : undefined, + EventContextData: output.EventContextData !== undefined && output.EventContextData !== null + ? deserializeAws_json1_1EventContextDataType(output.EventContextData, context) + : undefined, + EventFeedback: output.EventFeedback !== undefined && output.EventFeedback !== null + ? deserializeAws_json1_1EventFeedbackType(output.EventFeedback, context) + : undefined, + EventId: output.EventId !== undefined && output.EventId !== null ? output.EventId : undefined, + EventResponse: output.EventResponse !== undefined && output.EventResponse !== null ? output.EventResponse : undefined, + EventRisk: output.EventRisk !== undefined && output.EventRisk !== null + ? deserializeAws_json1_1EventRiskType(output.EventRisk, context) + : undefined, + EventType: output.EventType !== undefined && output.EventType !== null ? output.EventType : undefined, + }; +}; +const deserializeAws_json1_1BlockedIPRangeListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1CallbackURLsListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1ChallengeParametersType = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_json1_1ChallengeResponseListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1ChallengeResponseType(entry, context); + }); +}; +const deserializeAws_json1_1ChallengeResponseType = (output, context) => { + return { + ChallengeName: output.ChallengeName !== undefined && output.ChallengeName !== null ? output.ChallengeName : undefined, + ChallengeResponse: output.ChallengeResponse !== undefined && output.ChallengeResponse !== null + ? output.ChallengeResponse + : undefined, + }; +}; +const deserializeAws_json1_1ChangePasswordResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1ClientPermissionListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1CodeDeliveryDetailsListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1CodeDeliveryDetailsType(entry, context); + }); +}; +const deserializeAws_json1_1CodeDeliveryDetailsType = (output, context) => { + return { + AttributeName: output.AttributeName !== undefined && output.AttributeName !== null ? output.AttributeName : undefined, + DeliveryMedium: output.DeliveryMedium !== undefined && output.DeliveryMedium !== null ? output.DeliveryMedium : undefined, + Destination: output.Destination !== undefined && output.Destination !== null ? output.Destination : undefined, + }; +}; +const deserializeAws_json1_1CodeDeliveryFailureException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1CodeMismatchException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1CompromisedCredentialsActionsType = (output, context) => { + return { + EventAction: output.EventAction !== undefined && output.EventAction !== null ? output.EventAction : undefined, + }; +}; +const deserializeAws_json1_1CompromisedCredentialsRiskConfigurationType = (output, context) => { + return { + Actions: output.Actions !== undefined && output.Actions !== null + ? deserializeAws_json1_1CompromisedCredentialsActionsType(output.Actions, context) + : undefined, + EventFilter: output.EventFilter !== undefined && output.EventFilter !== null + ? deserializeAws_json1_1EventFiltersType(output.EventFilter, context) + : undefined, + }; +}; +const deserializeAws_json1_1ConcurrentModificationException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1ConfirmDeviceResponse = (output, context) => { + return { + UserConfirmationNecessary: output.UserConfirmationNecessary !== undefined && output.UserConfirmationNecessary !== null + ? output.UserConfirmationNecessary + : undefined, + }; +}; +const deserializeAws_json1_1ConfirmForgotPasswordResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1ConfirmSignUpResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1CreateGroupResponse = (output, context) => { + return { + Group: output.Group !== undefined && output.Group !== null + ? deserializeAws_json1_1GroupType(output.Group, context) + : undefined, + }; +}; +const deserializeAws_json1_1CreateIdentityProviderResponse = (output, context) => { + return { + IdentityProvider: output.IdentityProvider !== undefined && output.IdentityProvider !== null + ? deserializeAws_json1_1IdentityProviderType(output.IdentityProvider, context) + : undefined, + }; +}; +const deserializeAws_json1_1CreateResourceServerResponse = (output, context) => { + return { + ResourceServer: output.ResourceServer !== undefined && output.ResourceServer !== null + ? deserializeAws_json1_1ResourceServerType(output.ResourceServer, context) + : undefined, + }; +}; +const deserializeAws_json1_1CreateUserImportJobResponse = (output, context) => { + return { + UserImportJob: output.UserImportJob !== undefined && output.UserImportJob !== null + ? deserializeAws_json1_1UserImportJobType(output.UserImportJob, context) + : undefined, + }; +}; +const deserializeAws_json1_1CreateUserPoolClientResponse = (output, context) => { + return { + UserPoolClient: output.UserPoolClient !== undefined && output.UserPoolClient !== null + ? deserializeAws_json1_1UserPoolClientType(output.UserPoolClient, context) + : undefined, + }; +}; +const deserializeAws_json1_1CreateUserPoolDomainResponse = (output, context) => { + return { + CloudFrontDomain: output.CloudFrontDomain !== undefined && output.CloudFrontDomain !== null ? output.CloudFrontDomain : undefined, + }; +}; +const deserializeAws_json1_1CreateUserPoolResponse = (output, context) => { + return { + UserPool: output.UserPool !== undefined && output.UserPool !== null + ? deserializeAws_json1_1UserPoolType(output.UserPool, context) + : undefined, + }; +}; +const deserializeAws_json1_1CustomDomainConfigType = (output, context) => { + return { + CertificateArn: output.CertificateArn !== undefined && output.CertificateArn !== null ? output.CertificateArn : undefined, + }; +}; +const deserializeAws_json1_1CustomEmailLambdaVersionConfigType = (output, context) => { + return { + LambdaArn: output.LambdaArn !== undefined && output.LambdaArn !== null ? output.LambdaArn : undefined, + LambdaVersion: output.LambdaVersion !== undefined && output.LambdaVersion !== null ? output.LambdaVersion : undefined, + }; +}; +const deserializeAws_json1_1CustomSMSLambdaVersionConfigType = (output, context) => { + return { + LambdaArn: output.LambdaArn !== undefined && output.LambdaArn !== null ? output.LambdaArn : undefined, + LambdaVersion: output.LambdaVersion !== undefined && output.LambdaVersion !== null ? output.LambdaVersion : undefined, + }; +}; +const deserializeAws_json1_1DeleteUserAttributesResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1DeleteUserPoolDomainResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1DescribeIdentityProviderResponse = (output, context) => { + return { + IdentityProvider: output.IdentityProvider !== undefined && output.IdentityProvider !== null + ? deserializeAws_json1_1IdentityProviderType(output.IdentityProvider, context) + : undefined, + }; +}; +const deserializeAws_json1_1DescribeResourceServerResponse = (output, context) => { + return { + ResourceServer: output.ResourceServer !== undefined && output.ResourceServer !== null + ? deserializeAws_json1_1ResourceServerType(output.ResourceServer, context) + : undefined, + }; +}; +const deserializeAws_json1_1DescribeRiskConfigurationResponse = (output, context) => { + return { + RiskConfiguration: output.RiskConfiguration !== undefined && output.RiskConfiguration !== null + ? deserializeAws_json1_1RiskConfigurationType(output.RiskConfiguration, context) + : undefined, + }; +}; +const deserializeAws_json1_1DescribeUserImportJobResponse = (output, context) => { + return { + UserImportJob: output.UserImportJob !== undefined && output.UserImportJob !== null + ? deserializeAws_json1_1UserImportJobType(output.UserImportJob, context) + : undefined, + }; +}; +const deserializeAws_json1_1DescribeUserPoolClientResponse = (output, context) => { + return { + UserPoolClient: output.UserPoolClient !== undefined && output.UserPoolClient !== null + ? deserializeAws_json1_1UserPoolClientType(output.UserPoolClient, context) + : undefined, + }; +}; +const deserializeAws_json1_1DescribeUserPoolDomainResponse = (output, context) => { + return { + DomainDescription: output.DomainDescription !== undefined && output.DomainDescription !== null + ? deserializeAws_json1_1DomainDescriptionType(output.DomainDescription, context) + : undefined, + }; +}; +const deserializeAws_json1_1DescribeUserPoolResponse = (output, context) => { + return { + UserPool: output.UserPool !== undefined && output.UserPool !== null + ? deserializeAws_json1_1UserPoolType(output.UserPool, context) + : undefined, + }; +}; +const deserializeAws_json1_1DeviceConfigurationType = (output, context) => { + return { + ChallengeRequiredOnNewDevice: output.ChallengeRequiredOnNewDevice !== undefined && output.ChallengeRequiredOnNewDevice !== null + ? output.ChallengeRequiredOnNewDevice + : undefined, + DeviceOnlyRememberedOnUserPrompt: output.DeviceOnlyRememberedOnUserPrompt !== undefined && output.DeviceOnlyRememberedOnUserPrompt !== null + ? output.DeviceOnlyRememberedOnUserPrompt + : undefined, + }; +}; +const deserializeAws_json1_1DeviceListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1DeviceType(entry, context); + }); +}; +const deserializeAws_json1_1DeviceType = (output, context) => { + return { + DeviceAttributes: output.DeviceAttributes !== undefined && output.DeviceAttributes !== null + ? deserializeAws_json1_1AttributeListType(output.DeviceAttributes, context) + : undefined, + DeviceCreateDate: output.DeviceCreateDate !== undefined && output.DeviceCreateDate !== null + ? new Date(Math.round(output.DeviceCreateDate * 1000)) + : undefined, + DeviceKey: output.DeviceKey !== undefined && output.DeviceKey !== null ? output.DeviceKey : undefined, + DeviceLastAuthenticatedDate: output.DeviceLastAuthenticatedDate !== undefined && output.DeviceLastAuthenticatedDate !== null + ? new Date(Math.round(output.DeviceLastAuthenticatedDate * 1000)) + : undefined, + DeviceLastModifiedDate: output.DeviceLastModifiedDate !== undefined && output.DeviceLastModifiedDate !== null + ? new Date(Math.round(output.DeviceLastModifiedDate * 1000)) + : undefined, + }; +}; +const deserializeAws_json1_1DomainDescriptionType = (output, context) => { + return { + AWSAccountId: output.AWSAccountId !== undefined && output.AWSAccountId !== null ? output.AWSAccountId : undefined, + CloudFrontDistribution: output.CloudFrontDistribution !== undefined && output.CloudFrontDistribution !== null + ? output.CloudFrontDistribution + : undefined, + CustomDomainConfig: output.CustomDomainConfig !== undefined && output.CustomDomainConfig !== null + ? deserializeAws_json1_1CustomDomainConfigType(output.CustomDomainConfig, context) + : undefined, + Domain: output.Domain !== undefined && output.Domain !== null ? output.Domain : undefined, + S3Bucket: output.S3Bucket !== undefined && output.S3Bucket !== null ? output.S3Bucket : undefined, + Status: output.Status !== undefined && output.Status !== null ? output.Status : undefined, + UserPoolId: output.UserPoolId !== undefined && output.UserPoolId !== null ? output.UserPoolId : undefined, + Version: output.Version !== undefined && output.Version !== null ? output.Version : undefined, + }; +}; +const deserializeAws_json1_1DuplicateProviderException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1EmailConfigurationType = (output, context) => { + return { + ConfigurationSet: output.ConfigurationSet !== undefined && output.ConfigurationSet !== null ? output.ConfigurationSet : undefined, + EmailSendingAccount: output.EmailSendingAccount !== undefined && output.EmailSendingAccount !== null + ? output.EmailSendingAccount + : undefined, + From: output.From !== undefined && output.From !== null ? output.From : undefined, + ReplyToEmailAddress: output.ReplyToEmailAddress !== undefined && output.ReplyToEmailAddress !== null + ? output.ReplyToEmailAddress + : undefined, + SourceArn: output.SourceArn !== undefined && output.SourceArn !== null ? output.SourceArn : undefined, + }; +}; +const deserializeAws_json1_1EnableSoftwareTokenMFAException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1EventContextDataType = (output, context) => { + return { + City: output.City !== undefined && output.City !== null ? output.City : undefined, + Country: output.Country !== undefined && output.Country !== null ? output.Country : undefined, + DeviceName: output.DeviceName !== undefined && output.DeviceName !== null ? output.DeviceName : undefined, + IpAddress: output.IpAddress !== undefined && output.IpAddress !== null ? output.IpAddress : undefined, + Timezone: output.Timezone !== undefined && output.Timezone !== null ? output.Timezone : undefined, + }; +}; +const deserializeAws_json1_1EventFeedbackType = (output, context) => { + return { + FeedbackDate: output.FeedbackDate !== undefined && output.FeedbackDate !== null + ? new Date(Math.round(output.FeedbackDate * 1000)) + : undefined, + FeedbackValue: output.FeedbackValue !== undefined && output.FeedbackValue !== null ? output.FeedbackValue : undefined, + Provider: output.Provider !== undefined && output.Provider !== null ? output.Provider : undefined, + }; +}; +const deserializeAws_json1_1EventFiltersType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1EventRiskType = (output, context) => { + return { + CompromisedCredentialsDetected: output.CompromisedCredentialsDetected !== undefined && output.CompromisedCredentialsDetected !== null + ? output.CompromisedCredentialsDetected + : undefined, + RiskDecision: output.RiskDecision !== undefined && output.RiskDecision !== null ? output.RiskDecision : undefined, + RiskLevel: output.RiskLevel !== undefined && output.RiskLevel !== null ? output.RiskLevel : undefined, + }; +}; +const deserializeAws_json1_1ExpiredCodeException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1ExplicitAuthFlowsListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1ForgotPasswordResponse = (output, context) => { + return { + CodeDeliveryDetails: output.CodeDeliveryDetails !== undefined && output.CodeDeliveryDetails !== null + ? deserializeAws_json1_1CodeDeliveryDetailsType(output.CodeDeliveryDetails, context) + : undefined, + }; +}; +const deserializeAws_json1_1GetCSVHeaderResponse = (output, context) => { + return { + CSVHeader: output.CSVHeader !== undefined && output.CSVHeader !== null + ? deserializeAws_json1_1ListOfStringTypes(output.CSVHeader, context) + : undefined, + UserPoolId: output.UserPoolId !== undefined && output.UserPoolId !== null ? output.UserPoolId : undefined, + }; +}; +const deserializeAws_json1_1GetDeviceResponse = (output, context) => { + return { + Device: output.Device !== undefined && output.Device !== null + ? deserializeAws_json1_1DeviceType(output.Device, context) + : undefined, + }; +}; +const deserializeAws_json1_1GetGroupResponse = (output, context) => { + return { + Group: output.Group !== undefined && output.Group !== null + ? deserializeAws_json1_1GroupType(output.Group, context) + : undefined, + }; +}; +const deserializeAws_json1_1GetIdentityProviderByIdentifierResponse = (output, context) => { + return { + IdentityProvider: output.IdentityProvider !== undefined && output.IdentityProvider !== null + ? deserializeAws_json1_1IdentityProviderType(output.IdentityProvider, context) + : undefined, + }; +}; +const deserializeAws_json1_1GetSigningCertificateResponse = (output, context) => { + return { + Certificate: output.Certificate !== undefined && output.Certificate !== null ? output.Certificate : undefined, + }; +}; +const deserializeAws_json1_1GetUICustomizationResponse = (output, context) => { + return { + UICustomization: output.UICustomization !== undefined && output.UICustomization !== null + ? deserializeAws_json1_1UICustomizationType(output.UICustomization, context) + : undefined, + }; +}; +const deserializeAws_json1_1GetUserAttributeVerificationCodeResponse = (output, context) => { + return { + CodeDeliveryDetails: output.CodeDeliveryDetails !== undefined && output.CodeDeliveryDetails !== null + ? deserializeAws_json1_1CodeDeliveryDetailsType(output.CodeDeliveryDetails, context) + : undefined, + }; +}; +const deserializeAws_json1_1GetUserPoolMfaConfigResponse = (output, context) => { + return { + MfaConfiguration: output.MfaConfiguration !== undefined && output.MfaConfiguration !== null ? output.MfaConfiguration : undefined, + SmsMfaConfiguration: output.SmsMfaConfiguration !== undefined && output.SmsMfaConfiguration !== null + ? deserializeAws_json1_1SmsMfaConfigType(output.SmsMfaConfiguration, context) + : undefined, + SoftwareTokenMfaConfiguration: output.SoftwareTokenMfaConfiguration !== undefined && output.SoftwareTokenMfaConfiguration !== null + ? deserializeAws_json1_1SoftwareTokenMfaConfigType(output.SoftwareTokenMfaConfiguration, context) + : undefined, + }; +}; +const deserializeAws_json1_1GetUserResponse = (output, context) => { + return { + MFAOptions: output.MFAOptions !== undefined && output.MFAOptions !== null + ? deserializeAws_json1_1MFAOptionListType(output.MFAOptions, context) + : undefined, + PreferredMfaSetting: output.PreferredMfaSetting !== undefined && output.PreferredMfaSetting !== null + ? output.PreferredMfaSetting + : undefined, + UserAttributes: output.UserAttributes !== undefined && output.UserAttributes !== null + ? deserializeAws_json1_1AttributeListType(output.UserAttributes, context) + : undefined, + UserMFASettingList: output.UserMFASettingList !== undefined && output.UserMFASettingList !== null + ? deserializeAws_json1_1UserMFASettingListType(output.UserMFASettingList, context) + : undefined, + Username: output.Username !== undefined && output.Username !== null ? output.Username : undefined, + }; +}; +const deserializeAws_json1_1GlobalSignOutResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1GroupExistsException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1GroupListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1GroupType(entry, context); + }); +}; +const deserializeAws_json1_1GroupType = (output, context) => { + return { + CreationDate: output.CreationDate !== undefined && output.CreationDate !== null + ? new Date(Math.round(output.CreationDate * 1000)) + : undefined, + Description: output.Description !== undefined && output.Description !== null ? output.Description : undefined, + GroupName: output.GroupName !== undefined && output.GroupName !== null ? output.GroupName : undefined, + LastModifiedDate: output.LastModifiedDate !== undefined && output.LastModifiedDate !== null + ? new Date(Math.round(output.LastModifiedDate * 1000)) + : undefined, + Precedence: output.Precedence !== undefined && output.Precedence !== null ? output.Precedence : undefined, + RoleArn: output.RoleArn !== undefined && output.RoleArn !== null ? output.RoleArn : undefined, + UserPoolId: output.UserPoolId !== undefined && output.UserPoolId !== null ? output.UserPoolId : undefined, + }; +}; +const deserializeAws_json1_1IdentityProviderType = (output, context) => { + return { + AttributeMapping: output.AttributeMapping !== undefined && output.AttributeMapping !== null + ? deserializeAws_json1_1AttributeMappingType(output.AttributeMapping, context) + : undefined, + CreationDate: output.CreationDate !== undefined && output.CreationDate !== null + ? new Date(Math.round(output.CreationDate * 1000)) + : undefined, + IdpIdentifiers: output.IdpIdentifiers !== undefined && output.IdpIdentifiers !== null + ? deserializeAws_json1_1IdpIdentifiersListType(output.IdpIdentifiers, context) + : undefined, + LastModifiedDate: output.LastModifiedDate !== undefined && output.LastModifiedDate !== null + ? new Date(Math.round(output.LastModifiedDate * 1000)) + : undefined, + ProviderDetails: output.ProviderDetails !== undefined && output.ProviderDetails !== null + ? deserializeAws_json1_1ProviderDetailsType(output.ProviderDetails, context) + : undefined, + ProviderName: output.ProviderName !== undefined && output.ProviderName !== null ? output.ProviderName : undefined, + ProviderType: output.ProviderType !== undefined && output.ProviderType !== null ? output.ProviderType : undefined, + UserPoolId: output.UserPoolId !== undefined && output.UserPoolId !== null ? output.UserPoolId : undefined, + }; +}; +const deserializeAws_json1_1IdpIdentifiersListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1InitiateAuthResponse = (output, context) => { + return { + AuthenticationResult: output.AuthenticationResult !== undefined && output.AuthenticationResult !== null + ? deserializeAws_json1_1AuthenticationResultType(output.AuthenticationResult, context) + : undefined, + ChallengeName: output.ChallengeName !== undefined && output.ChallengeName !== null ? output.ChallengeName : undefined, + ChallengeParameters: output.ChallengeParameters !== undefined && output.ChallengeParameters !== null + ? deserializeAws_json1_1ChallengeParametersType(output.ChallengeParameters, context) + : undefined, + Session: output.Session !== undefined && output.Session !== null ? output.Session : undefined, + }; +}; +const deserializeAws_json1_1InternalErrorException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1InvalidEmailRoleAccessPolicyException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1InvalidLambdaResponseException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1InvalidOAuthFlowException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1InvalidParameterException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1InvalidPasswordException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1InvalidSmsRoleAccessPolicyException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1InvalidSmsRoleTrustRelationshipException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1InvalidUserPoolConfigurationException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1LambdaConfigType = (output, context) => { + return { + CreateAuthChallenge: output.CreateAuthChallenge !== undefined && output.CreateAuthChallenge !== null + ? output.CreateAuthChallenge + : undefined, + CustomEmailSender: output.CustomEmailSender !== undefined && output.CustomEmailSender !== null + ? deserializeAws_json1_1CustomEmailLambdaVersionConfigType(output.CustomEmailSender, context) + : undefined, + CustomMessage: output.CustomMessage !== undefined && output.CustomMessage !== null ? output.CustomMessage : undefined, + CustomSMSSender: output.CustomSMSSender !== undefined && output.CustomSMSSender !== null + ? deserializeAws_json1_1CustomSMSLambdaVersionConfigType(output.CustomSMSSender, context) + : undefined, + DefineAuthChallenge: output.DefineAuthChallenge !== undefined && output.DefineAuthChallenge !== null + ? output.DefineAuthChallenge + : undefined, + KMSKeyID: output.KMSKeyID !== undefined && output.KMSKeyID !== null ? output.KMSKeyID : undefined, + PostAuthentication: output.PostAuthentication !== undefined && output.PostAuthentication !== null + ? output.PostAuthentication + : undefined, + PostConfirmation: output.PostConfirmation !== undefined && output.PostConfirmation !== null ? output.PostConfirmation : undefined, + PreAuthentication: output.PreAuthentication !== undefined && output.PreAuthentication !== null + ? output.PreAuthentication + : undefined, + PreSignUp: output.PreSignUp !== undefined && output.PreSignUp !== null ? output.PreSignUp : undefined, + PreTokenGeneration: output.PreTokenGeneration !== undefined && output.PreTokenGeneration !== null + ? output.PreTokenGeneration + : undefined, + UserMigration: output.UserMigration !== undefined && output.UserMigration !== null ? output.UserMigration : undefined, + VerifyAuthChallengeResponse: output.VerifyAuthChallengeResponse !== undefined && output.VerifyAuthChallengeResponse !== null + ? output.VerifyAuthChallengeResponse + : undefined, + }; +}; +const deserializeAws_json1_1LimitExceededException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1ListDevicesResponse = (output, context) => { + return { + Devices: output.Devices !== undefined && output.Devices !== null + ? deserializeAws_json1_1DeviceListType(output.Devices, context) + : undefined, + PaginationToken: output.PaginationToken !== undefined && output.PaginationToken !== null ? output.PaginationToken : undefined, + }; +}; +const deserializeAws_json1_1ListGroupsResponse = (output, context) => { + return { + Groups: output.Groups !== undefined && output.Groups !== null + ? deserializeAws_json1_1GroupListType(output.Groups, context) + : undefined, + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + }; +}; +const deserializeAws_json1_1ListIdentityProvidersResponse = (output, context) => { + return { + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + Providers: output.Providers !== undefined && output.Providers !== null + ? deserializeAws_json1_1ProvidersListType(output.Providers, context) + : undefined, + }; +}; +const deserializeAws_json1_1ListOfStringTypes = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1ListResourceServersResponse = (output, context) => { + return { + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + ResourceServers: output.ResourceServers !== undefined && output.ResourceServers !== null + ? deserializeAws_json1_1ResourceServersListType(output.ResourceServers, context) + : undefined, + }; +}; +const deserializeAws_json1_1ListTagsForResourceResponse = (output, context) => { + return { + Tags: output.Tags !== undefined && output.Tags !== null + ? deserializeAws_json1_1UserPoolTagsType(output.Tags, context) + : undefined, + }; +}; +const deserializeAws_json1_1ListUserImportJobsResponse = (output, context) => { + return { + PaginationToken: output.PaginationToken !== undefined && output.PaginationToken !== null ? output.PaginationToken : undefined, + UserImportJobs: output.UserImportJobs !== undefined && output.UserImportJobs !== null + ? deserializeAws_json1_1UserImportJobsListType(output.UserImportJobs, context) + : undefined, + }; +}; +const deserializeAws_json1_1ListUserPoolClientsResponse = (output, context) => { + return { + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + UserPoolClients: output.UserPoolClients !== undefined && output.UserPoolClients !== null + ? deserializeAws_json1_1UserPoolClientListType(output.UserPoolClients, context) + : undefined, + }; +}; +const deserializeAws_json1_1ListUserPoolsResponse = (output, context) => { + return { + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + UserPools: output.UserPools !== undefined && output.UserPools !== null + ? deserializeAws_json1_1UserPoolListType(output.UserPools, context) + : undefined, + }; +}; +const deserializeAws_json1_1ListUsersInGroupResponse = (output, context) => { + return { + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + Users: output.Users !== undefined && output.Users !== null + ? deserializeAws_json1_1UsersListType(output.Users, context) + : undefined, + }; +}; +const deserializeAws_json1_1ListUsersResponse = (output, context) => { + return { + PaginationToken: output.PaginationToken !== undefined && output.PaginationToken !== null ? output.PaginationToken : undefined, + Users: output.Users !== undefined && output.Users !== null + ? deserializeAws_json1_1UsersListType(output.Users, context) + : undefined, + }; +}; +const deserializeAws_json1_1LogoutURLsListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1MessageTemplateType = (output, context) => { + return { + EmailMessage: output.EmailMessage !== undefined && output.EmailMessage !== null ? output.EmailMessage : undefined, + EmailSubject: output.EmailSubject !== undefined && output.EmailSubject !== null ? output.EmailSubject : undefined, + SMSMessage: output.SMSMessage !== undefined && output.SMSMessage !== null ? output.SMSMessage : undefined, + }; +}; +const deserializeAws_json1_1MFAMethodNotFoundException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1MFAOptionListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1MFAOptionType(entry, context); + }); +}; +const deserializeAws_json1_1MFAOptionType = (output, context) => { + return { + AttributeName: output.AttributeName !== undefined && output.AttributeName !== null ? output.AttributeName : undefined, + DeliveryMedium: output.DeliveryMedium !== undefined && output.DeliveryMedium !== null ? output.DeliveryMedium : undefined, + }; +}; +const deserializeAws_json1_1NewDeviceMetadataType = (output, context) => { + return { + DeviceGroupKey: output.DeviceGroupKey !== undefined && output.DeviceGroupKey !== null ? output.DeviceGroupKey : undefined, + DeviceKey: output.DeviceKey !== undefined && output.DeviceKey !== null ? output.DeviceKey : undefined, + }; +}; +const deserializeAws_json1_1NotAuthorizedException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1NotifyConfigurationType = (output, context) => { + return { + BlockEmail: output.BlockEmail !== undefined && output.BlockEmail !== null + ? deserializeAws_json1_1NotifyEmailType(output.BlockEmail, context) + : undefined, + From: output.From !== undefined && output.From !== null ? output.From : undefined, + MfaEmail: output.MfaEmail !== undefined && output.MfaEmail !== null + ? deserializeAws_json1_1NotifyEmailType(output.MfaEmail, context) + : undefined, + NoActionEmail: output.NoActionEmail !== undefined && output.NoActionEmail !== null + ? deserializeAws_json1_1NotifyEmailType(output.NoActionEmail, context) + : undefined, + ReplyTo: output.ReplyTo !== undefined && output.ReplyTo !== null ? output.ReplyTo : undefined, + SourceArn: output.SourceArn !== undefined && output.SourceArn !== null ? output.SourceArn : undefined, + }; +}; +const deserializeAws_json1_1NotifyEmailType = (output, context) => { + return { + HtmlBody: output.HtmlBody !== undefined && output.HtmlBody !== null ? output.HtmlBody : undefined, + Subject: output.Subject !== undefined && output.Subject !== null ? output.Subject : undefined, + TextBody: output.TextBody !== undefined && output.TextBody !== null ? output.TextBody : undefined, + }; +}; +const deserializeAws_json1_1NumberAttributeConstraintsType = (output, context) => { + return { + MaxValue: output.MaxValue !== undefined && output.MaxValue !== null ? output.MaxValue : undefined, + MinValue: output.MinValue !== undefined && output.MinValue !== null ? output.MinValue : undefined, + }; +}; +const deserializeAws_json1_1OAuthFlowsType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1PasswordPolicyType = (output, context) => { + return { + MinimumLength: output.MinimumLength !== undefined && output.MinimumLength !== null ? output.MinimumLength : undefined, + RequireLowercase: output.RequireLowercase !== undefined && output.RequireLowercase !== null ? output.RequireLowercase : undefined, + RequireNumbers: output.RequireNumbers !== undefined && output.RequireNumbers !== null ? output.RequireNumbers : undefined, + RequireSymbols: output.RequireSymbols !== undefined && output.RequireSymbols !== null ? output.RequireSymbols : undefined, + RequireUppercase: output.RequireUppercase !== undefined && output.RequireUppercase !== null ? output.RequireUppercase : undefined, + TemporaryPasswordValidityDays: output.TemporaryPasswordValidityDays !== undefined && output.TemporaryPasswordValidityDays !== null + ? output.TemporaryPasswordValidityDays + : undefined, + }; +}; +const deserializeAws_json1_1PasswordResetRequiredException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1PreconditionNotMetException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1ProviderDescription = (output, context) => { + return { + CreationDate: output.CreationDate !== undefined && output.CreationDate !== null + ? new Date(Math.round(output.CreationDate * 1000)) + : undefined, + LastModifiedDate: output.LastModifiedDate !== undefined && output.LastModifiedDate !== null + ? new Date(Math.round(output.LastModifiedDate * 1000)) + : undefined, + ProviderName: output.ProviderName !== undefined && output.ProviderName !== null ? output.ProviderName : undefined, + ProviderType: output.ProviderType !== undefined && output.ProviderType !== null ? output.ProviderType : undefined, + }; +}; +const deserializeAws_json1_1ProviderDetailsType = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_json1_1ProvidersListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1ProviderDescription(entry, context); + }); +}; +const deserializeAws_json1_1RecoveryMechanismsType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1RecoveryOptionType(entry, context); + }); +}; +const deserializeAws_json1_1RecoveryOptionType = (output, context) => { + return { + Name: output.Name !== undefined && output.Name !== null ? output.Name : undefined, + Priority: output.Priority !== undefined && output.Priority !== null ? output.Priority : undefined, + }; +}; +const deserializeAws_json1_1ResendConfirmationCodeResponse = (output, context) => { + return { + CodeDeliveryDetails: output.CodeDeliveryDetails !== undefined && output.CodeDeliveryDetails !== null + ? deserializeAws_json1_1CodeDeliveryDetailsType(output.CodeDeliveryDetails, context) + : undefined, + }; +}; +const deserializeAws_json1_1ResourceNotFoundException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1ResourceServerScopeListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1ResourceServerScopeType(entry, context); + }); +}; +const deserializeAws_json1_1ResourceServerScopeType = (output, context) => { + return { + ScopeDescription: output.ScopeDescription !== undefined && output.ScopeDescription !== null ? output.ScopeDescription : undefined, + ScopeName: output.ScopeName !== undefined && output.ScopeName !== null ? output.ScopeName : undefined, + }; +}; +const deserializeAws_json1_1ResourceServersListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1ResourceServerType(entry, context); + }); +}; +const deserializeAws_json1_1ResourceServerType = (output, context) => { + return { + Identifier: output.Identifier !== undefined && output.Identifier !== null ? output.Identifier : undefined, + Name: output.Name !== undefined && output.Name !== null ? output.Name : undefined, + Scopes: output.Scopes !== undefined && output.Scopes !== null + ? deserializeAws_json1_1ResourceServerScopeListType(output.Scopes, context) + : undefined, + UserPoolId: output.UserPoolId !== undefined && output.UserPoolId !== null ? output.UserPoolId : undefined, + }; +}; +const deserializeAws_json1_1RespondToAuthChallengeResponse = (output, context) => { + return { + AuthenticationResult: output.AuthenticationResult !== undefined && output.AuthenticationResult !== null + ? deserializeAws_json1_1AuthenticationResultType(output.AuthenticationResult, context) + : undefined, + ChallengeName: output.ChallengeName !== undefined && output.ChallengeName !== null ? output.ChallengeName : undefined, + ChallengeParameters: output.ChallengeParameters !== undefined && output.ChallengeParameters !== null + ? deserializeAws_json1_1ChallengeParametersType(output.ChallengeParameters, context) + : undefined, + Session: output.Session !== undefined && output.Session !== null ? output.Session : undefined, + }; +}; +const deserializeAws_json1_1RiskConfigurationType = (output, context) => { + return { + AccountTakeoverRiskConfiguration: output.AccountTakeoverRiskConfiguration !== undefined && output.AccountTakeoverRiskConfiguration !== null + ? deserializeAws_json1_1AccountTakeoverRiskConfigurationType(output.AccountTakeoverRiskConfiguration, context) + : undefined, + ClientId: output.ClientId !== undefined && output.ClientId !== null ? output.ClientId : undefined, + CompromisedCredentialsRiskConfiguration: output.CompromisedCredentialsRiskConfiguration !== undefined && + output.CompromisedCredentialsRiskConfiguration !== null + ? deserializeAws_json1_1CompromisedCredentialsRiskConfigurationType(output.CompromisedCredentialsRiskConfiguration, context) + : undefined, + LastModifiedDate: output.LastModifiedDate !== undefined && output.LastModifiedDate !== null + ? new Date(Math.round(output.LastModifiedDate * 1000)) + : undefined, + RiskExceptionConfiguration: output.RiskExceptionConfiguration !== undefined && output.RiskExceptionConfiguration !== null + ? deserializeAws_json1_1RiskExceptionConfigurationType(output.RiskExceptionConfiguration, context) + : undefined, + UserPoolId: output.UserPoolId !== undefined && output.UserPoolId !== null ? output.UserPoolId : undefined, + }; +}; +const deserializeAws_json1_1RiskExceptionConfigurationType = (output, context) => { + return { + BlockedIPRangeList: output.BlockedIPRangeList !== undefined && output.BlockedIPRangeList !== null + ? deserializeAws_json1_1BlockedIPRangeListType(output.BlockedIPRangeList, context) + : undefined, + SkippedIPRangeList: output.SkippedIPRangeList !== undefined && output.SkippedIPRangeList !== null + ? deserializeAws_json1_1SkippedIPRangeListType(output.SkippedIPRangeList, context) + : undefined, + }; +}; +const deserializeAws_json1_1SchemaAttributesListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1SchemaAttributeType(entry, context); + }); +}; +const deserializeAws_json1_1SchemaAttributeType = (output, context) => { + return { + AttributeDataType: output.AttributeDataType !== undefined && output.AttributeDataType !== null + ? output.AttributeDataType + : undefined, + DeveloperOnlyAttribute: output.DeveloperOnlyAttribute !== undefined && output.DeveloperOnlyAttribute !== null + ? output.DeveloperOnlyAttribute + : undefined, + Mutable: output.Mutable !== undefined && output.Mutable !== null ? output.Mutable : undefined, + Name: output.Name !== undefined && output.Name !== null ? output.Name : undefined, + NumberAttributeConstraints: output.NumberAttributeConstraints !== undefined && output.NumberAttributeConstraints !== null + ? deserializeAws_json1_1NumberAttributeConstraintsType(output.NumberAttributeConstraints, context) + : undefined, + Required: output.Required !== undefined && output.Required !== null ? output.Required : undefined, + StringAttributeConstraints: output.StringAttributeConstraints !== undefined && output.StringAttributeConstraints !== null + ? deserializeAws_json1_1StringAttributeConstraintsType(output.StringAttributeConstraints, context) + : undefined, + }; +}; +const deserializeAws_json1_1ScopeDoesNotExistException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1ScopeListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1SetRiskConfigurationResponse = (output, context) => { + return { + RiskConfiguration: output.RiskConfiguration !== undefined && output.RiskConfiguration !== null + ? deserializeAws_json1_1RiskConfigurationType(output.RiskConfiguration, context) + : undefined, + }; +}; +const deserializeAws_json1_1SetUICustomizationResponse = (output, context) => { + return { + UICustomization: output.UICustomization !== undefined && output.UICustomization !== null + ? deserializeAws_json1_1UICustomizationType(output.UICustomization, context) + : undefined, + }; +}; +const deserializeAws_json1_1SetUserMFAPreferenceResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1SetUserPoolMfaConfigResponse = (output, context) => { + return { + MfaConfiguration: output.MfaConfiguration !== undefined && output.MfaConfiguration !== null ? output.MfaConfiguration : undefined, + SmsMfaConfiguration: output.SmsMfaConfiguration !== undefined && output.SmsMfaConfiguration !== null + ? deserializeAws_json1_1SmsMfaConfigType(output.SmsMfaConfiguration, context) + : undefined, + SoftwareTokenMfaConfiguration: output.SoftwareTokenMfaConfiguration !== undefined && output.SoftwareTokenMfaConfiguration !== null + ? deserializeAws_json1_1SoftwareTokenMfaConfigType(output.SoftwareTokenMfaConfiguration, context) + : undefined, + }; +}; +const deserializeAws_json1_1SetUserSettingsResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1SignUpResponse = (output, context) => { + return { + CodeDeliveryDetails: output.CodeDeliveryDetails !== undefined && output.CodeDeliveryDetails !== null + ? deserializeAws_json1_1CodeDeliveryDetailsType(output.CodeDeliveryDetails, context) + : undefined, + UserConfirmed: output.UserConfirmed !== undefined && output.UserConfirmed !== null ? output.UserConfirmed : undefined, + UserSub: output.UserSub !== undefined && output.UserSub !== null ? output.UserSub : undefined, + }; +}; +const deserializeAws_json1_1SkippedIPRangeListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1SmsConfigurationType = (output, context) => { + return { + ExternalId: output.ExternalId !== undefined && output.ExternalId !== null ? output.ExternalId : undefined, + SnsCallerArn: output.SnsCallerArn !== undefined && output.SnsCallerArn !== null ? output.SnsCallerArn : undefined, + }; +}; +const deserializeAws_json1_1SmsMfaConfigType = (output, context) => { + return { + SmsAuthenticationMessage: output.SmsAuthenticationMessage !== undefined && output.SmsAuthenticationMessage !== null + ? output.SmsAuthenticationMessage + : undefined, + SmsConfiguration: output.SmsConfiguration !== undefined && output.SmsConfiguration !== null + ? deserializeAws_json1_1SmsConfigurationType(output.SmsConfiguration, context) + : undefined, + }; +}; +const deserializeAws_json1_1SoftwareTokenMfaConfigType = (output, context) => { + return { + Enabled: output.Enabled !== undefined && output.Enabled !== null ? output.Enabled : undefined, + }; +}; +const deserializeAws_json1_1SoftwareTokenMFANotFoundException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1StartUserImportJobResponse = (output, context) => { + return { + UserImportJob: output.UserImportJob !== undefined && output.UserImportJob !== null + ? deserializeAws_json1_1UserImportJobType(output.UserImportJob, context) + : undefined, + }; +}; +const deserializeAws_json1_1StopUserImportJobResponse = (output, context) => { + return { + UserImportJob: output.UserImportJob !== undefined && output.UserImportJob !== null + ? deserializeAws_json1_1UserImportJobType(output.UserImportJob, context) + : undefined, + }; +}; +const deserializeAws_json1_1StringAttributeConstraintsType = (output, context) => { + return { + MaxLength: output.MaxLength !== undefined && output.MaxLength !== null ? output.MaxLength : undefined, + MinLength: output.MinLength !== undefined && output.MinLength !== null ? output.MinLength : undefined, + }; +}; +const deserializeAws_json1_1SupportedIdentityProvidersListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1TagResourceResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1TokenValidityUnitsType = (output, context) => { + return { + AccessToken: output.AccessToken !== undefined && output.AccessToken !== null ? output.AccessToken : undefined, + IdToken: output.IdToken !== undefined && output.IdToken !== null ? output.IdToken : undefined, + RefreshToken: output.RefreshToken !== undefined && output.RefreshToken !== null ? output.RefreshToken : undefined, + }; +}; +const deserializeAws_json1_1TooManyFailedAttemptsException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1TooManyRequestsException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UICustomizationType = (output, context) => { + return { + CSS: output.CSS !== undefined && output.CSS !== null ? output.CSS : undefined, + CSSVersion: output.CSSVersion !== undefined && output.CSSVersion !== null ? output.CSSVersion : undefined, + ClientId: output.ClientId !== undefined && output.ClientId !== null ? output.ClientId : undefined, + CreationDate: output.CreationDate !== undefined && output.CreationDate !== null + ? new Date(Math.round(output.CreationDate * 1000)) + : undefined, + ImageUrl: output.ImageUrl !== undefined && output.ImageUrl !== null ? output.ImageUrl : undefined, + LastModifiedDate: output.LastModifiedDate !== undefined && output.LastModifiedDate !== null + ? new Date(Math.round(output.LastModifiedDate * 1000)) + : undefined, + UserPoolId: output.UserPoolId !== undefined && output.UserPoolId !== null ? output.UserPoolId : undefined, + }; +}; +const deserializeAws_json1_1UnexpectedLambdaException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UnsupportedIdentityProviderException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UnsupportedUserStateException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UntagResourceResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1UpdateAuthEventFeedbackResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1UpdateDeviceStatusResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1UpdateGroupResponse = (output, context) => { + return { + Group: output.Group !== undefined && output.Group !== null + ? deserializeAws_json1_1GroupType(output.Group, context) + : undefined, + }; +}; +const deserializeAws_json1_1UpdateIdentityProviderResponse = (output, context) => { + return { + IdentityProvider: output.IdentityProvider !== undefined && output.IdentityProvider !== null + ? deserializeAws_json1_1IdentityProviderType(output.IdentityProvider, context) + : undefined, + }; +}; +const deserializeAws_json1_1UpdateResourceServerResponse = (output, context) => { + return { + ResourceServer: output.ResourceServer !== undefined && output.ResourceServer !== null + ? deserializeAws_json1_1ResourceServerType(output.ResourceServer, context) + : undefined, + }; +}; +const deserializeAws_json1_1UpdateUserAttributesResponse = (output, context) => { + return { + CodeDeliveryDetailsList: output.CodeDeliveryDetailsList !== undefined && output.CodeDeliveryDetailsList !== null + ? deserializeAws_json1_1CodeDeliveryDetailsListType(output.CodeDeliveryDetailsList, context) + : undefined, + }; +}; +const deserializeAws_json1_1UpdateUserPoolClientResponse = (output, context) => { + return { + UserPoolClient: output.UserPoolClient !== undefined && output.UserPoolClient !== null + ? deserializeAws_json1_1UserPoolClientType(output.UserPoolClient, context) + : undefined, + }; +}; +const deserializeAws_json1_1UpdateUserPoolDomainResponse = (output, context) => { + return { + CloudFrontDomain: output.CloudFrontDomain !== undefined && output.CloudFrontDomain !== null ? output.CloudFrontDomain : undefined, + }; +}; +const deserializeAws_json1_1UpdateUserPoolResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1UserImportInProgressException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UserImportJobsListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1UserImportJobType(entry, context); + }); +}; +const deserializeAws_json1_1UserImportJobType = (output, context) => { + return { + CloudWatchLogsRoleArn: output.CloudWatchLogsRoleArn !== undefined && output.CloudWatchLogsRoleArn !== null + ? output.CloudWatchLogsRoleArn + : undefined, + CompletionDate: output.CompletionDate !== undefined && output.CompletionDate !== null + ? new Date(Math.round(output.CompletionDate * 1000)) + : undefined, + CompletionMessage: output.CompletionMessage !== undefined && output.CompletionMessage !== null + ? output.CompletionMessage + : undefined, + CreationDate: output.CreationDate !== undefined && output.CreationDate !== null + ? new Date(Math.round(output.CreationDate * 1000)) + : undefined, + FailedUsers: output.FailedUsers !== undefined && output.FailedUsers !== null ? output.FailedUsers : undefined, + ImportedUsers: output.ImportedUsers !== undefined && output.ImportedUsers !== null ? output.ImportedUsers : undefined, + JobId: output.JobId !== undefined && output.JobId !== null ? output.JobId : undefined, + JobName: output.JobName !== undefined && output.JobName !== null ? output.JobName : undefined, + PreSignedUrl: output.PreSignedUrl !== undefined && output.PreSignedUrl !== null ? output.PreSignedUrl : undefined, + SkippedUsers: output.SkippedUsers !== undefined && output.SkippedUsers !== null ? output.SkippedUsers : undefined, + StartDate: output.StartDate !== undefined && output.StartDate !== null + ? new Date(Math.round(output.StartDate * 1000)) + : undefined, + Status: output.Status !== undefined && output.Status !== null ? output.Status : undefined, + UserPoolId: output.UserPoolId !== undefined && output.UserPoolId !== null ? output.UserPoolId : undefined, + }; +}; +const deserializeAws_json1_1UserLambdaValidationException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UserMFASettingListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1UsernameAttributesListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1UsernameConfigurationType = (output, context) => { + return { + CaseSensitive: output.CaseSensitive !== undefined && output.CaseSensitive !== null ? output.CaseSensitive : undefined, + }; +}; +const deserializeAws_json1_1UsernameExistsException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UserNotConfirmedException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UserNotFoundException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UserPoolAddOnNotEnabledException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UserPoolAddOnsType = (output, context) => { + return { + AdvancedSecurityMode: output.AdvancedSecurityMode !== undefined && output.AdvancedSecurityMode !== null + ? output.AdvancedSecurityMode + : undefined, + }; +}; +const deserializeAws_json1_1UserPoolClientDescription = (output, context) => { + return { + ClientId: output.ClientId !== undefined && output.ClientId !== null ? output.ClientId : undefined, + ClientName: output.ClientName !== undefined && output.ClientName !== null ? output.ClientName : undefined, + UserPoolId: output.UserPoolId !== undefined && output.UserPoolId !== null ? output.UserPoolId : undefined, + }; +}; +const deserializeAws_json1_1UserPoolClientListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1UserPoolClientDescription(entry, context); + }); +}; +const deserializeAws_json1_1UserPoolClientType = (output, context) => { + return { + AccessTokenValidity: output.AccessTokenValidity !== undefined && output.AccessTokenValidity !== null + ? output.AccessTokenValidity + : undefined, + AllowedOAuthFlows: output.AllowedOAuthFlows !== undefined && output.AllowedOAuthFlows !== null + ? deserializeAws_json1_1OAuthFlowsType(output.AllowedOAuthFlows, context) + : undefined, + AllowedOAuthFlowsUserPoolClient: output.AllowedOAuthFlowsUserPoolClient !== undefined && output.AllowedOAuthFlowsUserPoolClient !== null + ? output.AllowedOAuthFlowsUserPoolClient + : undefined, + AllowedOAuthScopes: output.AllowedOAuthScopes !== undefined && output.AllowedOAuthScopes !== null + ? deserializeAws_json1_1ScopeListType(output.AllowedOAuthScopes, context) + : undefined, + AnalyticsConfiguration: output.AnalyticsConfiguration !== undefined && output.AnalyticsConfiguration !== null + ? deserializeAws_json1_1AnalyticsConfigurationType(output.AnalyticsConfiguration, context) + : undefined, + CallbackURLs: output.CallbackURLs !== undefined && output.CallbackURLs !== null + ? deserializeAws_json1_1CallbackURLsListType(output.CallbackURLs, context) + : undefined, + ClientId: output.ClientId !== undefined && output.ClientId !== null ? output.ClientId : undefined, + ClientName: output.ClientName !== undefined && output.ClientName !== null ? output.ClientName : undefined, + ClientSecret: output.ClientSecret !== undefined && output.ClientSecret !== null ? output.ClientSecret : undefined, + CreationDate: output.CreationDate !== undefined && output.CreationDate !== null + ? new Date(Math.round(output.CreationDate * 1000)) + : undefined, + DefaultRedirectURI: output.DefaultRedirectURI !== undefined && output.DefaultRedirectURI !== null + ? output.DefaultRedirectURI + : undefined, + ExplicitAuthFlows: output.ExplicitAuthFlows !== undefined && output.ExplicitAuthFlows !== null + ? deserializeAws_json1_1ExplicitAuthFlowsListType(output.ExplicitAuthFlows, context) + : undefined, + IdTokenValidity: output.IdTokenValidity !== undefined && output.IdTokenValidity !== null ? output.IdTokenValidity : undefined, + LastModifiedDate: output.LastModifiedDate !== undefined && output.LastModifiedDate !== null + ? new Date(Math.round(output.LastModifiedDate * 1000)) + : undefined, + LogoutURLs: output.LogoutURLs !== undefined && output.LogoutURLs !== null + ? deserializeAws_json1_1LogoutURLsListType(output.LogoutURLs, context) + : undefined, + PreventUserExistenceErrors: output.PreventUserExistenceErrors !== undefined && output.PreventUserExistenceErrors !== null + ? output.PreventUserExistenceErrors + : undefined, + ReadAttributes: output.ReadAttributes !== undefined && output.ReadAttributes !== null + ? deserializeAws_json1_1ClientPermissionListType(output.ReadAttributes, context) + : undefined, + RefreshTokenValidity: output.RefreshTokenValidity !== undefined && output.RefreshTokenValidity !== null + ? output.RefreshTokenValidity + : undefined, + SupportedIdentityProviders: output.SupportedIdentityProviders !== undefined && output.SupportedIdentityProviders !== null + ? deserializeAws_json1_1SupportedIdentityProvidersListType(output.SupportedIdentityProviders, context) + : undefined, + TokenValidityUnits: output.TokenValidityUnits !== undefined && output.TokenValidityUnits !== null + ? deserializeAws_json1_1TokenValidityUnitsType(output.TokenValidityUnits, context) + : undefined, + UserPoolId: output.UserPoolId !== undefined && output.UserPoolId !== null ? output.UserPoolId : undefined, + WriteAttributes: output.WriteAttributes !== undefined && output.WriteAttributes !== null + ? deserializeAws_json1_1ClientPermissionListType(output.WriteAttributes, context) + : undefined, + }; +}; +const deserializeAws_json1_1UserPoolDescriptionType = (output, context) => { + return { + CreationDate: output.CreationDate !== undefined && output.CreationDate !== null + ? new Date(Math.round(output.CreationDate * 1000)) + : undefined, + Id: output.Id !== undefined && output.Id !== null ? output.Id : undefined, + LambdaConfig: output.LambdaConfig !== undefined && output.LambdaConfig !== null + ? deserializeAws_json1_1LambdaConfigType(output.LambdaConfig, context) + : undefined, + LastModifiedDate: output.LastModifiedDate !== undefined && output.LastModifiedDate !== null + ? new Date(Math.round(output.LastModifiedDate * 1000)) + : undefined, + Name: output.Name !== undefined && output.Name !== null ? output.Name : undefined, + Status: output.Status !== undefined && output.Status !== null ? output.Status : undefined, + }; +}; +const deserializeAws_json1_1UserPoolListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1UserPoolDescriptionType(entry, context); + }); +}; +const deserializeAws_json1_1UserPoolPolicyType = (output, context) => { + return { + PasswordPolicy: output.PasswordPolicy !== undefined && output.PasswordPolicy !== null + ? deserializeAws_json1_1PasswordPolicyType(output.PasswordPolicy, context) + : undefined, + }; +}; +const deserializeAws_json1_1UserPoolTaggingException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UserPoolTagsType = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_json1_1UserPoolType = (output, context) => { + return { + AccountRecoverySetting: output.AccountRecoverySetting !== undefined && output.AccountRecoverySetting !== null + ? deserializeAws_json1_1AccountRecoverySettingType(output.AccountRecoverySetting, context) + : undefined, + AdminCreateUserConfig: output.AdminCreateUserConfig !== undefined && output.AdminCreateUserConfig !== null + ? deserializeAws_json1_1AdminCreateUserConfigType(output.AdminCreateUserConfig, context) + : undefined, + AliasAttributes: output.AliasAttributes !== undefined && output.AliasAttributes !== null + ? deserializeAws_json1_1AliasAttributesListType(output.AliasAttributes, context) + : undefined, + Arn: output.Arn !== undefined && output.Arn !== null ? output.Arn : undefined, + AutoVerifiedAttributes: output.AutoVerifiedAttributes !== undefined && output.AutoVerifiedAttributes !== null + ? deserializeAws_json1_1VerifiedAttributesListType(output.AutoVerifiedAttributes, context) + : undefined, + CreationDate: output.CreationDate !== undefined && output.CreationDate !== null + ? new Date(Math.round(output.CreationDate * 1000)) + : undefined, + CustomDomain: output.CustomDomain !== undefined && output.CustomDomain !== null ? output.CustomDomain : undefined, + DeviceConfiguration: output.DeviceConfiguration !== undefined && output.DeviceConfiguration !== null + ? deserializeAws_json1_1DeviceConfigurationType(output.DeviceConfiguration, context) + : undefined, + Domain: output.Domain !== undefined && output.Domain !== null ? output.Domain : undefined, + EmailConfiguration: output.EmailConfiguration !== undefined && output.EmailConfiguration !== null + ? deserializeAws_json1_1EmailConfigurationType(output.EmailConfiguration, context) + : undefined, + EmailConfigurationFailure: output.EmailConfigurationFailure !== undefined && output.EmailConfigurationFailure !== null + ? output.EmailConfigurationFailure + : undefined, + EmailVerificationMessage: output.EmailVerificationMessage !== undefined && output.EmailVerificationMessage !== null + ? output.EmailVerificationMessage + : undefined, + EmailVerificationSubject: output.EmailVerificationSubject !== undefined && output.EmailVerificationSubject !== null + ? output.EmailVerificationSubject + : undefined, + EstimatedNumberOfUsers: output.EstimatedNumberOfUsers !== undefined && output.EstimatedNumberOfUsers !== null + ? output.EstimatedNumberOfUsers + : undefined, + Id: output.Id !== undefined && output.Id !== null ? output.Id : undefined, + LambdaConfig: output.LambdaConfig !== undefined && output.LambdaConfig !== null + ? deserializeAws_json1_1LambdaConfigType(output.LambdaConfig, context) + : undefined, + LastModifiedDate: output.LastModifiedDate !== undefined && output.LastModifiedDate !== null + ? new Date(Math.round(output.LastModifiedDate * 1000)) + : undefined, + MfaConfiguration: output.MfaConfiguration !== undefined && output.MfaConfiguration !== null ? output.MfaConfiguration : undefined, + Name: output.Name !== undefined && output.Name !== null ? output.Name : undefined, + Policies: output.Policies !== undefined && output.Policies !== null + ? deserializeAws_json1_1UserPoolPolicyType(output.Policies, context) + : undefined, + SchemaAttributes: output.SchemaAttributes !== undefined && output.SchemaAttributes !== null + ? deserializeAws_json1_1SchemaAttributesListType(output.SchemaAttributes, context) + : undefined, + SmsAuthenticationMessage: output.SmsAuthenticationMessage !== undefined && output.SmsAuthenticationMessage !== null + ? output.SmsAuthenticationMessage + : undefined, + SmsConfiguration: output.SmsConfiguration !== undefined && output.SmsConfiguration !== null + ? deserializeAws_json1_1SmsConfigurationType(output.SmsConfiguration, context) + : undefined, + SmsConfigurationFailure: output.SmsConfigurationFailure !== undefined && output.SmsConfigurationFailure !== null + ? output.SmsConfigurationFailure + : undefined, + SmsVerificationMessage: output.SmsVerificationMessage !== undefined && output.SmsVerificationMessage !== null + ? output.SmsVerificationMessage + : undefined, + Status: output.Status !== undefined && output.Status !== null ? output.Status : undefined, + UserPoolAddOns: output.UserPoolAddOns !== undefined && output.UserPoolAddOns !== null + ? deserializeAws_json1_1UserPoolAddOnsType(output.UserPoolAddOns, context) + : undefined, + UserPoolTags: output.UserPoolTags !== undefined && output.UserPoolTags !== null + ? deserializeAws_json1_1UserPoolTagsType(output.UserPoolTags, context) + : undefined, + UsernameAttributes: output.UsernameAttributes !== undefined && output.UsernameAttributes !== null + ? deserializeAws_json1_1UsernameAttributesListType(output.UsernameAttributes, context) + : undefined, + UsernameConfiguration: output.UsernameConfiguration !== undefined && output.UsernameConfiguration !== null + ? deserializeAws_json1_1UsernameConfigurationType(output.UsernameConfiguration, context) + : undefined, + VerificationMessageTemplate: output.VerificationMessageTemplate !== undefined && output.VerificationMessageTemplate !== null + ? deserializeAws_json1_1VerificationMessageTemplateType(output.VerificationMessageTemplate, context) + : undefined, + }; +}; +const deserializeAws_json1_1UsersListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1UserType(entry, context); + }); +}; +const deserializeAws_json1_1UserType = (output, context) => { + return { + Attributes: output.Attributes !== undefined && output.Attributes !== null + ? deserializeAws_json1_1AttributeListType(output.Attributes, context) + : undefined, + Enabled: output.Enabled !== undefined && output.Enabled !== null ? output.Enabled : undefined, + MFAOptions: output.MFAOptions !== undefined && output.MFAOptions !== null + ? deserializeAws_json1_1MFAOptionListType(output.MFAOptions, context) + : undefined, + UserCreateDate: output.UserCreateDate !== undefined && output.UserCreateDate !== null + ? new Date(Math.round(output.UserCreateDate * 1000)) + : undefined, + UserLastModifiedDate: output.UserLastModifiedDate !== undefined && output.UserLastModifiedDate !== null + ? new Date(Math.round(output.UserLastModifiedDate * 1000)) + : undefined, + UserStatus: output.UserStatus !== undefined && output.UserStatus !== null ? output.UserStatus : undefined, + Username: output.Username !== undefined && output.Username !== null ? output.Username : undefined, + }; +}; +const deserializeAws_json1_1VerificationMessageTemplateType = (output, context) => { + return { + DefaultEmailOption: output.DefaultEmailOption !== undefined && output.DefaultEmailOption !== null + ? output.DefaultEmailOption + : undefined, + EmailMessage: output.EmailMessage !== undefined && output.EmailMessage !== null ? output.EmailMessage : undefined, + EmailMessageByLink: output.EmailMessageByLink !== undefined && output.EmailMessageByLink !== null + ? output.EmailMessageByLink + : undefined, + EmailSubject: output.EmailSubject !== undefined && output.EmailSubject !== null ? output.EmailSubject : undefined, + EmailSubjectByLink: output.EmailSubjectByLink !== undefined && output.EmailSubjectByLink !== null + ? output.EmailSubjectByLink + : undefined, + SmsMessage: output.SmsMessage !== undefined && output.SmsMessage !== null ? output.SmsMessage : undefined, + }; +}; +const deserializeAws_json1_1VerifiedAttributesListType = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1VerifySoftwareTokenResponse = (output, context) => { + return { + Session: output.Session !== undefined && output.Session !== null ? output.Session : undefined, + Status: output.Status !== undefined && output.Status !== null ? output.Status : undefined, + }; +}; +const deserializeAws_json1_1VerifyUserAttributeResponse = (output, context) => { + return {}; +}; +const deserializeMetadata = (output) => { + var _a; + return ({ + httpStatusCode: output.statusCode, + requestId: (_a = output.headers["x-amzn-requestid"]) !== null && _a !== void 0 ? _a : output.headers["x-amzn-request-id"], + extendedRequestId: output.headers["x-amz-id-2"], + cfId: output.headers["x-amz-cf-id"], + }); +}; +// Collect low-level response body stream to Uint8Array. +const collectBody = (streamBody = new Uint8Array(), context) => { + if (streamBody instanceof Uint8Array) { + return Promise.resolve(streamBody); + } + return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array()); +}; +// Encode Uint8Array data into string with utf-8. +const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body)); +const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => { + const { hostname, protocol = "https", port } = await context.endpoint(); + const contents = { + protocol, + hostname, + port, + method: "POST", + path, + headers, + }; + if (resolvedHostname !== undefined) { + contents.hostname = resolvedHostname; + } + if (body !== undefined) { + contents.body = body; + } + return new protocol_http_1.HttpRequest(contents); +}; +const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => { + if (encoded.length) { + return JSON.parse(encoded); + } + return {}; +}); +/** + * Load an error code for the aws.rest-json-1.1 protocol. + */ +const loadRestJsonErrorCode = (output, data) => { + const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase()); + const sanitizeErrorCode = (rawValue) => { + let cleanValue = rawValue; + if (cleanValue.indexOf(":") >= 0) { + cleanValue = cleanValue.split(":")[0]; + } + if (cleanValue.indexOf("#") >= 0) { + cleanValue = cleanValue.split("#")[1]; + } + return cleanValue; + }; + const headerKey = findKey(output.headers, "x-amzn-errortype"); + if (headerKey !== undefined) { + return sanitizeErrorCode(output.headers[headerKey]); + } + if (data.code !== undefined) { + return sanitizeErrorCode(data.code); + } + if (data["__type"] !== undefined) { + return sanitizeErrorCode(data["__type"]); + } + return ""; +}; +//# sourceMappingURL=Aws_json1_1.js.map + +/***/ }), + +/***/ 45628: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ClientDefaultValues = void 0; +const tslib_1 = __nccwpck_require__(37706); +const package_json_1 = tslib_1.__importDefault(__nccwpck_require__(48166)); +const config_resolver_1 = __nccwpck_require__(87229); +const credential_provider_node_1 = __nccwpck_require__(98030); +const hash_node_1 = __nccwpck_require__(90791); +const middleware_retry_1 = __nccwpck_require__(7000); +const node_config_provider_1 = __nccwpck_require__(71124); +const node_http_handler_1 = __nccwpck_require__(15168); +const util_base64_node_1 = __nccwpck_require__(2091); +const util_body_length_node_1 = __nccwpck_require__(40286); +const util_user_agent_node_1 = __nccwpck_require__(64717); +const util_utf8_node_1 = __nccwpck_require__(85227); +const runtimeConfig_shared_1 = __nccwpck_require__(34192); +/** + * @internal + */ +exports.ClientDefaultValues = { + ...runtimeConfig_shared_1.ClientSharedValues, + runtime: "node", + base64Decoder: util_base64_node_1.fromBase64, + base64Encoder: util_base64_node_1.toBase64, + bodyLengthChecker: util_body_length_node_1.calculateBodyLength, + credentialDefaultProvider: credential_provider_node_1.defaultProvider, + defaultUserAgentProvider: util_user_agent_node_1.defaultUserAgent({ + serviceId: runtimeConfig_shared_1.ClientSharedValues.serviceId, + clientVersion: package_json_1.default.version, + }), + maxAttempts: node_config_provider_1.loadConfig(middleware_retry_1.NODE_MAX_ATTEMPT_CONFIG_OPTIONS), + region: node_config_provider_1.loadConfig(config_resolver_1.NODE_REGION_CONFIG_OPTIONS, config_resolver_1.NODE_REGION_CONFIG_FILE_OPTIONS), + requestHandler: new node_http_handler_1.NodeHttpHandler(), + sha256: hash_node_1.Hash.bind(null, "sha256"), + streamCollector: node_http_handler_1.streamCollector, + utf8Decoder: util_utf8_node_1.fromUtf8, + utf8Encoder: util_utf8_node_1.toUtf8, +}; +//# sourceMappingURL=runtimeConfig.js.map + +/***/ }), + +/***/ 34192: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ClientSharedValues = void 0; +const endpoints_1 = __nccwpck_require__(96941); +const url_parser_1 = __nccwpck_require__(99427); +/** + * @internal + */ +exports.ClientSharedValues = { + apiVersion: "2016-04-18", + disableHostPrefix: false, + logger: {}, + regionInfoProvider: endpoints_1.defaultRegionInfoProvider, + serviceId: "Cognito Identity Provider", + urlParser: url_parser_1.parseUrl, +}; +//# sourceMappingURL=runtimeConfig.shared.js.map + +/***/ }), + +/***/ 37706: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +__nccwpck_require__.r(__webpack_exports__); +/* harmony export */ __nccwpck_require__.d(__webpack_exports__, { +/* harmony export */ "__extends": () => /* binding */ __extends, +/* harmony export */ "__assign": () => /* binding */ __assign, +/* harmony export */ "__rest": () => /* binding */ __rest, +/* harmony export */ "__decorate": () => /* binding */ __decorate, +/* harmony export */ "__param": () => /* binding */ __param, +/* harmony export */ "__metadata": () => /* binding */ __metadata, +/* harmony export */ "__awaiter": () => /* binding */ __awaiter, +/* harmony export */ "__generator": () => /* binding */ __generator, +/* harmony export */ "__createBinding": () => /* binding */ __createBinding, +/* harmony export */ "__exportStar": () => /* binding */ __exportStar, +/* harmony export */ "__values": () => /* binding */ __values, +/* harmony export */ "__read": () => /* binding */ __read, +/* harmony export */ "__spread": () => /* binding */ __spread, +/* harmony export */ "__spreadArrays": () => /* binding */ __spreadArrays, +/* harmony export */ "__spreadArray": () => /* binding */ __spreadArray, +/* harmony export */ "__await": () => /* binding */ __await, +/* harmony export */ "__asyncGenerator": () => /* binding */ __asyncGenerator, +/* harmony export */ "__asyncDelegator": () => /* binding */ __asyncDelegator, +/* harmony export */ "__asyncValues": () => /* binding */ __asyncValues, +/* harmony export */ "__makeTemplateObject": () => /* binding */ __makeTemplateObject, +/* harmony export */ "__importStar": () => /* binding */ __importStar, +/* harmony export */ "__importDefault": () => /* binding */ __importDefault, +/* harmony export */ "__classPrivateFieldGet": () => /* binding */ __classPrivateFieldGet, +/* harmony export */ "__classPrivateFieldSet": () => /* binding */ __classPrivateFieldSet +/* harmony export */ }); +/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. +***************************************************************************** */ +/* global Reflect, Promise */ + +var extendStatics = function(d, b) { + extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; + return extendStatics(d, b); +}; + +function __extends(d, b) { + if (typeof b !== "function" && b !== null) + throw new TypeError("Class extends value " + String(b) + " is not a constructor or null"); + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +} + +var __assign = function() { + __assign = Object.assign || function __assign(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p]; + } + return t; + } + return __assign.apply(this, arguments); +} + +function __rest(s, e) { + var t = {}; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) + t[p] = s[p]; + if (s != null && typeof Object.getOwnPropertySymbols === "function") + for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { + if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) + t[p[i]] = s[p[i]]; + } + return t; +} + +function __decorate(decorators, target, key, desc) { + var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; + if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); + else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; + return c > 3 && r && Object.defineProperty(target, key, r), r; +} + +function __param(paramIndex, decorator) { + return function (target, key) { decorator(target, key, paramIndex); } +} + +function __metadata(metadataKey, metadataValue) { + if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue); +} + +function __awaiter(thisArg, _arguments, P, generator) { + function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } + return new (P || (P = Promise))(function (resolve, reject) { + function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } + function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } + function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + step((generator = generator.apply(thisArg, _arguments || [])).next()); + }); +} + +function __generator(thisArg, body) { + var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g; + return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g; + function verb(n) { return function (v) { return step([n, v]); }; } + function step(op) { + if (f) throw new TypeError("Generator is already executing."); + while (_) try { + if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t; + if (y = 0, t) op = [op[0] & 2, t.value]; + switch (op[0]) { + case 0: case 1: t = op; break; + case 4: _.label++; return { value: op[1], done: false }; + case 5: _.label++; y = op[1]; op = [0]; continue; + case 7: op = _.ops.pop(); _.trys.pop(); continue; + default: + if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; } + if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; } + if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; } + if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; } + if (t[2]) _.ops.pop(); + _.trys.pop(); continue; + } + op = body.call(thisArg, _); + } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; } + if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true }; + } +} + +var __createBinding = Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +}); + +function __exportStar(m, o) { + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p); +} + +function __values(o) { + var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0; + if (m) return m.call(o); + if (o && typeof o.length === "number") return { + next: function () { + if (o && i >= o.length) o = void 0; + return { value: o && o[i++], done: !o }; + } + }; + throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined."); +} + +function __read(o, n) { + var m = typeof Symbol === "function" && o[Symbol.iterator]; + if (!m) return o; + var i = m.call(o), r, ar = [], e; + try { + while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value); + } + catch (error) { e = { error: error }; } + finally { + try { + if (r && !r.done && (m = i["return"])) m.call(i); + } + finally { if (e) throw e.error; } + } + return ar; +} + +/** @deprecated */ +function __spread() { + for (var ar = [], i = 0; i < arguments.length; i++) + ar = ar.concat(__read(arguments[i])); + return ar; +} + +/** @deprecated */ +function __spreadArrays() { + for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length; + for (var r = Array(s), k = 0, i = 0; i < il; i++) + for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++) + r[k] = a[j]; + return r; +} + +function __spreadArray(to, from) { + for (var i = 0, il = from.length, j = to.length; i < il; i++, j++) + to[j] = from[i]; + return to; +} + +function __await(v) { + return this instanceof __await ? (this.v = v, this) : new __await(v); +} + +function __asyncGenerator(thisArg, _arguments, generator) { + if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined."); + var g = generator.apply(thisArg, _arguments || []), i, q = []; + return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i; + function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; } + function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } } + function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); } + function fulfill(value) { resume("next", value); } + function reject(value) { resume("throw", value); } + function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); } +} + +function __asyncDelegator(o) { + var i, p; + return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i; + function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; } +} + +function __asyncValues(o) { + if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined."); + var m = o[Symbol.asyncIterator], i; + return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i); + function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; } + function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); } +} + +function __makeTemplateObject(cooked, raw) { + if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; } + return cooked; +}; + +var __setModuleDefault = Object.create ? (function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); +}) : function(o, v) { + o["default"] = v; +}; + +function __importStar(mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + __setModuleDefault(result, mod); + return result; +} + +function __importDefault(mod) { + return (mod && mod.__esModule) ? mod : { default: mod }; +} + +function __classPrivateFieldGet(receiver, privateMap) { + if (!privateMap.has(receiver)) { + throw new TypeError("attempted to get private field on non-instance"); + } + return privateMap.get(receiver); +} + +function __classPrivateFieldSet(receiver, privateMap, value) { + if (!privateMap.has(receiver)) { + throw new TypeError("attempted to set private field on non-instance"); + } + privateMap.set(receiver, value); + return value; +} + + +/***/ }), + +/***/ 67301: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CognitoIdentity = void 0; +const CognitoIdentityClient_1 = __nccwpck_require__(72614); +const CreateIdentityPoolCommand_1 = __nccwpck_require__(7373); +const DeleteIdentitiesCommand_1 = __nccwpck_require__(16080); +const DeleteIdentityPoolCommand_1 = __nccwpck_require__(91472); +const DescribeIdentityCommand_1 = __nccwpck_require__(14047); +const DescribeIdentityPoolCommand_1 = __nccwpck_require__(41066); +const GetCredentialsForIdentityCommand_1 = __nccwpck_require__(24133); +const GetIdCommand_1 = __nccwpck_require__(37292); +const GetIdentityPoolRolesCommand_1 = __nccwpck_require__(23106); +const GetOpenIdTokenCommand_1 = __nccwpck_require__(89258); +const GetOpenIdTokenForDeveloperIdentityCommand_1 = __nccwpck_require__(86688); +const ListIdentitiesCommand_1 = __nccwpck_require__(24194); +const ListIdentityPoolsCommand_1 = __nccwpck_require__(53836); +const ListTagsForResourceCommand_1 = __nccwpck_require__(29314); +const LookupDeveloperIdentityCommand_1 = __nccwpck_require__(4664); +const MergeDeveloperIdentitiesCommand_1 = __nccwpck_require__(64385); +const SetIdentityPoolRolesCommand_1 = __nccwpck_require__(4039); +const TagResourceCommand_1 = __nccwpck_require__(67926); +const UnlinkDeveloperIdentityCommand_1 = __nccwpck_require__(55410); +const UnlinkIdentityCommand_1 = __nccwpck_require__(98248); +const UntagResourceCommand_1 = __nccwpck_require__(37358); +const UpdateIdentityPoolCommand_1 = __nccwpck_require__(97273); +/** + *Amazon Cognito Federated Identities is a web service that delivers scoped temporary + * credentials to mobile devices and other untrusted environments. It uniquely identifies a + * device and supplies the user with a consistent identity over the lifetime of an + * application.
+ *Using Amazon Cognito Federated Identities, you can enable authentication with one or + * more third-party identity providers (Facebook, Google, or Login with Amazon) or an Amazon + * Cognito user pool, and you can also choose to support unauthenticated access from your app. + * Cognito delivers a unique identifier for each user and acts as an OpenID token provider + * trusted by AWS Security Token Service (STS) to access temporary, limited-privilege AWS + * credentials.
+ *For a description of the authentication flow from the Amazon Cognito Developer Guide + * see Authentication Flow.
+ *For more information see Amazon Cognito Federated Identities.
+ */ +class CognitoIdentity extends CognitoIdentityClient_1.CognitoIdentityClient { + createIdentityPool(args, optionsOrCb, cb) { + const command = new CreateIdentityPoolCommand_1.CreateIdentityPoolCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteIdentities(args, optionsOrCb, cb) { + const command = new DeleteIdentitiesCommand_1.DeleteIdentitiesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteIdentityPool(args, optionsOrCb, cb) { + const command = new DeleteIdentityPoolCommand_1.DeleteIdentityPoolCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeIdentity(args, optionsOrCb, cb) { + const command = new DescribeIdentityCommand_1.DescribeIdentityCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeIdentityPool(args, optionsOrCb, cb) { + const command = new DescribeIdentityPoolCommand_1.DescribeIdentityPoolCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getCredentialsForIdentity(args, optionsOrCb, cb) { + const command = new GetCredentialsForIdentityCommand_1.GetCredentialsForIdentityCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getId(args, optionsOrCb, cb) { + const command = new GetIdCommand_1.GetIdCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getIdentityPoolRoles(args, optionsOrCb, cb) { + const command = new GetIdentityPoolRolesCommand_1.GetIdentityPoolRolesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getOpenIdToken(args, optionsOrCb, cb) { + const command = new GetOpenIdTokenCommand_1.GetOpenIdTokenCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getOpenIdTokenForDeveloperIdentity(args, optionsOrCb, cb) { + const command = new GetOpenIdTokenForDeveloperIdentityCommand_1.GetOpenIdTokenForDeveloperIdentityCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listIdentities(args, optionsOrCb, cb) { + const command = new ListIdentitiesCommand_1.ListIdentitiesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listIdentityPools(args, optionsOrCb, cb) { + const command = new ListIdentityPoolsCommand_1.ListIdentityPoolsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listTagsForResource(args, optionsOrCb, cb) { + const command = new ListTagsForResourceCommand_1.ListTagsForResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + lookupDeveloperIdentity(args, optionsOrCb, cb) { + const command = new LookupDeveloperIdentityCommand_1.LookupDeveloperIdentityCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + mergeDeveloperIdentities(args, optionsOrCb, cb) { + const command = new MergeDeveloperIdentitiesCommand_1.MergeDeveloperIdentitiesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setIdentityPoolRoles(args, optionsOrCb, cb) { + const command = new SetIdentityPoolRolesCommand_1.SetIdentityPoolRolesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + tagResource(args, optionsOrCb, cb) { + const command = new TagResourceCommand_1.TagResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + unlinkDeveloperIdentity(args, optionsOrCb, cb) { + const command = new UnlinkDeveloperIdentityCommand_1.UnlinkDeveloperIdentityCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + unlinkIdentity(args, optionsOrCb, cb) { + const command = new UnlinkIdentityCommand_1.UnlinkIdentityCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + untagResource(args, optionsOrCb, cb) { + const command = new UntagResourceCommand_1.UntagResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateIdentityPool(args, optionsOrCb, cb) { + const command = new UpdateIdentityPoolCommand_1.UpdateIdentityPoolCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } +} +exports.CognitoIdentity = CognitoIdentity; +//# sourceMappingURL=CognitoIdentity.js.map + +/***/ }), + +/***/ 72614: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CognitoIdentityClient = void 0; +const runtimeConfig_1 = __nccwpck_require__(11407); +const config_resolver_1 = __nccwpck_require__(87229); +const middleware_content_length_1 = __nccwpck_require__(69323); +const middleware_host_header_1 = __nccwpck_require__(58645); +const middleware_logger_1 = __nccwpck_require__(98685); +const middleware_retry_1 = __nccwpck_require__(7000); +const middleware_signing_1 = __nccwpck_require__(82487); +const middleware_user_agent_1 = __nccwpck_require__(55976); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Amazon Cognito Federated Identities is a web service that delivers scoped temporary + * credentials to mobile devices and other untrusted environments. It uniquely identifies a + * device and supplies the user with a consistent identity over the lifetime of an + * application.
+ *Using Amazon Cognito Federated Identities, you can enable authentication with one or + * more third-party identity providers (Facebook, Google, or Login with Amazon) or an Amazon + * Cognito user pool, and you can also choose to support unauthenticated access from your app. + * Cognito delivers a unique identifier for each user and acts as an OpenID token provider + * trusted by AWS Security Token Service (STS) to access temporary, limited-privilege AWS + * credentials.
+ *For a description of the authentication flow from the Amazon Cognito Developer Guide + * see Authentication Flow.
+ *For more information see Amazon Cognito Federated Identities.
+ */ +class CognitoIdentityClient extends smithy_client_1.Client { + constructor(configuration) { + let _config_0 = { + ...runtimeConfig_1.ClientDefaultValues, + ...configuration, + }; + let _config_1 = config_resolver_1.resolveRegionConfig(_config_0); + let _config_2 = config_resolver_1.resolveEndpointsConfig(_config_1); + let _config_3 = middleware_signing_1.resolveAwsAuthConfig(_config_2); + let _config_4 = middleware_retry_1.resolveRetryConfig(_config_3); + let _config_5 = middleware_host_header_1.resolveHostHeaderConfig(_config_4); + let _config_6 = middleware_user_agent_1.resolveUserAgentConfig(_config_5); + super(_config_6); + this.config = _config_6; + this.middlewareStack.use(middleware_retry_1.getRetryPlugin(this.config)); + this.middlewareStack.use(middleware_content_length_1.getContentLengthPlugin(this.config)); + this.middlewareStack.use(middleware_host_header_1.getHostHeaderPlugin(this.config)); + this.middlewareStack.use(middleware_logger_1.getLoggerPlugin(this.config)); + this.middlewareStack.use(middleware_user_agent_1.getUserAgentPlugin(this.config)); + } + destroy() { + super.destroy(); + } +} +exports.CognitoIdentityClient = CognitoIdentityClient; +//# sourceMappingURL=CognitoIdentityClient.js.map + +/***/ }), + +/***/ 7373: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateIdentityPoolCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a new identity pool. The identity pool is a store of user identity
+ * information that is specific to your AWS account. The keys for SupportedLoginProviders
are as follows:
Facebook: graph.facebook.com
+ *
Google: accounts.google.com
+ *
Amazon: www.amazon.com
+ *
Twitter: api.twitter.com
+ *
Digits: www.digits.com
+ *
You must use AWS Developer credentials to call this API.
+ */ +class CreateIdentityPoolCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "CreateIdentityPoolCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateIdentityPoolInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.IdentityPool.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1CreateIdentityPoolCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1CreateIdentityPoolCommand(output, context); + } +} +exports.CreateIdentityPoolCommand = CreateIdentityPoolCommand; +//# sourceMappingURL=CreateIdentityPoolCommand.js.map + +/***/ }), + +/***/ 16080: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteIdentitiesCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes identities from an identity pool. You can specify a list of 1-60 identities + * that you want to delete.
+ *You must use AWS Developer credentials to call this API.
+ */ +class DeleteIdentitiesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "DeleteIdentitiesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteIdentitiesInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteIdentitiesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DeleteIdentitiesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DeleteIdentitiesCommand(output, context); + } +} +exports.DeleteIdentitiesCommand = DeleteIdentitiesCommand; +//# sourceMappingURL=DeleteIdentitiesCommand.js.map + +/***/ }), + +/***/ 91472: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteIdentityPoolCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes an identity pool. Once a pool is deleted, users will not be able to + * authenticate with the pool.
+ *You must use AWS Developer credentials to call this API.
+ */ +class DeleteIdentityPoolCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "DeleteIdentityPoolCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteIdentityPoolInput.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DeleteIdentityPoolCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DeleteIdentityPoolCommand(output, context); + } +} +exports.DeleteIdentityPoolCommand = DeleteIdentityPoolCommand; +//# sourceMappingURL=DeleteIdentityPoolCommand.js.map + +/***/ }), + +/***/ 14047: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeIdentityCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns metadata related to the given identity, including when the identity was + * created and any associated linked logins.
+ *You must use AWS Developer credentials to call this API.
+ */ +class DescribeIdentityCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "DescribeIdentityCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeIdentityInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.IdentityDescription.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DescribeIdentityCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DescribeIdentityCommand(output, context); + } +} +exports.DescribeIdentityCommand = DescribeIdentityCommand; +//# sourceMappingURL=DescribeIdentityCommand.js.map + +/***/ }), + +/***/ 41066: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeIdentityPoolCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets details about a particular identity pool, including the pool name, ID + * description, creation date, and current number of users.
+ *You must use AWS Developer credentials to call this API.
+ */ +class DescribeIdentityPoolCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "DescribeIdentityPoolCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeIdentityPoolInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.IdentityPool.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1DescribeIdentityPoolCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1DescribeIdentityPoolCommand(output, context); + } +} +exports.DescribeIdentityPoolCommand = DescribeIdentityPoolCommand; +//# sourceMappingURL=DescribeIdentityPoolCommand.js.map + +/***/ }), + +/***/ 24133: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetCredentialsForIdentityCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns credentials for the provided identity ID. Any provided logins will be + * validated against supported login providers. If the token is for + * cognito-identity.amazonaws.com, it will be passed through to AWS Security Token Service + * with the appropriate role for the token.
+ *This is a public API. You do not need any credentials to call this API.
+ */ +class GetCredentialsForIdentityCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "GetCredentialsForIdentityCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetCredentialsForIdentityInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetCredentialsForIdentityResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetCredentialsForIdentityCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetCredentialsForIdentityCommand(output, context); + } +} +exports.GetCredentialsForIdentityCommand = GetCredentialsForIdentityCommand; +//# sourceMappingURL=GetCredentialsForIdentityCommand.js.map + +/***/ }), + +/***/ 37292: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetIdCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Generates (or retrieves) a Cognito ID. Supplying multiple logins will create an + * implicit linked account.
+ *This is a public API. You do not need any credentials to call this API.
+ */ +class GetIdCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "GetIdCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetIdInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetIdResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetIdCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetIdCommand(output, context); + } +} +exports.GetIdCommand = GetIdCommand; +//# sourceMappingURL=GetIdCommand.js.map + +/***/ }), + +/***/ 23106: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetIdentityPoolRolesCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the roles for an identity pool.
+ *You must use AWS Developer credentials to call this API.
+ */ +class GetIdentityPoolRolesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "GetIdentityPoolRolesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetIdentityPoolRolesInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetIdentityPoolRolesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetIdentityPoolRolesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetIdentityPoolRolesCommand(output, context); + } +} +exports.GetIdentityPoolRolesCommand = GetIdentityPoolRolesCommand; +//# sourceMappingURL=GetIdentityPoolRolesCommand.js.map + +/***/ }), + +/***/ 89258: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetOpenIdTokenCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets an OpenID token, using a known Cognito ID. This known Cognito ID is returned by + * GetId. You can optionally add additional logins for the identity. + * Supplying multiple logins creates an implicit link.
+ *The OpenId token is valid for 10 minutes.
+ *This is a public API. You do not need any credentials to call this API.
+ */ +class GetOpenIdTokenCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "GetOpenIdTokenCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetOpenIdTokenInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetOpenIdTokenResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetOpenIdTokenCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetOpenIdTokenCommand(output, context); + } +} +exports.GetOpenIdTokenCommand = GetOpenIdTokenCommand; +//# sourceMappingURL=GetOpenIdTokenCommand.js.map + +/***/ }), + +/***/ 86688: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetOpenIdTokenForDeveloperIdentityCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Registers (or retrieves) a Cognito IdentityId
and an OpenID Connect
+ * token for a user authenticated by your backend authentication process. Supplying multiple
+ * logins will create an implicit linked account. You can only specify one developer provider
+ * as part of the Logins
map, which is linked to the identity pool. The developer
+ * provider is the "domain" by which Cognito will refer to your users.
You can use GetOpenIdTokenForDeveloperIdentity
to create a new identity
+ * and to link new logins (that is, user credentials issued by a public provider or developer
+ * provider) to an existing identity. When you want to create a new identity, the
+ * IdentityId
should be null. When you want to associate a new login with an
+ * existing authenticated/unauthenticated identity, you can do so by providing the existing
+ * IdentityId
. This API will create the identity in the specified
+ * IdentityPoolId
.
You must use AWS Developer credentials to call this API.
+ */ +class GetOpenIdTokenForDeveloperIdentityCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "GetOpenIdTokenForDeveloperIdentityCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetOpenIdTokenForDeveloperIdentityInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetOpenIdTokenForDeveloperIdentityResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommand(output, context); + } +} +exports.GetOpenIdTokenForDeveloperIdentityCommand = GetOpenIdTokenForDeveloperIdentityCommand; +//# sourceMappingURL=GetOpenIdTokenForDeveloperIdentityCommand.js.map + +/***/ }), + +/***/ 24194: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListIdentitiesCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the identities in an identity pool.
+ *You must use AWS Developer credentials to call this API.
+ */ +class ListIdentitiesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "ListIdentitiesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListIdentitiesInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListIdentitiesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListIdentitiesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListIdentitiesCommand(output, context); + } +} +exports.ListIdentitiesCommand = ListIdentitiesCommand; +//# sourceMappingURL=ListIdentitiesCommand.js.map + +/***/ }), + +/***/ 53836: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListIdentityPoolsCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists all of the Cognito identity pools registered for your account.
+ *You must use AWS Developer credentials to call this API.
+ */ +class ListIdentityPoolsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "ListIdentityPoolsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListIdentityPoolsInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListIdentityPoolsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListIdentityPoolsCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListIdentityPoolsCommand(output, context); + } +} +exports.ListIdentityPoolsCommand = ListIdentityPoolsCommand; +//# sourceMappingURL=ListIdentityPoolsCommand.js.map + +/***/ }), + +/***/ 29314: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListTagsForResourceCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the tags that are assigned to an Amazon Cognito identity pool.
+ *A tag is a label that you can apply to identity pools to categorize and manage them in + * different ways, such as by purpose, owner, environment, or other criteria.
+ *You can use this action up to 10 times per second, per account.
+ */ +class ListTagsForResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "ListTagsForResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListTagsForResourceInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListTagsForResourceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1ListTagsForResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1ListTagsForResourceCommand(output, context); + } +} +exports.ListTagsForResourceCommand = ListTagsForResourceCommand; +//# sourceMappingURL=ListTagsForResourceCommand.js.map + +/***/ }), + +/***/ 4664: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.LookupDeveloperIdentityCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Retrieves the IdentityID
associated with a
+ * DeveloperUserIdentifier
or the list of DeveloperUserIdentifier
+ * values associated with an IdentityId
for an existing identity. Either
+ * IdentityID
or DeveloperUserIdentifier
must not be null. If you
+ * supply only one of these values, the other value will be searched in the database and
+ * returned as a part of the response. If you supply both,
+ * DeveloperUserIdentifier
will be matched against IdentityID
. If
+ * the values are verified against the database, the response returns both values and is the
+ * same as the request. Otherwise a ResourceConflictException
is
+ * thrown.
+ * LookupDeveloperIdentity
is intended for low-throughput control plane
+ * operations: for example, to enable customer service to locate an identity ID by username.
+ * If you are using it for higher-volume operations such as user authentication, your requests
+ * are likely to be throttled. GetOpenIdTokenForDeveloperIdentity is a
+ * better option for higher-volume operations for user authentication.
You must use AWS Developer credentials to call this API.
+ */ +class LookupDeveloperIdentityCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "LookupDeveloperIdentityCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.LookupDeveloperIdentityInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.LookupDeveloperIdentityResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1LookupDeveloperIdentityCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1LookupDeveloperIdentityCommand(output, context); + } +} +exports.LookupDeveloperIdentityCommand = LookupDeveloperIdentityCommand; +//# sourceMappingURL=LookupDeveloperIdentityCommand.js.map + +/***/ }), + +/***/ 64385: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.MergeDeveloperIdentitiesCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Merges two users having different IdentityId
s, existing in the same
+ * identity pool, and identified by the same developer provider. You can use this action to
+ * request that discrete users be merged and identified as a single user in the Cognito
+ * environment. Cognito associates the given source user (SourceUserIdentifier
)
+ * with the IdentityId
of the DestinationUserIdentifier
. Only
+ * developer-authenticated users can be merged. If the users to be merged are associated with
+ * the same public provider, but as two different users, an exception will be
+ * thrown.
The number of linked logins is limited to 20. So, the number of linked logins for the
+ * source user, SourceUserIdentifier
, and the destination user,
+ * DestinationUserIdentifier
, together should not be larger than 20.
+ * Otherwise, an exception will be thrown.
You must use AWS Developer credentials to call this API.
+ */ +class MergeDeveloperIdentitiesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "MergeDeveloperIdentitiesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.MergeDeveloperIdentitiesInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.MergeDeveloperIdentitiesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1MergeDeveloperIdentitiesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1MergeDeveloperIdentitiesCommand(output, context); + } +} +exports.MergeDeveloperIdentitiesCommand = MergeDeveloperIdentitiesCommand; +//# sourceMappingURL=MergeDeveloperIdentitiesCommand.js.map + +/***/ }), + +/***/ 4039: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SetIdentityPoolRolesCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Sets the roles for an identity pool. These roles are used when making calls to GetCredentialsForIdentity action.
+ *You must use AWS Developer credentials to call this API.
+ */ +class SetIdentityPoolRolesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "SetIdentityPoolRolesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.SetIdentityPoolRolesInput.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1SetIdentityPoolRolesCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1SetIdentityPoolRolesCommand(output, context); + } +} +exports.SetIdentityPoolRolesCommand = SetIdentityPoolRolesCommand; +//# sourceMappingURL=SetIdentityPoolRolesCommand.js.map + +/***/ }), + +/***/ 67926: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.TagResourceCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Assigns a set of tags to an Amazon Cognito identity pool. A tag is a label that you can + * use to categorize and manage identity pools in different ways, such as by purpose, owner, + * environment, or other criteria.
+ *Each tag consists of a key and value, both of which you define. A key is a general
+ * category for more specific values. For example, if you have two versions of an identity
+ * pool, one for testing and another for production, you might assign an
+ * Environment
tag key to both identity pools. The value of this key might be
+ * Test
for one identity pool and Production
for the
+ * other.
Tags are useful for cost tracking and access control. You can activate your tags so that + * they appear on the Billing and Cost Management console, where you can track the costs + * associated with your identity pools. In an IAM policy, you can constrain permissions for + * identity pools based on specific tags or tag values.
+ *You can use this action up to 5 times per second, per account. An identity pool can have + * as many as 50 tags.
+ */ +class TagResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "TagResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.TagResourceInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.TagResourceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1TagResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1TagResourceCommand(output, context); + } +} +exports.TagResourceCommand = TagResourceCommand; +//# sourceMappingURL=TagResourceCommand.js.map + +/***/ }), + +/***/ 55410: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UnlinkDeveloperIdentityCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Unlinks a DeveloperUserIdentifier
from an existing identity. Unlinked
+ * developer users will be considered new identities next time they are seen. If, for a given
+ * Cognito identity, you remove all federated identities as well as the developer user
+ * identifier, the Cognito identity becomes inaccessible.
You must use AWS Developer credentials to call this API.
+ */ +class UnlinkDeveloperIdentityCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "UnlinkDeveloperIdentityCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.UnlinkDeveloperIdentityInput.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1UnlinkDeveloperIdentityCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1UnlinkDeveloperIdentityCommand(output, context); + } +} +exports.UnlinkDeveloperIdentityCommand = UnlinkDeveloperIdentityCommand; +//# sourceMappingURL=UnlinkDeveloperIdentityCommand.js.map + +/***/ }), + +/***/ 98248: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UnlinkIdentityCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Unlinks a federated identity from an existing account. Unlinked logins will be + * considered new identities next time they are seen. Removing the last linked login will make + * this identity inaccessible.
+ *This is a public API. You do not need any credentials to call this API.
+ */ +class UnlinkIdentityCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "UnlinkIdentityCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.UnlinkIdentityInput.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1UnlinkIdentityCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1UnlinkIdentityCommand(output, context); + } +} +exports.UnlinkIdentityCommand = UnlinkIdentityCommand; +//# sourceMappingURL=UnlinkIdentityCommand.js.map + +/***/ }), + +/***/ 37358: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UntagResourceCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Removes the specified tags from an Amazon Cognito identity pool. You can use this action + * up to 5 times per second, per account
+ */ +class UntagResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "UntagResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.UntagResourceInput.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.UntagResourceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1UntagResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1UntagResourceCommand(output, context); + } +} +exports.UntagResourceCommand = UntagResourceCommand; +//# sourceMappingURL=UntagResourceCommand.js.map + +/***/ }), + +/***/ 97273: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateIdentityPoolCommand = void 0; +const models_0_1 = __nccwpck_require__(76319); +const Aws_json1_1_1 = __nccwpck_require__(69579); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates an identity pool.
+ *You must use AWS Developer credentials to call this API.
+ */ +class UpdateIdentityPoolCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "CognitoIdentityClient"; + const commandName = "UpdateIdentityPoolCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.IdentityPool.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.IdentityPool.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_json1_1_1.serializeAws_json1_1UpdateIdentityPoolCommand(input, context); + } + deserialize(output, context) { + return Aws_json1_1_1.deserializeAws_json1_1UpdateIdentityPoolCommand(output, context); + } +} +exports.UpdateIdentityPoolCommand = UpdateIdentityPoolCommand; +//# sourceMappingURL=UpdateIdentityPoolCommand.js.map + +/***/ }), + +/***/ 43366: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.defaultRegionInfoProvider = void 0; +// Partition default templates +const AWS_TEMPLATE = "cognito-identity.{region}.amazonaws.com"; +const AWS_CN_TEMPLATE = "cognito-identity.{region}.amazonaws.com.cn"; +const AWS_ISO_TEMPLATE = "cognito-identity.{region}.c2s.ic.gov"; +const AWS_ISO_B_TEMPLATE = "cognito-identity.{region}.sc2s.sgov.gov"; +const AWS_US_GOV_TEMPLATE = "cognito-identity.{region}.amazonaws.com"; +// Partition regions +const AWS_REGIONS = new Set([ + "af-south-1", + "ap-east-1", + "ap-northeast-1", + "ap-northeast-2", + "ap-south-1", + "ap-southeast-1", + "ap-southeast-2", + "ca-central-1", + "eu-central-1", + "eu-north-1", + "eu-south-1", + "eu-west-1", + "eu-west-2", + "eu-west-3", + "me-south-1", + "sa-east-1", + "us-east-1", + "us-east-2", + "us-west-1", + "us-west-2", +]); +const AWS_CN_REGIONS = new Set(["cn-north-1", "cn-northwest-1"]); +const AWS_ISO_REGIONS = new Set(["us-iso-east-1"]); +const AWS_ISO_B_REGIONS = new Set(["us-isob-east-1"]); +const AWS_US_GOV_REGIONS = new Set(["us-gov-east-1", "us-gov-west-1"]); +const defaultRegionInfoProvider = (region, options) => { + let regionInfo = undefined; + switch (region) { + // First, try to match exact region names. + case "ap-northeast-1": + regionInfo = { + hostname: "cognito-identity.ap-northeast-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-northeast-2": + regionInfo = { + hostname: "cognito-identity.ap-northeast-2.amazonaws.com", + partition: "aws", + }; + break; + case "ap-south-1": + regionInfo = { + hostname: "cognito-identity.ap-south-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-southeast-1": + regionInfo = { + hostname: "cognito-identity.ap-southeast-1.amazonaws.com", + partition: "aws", + }; + break; + case "ap-southeast-2": + regionInfo = { + hostname: "cognito-identity.ap-southeast-2.amazonaws.com", + partition: "aws", + }; + break; + case "ca-central-1": + regionInfo = { + hostname: "cognito-identity.ca-central-1.amazonaws.com", + partition: "aws", + }; + break; + case "cn-north-1": + regionInfo = { + hostname: "cognito-identity.cn-north-1.amazonaws.com.cn", + partition: "aws-cn", + }; + break; + case "eu-central-1": + regionInfo = { + hostname: "cognito-identity.eu-central-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-north-1": + regionInfo = { + hostname: "cognito-identity.eu-north-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-west-1": + regionInfo = { + hostname: "cognito-identity.eu-west-1.amazonaws.com", + partition: "aws", + }; + break; + case "eu-west-2": + regionInfo = { + hostname: "cognito-identity.eu-west-2.amazonaws.com", + partition: "aws", + }; + break; + case "eu-west-3": + regionInfo = { + hostname: "cognito-identity.eu-west-3.amazonaws.com", + partition: "aws", + }; + break; + case "fips-us-east-1": + regionInfo = { + hostname: "cognito-identity-fips.us-east-1.amazonaws.com", + partition: "aws", + signingRegion: "us-east-1", + }; + break; + case "fips-us-east-2": + regionInfo = { + hostname: "cognito-identity-fips.us-east-2.amazonaws.com", + partition: "aws", + signingRegion: "us-east-2", + }; + break; + case "fips-us-gov-west-1": + regionInfo = { + hostname: "cognito-identity-fips.us-gov-west-1.amazonaws.com", + partition: "aws-us-gov", + signingRegion: "us-gov-west-1", + }; + break; + case "fips-us-west-2": + regionInfo = { + hostname: "cognito-identity-fips.us-west-2.amazonaws.com", + partition: "aws", + signingRegion: "us-west-2", + }; + break; + case "sa-east-1": + regionInfo = { + hostname: "cognito-identity.sa-east-1.amazonaws.com", + partition: "aws", + }; + break; + case "us-east-1": + regionInfo = { + hostname: "cognito-identity.us-east-1.amazonaws.com", + partition: "aws", + }; + break; + case "us-east-2": + regionInfo = { + hostname: "cognito-identity.us-east-2.amazonaws.com", + partition: "aws", + }; + break; + case "us-gov-west-1": + regionInfo = { + hostname: "cognito-identity.us-gov-west-1.amazonaws.com", + partition: "aws-us-gov", + }; + break; + case "us-west-1": + regionInfo = { + hostname: "cognito-identity.us-west-1.amazonaws.com", + partition: "aws", + }; + break; + case "us-west-2": + regionInfo = { + hostname: "cognito-identity.us-west-2.amazonaws.com", + partition: "aws", + }; + break; + // Next, try to match partition endpoints. + default: + if (AWS_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_TEMPLATE.replace("{region}", region), + partition: "aws", + }; + } + if (AWS_CN_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_CN_TEMPLATE.replace("{region}", region), + partition: "aws-cn", + }; + } + if (AWS_ISO_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_ISO_TEMPLATE.replace("{region}", region), + partition: "aws-iso", + }; + } + if (AWS_ISO_B_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_ISO_B_TEMPLATE.replace("{region}", region), + partition: "aws-iso-b", + }; + } + if (AWS_US_GOV_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_US_GOV_TEMPLATE.replace("{region}", region), + partition: "aws-us-gov", + }; + } + // Finally, assume it's an AWS partition endpoint. + if (regionInfo === undefined) { + regionInfo = { + hostname: AWS_TEMPLATE.replace("{region}", region), + partition: "aws", + }; + } + } + return Promise.resolve({ signingService: "cognito-identity", ...regionInfo }); +}; +exports.defaultRegionInfoProvider = defaultRegionInfoProvider; +//# sourceMappingURL=endpoints.js.map + +/***/ }), + +/***/ 25949: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +const tslib_1 = __nccwpck_require__(57088); +tslib_1.__exportStar(__nccwpck_require__(72614), exports); +tslib_1.__exportStar(__nccwpck_require__(67301), exports); +tslib_1.__exportStar(__nccwpck_require__(7373), exports); +tslib_1.__exportStar(__nccwpck_require__(16080), exports); +tslib_1.__exportStar(__nccwpck_require__(91472), exports); +tslib_1.__exportStar(__nccwpck_require__(14047), exports); +tslib_1.__exportStar(__nccwpck_require__(41066), exports); +tslib_1.__exportStar(__nccwpck_require__(24133), exports); +tslib_1.__exportStar(__nccwpck_require__(37292), exports); +tslib_1.__exportStar(__nccwpck_require__(23106), exports); +tslib_1.__exportStar(__nccwpck_require__(89258), exports); +tslib_1.__exportStar(__nccwpck_require__(86688), exports); +tslib_1.__exportStar(__nccwpck_require__(24194), exports); +tslib_1.__exportStar(__nccwpck_require__(53836), exports); +tslib_1.__exportStar(__nccwpck_require__(26964), exports); +tslib_1.__exportStar(__nccwpck_require__(29314), exports); +tslib_1.__exportStar(__nccwpck_require__(4664), exports); +tslib_1.__exportStar(__nccwpck_require__(64385), exports); +tslib_1.__exportStar(__nccwpck_require__(4039), exports); +tslib_1.__exportStar(__nccwpck_require__(67926), exports); +tslib_1.__exportStar(__nccwpck_require__(55410), exports); +tslib_1.__exportStar(__nccwpck_require__(98248), exports); +tslib_1.__exportStar(__nccwpck_require__(37358), exports); +tslib_1.__exportStar(__nccwpck_require__(97273), exports); +tslib_1.__exportStar(__nccwpck_require__(46914), exports); +tslib_1.__exportStar(__nccwpck_require__(69902), exports); +//# sourceMappingURL=index.js.map + +/***/ }), + +/***/ 69902: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +const tslib_1 = __nccwpck_require__(57088); +tslib_1.__exportStar(__nccwpck_require__(76319), exports); +//# sourceMappingURL=index.js.map + +/***/ }), + +/***/ 76319: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ConcurrentModificationException = exports.MergeDeveloperIdentitiesResponse = exports.MergeDeveloperIdentitiesInput = exports.LookupDeveloperIdentityResponse = exports.LookupDeveloperIdentityInput = exports.ListTagsForResourceResponse = exports.ListTagsForResourceInput = exports.ListIdentityPoolsResponse = exports.IdentityPoolShortDescription = exports.ListIdentityPoolsInput = exports.ListIdentitiesResponse = exports.ListIdentitiesInput = exports.GetOpenIdTokenForDeveloperIdentityResponse = exports.GetOpenIdTokenForDeveloperIdentityInput = exports.DeveloperUserAlreadyRegisteredException = exports.GetOpenIdTokenResponse = exports.GetOpenIdTokenInput = exports.GetIdentityPoolRolesResponse = exports.RoleMapping = exports.RoleMappingType = exports.RulesConfigurationType = exports.MappingRule = exports.MappingRuleMatchType = exports.GetIdentityPoolRolesInput = exports.GetIdResponse = exports.GetIdInput = exports.InvalidIdentityPoolConfigurationException = exports.GetCredentialsForIdentityResponse = exports.Credentials = exports.GetCredentialsForIdentityInput = exports.ExternalServiceException = exports.DescribeIdentityPoolInput = exports.IdentityDescription = exports.DescribeIdentityInput = exports.ResourceNotFoundException = exports.DeleteIdentityPoolInput = exports.DeleteIdentitiesResponse = exports.UnprocessedIdentityId = exports.ErrorCode = exports.DeleteIdentitiesInput = exports.TooManyRequestsException = exports.ResourceConflictException = exports.NotAuthorizedException = exports.LimitExceededException = exports.InvalidParameterException = exports.InternalErrorException = exports.IdentityPool = exports.CreateIdentityPoolInput = exports.CognitoIdentityProvider = exports.AmbiguousRoleResolutionType = void 0; +exports.UntagResourceResponse = exports.UntagResourceInput = exports.UnlinkIdentityInput = exports.UnlinkDeveloperIdentityInput = exports.TagResourceResponse = exports.TagResourceInput = exports.SetIdentityPoolRolesInput = void 0; +var AmbiguousRoleResolutionType; +(function (AmbiguousRoleResolutionType) { + AmbiguousRoleResolutionType["AUTHENTICATED_ROLE"] = "AuthenticatedRole"; + AmbiguousRoleResolutionType["DENY"] = "Deny"; +})(AmbiguousRoleResolutionType = exports.AmbiguousRoleResolutionType || (exports.AmbiguousRoleResolutionType = {})); +var CognitoIdentityProvider; +(function (CognitoIdentityProvider) { + CognitoIdentityProvider.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CognitoIdentityProvider = exports.CognitoIdentityProvider || (exports.CognitoIdentityProvider = {})); +var CreateIdentityPoolInput; +(function (CreateIdentityPoolInput) { + CreateIdentityPoolInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateIdentityPoolInput = exports.CreateIdentityPoolInput || (exports.CreateIdentityPoolInput = {})); +var IdentityPool; +(function (IdentityPool) { + IdentityPool.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(IdentityPool = exports.IdentityPool || (exports.IdentityPool = {})); +var InternalErrorException; +(function (InternalErrorException) { + InternalErrorException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InternalErrorException = exports.InternalErrorException || (exports.InternalErrorException = {})); +var InvalidParameterException; +(function (InvalidParameterException) { + InvalidParameterException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidParameterException = exports.InvalidParameterException || (exports.InvalidParameterException = {})); +var LimitExceededException; +(function (LimitExceededException) { + LimitExceededException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LimitExceededException = exports.LimitExceededException || (exports.LimitExceededException = {})); +var NotAuthorizedException; +(function (NotAuthorizedException) { + NotAuthorizedException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(NotAuthorizedException = exports.NotAuthorizedException || (exports.NotAuthorizedException = {})); +var ResourceConflictException; +(function (ResourceConflictException) { + ResourceConflictException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceConflictException = exports.ResourceConflictException || (exports.ResourceConflictException = {})); +var TooManyRequestsException; +(function (TooManyRequestsException) { + TooManyRequestsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TooManyRequestsException = exports.TooManyRequestsException || (exports.TooManyRequestsException = {})); +var DeleteIdentitiesInput; +(function (DeleteIdentitiesInput) { + DeleteIdentitiesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteIdentitiesInput = exports.DeleteIdentitiesInput || (exports.DeleteIdentitiesInput = {})); +var ErrorCode; +(function (ErrorCode) { + ErrorCode["ACCESS_DENIED"] = "AccessDenied"; + ErrorCode["INTERNAL_SERVER_ERROR"] = "InternalServerError"; +})(ErrorCode = exports.ErrorCode || (exports.ErrorCode = {})); +var UnprocessedIdentityId; +(function (UnprocessedIdentityId) { + UnprocessedIdentityId.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UnprocessedIdentityId = exports.UnprocessedIdentityId || (exports.UnprocessedIdentityId = {})); +var DeleteIdentitiesResponse; +(function (DeleteIdentitiesResponse) { + DeleteIdentitiesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteIdentitiesResponse = exports.DeleteIdentitiesResponse || (exports.DeleteIdentitiesResponse = {})); +var DeleteIdentityPoolInput; +(function (DeleteIdentityPoolInput) { + DeleteIdentityPoolInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteIdentityPoolInput = exports.DeleteIdentityPoolInput || (exports.DeleteIdentityPoolInput = {})); +var ResourceNotFoundException; +(function (ResourceNotFoundException) { + ResourceNotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceNotFoundException = exports.ResourceNotFoundException || (exports.ResourceNotFoundException = {})); +var DescribeIdentityInput; +(function (DescribeIdentityInput) { + DescribeIdentityInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeIdentityInput = exports.DescribeIdentityInput || (exports.DescribeIdentityInput = {})); +var IdentityDescription; +(function (IdentityDescription) { + IdentityDescription.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(IdentityDescription = exports.IdentityDescription || (exports.IdentityDescription = {})); +var DescribeIdentityPoolInput; +(function (DescribeIdentityPoolInput) { + DescribeIdentityPoolInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeIdentityPoolInput = exports.DescribeIdentityPoolInput || (exports.DescribeIdentityPoolInput = {})); +var ExternalServiceException; +(function (ExternalServiceException) { + ExternalServiceException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ExternalServiceException = exports.ExternalServiceException || (exports.ExternalServiceException = {})); +var GetCredentialsForIdentityInput; +(function (GetCredentialsForIdentityInput) { + GetCredentialsForIdentityInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetCredentialsForIdentityInput = exports.GetCredentialsForIdentityInput || (exports.GetCredentialsForIdentityInput = {})); +var Credentials; +(function (Credentials) { + Credentials.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Credentials = exports.Credentials || (exports.Credentials = {})); +var GetCredentialsForIdentityResponse; +(function (GetCredentialsForIdentityResponse) { + GetCredentialsForIdentityResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetCredentialsForIdentityResponse = exports.GetCredentialsForIdentityResponse || (exports.GetCredentialsForIdentityResponse = {})); +var InvalidIdentityPoolConfigurationException; +(function (InvalidIdentityPoolConfigurationException) { + InvalidIdentityPoolConfigurationException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidIdentityPoolConfigurationException = exports.InvalidIdentityPoolConfigurationException || (exports.InvalidIdentityPoolConfigurationException = {})); +var GetIdInput; +(function (GetIdInput) { + GetIdInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetIdInput = exports.GetIdInput || (exports.GetIdInput = {})); +var GetIdResponse; +(function (GetIdResponse) { + GetIdResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetIdResponse = exports.GetIdResponse || (exports.GetIdResponse = {})); +var GetIdentityPoolRolesInput; +(function (GetIdentityPoolRolesInput) { + GetIdentityPoolRolesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetIdentityPoolRolesInput = exports.GetIdentityPoolRolesInput || (exports.GetIdentityPoolRolesInput = {})); +var MappingRuleMatchType; +(function (MappingRuleMatchType) { + MappingRuleMatchType["CONTAINS"] = "Contains"; + MappingRuleMatchType["EQUALS"] = "Equals"; + MappingRuleMatchType["NOT_EQUAL"] = "NotEqual"; + MappingRuleMatchType["STARTS_WITH"] = "StartsWith"; +})(MappingRuleMatchType = exports.MappingRuleMatchType || (exports.MappingRuleMatchType = {})); +var MappingRule; +(function (MappingRule) { + MappingRule.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MappingRule = exports.MappingRule || (exports.MappingRule = {})); +var RulesConfigurationType; +(function (RulesConfigurationType) { + RulesConfigurationType.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RulesConfigurationType = exports.RulesConfigurationType || (exports.RulesConfigurationType = {})); +var RoleMappingType; +(function (RoleMappingType) { + RoleMappingType["RULES"] = "Rules"; + RoleMappingType["TOKEN"] = "Token"; +})(RoleMappingType = exports.RoleMappingType || (exports.RoleMappingType = {})); +var RoleMapping; +(function (RoleMapping) { + RoleMapping.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RoleMapping = exports.RoleMapping || (exports.RoleMapping = {})); +var GetIdentityPoolRolesResponse; +(function (GetIdentityPoolRolesResponse) { + GetIdentityPoolRolesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetIdentityPoolRolesResponse = exports.GetIdentityPoolRolesResponse || (exports.GetIdentityPoolRolesResponse = {})); +var GetOpenIdTokenInput; +(function (GetOpenIdTokenInput) { + GetOpenIdTokenInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetOpenIdTokenInput = exports.GetOpenIdTokenInput || (exports.GetOpenIdTokenInput = {})); +var GetOpenIdTokenResponse; +(function (GetOpenIdTokenResponse) { + GetOpenIdTokenResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetOpenIdTokenResponse = exports.GetOpenIdTokenResponse || (exports.GetOpenIdTokenResponse = {})); +var DeveloperUserAlreadyRegisteredException; +(function (DeveloperUserAlreadyRegisteredException) { + DeveloperUserAlreadyRegisteredException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeveloperUserAlreadyRegisteredException = exports.DeveloperUserAlreadyRegisteredException || (exports.DeveloperUserAlreadyRegisteredException = {})); +var GetOpenIdTokenForDeveloperIdentityInput; +(function (GetOpenIdTokenForDeveloperIdentityInput) { + GetOpenIdTokenForDeveloperIdentityInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetOpenIdTokenForDeveloperIdentityInput = exports.GetOpenIdTokenForDeveloperIdentityInput || (exports.GetOpenIdTokenForDeveloperIdentityInput = {})); +var GetOpenIdTokenForDeveloperIdentityResponse; +(function (GetOpenIdTokenForDeveloperIdentityResponse) { + GetOpenIdTokenForDeveloperIdentityResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetOpenIdTokenForDeveloperIdentityResponse = exports.GetOpenIdTokenForDeveloperIdentityResponse || (exports.GetOpenIdTokenForDeveloperIdentityResponse = {})); +var ListIdentitiesInput; +(function (ListIdentitiesInput) { + ListIdentitiesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListIdentitiesInput = exports.ListIdentitiesInput || (exports.ListIdentitiesInput = {})); +var ListIdentitiesResponse; +(function (ListIdentitiesResponse) { + ListIdentitiesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListIdentitiesResponse = exports.ListIdentitiesResponse || (exports.ListIdentitiesResponse = {})); +var ListIdentityPoolsInput; +(function (ListIdentityPoolsInput) { + ListIdentityPoolsInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListIdentityPoolsInput = exports.ListIdentityPoolsInput || (exports.ListIdentityPoolsInput = {})); +var IdentityPoolShortDescription; +(function (IdentityPoolShortDescription) { + IdentityPoolShortDescription.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(IdentityPoolShortDescription = exports.IdentityPoolShortDescription || (exports.IdentityPoolShortDescription = {})); +var ListIdentityPoolsResponse; +(function (ListIdentityPoolsResponse) { + ListIdentityPoolsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListIdentityPoolsResponse = exports.ListIdentityPoolsResponse || (exports.ListIdentityPoolsResponse = {})); +var ListTagsForResourceInput; +(function (ListTagsForResourceInput) { + ListTagsForResourceInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTagsForResourceInput = exports.ListTagsForResourceInput || (exports.ListTagsForResourceInput = {})); +var ListTagsForResourceResponse; +(function (ListTagsForResourceResponse) { + ListTagsForResourceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTagsForResourceResponse = exports.ListTagsForResourceResponse || (exports.ListTagsForResourceResponse = {})); +var LookupDeveloperIdentityInput; +(function (LookupDeveloperIdentityInput) { + LookupDeveloperIdentityInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LookupDeveloperIdentityInput = exports.LookupDeveloperIdentityInput || (exports.LookupDeveloperIdentityInput = {})); +var LookupDeveloperIdentityResponse; +(function (LookupDeveloperIdentityResponse) { + LookupDeveloperIdentityResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LookupDeveloperIdentityResponse = exports.LookupDeveloperIdentityResponse || (exports.LookupDeveloperIdentityResponse = {})); +var MergeDeveloperIdentitiesInput; +(function (MergeDeveloperIdentitiesInput) { + MergeDeveloperIdentitiesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MergeDeveloperIdentitiesInput = exports.MergeDeveloperIdentitiesInput || (exports.MergeDeveloperIdentitiesInput = {})); +var MergeDeveloperIdentitiesResponse; +(function (MergeDeveloperIdentitiesResponse) { + MergeDeveloperIdentitiesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MergeDeveloperIdentitiesResponse = exports.MergeDeveloperIdentitiesResponse || (exports.MergeDeveloperIdentitiesResponse = {})); +var ConcurrentModificationException; +(function (ConcurrentModificationException) { + ConcurrentModificationException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ConcurrentModificationException = exports.ConcurrentModificationException || (exports.ConcurrentModificationException = {})); +var SetIdentityPoolRolesInput; +(function (SetIdentityPoolRolesInput) { + SetIdentityPoolRolesInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetIdentityPoolRolesInput = exports.SetIdentityPoolRolesInput || (exports.SetIdentityPoolRolesInput = {})); +var TagResourceInput; +(function (TagResourceInput) { + TagResourceInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TagResourceInput = exports.TagResourceInput || (exports.TagResourceInput = {})); +var TagResourceResponse; +(function (TagResourceResponse) { + TagResourceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TagResourceResponse = exports.TagResourceResponse || (exports.TagResourceResponse = {})); +var UnlinkDeveloperIdentityInput; +(function (UnlinkDeveloperIdentityInput) { + UnlinkDeveloperIdentityInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UnlinkDeveloperIdentityInput = exports.UnlinkDeveloperIdentityInput || (exports.UnlinkDeveloperIdentityInput = {})); +var UnlinkIdentityInput; +(function (UnlinkIdentityInput) { + UnlinkIdentityInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UnlinkIdentityInput = exports.UnlinkIdentityInput || (exports.UnlinkIdentityInput = {})); +var UntagResourceInput; +(function (UntagResourceInput) { + UntagResourceInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UntagResourceInput = exports.UntagResourceInput || (exports.UntagResourceInput = {})); +var UntagResourceResponse; +(function (UntagResourceResponse) { + UntagResourceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UntagResourceResponse = exports.UntagResourceResponse || (exports.UntagResourceResponse = {})); +//# sourceMappingURL=models_0.js.map + +/***/ }), + +/***/ 46914: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +//# sourceMappingURL=Interfaces.js.map + +/***/ }), + +/***/ 26964: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListIdentityPools = void 0; +const CognitoIdentity_1 = __nccwpck_require__(67301); +const CognitoIdentityClient_1 = __nccwpck_require__(72614); +const ListIdentityPoolsCommand_1 = __nccwpck_require__(53836); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListIdentityPoolsCommand_1.ListIdentityPoolsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listIdentityPools(input, ...args); +}; +async function* paginateListIdentityPools(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.NextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.NextToken = token; + input["MaxResults"] = config.pageSize; + if (config.client instanceof CognitoIdentity_1.CognitoIdentity) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof CognitoIdentityClient_1.CognitoIdentityClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected CognitoIdentity | CognitoIdentityClient"); + } + yield page; + token = page.NextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListIdentityPools = paginateListIdentityPools; +//# sourceMappingURL=ListIdentityPoolsPaginator.js.map + +/***/ }), + +/***/ 69579: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.deserializeAws_json1_1UpdateIdentityPoolCommand = exports.deserializeAws_json1_1UntagResourceCommand = exports.deserializeAws_json1_1UnlinkIdentityCommand = exports.deserializeAws_json1_1UnlinkDeveloperIdentityCommand = exports.deserializeAws_json1_1TagResourceCommand = exports.deserializeAws_json1_1SetIdentityPoolRolesCommand = exports.deserializeAws_json1_1MergeDeveloperIdentitiesCommand = exports.deserializeAws_json1_1LookupDeveloperIdentityCommand = exports.deserializeAws_json1_1ListTagsForResourceCommand = exports.deserializeAws_json1_1ListIdentityPoolsCommand = exports.deserializeAws_json1_1ListIdentitiesCommand = exports.deserializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommand = exports.deserializeAws_json1_1GetOpenIdTokenCommand = exports.deserializeAws_json1_1GetIdentityPoolRolesCommand = exports.deserializeAws_json1_1GetIdCommand = exports.deserializeAws_json1_1GetCredentialsForIdentityCommand = exports.deserializeAws_json1_1DescribeIdentityPoolCommand = exports.deserializeAws_json1_1DescribeIdentityCommand = exports.deserializeAws_json1_1DeleteIdentityPoolCommand = exports.deserializeAws_json1_1DeleteIdentitiesCommand = exports.deserializeAws_json1_1CreateIdentityPoolCommand = exports.serializeAws_json1_1UpdateIdentityPoolCommand = exports.serializeAws_json1_1UntagResourceCommand = exports.serializeAws_json1_1UnlinkIdentityCommand = exports.serializeAws_json1_1UnlinkDeveloperIdentityCommand = exports.serializeAws_json1_1TagResourceCommand = exports.serializeAws_json1_1SetIdentityPoolRolesCommand = exports.serializeAws_json1_1MergeDeveloperIdentitiesCommand = exports.serializeAws_json1_1LookupDeveloperIdentityCommand = exports.serializeAws_json1_1ListTagsForResourceCommand = exports.serializeAws_json1_1ListIdentityPoolsCommand = exports.serializeAws_json1_1ListIdentitiesCommand = exports.serializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommand = exports.serializeAws_json1_1GetOpenIdTokenCommand = exports.serializeAws_json1_1GetIdentityPoolRolesCommand = exports.serializeAws_json1_1GetIdCommand = exports.serializeAws_json1_1GetCredentialsForIdentityCommand = exports.serializeAws_json1_1DescribeIdentityPoolCommand = exports.serializeAws_json1_1DescribeIdentityCommand = exports.serializeAws_json1_1DeleteIdentityPoolCommand = exports.serializeAws_json1_1DeleteIdentitiesCommand = exports.serializeAws_json1_1CreateIdentityPoolCommand = void 0; +const protocol_http_1 = __nccwpck_require__(67498); +const serializeAws_json1_1CreateIdentityPoolCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.CreateIdentityPool", + }; + let body; + body = JSON.stringify(serializeAws_json1_1CreateIdentityPoolInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1CreateIdentityPoolCommand = serializeAws_json1_1CreateIdentityPoolCommand; +const serializeAws_json1_1DeleteIdentitiesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.DeleteIdentities", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DeleteIdentitiesInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DeleteIdentitiesCommand = serializeAws_json1_1DeleteIdentitiesCommand; +const serializeAws_json1_1DeleteIdentityPoolCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.DeleteIdentityPool", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DeleteIdentityPoolInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DeleteIdentityPoolCommand = serializeAws_json1_1DeleteIdentityPoolCommand; +const serializeAws_json1_1DescribeIdentityCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.DescribeIdentity", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DescribeIdentityInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DescribeIdentityCommand = serializeAws_json1_1DescribeIdentityCommand; +const serializeAws_json1_1DescribeIdentityPoolCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.DescribeIdentityPool", + }; + let body; + body = JSON.stringify(serializeAws_json1_1DescribeIdentityPoolInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1DescribeIdentityPoolCommand = serializeAws_json1_1DescribeIdentityPoolCommand; +const serializeAws_json1_1GetCredentialsForIdentityCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.GetCredentialsForIdentity", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetCredentialsForIdentityInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetCredentialsForIdentityCommand = serializeAws_json1_1GetCredentialsForIdentityCommand; +const serializeAws_json1_1GetIdCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.GetId", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetIdInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetIdCommand = serializeAws_json1_1GetIdCommand; +const serializeAws_json1_1GetIdentityPoolRolesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.GetIdentityPoolRoles", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetIdentityPoolRolesInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetIdentityPoolRolesCommand = serializeAws_json1_1GetIdentityPoolRolesCommand; +const serializeAws_json1_1GetOpenIdTokenCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.GetOpenIdToken", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetOpenIdTokenInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetOpenIdTokenCommand = serializeAws_json1_1GetOpenIdTokenCommand; +const serializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.GetOpenIdTokenForDeveloperIdentity", + }; + let body; + body = JSON.stringify(serializeAws_json1_1GetOpenIdTokenForDeveloperIdentityInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommand = serializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommand; +const serializeAws_json1_1ListIdentitiesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.ListIdentities", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListIdentitiesInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListIdentitiesCommand = serializeAws_json1_1ListIdentitiesCommand; +const serializeAws_json1_1ListIdentityPoolsCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.ListIdentityPools", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListIdentityPoolsInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListIdentityPoolsCommand = serializeAws_json1_1ListIdentityPoolsCommand; +const serializeAws_json1_1ListTagsForResourceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.ListTagsForResource", + }; + let body; + body = JSON.stringify(serializeAws_json1_1ListTagsForResourceInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1ListTagsForResourceCommand = serializeAws_json1_1ListTagsForResourceCommand; +const serializeAws_json1_1LookupDeveloperIdentityCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.LookupDeveloperIdentity", + }; + let body; + body = JSON.stringify(serializeAws_json1_1LookupDeveloperIdentityInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1LookupDeveloperIdentityCommand = serializeAws_json1_1LookupDeveloperIdentityCommand; +const serializeAws_json1_1MergeDeveloperIdentitiesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.MergeDeveloperIdentities", + }; + let body; + body = JSON.stringify(serializeAws_json1_1MergeDeveloperIdentitiesInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1MergeDeveloperIdentitiesCommand = serializeAws_json1_1MergeDeveloperIdentitiesCommand; +const serializeAws_json1_1SetIdentityPoolRolesCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.SetIdentityPoolRoles", + }; + let body; + body = JSON.stringify(serializeAws_json1_1SetIdentityPoolRolesInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1SetIdentityPoolRolesCommand = serializeAws_json1_1SetIdentityPoolRolesCommand; +const serializeAws_json1_1TagResourceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.TagResource", + }; + let body; + body = JSON.stringify(serializeAws_json1_1TagResourceInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1TagResourceCommand = serializeAws_json1_1TagResourceCommand; +const serializeAws_json1_1UnlinkDeveloperIdentityCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.UnlinkDeveloperIdentity", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UnlinkDeveloperIdentityInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UnlinkDeveloperIdentityCommand = serializeAws_json1_1UnlinkDeveloperIdentityCommand; +const serializeAws_json1_1UnlinkIdentityCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.UnlinkIdentity", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UnlinkIdentityInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UnlinkIdentityCommand = serializeAws_json1_1UnlinkIdentityCommand; +const serializeAws_json1_1UntagResourceCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.UntagResource", + }; + let body; + body = JSON.stringify(serializeAws_json1_1UntagResourceInput(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UntagResourceCommand = serializeAws_json1_1UntagResourceCommand; +const serializeAws_json1_1UpdateIdentityPoolCommand = async (input, context) => { + const headers = { + "content-type": "application/x-amz-json-1.1", + "x-amz-target": "AWSCognitoIdentityService.UpdateIdentityPool", + }; + let body; + body = JSON.stringify(serializeAws_json1_1IdentityPool(input, context)); + return buildHttpRpcRequest(context, headers, "/", undefined, body); +}; +exports.serializeAws_json1_1UpdateIdentityPoolCommand = serializeAws_json1_1UpdateIdentityPoolCommand; +const deserializeAws_json1_1CreateIdentityPoolCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1CreateIdentityPoolCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1IdentityPool(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1CreateIdentityPoolCommand = deserializeAws_json1_1CreateIdentityPoolCommand; +const deserializeAws_json1_1CreateIdentityPoolCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentity#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DeleteIdentitiesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DeleteIdentitiesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1DeleteIdentitiesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DeleteIdentitiesCommand = deserializeAws_json1_1DeleteIdentitiesCommand; +const deserializeAws_json1_1DeleteIdentitiesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DeleteIdentityPoolCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DeleteIdentityPoolCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DeleteIdentityPoolCommand = deserializeAws_json1_1DeleteIdentityPoolCommand; +const deserializeAws_json1_1DeleteIdentityPoolCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DescribeIdentityCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DescribeIdentityCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1IdentityDescription(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DescribeIdentityCommand = deserializeAws_json1_1DescribeIdentityCommand; +const deserializeAws_json1_1DescribeIdentityCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1DescribeIdentityPoolCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1DescribeIdentityPoolCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1IdentityPool(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1DescribeIdentityPoolCommand = deserializeAws_json1_1DescribeIdentityPoolCommand; +const deserializeAws_json1_1DescribeIdentityPoolCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetCredentialsForIdentityCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetCredentialsForIdentityCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetCredentialsForIdentityResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetCredentialsForIdentityCommand = deserializeAws_json1_1GetCredentialsForIdentityCommand; +const deserializeAws_json1_1GetCredentialsForIdentityCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ExternalServiceException": + case "com.amazonaws.cognitoidentity#ExternalServiceException": + response = { + ...(await deserializeAws_json1_1ExternalServiceExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidIdentityPoolConfigurationException": + case "com.amazonaws.cognitoidentity#InvalidIdentityPoolConfigurationException": + response = { + ...(await deserializeAws_json1_1InvalidIdentityPoolConfigurationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetIdCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetIdCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetIdResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetIdCommand = deserializeAws_json1_1GetIdCommand; +const deserializeAws_json1_1GetIdCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ExternalServiceException": + case "com.amazonaws.cognitoidentity#ExternalServiceException": + response = { + ...(await deserializeAws_json1_1ExternalServiceExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentity#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetIdentityPoolRolesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetIdentityPoolRolesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetIdentityPoolRolesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetIdentityPoolRolesCommand = deserializeAws_json1_1GetIdentityPoolRolesCommand; +const deserializeAws_json1_1GetIdentityPoolRolesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetOpenIdTokenCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetOpenIdTokenCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetOpenIdTokenResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetOpenIdTokenCommand = deserializeAws_json1_1GetOpenIdTokenCommand; +const deserializeAws_json1_1GetOpenIdTokenCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ExternalServiceException": + case "com.amazonaws.cognitoidentity#ExternalServiceException": + response = { + ...(await deserializeAws_json1_1ExternalServiceExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1GetOpenIdTokenForDeveloperIdentityResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommand = deserializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommand; +const deserializeAws_json1_1GetOpenIdTokenForDeveloperIdentityCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "DeveloperUserAlreadyRegisteredException": + case "com.amazonaws.cognitoidentity#DeveloperUserAlreadyRegisteredException": + response = { + ...(await deserializeAws_json1_1DeveloperUserAlreadyRegisteredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListIdentitiesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListIdentitiesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListIdentitiesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListIdentitiesCommand = deserializeAws_json1_1ListIdentitiesCommand; +const deserializeAws_json1_1ListIdentitiesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListIdentityPoolsCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListIdentityPoolsCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListIdentityPoolsResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListIdentityPoolsCommand = deserializeAws_json1_1ListIdentityPoolsCommand; +const deserializeAws_json1_1ListIdentityPoolsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ListTagsForResourceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1ListTagsForResourceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1ListTagsForResourceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1ListTagsForResourceCommand = deserializeAws_json1_1ListTagsForResourceCommand; +const deserializeAws_json1_1ListTagsForResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1LookupDeveloperIdentityCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1LookupDeveloperIdentityCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1LookupDeveloperIdentityResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1LookupDeveloperIdentityCommand = deserializeAws_json1_1LookupDeveloperIdentityCommand; +const deserializeAws_json1_1LookupDeveloperIdentityCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1MergeDeveloperIdentitiesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1MergeDeveloperIdentitiesCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1MergeDeveloperIdentitiesResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1MergeDeveloperIdentitiesCommand = deserializeAws_json1_1MergeDeveloperIdentitiesCommand; +const deserializeAws_json1_1MergeDeveloperIdentitiesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1SetIdentityPoolRolesCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1SetIdentityPoolRolesCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1SetIdentityPoolRolesCommand = deserializeAws_json1_1SetIdentityPoolRolesCommand; +const deserializeAws_json1_1SetIdentityPoolRolesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConcurrentModificationException": + case "com.amazonaws.cognitoidentity#ConcurrentModificationException": + response = { + ...(await deserializeAws_json1_1ConcurrentModificationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1TagResourceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1TagResourceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1TagResourceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1TagResourceCommand = deserializeAws_json1_1TagResourceCommand; +const deserializeAws_json1_1TagResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UnlinkDeveloperIdentityCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UnlinkDeveloperIdentityCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UnlinkDeveloperIdentityCommand = deserializeAws_json1_1UnlinkDeveloperIdentityCommand; +const deserializeAws_json1_1UnlinkDeveloperIdentityCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UnlinkIdentityCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UnlinkIdentityCommandError(output, context); + } + await collectBody(output.body, context); + const response = { + $metadata: deserializeMetadata(output), + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UnlinkIdentityCommand = deserializeAws_json1_1UnlinkIdentityCommand; +const deserializeAws_json1_1UnlinkIdentityCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ExternalServiceException": + case "com.amazonaws.cognitoidentity#ExternalServiceException": + response = { + ...(await deserializeAws_json1_1ExternalServiceExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UntagResourceCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UntagResourceCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1UntagResourceResponse(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UntagResourceCommand = deserializeAws_json1_1UntagResourceCommand; +const deserializeAws_json1_1UntagResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1UpdateIdentityPoolCommand = async (output, context) => { + if (output.statusCode >= 300) { + return deserializeAws_json1_1UpdateIdentityPoolCommandError(output, context); + } + const data = await parseBody(output.body, context); + let contents = {}; + contents = deserializeAws_json1_1IdentityPool(data, context); + const response = { + $metadata: deserializeMetadata(output), + ...contents, + }; + return Promise.resolve(response); +}; +exports.deserializeAws_json1_1UpdateIdentityPoolCommand = deserializeAws_json1_1UpdateIdentityPoolCommand; +const deserializeAws_json1_1UpdateIdentityPoolCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConcurrentModificationException": + case "com.amazonaws.cognitoidentity#ConcurrentModificationException": + response = { + ...(await deserializeAws_json1_1ConcurrentModificationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalErrorException": + case "com.amazonaws.cognitoidentity#InternalErrorException": + response = { + ...(await deserializeAws_json1_1InternalErrorExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidParameterException": + case "com.amazonaws.cognitoidentity#InvalidParameterException": + response = { + ...(await deserializeAws_json1_1InvalidParameterExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.cognitoidentity#LimitExceededException": + response = { + ...(await deserializeAws_json1_1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotAuthorizedException": + case "com.amazonaws.cognitoidentity#NotAuthorizedException": + response = { + ...(await deserializeAws_json1_1NotAuthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceConflictException": + case "com.amazonaws.cognitoidentity#ResourceConflictException": + response = { + ...(await deserializeAws_json1_1ResourceConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.cognitoidentity#ResourceNotFoundException": + response = { + ...(await deserializeAws_json1_1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TooManyRequestsException": + case "com.amazonaws.cognitoidentity#TooManyRequestsException": + response = { + ...(await deserializeAws_json1_1TooManyRequestsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_json1_1ConcurrentModificationExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1ConcurrentModificationException(body, context); + const contents = { + name: "ConcurrentModificationException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1DeveloperUserAlreadyRegisteredExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1DeveloperUserAlreadyRegisteredException(body, context); + const contents = { + name: "DeveloperUserAlreadyRegisteredException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1ExternalServiceExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1ExternalServiceException(body, context); + const contents = { + name: "ExternalServiceException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InternalErrorExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InternalErrorException(body, context); + const contents = { + name: "InternalErrorException", + $fault: "server", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InvalidIdentityPoolConfigurationExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InvalidIdentityPoolConfigurationException(body, context); + const contents = { + name: "InvalidIdentityPoolConfigurationException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1InvalidParameterExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1InvalidParameterException(body, context); + const contents = { + name: "InvalidParameterException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1LimitExceededExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1LimitExceededException(body, context); + const contents = { + name: "LimitExceededException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1NotAuthorizedExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1NotAuthorizedException(body, context); + const contents = { + name: "NotAuthorizedException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1ResourceConflictExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1ResourceConflictException(body, context); + const contents = { + name: "ResourceConflictException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1ResourceNotFoundExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1ResourceNotFoundException(body, context); + const contents = { + name: "ResourceNotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const deserializeAws_json1_1TooManyRequestsExceptionResponse = async (parsedOutput, context) => { + const body = parsedOutput.body; + const deserialized = deserializeAws_json1_1TooManyRequestsException(body, context); + const contents = { + name: "TooManyRequestsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + ...deserialized, + }; + return contents; +}; +const serializeAws_json1_1CognitoIdentityProvider = (input, context) => { + return { + ...(input.ClientId !== undefined && input.ClientId !== null && { ClientId: input.ClientId }), + ...(input.ProviderName !== undefined && input.ProviderName !== null && { ProviderName: input.ProviderName }), + ...(input.ServerSideTokenCheck !== undefined && + input.ServerSideTokenCheck !== null && { ServerSideTokenCheck: input.ServerSideTokenCheck }), + }; +}; +const serializeAws_json1_1CognitoIdentityProviderList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_json1_1CognitoIdentityProvider(entry, context); + }); +}; +const serializeAws_json1_1CreateIdentityPoolInput = (input, context) => { + return { + ...(input.AllowClassicFlow !== undefined && + input.AllowClassicFlow !== null && { AllowClassicFlow: input.AllowClassicFlow }), + ...(input.AllowUnauthenticatedIdentities !== undefined && + input.AllowUnauthenticatedIdentities !== null && { + AllowUnauthenticatedIdentities: input.AllowUnauthenticatedIdentities, + }), + ...(input.CognitoIdentityProviders !== undefined && + input.CognitoIdentityProviders !== null && { + CognitoIdentityProviders: serializeAws_json1_1CognitoIdentityProviderList(input.CognitoIdentityProviders, context), + }), + ...(input.DeveloperProviderName !== undefined && + input.DeveloperProviderName !== null && { DeveloperProviderName: input.DeveloperProviderName }), + ...(input.IdentityPoolName !== undefined && + input.IdentityPoolName !== null && { IdentityPoolName: input.IdentityPoolName }), + ...(input.IdentityPoolTags !== undefined && + input.IdentityPoolTags !== null && { + IdentityPoolTags: serializeAws_json1_1IdentityPoolTagsType(input.IdentityPoolTags, context), + }), + ...(input.OpenIdConnectProviderARNs !== undefined && + input.OpenIdConnectProviderARNs !== null && { + OpenIdConnectProviderARNs: serializeAws_json1_1OIDCProviderList(input.OpenIdConnectProviderARNs, context), + }), + ...(input.SamlProviderARNs !== undefined && + input.SamlProviderARNs !== null && { + SamlProviderARNs: serializeAws_json1_1SAMLProviderList(input.SamlProviderARNs, context), + }), + ...(input.SupportedLoginProviders !== undefined && + input.SupportedLoginProviders !== null && { + SupportedLoginProviders: serializeAws_json1_1IdentityProviders(input.SupportedLoginProviders, context), + }), + }; +}; +const serializeAws_json1_1DeleteIdentitiesInput = (input, context) => { + return { + ...(input.IdentityIdsToDelete !== undefined && + input.IdentityIdsToDelete !== null && { + IdentityIdsToDelete: serializeAws_json1_1IdentityIdList(input.IdentityIdsToDelete, context), + }), + }; +}; +const serializeAws_json1_1DeleteIdentityPoolInput = (input, context) => { + return { + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + }; +}; +const serializeAws_json1_1DescribeIdentityInput = (input, context) => { + return { + ...(input.IdentityId !== undefined && input.IdentityId !== null && { IdentityId: input.IdentityId }), + }; +}; +const serializeAws_json1_1DescribeIdentityPoolInput = (input, context) => { + return { + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + }; +}; +const serializeAws_json1_1GetCredentialsForIdentityInput = (input, context) => { + return { + ...(input.CustomRoleArn !== undefined && input.CustomRoleArn !== null && { CustomRoleArn: input.CustomRoleArn }), + ...(input.IdentityId !== undefined && input.IdentityId !== null && { IdentityId: input.IdentityId }), + ...(input.Logins !== undefined && + input.Logins !== null && { Logins: serializeAws_json1_1LoginsMap(input.Logins, context) }), + }; +}; +const serializeAws_json1_1GetIdentityPoolRolesInput = (input, context) => { + return { + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + }; +}; +const serializeAws_json1_1GetIdInput = (input, context) => { + return { + ...(input.AccountId !== undefined && input.AccountId !== null && { AccountId: input.AccountId }), + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + ...(input.Logins !== undefined && + input.Logins !== null && { Logins: serializeAws_json1_1LoginsMap(input.Logins, context) }), + }; +}; +const serializeAws_json1_1GetOpenIdTokenForDeveloperIdentityInput = (input, context) => { + return { + ...(input.IdentityId !== undefined && input.IdentityId !== null && { IdentityId: input.IdentityId }), + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + ...(input.Logins !== undefined && + input.Logins !== null && { Logins: serializeAws_json1_1LoginsMap(input.Logins, context) }), + ...(input.TokenDuration !== undefined && input.TokenDuration !== null && { TokenDuration: input.TokenDuration }), + }; +}; +const serializeAws_json1_1GetOpenIdTokenInput = (input, context) => { + return { + ...(input.IdentityId !== undefined && input.IdentityId !== null && { IdentityId: input.IdentityId }), + ...(input.Logins !== undefined && + input.Logins !== null && { Logins: serializeAws_json1_1LoginsMap(input.Logins, context) }), + }; +}; +const serializeAws_json1_1IdentityIdList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1IdentityPool = (input, context) => { + return { + ...(input.AllowClassicFlow !== undefined && + input.AllowClassicFlow !== null && { AllowClassicFlow: input.AllowClassicFlow }), + ...(input.AllowUnauthenticatedIdentities !== undefined && + input.AllowUnauthenticatedIdentities !== null && { + AllowUnauthenticatedIdentities: input.AllowUnauthenticatedIdentities, + }), + ...(input.CognitoIdentityProviders !== undefined && + input.CognitoIdentityProviders !== null && { + CognitoIdentityProviders: serializeAws_json1_1CognitoIdentityProviderList(input.CognitoIdentityProviders, context), + }), + ...(input.DeveloperProviderName !== undefined && + input.DeveloperProviderName !== null && { DeveloperProviderName: input.DeveloperProviderName }), + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + ...(input.IdentityPoolName !== undefined && + input.IdentityPoolName !== null && { IdentityPoolName: input.IdentityPoolName }), + ...(input.IdentityPoolTags !== undefined && + input.IdentityPoolTags !== null && { + IdentityPoolTags: serializeAws_json1_1IdentityPoolTagsType(input.IdentityPoolTags, context), + }), + ...(input.OpenIdConnectProviderARNs !== undefined && + input.OpenIdConnectProviderARNs !== null && { + OpenIdConnectProviderARNs: serializeAws_json1_1OIDCProviderList(input.OpenIdConnectProviderARNs, context), + }), + ...(input.SamlProviderARNs !== undefined && + input.SamlProviderARNs !== null && { + SamlProviderARNs: serializeAws_json1_1SAMLProviderList(input.SamlProviderARNs, context), + }), + ...(input.SupportedLoginProviders !== undefined && + input.SupportedLoginProviders !== null && { + SupportedLoginProviders: serializeAws_json1_1IdentityProviders(input.SupportedLoginProviders, context), + }), + }; +}; +const serializeAws_json1_1IdentityPoolTagsListType = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1IdentityPoolTagsType = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_json1_1IdentityProviders = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_json1_1ListIdentitiesInput = (input, context) => { + return { + ...(input.HideDisabled !== undefined && input.HideDisabled !== null && { HideDisabled: input.HideDisabled }), + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + ...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + }; +}; +const serializeAws_json1_1ListIdentityPoolsInput = (input, context) => { + return { + ...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + }; +}; +const serializeAws_json1_1ListTagsForResourceInput = (input, context) => { + return { + ...(input.ResourceArn !== undefined && input.ResourceArn !== null && { ResourceArn: input.ResourceArn }), + }; +}; +const serializeAws_json1_1LoginsList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1LoginsMap = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_json1_1LookupDeveloperIdentityInput = (input, context) => { + return { + ...(input.DeveloperUserIdentifier !== undefined && + input.DeveloperUserIdentifier !== null && { DeveloperUserIdentifier: input.DeveloperUserIdentifier }), + ...(input.IdentityId !== undefined && input.IdentityId !== null && { IdentityId: input.IdentityId }), + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + ...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }), + ...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }), + }; +}; +const serializeAws_json1_1MappingRule = (input, context) => { + return { + ...(input.Claim !== undefined && input.Claim !== null && { Claim: input.Claim }), + ...(input.MatchType !== undefined && input.MatchType !== null && { MatchType: input.MatchType }), + ...(input.RoleARN !== undefined && input.RoleARN !== null && { RoleARN: input.RoleARN }), + ...(input.Value !== undefined && input.Value !== null && { Value: input.Value }), + }; +}; +const serializeAws_json1_1MappingRulesList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_json1_1MappingRule(entry, context); + }); +}; +const serializeAws_json1_1MergeDeveloperIdentitiesInput = (input, context) => { + return { + ...(input.DestinationUserIdentifier !== undefined && + input.DestinationUserIdentifier !== null && { DestinationUserIdentifier: input.DestinationUserIdentifier }), + ...(input.DeveloperProviderName !== undefined && + input.DeveloperProviderName !== null && { DeveloperProviderName: input.DeveloperProviderName }), + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + ...(input.SourceUserIdentifier !== undefined && + input.SourceUserIdentifier !== null && { SourceUserIdentifier: input.SourceUserIdentifier }), + }; +}; +const serializeAws_json1_1OIDCProviderList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1RoleMapping = (input, context) => { + return { + ...(input.AmbiguousRoleResolution !== undefined && + input.AmbiguousRoleResolution !== null && { AmbiguousRoleResolution: input.AmbiguousRoleResolution }), + ...(input.RulesConfiguration !== undefined && + input.RulesConfiguration !== null && { + RulesConfiguration: serializeAws_json1_1RulesConfigurationType(input.RulesConfiguration, context), + }), + ...(input.Type !== undefined && input.Type !== null && { Type: input.Type }), + }; +}; +const serializeAws_json1_1RoleMappingMap = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: serializeAws_json1_1RoleMapping(value, context), + }; + }, {}); +}; +const serializeAws_json1_1RolesMap = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_json1_1RulesConfigurationType = (input, context) => { + return { + ...(input.Rules !== undefined && + input.Rules !== null && { Rules: serializeAws_json1_1MappingRulesList(input.Rules, context) }), + }; +}; +const serializeAws_json1_1SAMLProviderList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_json1_1SetIdentityPoolRolesInput = (input, context) => { + return { + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + ...(input.RoleMappings !== undefined && + input.RoleMappings !== null && { RoleMappings: serializeAws_json1_1RoleMappingMap(input.RoleMappings, context) }), + ...(input.Roles !== undefined && + input.Roles !== null && { Roles: serializeAws_json1_1RolesMap(input.Roles, context) }), + }; +}; +const serializeAws_json1_1TagResourceInput = (input, context) => { + return { + ...(input.ResourceArn !== undefined && input.ResourceArn !== null && { ResourceArn: input.ResourceArn }), + ...(input.Tags !== undefined && + input.Tags !== null && { Tags: serializeAws_json1_1IdentityPoolTagsType(input.Tags, context) }), + }; +}; +const serializeAws_json1_1UnlinkDeveloperIdentityInput = (input, context) => { + return { + ...(input.DeveloperProviderName !== undefined && + input.DeveloperProviderName !== null && { DeveloperProviderName: input.DeveloperProviderName }), + ...(input.DeveloperUserIdentifier !== undefined && + input.DeveloperUserIdentifier !== null && { DeveloperUserIdentifier: input.DeveloperUserIdentifier }), + ...(input.IdentityId !== undefined && input.IdentityId !== null && { IdentityId: input.IdentityId }), + ...(input.IdentityPoolId !== undefined && + input.IdentityPoolId !== null && { IdentityPoolId: input.IdentityPoolId }), + }; +}; +const serializeAws_json1_1UnlinkIdentityInput = (input, context) => { + return { + ...(input.IdentityId !== undefined && input.IdentityId !== null && { IdentityId: input.IdentityId }), + ...(input.Logins !== undefined && + input.Logins !== null && { Logins: serializeAws_json1_1LoginsMap(input.Logins, context) }), + ...(input.LoginsToRemove !== undefined && + input.LoginsToRemove !== null && { + LoginsToRemove: serializeAws_json1_1LoginsList(input.LoginsToRemove, context), + }), + }; +}; +const serializeAws_json1_1UntagResourceInput = (input, context) => { + return { + ...(input.ResourceArn !== undefined && input.ResourceArn !== null && { ResourceArn: input.ResourceArn }), + ...(input.TagKeys !== undefined && + input.TagKeys !== null && { TagKeys: serializeAws_json1_1IdentityPoolTagsListType(input.TagKeys, context) }), + }; +}; +const deserializeAws_json1_1CognitoIdentityProvider = (output, context) => { + return { + ClientId: output.ClientId !== undefined && output.ClientId !== null ? output.ClientId : undefined, + ProviderName: output.ProviderName !== undefined && output.ProviderName !== null ? output.ProviderName : undefined, + ServerSideTokenCheck: output.ServerSideTokenCheck !== undefined && output.ServerSideTokenCheck !== null + ? output.ServerSideTokenCheck + : undefined, + }; +}; +const deserializeAws_json1_1CognitoIdentityProviderList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1CognitoIdentityProvider(entry, context); + }); +}; +const deserializeAws_json1_1ConcurrentModificationException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1Credentials = (output, context) => { + return { + AccessKeyId: output.AccessKeyId !== undefined && output.AccessKeyId !== null ? output.AccessKeyId : undefined, + Expiration: output.Expiration !== undefined && output.Expiration !== null + ? new Date(Math.round(output.Expiration * 1000)) + : undefined, + SecretKey: output.SecretKey !== undefined && output.SecretKey !== null ? output.SecretKey : undefined, + SessionToken: output.SessionToken !== undefined && output.SessionToken !== null ? output.SessionToken : undefined, + }; +}; +const deserializeAws_json1_1DeleteIdentitiesResponse = (output, context) => { + return { + UnprocessedIdentityIds: output.UnprocessedIdentityIds !== undefined && output.UnprocessedIdentityIds !== null + ? deserializeAws_json1_1UnprocessedIdentityIdList(output.UnprocessedIdentityIds, context) + : undefined, + }; +}; +const deserializeAws_json1_1DeveloperUserAlreadyRegisteredException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1DeveloperUserIdentifierList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1ExternalServiceException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1GetCredentialsForIdentityResponse = (output, context) => { + return { + Credentials: output.Credentials !== undefined && output.Credentials !== null + ? deserializeAws_json1_1Credentials(output.Credentials, context) + : undefined, + IdentityId: output.IdentityId !== undefined && output.IdentityId !== null ? output.IdentityId : undefined, + }; +}; +const deserializeAws_json1_1GetIdentityPoolRolesResponse = (output, context) => { + return { + IdentityPoolId: output.IdentityPoolId !== undefined && output.IdentityPoolId !== null ? output.IdentityPoolId : undefined, + RoleMappings: output.RoleMappings !== undefined && output.RoleMappings !== null + ? deserializeAws_json1_1RoleMappingMap(output.RoleMappings, context) + : undefined, + Roles: output.Roles !== undefined && output.Roles !== null + ? deserializeAws_json1_1RolesMap(output.Roles, context) + : undefined, + }; +}; +const deserializeAws_json1_1GetIdResponse = (output, context) => { + return { + IdentityId: output.IdentityId !== undefined && output.IdentityId !== null ? output.IdentityId : undefined, + }; +}; +const deserializeAws_json1_1GetOpenIdTokenForDeveloperIdentityResponse = (output, context) => { + return { + IdentityId: output.IdentityId !== undefined && output.IdentityId !== null ? output.IdentityId : undefined, + Token: output.Token !== undefined && output.Token !== null ? output.Token : undefined, + }; +}; +const deserializeAws_json1_1GetOpenIdTokenResponse = (output, context) => { + return { + IdentityId: output.IdentityId !== undefined && output.IdentityId !== null ? output.IdentityId : undefined, + Token: output.Token !== undefined && output.Token !== null ? output.Token : undefined, + }; +}; +const deserializeAws_json1_1IdentitiesList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1IdentityDescription(entry, context); + }); +}; +const deserializeAws_json1_1IdentityDescription = (output, context) => { + return { + CreationDate: output.CreationDate !== undefined && output.CreationDate !== null + ? new Date(Math.round(output.CreationDate * 1000)) + : undefined, + IdentityId: output.IdentityId !== undefined && output.IdentityId !== null ? output.IdentityId : undefined, + LastModifiedDate: output.LastModifiedDate !== undefined && output.LastModifiedDate !== null + ? new Date(Math.round(output.LastModifiedDate * 1000)) + : undefined, + Logins: output.Logins !== undefined && output.Logins !== null + ? deserializeAws_json1_1LoginsList(output.Logins, context) + : undefined, + }; +}; +const deserializeAws_json1_1IdentityPool = (output, context) => { + return { + AllowClassicFlow: output.AllowClassicFlow !== undefined && output.AllowClassicFlow !== null ? output.AllowClassicFlow : undefined, + AllowUnauthenticatedIdentities: output.AllowUnauthenticatedIdentities !== undefined && output.AllowUnauthenticatedIdentities !== null + ? output.AllowUnauthenticatedIdentities + : undefined, + CognitoIdentityProviders: output.CognitoIdentityProviders !== undefined && output.CognitoIdentityProviders !== null + ? deserializeAws_json1_1CognitoIdentityProviderList(output.CognitoIdentityProviders, context) + : undefined, + DeveloperProviderName: output.DeveloperProviderName !== undefined && output.DeveloperProviderName !== null + ? output.DeveloperProviderName + : undefined, + IdentityPoolId: output.IdentityPoolId !== undefined && output.IdentityPoolId !== null ? output.IdentityPoolId : undefined, + IdentityPoolName: output.IdentityPoolName !== undefined && output.IdentityPoolName !== null ? output.IdentityPoolName : undefined, + IdentityPoolTags: output.IdentityPoolTags !== undefined && output.IdentityPoolTags !== null + ? deserializeAws_json1_1IdentityPoolTagsType(output.IdentityPoolTags, context) + : undefined, + OpenIdConnectProviderARNs: output.OpenIdConnectProviderARNs !== undefined && output.OpenIdConnectProviderARNs !== null + ? deserializeAws_json1_1OIDCProviderList(output.OpenIdConnectProviderARNs, context) + : undefined, + SamlProviderARNs: output.SamlProviderARNs !== undefined && output.SamlProviderARNs !== null + ? deserializeAws_json1_1SAMLProviderList(output.SamlProviderARNs, context) + : undefined, + SupportedLoginProviders: output.SupportedLoginProviders !== undefined && output.SupportedLoginProviders !== null + ? deserializeAws_json1_1IdentityProviders(output.SupportedLoginProviders, context) + : undefined, + }; +}; +const deserializeAws_json1_1IdentityPoolShortDescription = (output, context) => { + return { + IdentityPoolId: output.IdentityPoolId !== undefined && output.IdentityPoolId !== null ? output.IdentityPoolId : undefined, + IdentityPoolName: output.IdentityPoolName !== undefined && output.IdentityPoolName !== null ? output.IdentityPoolName : undefined, + }; +}; +const deserializeAws_json1_1IdentityPoolsList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1IdentityPoolShortDescription(entry, context); + }); +}; +const deserializeAws_json1_1IdentityPoolTagsType = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_json1_1IdentityProviders = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_json1_1InternalErrorException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1InvalidIdentityPoolConfigurationException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1InvalidParameterException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1LimitExceededException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1ListIdentitiesResponse = (output, context) => { + return { + Identities: output.Identities !== undefined && output.Identities !== null + ? deserializeAws_json1_1IdentitiesList(output.Identities, context) + : undefined, + IdentityPoolId: output.IdentityPoolId !== undefined && output.IdentityPoolId !== null ? output.IdentityPoolId : undefined, + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + }; +}; +const deserializeAws_json1_1ListIdentityPoolsResponse = (output, context) => { + return { + IdentityPools: output.IdentityPools !== undefined && output.IdentityPools !== null + ? deserializeAws_json1_1IdentityPoolsList(output.IdentityPools, context) + : undefined, + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + }; +}; +const deserializeAws_json1_1ListTagsForResourceResponse = (output, context) => { + return { + Tags: output.Tags !== undefined && output.Tags !== null + ? deserializeAws_json1_1IdentityPoolTagsType(output.Tags, context) + : undefined, + }; +}; +const deserializeAws_json1_1LoginsList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1LookupDeveloperIdentityResponse = (output, context) => { + return { + DeveloperUserIdentifierList: output.DeveloperUserIdentifierList !== undefined && output.DeveloperUserIdentifierList !== null + ? deserializeAws_json1_1DeveloperUserIdentifierList(output.DeveloperUserIdentifierList, context) + : undefined, + IdentityId: output.IdentityId !== undefined && output.IdentityId !== null ? output.IdentityId : undefined, + NextToken: output.NextToken !== undefined && output.NextToken !== null ? output.NextToken : undefined, + }; +}; +const deserializeAws_json1_1MappingRule = (output, context) => { + return { + Claim: output.Claim !== undefined && output.Claim !== null ? output.Claim : undefined, + MatchType: output.MatchType !== undefined && output.MatchType !== null ? output.MatchType : undefined, + RoleARN: output.RoleARN !== undefined && output.RoleARN !== null ? output.RoleARN : undefined, + Value: output.Value !== undefined && output.Value !== null ? output.Value : undefined, + }; +}; +const deserializeAws_json1_1MappingRulesList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1MappingRule(entry, context); + }); +}; +const deserializeAws_json1_1MergeDeveloperIdentitiesResponse = (output, context) => { + return { + IdentityId: output.IdentityId !== undefined && output.IdentityId !== null ? output.IdentityId : undefined, + }; +}; +const deserializeAws_json1_1NotAuthorizedException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1OIDCProviderList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1ResourceConflictException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1ResourceNotFoundException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1RoleMapping = (output, context) => { + return { + AmbiguousRoleResolution: output.AmbiguousRoleResolution !== undefined && output.AmbiguousRoleResolution !== null + ? output.AmbiguousRoleResolution + : undefined, + RulesConfiguration: output.RulesConfiguration !== undefined && output.RulesConfiguration !== null + ? deserializeAws_json1_1RulesConfigurationType(output.RulesConfiguration, context) + : undefined, + Type: output.Type !== undefined && output.Type !== null ? output.Type : undefined, + }; +}; +const deserializeAws_json1_1RoleMappingMap = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: deserializeAws_json1_1RoleMapping(value, context), + }; + }, {}); +}; +const deserializeAws_json1_1RolesMap = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_json1_1RulesConfigurationType = (output, context) => { + return { + Rules: output.Rules !== undefined && output.Rules !== null + ? deserializeAws_json1_1MappingRulesList(output.Rules, context) + : undefined, + }; +}; +const deserializeAws_json1_1SAMLProviderList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_json1_1TagResourceResponse = (output, context) => { + return {}; +}; +const deserializeAws_json1_1TooManyRequestsException = (output, context) => { + return { + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_json1_1UnprocessedIdentityId = (output, context) => { + return { + ErrorCode: output.ErrorCode !== undefined && output.ErrorCode !== null ? output.ErrorCode : undefined, + IdentityId: output.IdentityId !== undefined && output.IdentityId !== null ? output.IdentityId : undefined, + }; +}; +const deserializeAws_json1_1UnprocessedIdentityIdList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_json1_1UnprocessedIdentityId(entry, context); + }); +}; +const deserializeAws_json1_1UntagResourceResponse = (output, context) => { + return {}; +}; +const deserializeMetadata = (output) => { + var _a; + return ({ + httpStatusCode: output.statusCode, + requestId: (_a = output.headers["x-amzn-requestid"]) !== null && _a !== void 0 ? _a : output.headers["x-amzn-request-id"], + extendedRequestId: output.headers["x-amz-id-2"], + cfId: output.headers["x-amz-cf-id"], + }); +}; +// Collect low-level response body stream to Uint8Array. +const collectBody = (streamBody = new Uint8Array(), context) => { + if (streamBody instanceof Uint8Array) { + return Promise.resolve(streamBody); + } + return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array()); +}; +// Encode Uint8Array data into string with utf-8. +const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body)); +const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => { + const { hostname, protocol = "https", port } = await context.endpoint(); + const contents = { + protocol, + hostname, + port, + method: "POST", + path, + headers, + }; + if (resolvedHostname !== undefined) { + contents.hostname = resolvedHostname; + } + if (body !== undefined) { + contents.body = body; + } + return new protocol_http_1.HttpRequest(contents); +}; +const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => { + if (encoded.length) { + return JSON.parse(encoded); + } + return {}; +}); +/** + * Load an error code for the aws.rest-json-1.1 protocol. + */ +const loadRestJsonErrorCode = (output, data) => { + const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase()); + const sanitizeErrorCode = (rawValue) => { + let cleanValue = rawValue; + if (cleanValue.indexOf(":") >= 0) { + cleanValue = cleanValue.split(":")[0]; + } + if (cleanValue.indexOf("#") >= 0) { + cleanValue = cleanValue.split("#")[1]; + } + return cleanValue; + }; + const headerKey = findKey(output.headers, "x-amzn-errortype"); + if (headerKey !== undefined) { + return sanitizeErrorCode(output.headers[headerKey]); + } + if (data.code !== undefined) { + return sanitizeErrorCode(data.code); + } + if (data["__type"] !== undefined) { + return sanitizeErrorCode(data["__type"]); + } + return ""; +}; +//# sourceMappingURL=Aws_json1_1.js.map + +/***/ }), + +/***/ 11407: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ClientDefaultValues = void 0; +const tslib_1 = __nccwpck_require__(57088); +const package_json_1 = tslib_1.__importDefault(__nccwpck_require__(67367)); +const config_resolver_1 = __nccwpck_require__(87229); +const credential_provider_node_1 = __nccwpck_require__(98030); +const hash_node_1 = __nccwpck_require__(90791); +const middleware_retry_1 = __nccwpck_require__(7000); +const node_config_provider_1 = __nccwpck_require__(71124); +const node_http_handler_1 = __nccwpck_require__(15168); +const util_base64_node_1 = __nccwpck_require__(2091); +const util_body_length_node_1 = __nccwpck_require__(40286); +const util_user_agent_node_1 = __nccwpck_require__(64717); +const util_utf8_node_1 = __nccwpck_require__(85227); +const runtimeConfig_shared_1 = __nccwpck_require__(59013); +/** + * @internal + */ +exports.ClientDefaultValues = { + ...runtimeConfig_shared_1.ClientSharedValues, + runtime: "node", + base64Decoder: util_base64_node_1.fromBase64, + base64Encoder: util_base64_node_1.toBase64, + bodyLengthChecker: util_body_length_node_1.calculateBodyLength, + credentialDefaultProvider: credential_provider_node_1.defaultProvider, + defaultUserAgentProvider: util_user_agent_node_1.defaultUserAgent({ + serviceId: runtimeConfig_shared_1.ClientSharedValues.serviceId, + clientVersion: package_json_1.default.version, + }), + maxAttempts: node_config_provider_1.loadConfig(middleware_retry_1.NODE_MAX_ATTEMPT_CONFIG_OPTIONS), + region: node_config_provider_1.loadConfig(config_resolver_1.NODE_REGION_CONFIG_OPTIONS, config_resolver_1.NODE_REGION_CONFIG_FILE_OPTIONS), + requestHandler: new node_http_handler_1.NodeHttpHandler(), + sha256: hash_node_1.Hash.bind(null, "sha256"), + streamCollector: node_http_handler_1.streamCollector, + utf8Decoder: util_utf8_node_1.fromUtf8, + utf8Encoder: util_utf8_node_1.toUtf8, +}; +//# sourceMappingURL=runtimeConfig.js.map + +/***/ }), + +/***/ 59013: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ClientSharedValues = void 0; +const endpoints_1 = __nccwpck_require__(43366); +const url_parser_1 = __nccwpck_require__(99427); +/** + * @internal + */ +exports.ClientSharedValues = { + apiVersion: "2014-06-30", + disableHostPrefix: false, + logger: {}, + regionInfoProvider: endpoints_1.defaultRegionInfoProvider, + serviceId: "Cognito Identity", + urlParser: url_parser_1.parseUrl, +}; +//# sourceMappingURL=runtimeConfig.shared.js.map + +/***/ }), + +/***/ 57088: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +__nccwpck_require__.r(__webpack_exports__); +/* harmony export */ __nccwpck_require__.d(__webpack_exports__, { +/* harmony export */ "__extends": () => /* binding */ __extends, +/* harmony export */ "__assign": () => /* binding */ __assign, +/* harmony export */ "__rest": () => /* binding */ __rest, +/* harmony export */ "__decorate": () => /* binding */ __decorate, +/* harmony export */ "__param": () => /* binding */ __param, +/* harmony export */ "__metadata": () => /* binding */ __metadata, +/* harmony export */ "__awaiter": () => /* binding */ __awaiter, +/* harmony export */ "__generator": () => /* binding */ __generator, +/* harmony export */ "__createBinding": () => /* binding */ __createBinding, +/* harmony export */ "__exportStar": () => /* binding */ __exportStar, +/* harmony export */ "__values": () => /* binding */ __values, +/* harmony export */ "__read": () => /* binding */ __read, +/* harmony export */ "__spread": () => /* binding */ __spread, +/* harmony export */ "__spreadArrays": () => /* binding */ __spreadArrays, +/* harmony export */ "__spreadArray": () => /* binding */ __spreadArray, +/* harmony export */ "__await": () => /* binding */ __await, +/* harmony export */ "__asyncGenerator": () => /* binding */ __asyncGenerator, +/* harmony export */ "__asyncDelegator": () => /* binding */ __asyncDelegator, +/* harmony export */ "__asyncValues": () => /* binding */ __asyncValues, +/* harmony export */ "__makeTemplateObject": () => /* binding */ __makeTemplateObject, +/* harmony export */ "__importStar": () => /* binding */ __importStar, +/* harmony export */ "__importDefault": () => /* binding */ __importDefault, +/* harmony export */ "__classPrivateFieldGet": () => /* binding */ __classPrivateFieldGet, +/* harmony export */ "__classPrivateFieldSet": () => /* binding */ __classPrivateFieldSet +/* harmony export */ }); +/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. +***************************************************************************** */ +/* global Reflect, Promise */ + +var extendStatics = function(d, b) { + extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; + return extendStatics(d, b); +}; + +function __extends(d, b) { + if (typeof b !== "function" && b !== null) + throw new TypeError("Class extends value " + String(b) + " is not a constructor or null"); + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +} + +var __assign = function() { + __assign = Object.assign || function __assign(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p]; + } + return t; + } + return __assign.apply(this, arguments); +} + +function __rest(s, e) { + var t = {}; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) + t[p] = s[p]; + if (s != null && typeof Object.getOwnPropertySymbols === "function") + for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { + if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) + t[p[i]] = s[p[i]]; + } + return t; +} + +function __decorate(decorators, target, key, desc) { + var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; + if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); + else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; + return c > 3 && r && Object.defineProperty(target, key, r), r; +} + +function __param(paramIndex, decorator) { + return function (target, key) { decorator(target, key, paramIndex); } +} + +function __metadata(metadataKey, metadataValue) { + if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue); +} + +function __awaiter(thisArg, _arguments, P, generator) { + function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } + return new (P || (P = Promise))(function (resolve, reject) { + function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } + function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } + function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + step((generator = generator.apply(thisArg, _arguments || [])).next()); + }); +} + +function __generator(thisArg, body) { + var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g; + return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g; + function verb(n) { return function (v) { return step([n, v]); }; } + function step(op) { + if (f) throw new TypeError("Generator is already executing."); + while (_) try { + if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t; + if (y = 0, t) op = [op[0] & 2, t.value]; + switch (op[0]) { + case 0: case 1: t = op; break; + case 4: _.label++; return { value: op[1], done: false }; + case 5: _.label++; y = op[1]; op = [0]; continue; + case 7: op = _.ops.pop(); _.trys.pop(); continue; + default: + if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; } + if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; } + if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; } + if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; } + if (t[2]) _.ops.pop(); + _.trys.pop(); continue; + } + op = body.call(thisArg, _); + } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; } + if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true }; + } +} + +var __createBinding = Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +}); + +function __exportStar(m, o) { + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p); +} + +function __values(o) { + var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0; + if (m) return m.call(o); + if (o && typeof o.length === "number") return { + next: function () { + if (o && i >= o.length) o = void 0; + return { value: o && o[i++], done: !o }; + } + }; + throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined."); +} + +function __read(o, n) { + var m = typeof Symbol === "function" && o[Symbol.iterator]; + if (!m) return o; + var i = m.call(o), r, ar = [], e; + try { + while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value); + } + catch (error) { e = { error: error }; } + finally { + try { + if (r && !r.done && (m = i["return"])) m.call(i); + } + finally { if (e) throw e.error; } + } + return ar; +} + +/** @deprecated */ +function __spread() { + for (var ar = [], i = 0; i < arguments.length; i++) + ar = ar.concat(__read(arguments[i])); + return ar; +} + +/** @deprecated */ +function __spreadArrays() { + for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length; + for (var r = Array(s), k = 0, i = 0; i < il; i++) + for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++) + r[k] = a[j]; + return r; +} + +function __spreadArray(to, from) { + for (var i = 0, il = from.length, j = to.length; i < il; i++, j++) + to[j] = from[i]; + return to; +} + +function __await(v) { + return this instanceof __await ? (this.v = v, this) : new __await(v); +} + +function __asyncGenerator(thisArg, _arguments, generator) { + if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined."); + var g = generator.apply(thisArg, _arguments || []), i, q = []; + return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i; + function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; } + function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } } + function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); } + function fulfill(value) { resume("next", value); } + function reject(value) { resume("throw", value); } + function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); } +} + +function __asyncDelegator(o) { + var i, p; + return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i; + function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; } +} + +function __asyncValues(o) { + if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined."); + var m = o[Symbol.asyncIterator], i; + return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i); + function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; } + function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); } +} + +function __makeTemplateObject(cooked, raw) { + if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; } + return cooked; +}; + +var __setModuleDefault = Object.create ? (function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); +}) : function(o, v) { + o["default"] = v; +}; + +function __importStar(mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + __setModuleDefault(result, mod); + return result; +} + +function __importDefault(mod) { + return (mod && mod.__esModule) ? mod : { default: mod }; +} + +function __classPrivateFieldGet(receiver, privateMap) { + if (!privateMap.has(receiver)) { + throw new TypeError("attempted to get private field on non-instance"); + } + return privateMap.get(receiver); +} + +function __classPrivateFieldSet(receiver, privateMap, value) { + if (!privateMap.has(receiver)) { + throw new TypeError("attempted to set private field on non-instance"); + } + privateMap.set(receiver, value); + return value; +} + + +/***/ }), + +/***/ 37811: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.IoT = void 0; +const IoTClient_1 = __nccwpck_require__(31450); +const AcceptCertificateTransferCommand_1 = __nccwpck_require__(56298); +const AddThingToBillingGroupCommand_1 = __nccwpck_require__(50444); +const AddThingToThingGroupCommand_1 = __nccwpck_require__(70565); +const AssociateTargetsWithJobCommand_1 = __nccwpck_require__(35126); +const AttachPolicyCommand_1 = __nccwpck_require__(90420); +const AttachPrincipalPolicyCommand_1 = __nccwpck_require__(4077); +const AttachSecurityProfileCommand_1 = __nccwpck_require__(36378); +const AttachThingPrincipalCommand_1 = __nccwpck_require__(92532); +const CancelAuditMitigationActionsTaskCommand_1 = __nccwpck_require__(84); +const CancelAuditTaskCommand_1 = __nccwpck_require__(58801); +const CancelCertificateTransferCommand_1 = __nccwpck_require__(69974); +const CancelJobCommand_1 = __nccwpck_require__(62205); +const CancelJobExecutionCommand_1 = __nccwpck_require__(21972); +const ClearDefaultAuthorizerCommand_1 = __nccwpck_require__(97176); +const ConfirmTopicRuleDestinationCommand_1 = __nccwpck_require__(83239); +const CreateAuditSuppressionCommand_1 = __nccwpck_require__(27690); +const CreateAuthorizerCommand_1 = __nccwpck_require__(57959); +const CreateBillingGroupCommand_1 = __nccwpck_require__(81102); +const CreateCertificateFromCsrCommand_1 = __nccwpck_require__(26470); +const CreateDimensionCommand_1 = __nccwpck_require__(71146); +const CreateDomainConfigurationCommand_1 = __nccwpck_require__(18664); +const CreateDynamicThingGroupCommand_1 = __nccwpck_require__(22271); +const CreateJobCommand_1 = __nccwpck_require__(14059); +const CreateKeysAndCertificateCommand_1 = __nccwpck_require__(4848); +const CreateMitigationActionCommand_1 = __nccwpck_require__(19583); +const CreateOTAUpdateCommand_1 = __nccwpck_require__(45447); +const CreatePolicyCommand_1 = __nccwpck_require__(35362); +const CreatePolicyVersionCommand_1 = __nccwpck_require__(72718); +const CreateProvisioningClaimCommand_1 = __nccwpck_require__(38826); +const CreateProvisioningTemplateCommand_1 = __nccwpck_require__(79093); +const CreateProvisioningTemplateVersionCommand_1 = __nccwpck_require__(28951); +const CreateRoleAliasCommand_1 = __nccwpck_require__(78443); +const CreateScheduledAuditCommand_1 = __nccwpck_require__(6809); +const CreateSecurityProfileCommand_1 = __nccwpck_require__(56822); +const CreateStreamCommand_1 = __nccwpck_require__(312); +const CreateThingCommand_1 = __nccwpck_require__(60949); +const CreateThingGroupCommand_1 = __nccwpck_require__(99585); +const CreateThingTypeCommand_1 = __nccwpck_require__(76406); +const CreateTopicRuleCommand_1 = __nccwpck_require__(96982); +const CreateTopicRuleDestinationCommand_1 = __nccwpck_require__(15724); +const DeleteAccountAuditConfigurationCommand_1 = __nccwpck_require__(4430); +const DeleteAuditSuppressionCommand_1 = __nccwpck_require__(90704); +const DeleteAuthorizerCommand_1 = __nccwpck_require__(32183); +const DeleteBillingGroupCommand_1 = __nccwpck_require__(56409); +const DeleteCACertificateCommand_1 = __nccwpck_require__(73697); +const DeleteCertificateCommand_1 = __nccwpck_require__(63911); +const DeleteDimensionCommand_1 = __nccwpck_require__(91697); +const DeleteDomainConfigurationCommand_1 = __nccwpck_require__(38666); +const DeleteDynamicThingGroupCommand_1 = __nccwpck_require__(17557); +const DeleteJobCommand_1 = __nccwpck_require__(22855); +const DeleteJobExecutionCommand_1 = __nccwpck_require__(39671); +const DeleteMitigationActionCommand_1 = __nccwpck_require__(45947); +const DeleteOTAUpdateCommand_1 = __nccwpck_require__(52941); +const DeletePolicyCommand_1 = __nccwpck_require__(26106); +const DeletePolicyVersionCommand_1 = __nccwpck_require__(67779); +const DeleteProvisioningTemplateCommand_1 = __nccwpck_require__(11659); +const DeleteProvisioningTemplateVersionCommand_1 = __nccwpck_require__(37562); +const DeleteRegistrationCodeCommand_1 = __nccwpck_require__(23235); +const DeleteRoleAliasCommand_1 = __nccwpck_require__(42187); +const DeleteScheduledAuditCommand_1 = __nccwpck_require__(61685); +const DeleteSecurityProfileCommand_1 = __nccwpck_require__(77857); +const DeleteStreamCommand_1 = __nccwpck_require__(68349); +const DeleteThingCommand_1 = __nccwpck_require__(31281); +const DeleteThingGroupCommand_1 = __nccwpck_require__(73451); +const DeleteThingTypeCommand_1 = __nccwpck_require__(36024); +const DeleteTopicRuleCommand_1 = __nccwpck_require__(32270); +const DeleteTopicRuleDestinationCommand_1 = __nccwpck_require__(62838); +const DeleteV2LoggingLevelCommand_1 = __nccwpck_require__(35964); +const DeprecateThingTypeCommand_1 = __nccwpck_require__(13748); +const DescribeAccountAuditConfigurationCommand_1 = __nccwpck_require__(13811); +const DescribeAuditFindingCommand_1 = __nccwpck_require__(91538); +const DescribeAuditMitigationActionsTaskCommand_1 = __nccwpck_require__(16532); +const DescribeAuditSuppressionCommand_1 = __nccwpck_require__(84970); +const DescribeAuditTaskCommand_1 = __nccwpck_require__(74328); +const DescribeAuthorizerCommand_1 = __nccwpck_require__(85629); +const DescribeBillingGroupCommand_1 = __nccwpck_require__(40564); +const DescribeCACertificateCommand_1 = __nccwpck_require__(42279); +const DescribeCertificateCommand_1 = __nccwpck_require__(78585); +const DescribeDefaultAuthorizerCommand_1 = __nccwpck_require__(68623); +const DescribeDimensionCommand_1 = __nccwpck_require__(46755); +const DescribeDomainConfigurationCommand_1 = __nccwpck_require__(83673); +const DescribeEndpointCommand_1 = __nccwpck_require__(77554); +const DescribeEventConfigurationsCommand_1 = __nccwpck_require__(87665); +const DescribeIndexCommand_1 = __nccwpck_require__(77948); +const DescribeJobCommand_1 = __nccwpck_require__(28980); +const DescribeJobExecutionCommand_1 = __nccwpck_require__(65547); +const DescribeMitigationActionCommand_1 = __nccwpck_require__(1175); +const DescribeProvisioningTemplateCommand_1 = __nccwpck_require__(44539); +const DescribeProvisioningTemplateVersionCommand_1 = __nccwpck_require__(34488); +const DescribeRoleAliasCommand_1 = __nccwpck_require__(44504); +const DescribeScheduledAuditCommand_1 = __nccwpck_require__(61131); +const DescribeSecurityProfileCommand_1 = __nccwpck_require__(22237); +const DescribeStreamCommand_1 = __nccwpck_require__(90953); +const DescribeThingCommand_1 = __nccwpck_require__(44526); +const DescribeThingGroupCommand_1 = __nccwpck_require__(19878); +const DescribeThingRegistrationTaskCommand_1 = __nccwpck_require__(83198); +const DescribeThingTypeCommand_1 = __nccwpck_require__(50780); +const DetachPolicyCommand_1 = __nccwpck_require__(17402); +const DetachPrincipalPolicyCommand_1 = __nccwpck_require__(7189); +const DetachSecurityProfileCommand_1 = __nccwpck_require__(9688); +const DetachThingPrincipalCommand_1 = __nccwpck_require__(71366); +const DisableTopicRuleCommand_1 = __nccwpck_require__(79248); +const EnableTopicRuleCommand_1 = __nccwpck_require__(83282); +const GetCardinalityCommand_1 = __nccwpck_require__(19687); +const GetEffectivePoliciesCommand_1 = __nccwpck_require__(51757); +const GetIndexingConfigurationCommand_1 = __nccwpck_require__(189); +const GetJobDocumentCommand_1 = __nccwpck_require__(91665); +const GetLoggingOptionsCommand_1 = __nccwpck_require__(57429); +const GetOTAUpdateCommand_1 = __nccwpck_require__(24694); +const GetPercentilesCommand_1 = __nccwpck_require__(33048); +const GetPolicyCommand_1 = __nccwpck_require__(22965); +const GetPolicyVersionCommand_1 = __nccwpck_require__(51843); +const GetRegistrationCodeCommand_1 = __nccwpck_require__(22069); +const GetStatisticsCommand_1 = __nccwpck_require__(36408); +const GetTopicRuleCommand_1 = __nccwpck_require__(82246); +const GetTopicRuleDestinationCommand_1 = __nccwpck_require__(93616); +const GetV2LoggingOptionsCommand_1 = __nccwpck_require__(23036); +const ListActiveViolationsCommand_1 = __nccwpck_require__(90886); +const ListAttachedPoliciesCommand_1 = __nccwpck_require__(59388); +const ListAuditFindingsCommand_1 = __nccwpck_require__(55133); +const ListAuditMitigationActionsExecutionsCommand_1 = __nccwpck_require__(35836); +const ListAuditMitigationActionsTasksCommand_1 = __nccwpck_require__(45704); +const ListAuditSuppressionsCommand_1 = __nccwpck_require__(60827); +const ListAuditTasksCommand_1 = __nccwpck_require__(50108); +const ListAuthorizersCommand_1 = __nccwpck_require__(99389); +const ListBillingGroupsCommand_1 = __nccwpck_require__(13648); +const ListCACertificatesCommand_1 = __nccwpck_require__(77650); +const ListCertificatesByCACommand_1 = __nccwpck_require__(23163); +const ListCertificatesCommand_1 = __nccwpck_require__(14749); +const ListDimensionsCommand_1 = __nccwpck_require__(74775); +const ListDomainConfigurationsCommand_1 = __nccwpck_require__(75947); +const ListIndicesCommand_1 = __nccwpck_require__(36240); +const ListJobExecutionsForJobCommand_1 = __nccwpck_require__(68068); +const ListJobExecutionsForThingCommand_1 = __nccwpck_require__(20874); +const ListJobsCommand_1 = __nccwpck_require__(25341); +const ListMitigationActionsCommand_1 = __nccwpck_require__(93159); +const ListOTAUpdatesCommand_1 = __nccwpck_require__(76188); +const ListOutgoingCertificatesCommand_1 = __nccwpck_require__(90321); +const ListPoliciesCommand_1 = __nccwpck_require__(81192); +const ListPolicyPrincipalsCommand_1 = __nccwpck_require__(86657); +const ListPolicyVersionsCommand_1 = __nccwpck_require__(21085); +const ListPrincipalPoliciesCommand_1 = __nccwpck_require__(3702); +const ListPrincipalThingsCommand_1 = __nccwpck_require__(62558); +const ListProvisioningTemplateVersionsCommand_1 = __nccwpck_require__(48529); +const ListProvisioningTemplatesCommand_1 = __nccwpck_require__(59524); +const ListRoleAliasesCommand_1 = __nccwpck_require__(31543); +const ListScheduledAuditsCommand_1 = __nccwpck_require__(79905); +const ListSecurityProfilesCommand_1 = __nccwpck_require__(17473); +const ListSecurityProfilesForTargetCommand_1 = __nccwpck_require__(26323); +const ListStreamsCommand_1 = __nccwpck_require__(76326); +const ListTagsForResourceCommand_1 = __nccwpck_require__(87749); +const ListTargetsForPolicyCommand_1 = __nccwpck_require__(71438); +const ListTargetsForSecurityProfileCommand_1 = __nccwpck_require__(47470); +const ListThingGroupsCommand_1 = __nccwpck_require__(59885); +const ListThingGroupsForThingCommand_1 = __nccwpck_require__(532); +const ListThingPrincipalsCommand_1 = __nccwpck_require__(18466); +const ListThingRegistrationTaskReportsCommand_1 = __nccwpck_require__(31905); +const ListThingRegistrationTasksCommand_1 = __nccwpck_require__(74999); +const ListThingTypesCommand_1 = __nccwpck_require__(28092); +const ListThingsCommand_1 = __nccwpck_require__(1243); +const ListThingsInBillingGroupCommand_1 = __nccwpck_require__(51357); +const ListThingsInThingGroupCommand_1 = __nccwpck_require__(33672); +const ListTopicRuleDestinationsCommand_1 = __nccwpck_require__(29621); +const ListTopicRulesCommand_1 = __nccwpck_require__(2823); +const ListV2LoggingLevelsCommand_1 = __nccwpck_require__(47492); +const ListViolationEventsCommand_1 = __nccwpck_require__(77560); +const RegisterCACertificateCommand_1 = __nccwpck_require__(97568); +const RegisterCertificateCommand_1 = __nccwpck_require__(59389); +const RegisterCertificateWithoutCACommand_1 = __nccwpck_require__(69343); +const RegisterThingCommand_1 = __nccwpck_require__(35331); +const RejectCertificateTransferCommand_1 = __nccwpck_require__(75265); +const RemoveThingFromBillingGroupCommand_1 = __nccwpck_require__(98700); +const RemoveThingFromThingGroupCommand_1 = __nccwpck_require__(47706); +const ReplaceTopicRuleCommand_1 = __nccwpck_require__(22174); +const SearchIndexCommand_1 = __nccwpck_require__(8101); +const SetDefaultAuthorizerCommand_1 = __nccwpck_require__(47153); +const SetDefaultPolicyVersionCommand_1 = __nccwpck_require__(93486); +const SetLoggingOptionsCommand_1 = __nccwpck_require__(74975); +const SetV2LoggingLevelCommand_1 = __nccwpck_require__(63248); +const SetV2LoggingOptionsCommand_1 = __nccwpck_require__(56768); +const StartAuditMitigationActionsTaskCommand_1 = __nccwpck_require__(67796); +const StartOnDemandAuditTaskCommand_1 = __nccwpck_require__(37467); +const StartThingRegistrationTaskCommand_1 = __nccwpck_require__(47587); +const StopThingRegistrationTaskCommand_1 = __nccwpck_require__(84000); +const TagResourceCommand_1 = __nccwpck_require__(94545); +const TestAuthorizationCommand_1 = __nccwpck_require__(31855); +const TestInvokeAuthorizerCommand_1 = __nccwpck_require__(21145); +const TransferCertificateCommand_1 = __nccwpck_require__(96463); +const UntagResourceCommand_1 = __nccwpck_require__(15850); +const UpdateAccountAuditConfigurationCommand_1 = __nccwpck_require__(12283); +const UpdateAuditSuppressionCommand_1 = __nccwpck_require__(13125); +const UpdateAuthorizerCommand_1 = __nccwpck_require__(27955); +const UpdateBillingGroupCommand_1 = __nccwpck_require__(14430); +const UpdateCACertificateCommand_1 = __nccwpck_require__(18036); +const UpdateCertificateCommand_1 = __nccwpck_require__(30885); +const UpdateDimensionCommand_1 = __nccwpck_require__(52162); +const UpdateDomainConfigurationCommand_1 = __nccwpck_require__(89212); +const UpdateDynamicThingGroupCommand_1 = __nccwpck_require__(39452); +const UpdateEventConfigurationsCommand_1 = __nccwpck_require__(90134); +const UpdateIndexingConfigurationCommand_1 = __nccwpck_require__(40352); +const UpdateJobCommand_1 = __nccwpck_require__(22654); +const UpdateMitigationActionCommand_1 = __nccwpck_require__(57468); +const UpdateProvisioningTemplateCommand_1 = __nccwpck_require__(72154); +const UpdateRoleAliasCommand_1 = __nccwpck_require__(47584); +const UpdateScheduledAuditCommand_1 = __nccwpck_require__(45277); +const UpdateSecurityProfileCommand_1 = __nccwpck_require__(21654); +const UpdateStreamCommand_1 = __nccwpck_require__(98689); +const UpdateThingCommand_1 = __nccwpck_require__(51903); +const UpdateThingGroupCommand_1 = __nccwpck_require__(46410); +const UpdateThingGroupsForThingCommand_1 = __nccwpck_require__(71585); +const UpdateTopicRuleDestinationCommand_1 = __nccwpck_require__(18671); +const ValidateSecurityProfileBehaviorsCommand_1 = __nccwpck_require__(91452); +/** + *AWS IoT provides secure, bi-directional communication between Internet-connected + * devices (such as sensors, actuators, embedded devices, or smart appliances) and the AWS + * cloud. You can discover your custom IoT-Data endpoint to communicate with, configure + * rules for data processing and integration with other services, organize resources + * associated with each device (Registry), configure logging, and create and manage + * policies and credentials to authenticate devices.
+ *The service endpoints that expose this API are listed in + * AWS IoT Core Endpoints and Quotas. + * You must use the endpoint for the region that has the resources you want to access.
+ *The service name used by AWS + * Signature Version 4 to sign the request is: + * execute-api.
+ *For more information about how AWS IoT works, see the Developer + * Guide.
+ *For information about how to use the credentials provider for AWS IoT, see Authorizing Direct Calls to AWS Services.
+ */ +class IoT extends IoTClient_1.IoTClient { + acceptCertificateTransfer(args, optionsOrCb, cb) { + const command = new AcceptCertificateTransferCommand_1.AcceptCertificateTransferCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + addThingToBillingGroup(args, optionsOrCb, cb) { + const command = new AddThingToBillingGroupCommand_1.AddThingToBillingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + addThingToThingGroup(args, optionsOrCb, cb) { + const command = new AddThingToThingGroupCommand_1.AddThingToThingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + associateTargetsWithJob(args, optionsOrCb, cb) { + const command = new AssociateTargetsWithJobCommand_1.AssociateTargetsWithJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + attachPolicy(args, optionsOrCb, cb) { + const command = new AttachPolicyCommand_1.AttachPolicyCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + attachPrincipalPolicy(args, optionsOrCb, cb) { + const command = new AttachPrincipalPolicyCommand_1.AttachPrincipalPolicyCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + attachSecurityProfile(args, optionsOrCb, cb) { + const command = new AttachSecurityProfileCommand_1.AttachSecurityProfileCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + attachThingPrincipal(args, optionsOrCb, cb) { + const command = new AttachThingPrincipalCommand_1.AttachThingPrincipalCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + cancelAuditMitigationActionsTask(args, optionsOrCb, cb) { + const command = new CancelAuditMitigationActionsTaskCommand_1.CancelAuditMitigationActionsTaskCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + cancelAuditTask(args, optionsOrCb, cb) { + const command = new CancelAuditTaskCommand_1.CancelAuditTaskCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + cancelCertificateTransfer(args, optionsOrCb, cb) { + const command = new CancelCertificateTransferCommand_1.CancelCertificateTransferCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + cancelJob(args, optionsOrCb, cb) { + const command = new CancelJobCommand_1.CancelJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + cancelJobExecution(args, optionsOrCb, cb) { + const command = new CancelJobExecutionCommand_1.CancelJobExecutionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + clearDefaultAuthorizer(args, optionsOrCb, cb) { + const command = new ClearDefaultAuthorizerCommand_1.ClearDefaultAuthorizerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + confirmTopicRuleDestination(args, optionsOrCb, cb) { + const command = new ConfirmTopicRuleDestinationCommand_1.ConfirmTopicRuleDestinationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createAuditSuppression(args, optionsOrCb, cb) { + const command = new CreateAuditSuppressionCommand_1.CreateAuditSuppressionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createAuthorizer(args, optionsOrCb, cb) { + const command = new CreateAuthorizerCommand_1.CreateAuthorizerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createBillingGroup(args, optionsOrCb, cb) { + const command = new CreateBillingGroupCommand_1.CreateBillingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createCertificateFromCsr(args, optionsOrCb, cb) { + const command = new CreateCertificateFromCsrCommand_1.CreateCertificateFromCsrCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createDimension(args, optionsOrCb, cb) { + const command = new CreateDimensionCommand_1.CreateDimensionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createDomainConfiguration(args, optionsOrCb, cb) { + const command = new CreateDomainConfigurationCommand_1.CreateDomainConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createDynamicThingGroup(args, optionsOrCb, cb) { + const command = new CreateDynamicThingGroupCommand_1.CreateDynamicThingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createJob(args, optionsOrCb, cb) { + const command = new CreateJobCommand_1.CreateJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createKeysAndCertificate(args, optionsOrCb, cb) { + const command = new CreateKeysAndCertificateCommand_1.CreateKeysAndCertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createMitigationAction(args, optionsOrCb, cb) { + const command = new CreateMitigationActionCommand_1.CreateMitigationActionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createOTAUpdate(args, optionsOrCb, cb) { + const command = new CreateOTAUpdateCommand_1.CreateOTAUpdateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createPolicy(args, optionsOrCb, cb) { + const command = new CreatePolicyCommand_1.CreatePolicyCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createPolicyVersion(args, optionsOrCb, cb) { + const command = new CreatePolicyVersionCommand_1.CreatePolicyVersionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createProvisioningClaim(args, optionsOrCb, cb) { + const command = new CreateProvisioningClaimCommand_1.CreateProvisioningClaimCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createProvisioningTemplate(args, optionsOrCb, cb) { + const command = new CreateProvisioningTemplateCommand_1.CreateProvisioningTemplateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createProvisioningTemplateVersion(args, optionsOrCb, cb) { + const command = new CreateProvisioningTemplateVersionCommand_1.CreateProvisioningTemplateVersionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createRoleAlias(args, optionsOrCb, cb) { + const command = new CreateRoleAliasCommand_1.CreateRoleAliasCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createScheduledAudit(args, optionsOrCb, cb) { + const command = new CreateScheduledAuditCommand_1.CreateScheduledAuditCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createSecurityProfile(args, optionsOrCb, cb) { + const command = new CreateSecurityProfileCommand_1.CreateSecurityProfileCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createStream(args, optionsOrCb, cb) { + const command = new CreateStreamCommand_1.CreateStreamCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createThing(args, optionsOrCb, cb) { + const command = new CreateThingCommand_1.CreateThingCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createThingGroup(args, optionsOrCb, cb) { + const command = new CreateThingGroupCommand_1.CreateThingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createThingType(args, optionsOrCb, cb) { + const command = new CreateThingTypeCommand_1.CreateThingTypeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createTopicRule(args, optionsOrCb, cb) { + const command = new CreateTopicRuleCommand_1.CreateTopicRuleCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + createTopicRuleDestination(args, optionsOrCb, cb) { + const command = new CreateTopicRuleDestinationCommand_1.CreateTopicRuleDestinationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteAccountAuditConfiguration(args, optionsOrCb, cb) { + const command = new DeleteAccountAuditConfigurationCommand_1.DeleteAccountAuditConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteAuditSuppression(args, optionsOrCb, cb) { + const command = new DeleteAuditSuppressionCommand_1.DeleteAuditSuppressionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteAuthorizer(args, optionsOrCb, cb) { + const command = new DeleteAuthorizerCommand_1.DeleteAuthorizerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteBillingGroup(args, optionsOrCb, cb) { + const command = new DeleteBillingGroupCommand_1.DeleteBillingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteCACertificate(args, optionsOrCb, cb) { + const command = new DeleteCACertificateCommand_1.DeleteCACertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteCertificate(args, optionsOrCb, cb) { + const command = new DeleteCertificateCommand_1.DeleteCertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteDimension(args, optionsOrCb, cb) { + const command = new DeleteDimensionCommand_1.DeleteDimensionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteDomainConfiguration(args, optionsOrCb, cb) { + const command = new DeleteDomainConfigurationCommand_1.DeleteDomainConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteDynamicThingGroup(args, optionsOrCb, cb) { + const command = new DeleteDynamicThingGroupCommand_1.DeleteDynamicThingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteJob(args, optionsOrCb, cb) { + const command = new DeleteJobCommand_1.DeleteJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteJobExecution(args, optionsOrCb, cb) { + const command = new DeleteJobExecutionCommand_1.DeleteJobExecutionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteMitigationAction(args, optionsOrCb, cb) { + const command = new DeleteMitigationActionCommand_1.DeleteMitigationActionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteOTAUpdate(args, optionsOrCb, cb) { + const command = new DeleteOTAUpdateCommand_1.DeleteOTAUpdateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deletePolicy(args, optionsOrCb, cb) { + const command = new DeletePolicyCommand_1.DeletePolicyCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deletePolicyVersion(args, optionsOrCb, cb) { + const command = new DeletePolicyVersionCommand_1.DeletePolicyVersionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteProvisioningTemplate(args, optionsOrCb, cb) { + const command = new DeleteProvisioningTemplateCommand_1.DeleteProvisioningTemplateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteProvisioningTemplateVersion(args, optionsOrCb, cb) { + const command = new DeleteProvisioningTemplateVersionCommand_1.DeleteProvisioningTemplateVersionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteRegistrationCode(args, optionsOrCb, cb) { + const command = new DeleteRegistrationCodeCommand_1.DeleteRegistrationCodeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteRoleAlias(args, optionsOrCb, cb) { + const command = new DeleteRoleAliasCommand_1.DeleteRoleAliasCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteScheduledAudit(args, optionsOrCb, cb) { + const command = new DeleteScheduledAuditCommand_1.DeleteScheduledAuditCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteSecurityProfile(args, optionsOrCb, cb) { + const command = new DeleteSecurityProfileCommand_1.DeleteSecurityProfileCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteStream(args, optionsOrCb, cb) { + const command = new DeleteStreamCommand_1.DeleteStreamCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteThing(args, optionsOrCb, cb) { + const command = new DeleteThingCommand_1.DeleteThingCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteThingGroup(args, optionsOrCb, cb) { + const command = new DeleteThingGroupCommand_1.DeleteThingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteThingType(args, optionsOrCb, cb) { + const command = new DeleteThingTypeCommand_1.DeleteThingTypeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteTopicRule(args, optionsOrCb, cb) { + const command = new DeleteTopicRuleCommand_1.DeleteTopicRuleCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteTopicRuleDestination(args, optionsOrCb, cb) { + const command = new DeleteTopicRuleDestinationCommand_1.DeleteTopicRuleDestinationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deleteV2LoggingLevel(args, optionsOrCb, cb) { + const command = new DeleteV2LoggingLevelCommand_1.DeleteV2LoggingLevelCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + deprecateThingType(args, optionsOrCb, cb) { + const command = new DeprecateThingTypeCommand_1.DeprecateThingTypeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeAccountAuditConfiguration(args, optionsOrCb, cb) { + const command = new DescribeAccountAuditConfigurationCommand_1.DescribeAccountAuditConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeAuditFinding(args, optionsOrCb, cb) { + const command = new DescribeAuditFindingCommand_1.DescribeAuditFindingCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeAuditMitigationActionsTask(args, optionsOrCb, cb) { + const command = new DescribeAuditMitigationActionsTaskCommand_1.DescribeAuditMitigationActionsTaskCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeAuditSuppression(args, optionsOrCb, cb) { + const command = new DescribeAuditSuppressionCommand_1.DescribeAuditSuppressionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeAuditTask(args, optionsOrCb, cb) { + const command = new DescribeAuditTaskCommand_1.DescribeAuditTaskCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeAuthorizer(args, optionsOrCb, cb) { + const command = new DescribeAuthorizerCommand_1.DescribeAuthorizerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeBillingGroup(args, optionsOrCb, cb) { + const command = new DescribeBillingGroupCommand_1.DescribeBillingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeCACertificate(args, optionsOrCb, cb) { + const command = new DescribeCACertificateCommand_1.DescribeCACertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeCertificate(args, optionsOrCb, cb) { + const command = new DescribeCertificateCommand_1.DescribeCertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeDefaultAuthorizer(args, optionsOrCb, cb) { + const command = new DescribeDefaultAuthorizerCommand_1.DescribeDefaultAuthorizerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeDimension(args, optionsOrCb, cb) { + const command = new DescribeDimensionCommand_1.DescribeDimensionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeDomainConfiguration(args, optionsOrCb, cb) { + const command = new DescribeDomainConfigurationCommand_1.DescribeDomainConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeEndpoint(args, optionsOrCb, cb) { + const command = new DescribeEndpointCommand_1.DescribeEndpointCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeEventConfigurations(args, optionsOrCb, cb) { + const command = new DescribeEventConfigurationsCommand_1.DescribeEventConfigurationsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeIndex(args, optionsOrCb, cb) { + const command = new DescribeIndexCommand_1.DescribeIndexCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeJob(args, optionsOrCb, cb) { + const command = new DescribeJobCommand_1.DescribeJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeJobExecution(args, optionsOrCb, cb) { + const command = new DescribeJobExecutionCommand_1.DescribeJobExecutionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeMitigationAction(args, optionsOrCb, cb) { + const command = new DescribeMitigationActionCommand_1.DescribeMitigationActionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeProvisioningTemplate(args, optionsOrCb, cb) { + const command = new DescribeProvisioningTemplateCommand_1.DescribeProvisioningTemplateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeProvisioningTemplateVersion(args, optionsOrCb, cb) { + const command = new DescribeProvisioningTemplateVersionCommand_1.DescribeProvisioningTemplateVersionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeRoleAlias(args, optionsOrCb, cb) { + const command = new DescribeRoleAliasCommand_1.DescribeRoleAliasCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeScheduledAudit(args, optionsOrCb, cb) { + const command = new DescribeScheduledAuditCommand_1.DescribeScheduledAuditCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeSecurityProfile(args, optionsOrCb, cb) { + const command = new DescribeSecurityProfileCommand_1.DescribeSecurityProfileCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeStream(args, optionsOrCb, cb) { + const command = new DescribeStreamCommand_1.DescribeStreamCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeThing(args, optionsOrCb, cb) { + const command = new DescribeThingCommand_1.DescribeThingCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeThingGroup(args, optionsOrCb, cb) { + const command = new DescribeThingGroupCommand_1.DescribeThingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeThingRegistrationTask(args, optionsOrCb, cb) { + const command = new DescribeThingRegistrationTaskCommand_1.DescribeThingRegistrationTaskCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + describeThingType(args, optionsOrCb, cb) { + const command = new DescribeThingTypeCommand_1.DescribeThingTypeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + detachPolicy(args, optionsOrCb, cb) { + const command = new DetachPolicyCommand_1.DetachPolicyCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + detachPrincipalPolicy(args, optionsOrCb, cb) { + const command = new DetachPrincipalPolicyCommand_1.DetachPrincipalPolicyCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + detachSecurityProfile(args, optionsOrCb, cb) { + const command = new DetachSecurityProfileCommand_1.DetachSecurityProfileCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + detachThingPrincipal(args, optionsOrCb, cb) { + const command = new DetachThingPrincipalCommand_1.DetachThingPrincipalCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + disableTopicRule(args, optionsOrCb, cb) { + const command = new DisableTopicRuleCommand_1.DisableTopicRuleCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + enableTopicRule(args, optionsOrCb, cb) { + const command = new EnableTopicRuleCommand_1.EnableTopicRuleCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getCardinality(args, optionsOrCb, cb) { + const command = new GetCardinalityCommand_1.GetCardinalityCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getEffectivePolicies(args, optionsOrCb, cb) { + const command = new GetEffectivePoliciesCommand_1.GetEffectivePoliciesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getIndexingConfiguration(args, optionsOrCb, cb) { + const command = new GetIndexingConfigurationCommand_1.GetIndexingConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getJobDocument(args, optionsOrCb, cb) { + const command = new GetJobDocumentCommand_1.GetJobDocumentCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getLoggingOptions(args, optionsOrCb, cb) { + const command = new GetLoggingOptionsCommand_1.GetLoggingOptionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getOTAUpdate(args, optionsOrCb, cb) { + const command = new GetOTAUpdateCommand_1.GetOTAUpdateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getPercentiles(args, optionsOrCb, cb) { + const command = new GetPercentilesCommand_1.GetPercentilesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getPolicy(args, optionsOrCb, cb) { + const command = new GetPolicyCommand_1.GetPolicyCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getPolicyVersion(args, optionsOrCb, cb) { + const command = new GetPolicyVersionCommand_1.GetPolicyVersionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getRegistrationCode(args, optionsOrCb, cb) { + const command = new GetRegistrationCodeCommand_1.GetRegistrationCodeCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getStatistics(args, optionsOrCb, cb) { + const command = new GetStatisticsCommand_1.GetStatisticsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getTopicRule(args, optionsOrCb, cb) { + const command = new GetTopicRuleCommand_1.GetTopicRuleCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getTopicRuleDestination(args, optionsOrCb, cb) { + const command = new GetTopicRuleDestinationCommand_1.GetTopicRuleDestinationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getV2LoggingOptions(args, optionsOrCb, cb) { + const command = new GetV2LoggingOptionsCommand_1.GetV2LoggingOptionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listActiveViolations(args, optionsOrCb, cb) { + const command = new ListActiveViolationsCommand_1.ListActiveViolationsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listAttachedPolicies(args, optionsOrCb, cb) { + const command = new ListAttachedPoliciesCommand_1.ListAttachedPoliciesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listAuditFindings(args, optionsOrCb, cb) { + const command = new ListAuditFindingsCommand_1.ListAuditFindingsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listAuditMitigationActionsExecutions(args, optionsOrCb, cb) { + const command = new ListAuditMitigationActionsExecutionsCommand_1.ListAuditMitigationActionsExecutionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listAuditMitigationActionsTasks(args, optionsOrCb, cb) { + const command = new ListAuditMitigationActionsTasksCommand_1.ListAuditMitigationActionsTasksCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listAuditSuppressions(args, optionsOrCb, cb) { + const command = new ListAuditSuppressionsCommand_1.ListAuditSuppressionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listAuditTasks(args, optionsOrCb, cb) { + const command = new ListAuditTasksCommand_1.ListAuditTasksCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listAuthorizers(args, optionsOrCb, cb) { + const command = new ListAuthorizersCommand_1.ListAuthorizersCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listBillingGroups(args, optionsOrCb, cb) { + const command = new ListBillingGroupsCommand_1.ListBillingGroupsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listCACertificates(args, optionsOrCb, cb) { + const command = new ListCACertificatesCommand_1.ListCACertificatesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listCertificates(args, optionsOrCb, cb) { + const command = new ListCertificatesCommand_1.ListCertificatesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listCertificatesByCA(args, optionsOrCb, cb) { + const command = new ListCertificatesByCACommand_1.ListCertificatesByCACommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listDimensions(args, optionsOrCb, cb) { + const command = new ListDimensionsCommand_1.ListDimensionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listDomainConfigurations(args, optionsOrCb, cb) { + const command = new ListDomainConfigurationsCommand_1.ListDomainConfigurationsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listIndices(args, optionsOrCb, cb) { + const command = new ListIndicesCommand_1.ListIndicesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listJobExecutionsForJob(args, optionsOrCb, cb) { + const command = new ListJobExecutionsForJobCommand_1.ListJobExecutionsForJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listJobExecutionsForThing(args, optionsOrCb, cb) { + const command = new ListJobExecutionsForThingCommand_1.ListJobExecutionsForThingCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listJobs(args, optionsOrCb, cb) { + const command = new ListJobsCommand_1.ListJobsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listMitigationActions(args, optionsOrCb, cb) { + const command = new ListMitigationActionsCommand_1.ListMitigationActionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listOTAUpdates(args, optionsOrCb, cb) { + const command = new ListOTAUpdatesCommand_1.ListOTAUpdatesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listOutgoingCertificates(args, optionsOrCb, cb) { + const command = new ListOutgoingCertificatesCommand_1.ListOutgoingCertificatesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listPolicies(args, optionsOrCb, cb) { + const command = new ListPoliciesCommand_1.ListPoliciesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listPolicyPrincipals(args, optionsOrCb, cb) { + const command = new ListPolicyPrincipalsCommand_1.ListPolicyPrincipalsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listPolicyVersions(args, optionsOrCb, cb) { + const command = new ListPolicyVersionsCommand_1.ListPolicyVersionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listPrincipalPolicies(args, optionsOrCb, cb) { + const command = new ListPrincipalPoliciesCommand_1.ListPrincipalPoliciesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listPrincipalThings(args, optionsOrCb, cb) { + const command = new ListPrincipalThingsCommand_1.ListPrincipalThingsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listProvisioningTemplates(args, optionsOrCb, cb) { + const command = new ListProvisioningTemplatesCommand_1.ListProvisioningTemplatesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listProvisioningTemplateVersions(args, optionsOrCb, cb) { + const command = new ListProvisioningTemplateVersionsCommand_1.ListProvisioningTemplateVersionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listRoleAliases(args, optionsOrCb, cb) { + const command = new ListRoleAliasesCommand_1.ListRoleAliasesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listScheduledAudits(args, optionsOrCb, cb) { + const command = new ListScheduledAuditsCommand_1.ListScheduledAuditsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listSecurityProfiles(args, optionsOrCb, cb) { + const command = new ListSecurityProfilesCommand_1.ListSecurityProfilesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listSecurityProfilesForTarget(args, optionsOrCb, cb) { + const command = new ListSecurityProfilesForTargetCommand_1.ListSecurityProfilesForTargetCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listStreams(args, optionsOrCb, cb) { + const command = new ListStreamsCommand_1.ListStreamsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listTagsForResource(args, optionsOrCb, cb) { + const command = new ListTagsForResourceCommand_1.ListTagsForResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listTargetsForPolicy(args, optionsOrCb, cb) { + const command = new ListTargetsForPolicyCommand_1.ListTargetsForPolicyCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listTargetsForSecurityProfile(args, optionsOrCb, cb) { + const command = new ListTargetsForSecurityProfileCommand_1.ListTargetsForSecurityProfileCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listThingGroups(args, optionsOrCb, cb) { + const command = new ListThingGroupsCommand_1.ListThingGroupsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listThingGroupsForThing(args, optionsOrCb, cb) { + const command = new ListThingGroupsForThingCommand_1.ListThingGroupsForThingCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listThingPrincipals(args, optionsOrCb, cb) { + const command = new ListThingPrincipalsCommand_1.ListThingPrincipalsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listThingRegistrationTaskReports(args, optionsOrCb, cb) { + const command = new ListThingRegistrationTaskReportsCommand_1.ListThingRegistrationTaskReportsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listThingRegistrationTasks(args, optionsOrCb, cb) { + const command = new ListThingRegistrationTasksCommand_1.ListThingRegistrationTasksCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listThings(args, optionsOrCb, cb) { + const command = new ListThingsCommand_1.ListThingsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listThingsInBillingGroup(args, optionsOrCb, cb) { + const command = new ListThingsInBillingGroupCommand_1.ListThingsInBillingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listThingsInThingGroup(args, optionsOrCb, cb) { + const command = new ListThingsInThingGroupCommand_1.ListThingsInThingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listThingTypes(args, optionsOrCb, cb) { + const command = new ListThingTypesCommand_1.ListThingTypesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listTopicRuleDestinations(args, optionsOrCb, cb) { + const command = new ListTopicRuleDestinationsCommand_1.ListTopicRuleDestinationsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listTopicRules(args, optionsOrCb, cb) { + const command = new ListTopicRulesCommand_1.ListTopicRulesCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listV2LoggingLevels(args, optionsOrCb, cb) { + const command = new ListV2LoggingLevelsCommand_1.ListV2LoggingLevelsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + listViolationEvents(args, optionsOrCb, cb) { + const command = new ListViolationEventsCommand_1.ListViolationEventsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + registerCACertificate(args, optionsOrCb, cb) { + const command = new RegisterCACertificateCommand_1.RegisterCACertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + registerCertificate(args, optionsOrCb, cb) { + const command = new RegisterCertificateCommand_1.RegisterCertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + registerCertificateWithoutCA(args, optionsOrCb, cb) { + const command = new RegisterCertificateWithoutCACommand_1.RegisterCertificateWithoutCACommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + registerThing(args, optionsOrCb, cb) { + const command = new RegisterThingCommand_1.RegisterThingCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + rejectCertificateTransfer(args, optionsOrCb, cb) { + const command = new RejectCertificateTransferCommand_1.RejectCertificateTransferCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + removeThingFromBillingGroup(args, optionsOrCb, cb) { + const command = new RemoveThingFromBillingGroupCommand_1.RemoveThingFromBillingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + removeThingFromThingGroup(args, optionsOrCb, cb) { + const command = new RemoveThingFromThingGroupCommand_1.RemoveThingFromThingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + replaceTopicRule(args, optionsOrCb, cb) { + const command = new ReplaceTopicRuleCommand_1.ReplaceTopicRuleCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + searchIndex(args, optionsOrCb, cb) { + const command = new SearchIndexCommand_1.SearchIndexCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setDefaultAuthorizer(args, optionsOrCb, cb) { + const command = new SetDefaultAuthorizerCommand_1.SetDefaultAuthorizerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setDefaultPolicyVersion(args, optionsOrCb, cb) { + const command = new SetDefaultPolicyVersionCommand_1.SetDefaultPolicyVersionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setLoggingOptions(args, optionsOrCb, cb) { + const command = new SetLoggingOptionsCommand_1.SetLoggingOptionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setV2LoggingLevel(args, optionsOrCb, cb) { + const command = new SetV2LoggingLevelCommand_1.SetV2LoggingLevelCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + setV2LoggingOptions(args, optionsOrCb, cb) { + const command = new SetV2LoggingOptionsCommand_1.SetV2LoggingOptionsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + startAuditMitigationActionsTask(args, optionsOrCb, cb) { + const command = new StartAuditMitigationActionsTaskCommand_1.StartAuditMitigationActionsTaskCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + startOnDemandAuditTask(args, optionsOrCb, cb) { + const command = new StartOnDemandAuditTaskCommand_1.StartOnDemandAuditTaskCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + startThingRegistrationTask(args, optionsOrCb, cb) { + const command = new StartThingRegistrationTaskCommand_1.StartThingRegistrationTaskCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + stopThingRegistrationTask(args, optionsOrCb, cb) { + const command = new StopThingRegistrationTaskCommand_1.StopThingRegistrationTaskCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + tagResource(args, optionsOrCb, cb) { + const command = new TagResourceCommand_1.TagResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + testAuthorization(args, optionsOrCb, cb) { + const command = new TestAuthorizationCommand_1.TestAuthorizationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + testInvokeAuthorizer(args, optionsOrCb, cb) { + const command = new TestInvokeAuthorizerCommand_1.TestInvokeAuthorizerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + transferCertificate(args, optionsOrCb, cb) { + const command = new TransferCertificateCommand_1.TransferCertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + untagResource(args, optionsOrCb, cb) { + const command = new UntagResourceCommand_1.UntagResourceCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateAccountAuditConfiguration(args, optionsOrCb, cb) { + const command = new UpdateAccountAuditConfigurationCommand_1.UpdateAccountAuditConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateAuditSuppression(args, optionsOrCb, cb) { + const command = new UpdateAuditSuppressionCommand_1.UpdateAuditSuppressionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateAuthorizer(args, optionsOrCb, cb) { + const command = new UpdateAuthorizerCommand_1.UpdateAuthorizerCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateBillingGroup(args, optionsOrCb, cb) { + const command = new UpdateBillingGroupCommand_1.UpdateBillingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateCACertificate(args, optionsOrCb, cb) { + const command = new UpdateCACertificateCommand_1.UpdateCACertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateCertificate(args, optionsOrCb, cb) { + const command = new UpdateCertificateCommand_1.UpdateCertificateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateDimension(args, optionsOrCb, cb) { + const command = new UpdateDimensionCommand_1.UpdateDimensionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateDomainConfiguration(args, optionsOrCb, cb) { + const command = new UpdateDomainConfigurationCommand_1.UpdateDomainConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateDynamicThingGroup(args, optionsOrCb, cb) { + const command = new UpdateDynamicThingGroupCommand_1.UpdateDynamicThingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateEventConfigurations(args, optionsOrCb, cb) { + const command = new UpdateEventConfigurationsCommand_1.UpdateEventConfigurationsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateIndexingConfiguration(args, optionsOrCb, cb) { + const command = new UpdateIndexingConfigurationCommand_1.UpdateIndexingConfigurationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateJob(args, optionsOrCb, cb) { + const command = new UpdateJobCommand_1.UpdateJobCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateMitigationAction(args, optionsOrCb, cb) { + const command = new UpdateMitigationActionCommand_1.UpdateMitigationActionCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateProvisioningTemplate(args, optionsOrCb, cb) { + const command = new UpdateProvisioningTemplateCommand_1.UpdateProvisioningTemplateCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateRoleAlias(args, optionsOrCb, cb) { + const command = new UpdateRoleAliasCommand_1.UpdateRoleAliasCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateScheduledAudit(args, optionsOrCb, cb) { + const command = new UpdateScheduledAuditCommand_1.UpdateScheduledAuditCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateSecurityProfile(args, optionsOrCb, cb) { + const command = new UpdateSecurityProfileCommand_1.UpdateSecurityProfileCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateStream(args, optionsOrCb, cb) { + const command = new UpdateStreamCommand_1.UpdateStreamCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateThing(args, optionsOrCb, cb) { + const command = new UpdateThingCommand_1.UpdateThingCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateThingGroup(args, optionsOrCb, cb) { + const command = new UpdateThingGroupCommand_1.UpdateThingGroupCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateThingGroupsForThing(args, optionsOrCb, cb) { + const command = new UpdateThingGroupsForThingCommand_1.UpdateThingGroupsForThingCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + updateTopicRuleDestination(args, optionsOrCb, cb) { + const command = new UpdateTopicRuleDestinationCommand_1.UpdateTopicRuleDestinationCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + validateSecurityProfileBehaviors(args, optionsOrCb, cb) { + const command = new ValidateSecurityProfileBehaviorsCommand_1.ValidateSecurityProfileBehaviorsCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } +} +exports.IoT = IoT; +//# sourceMappingURL=IoT.js.map + +/***/ }), + +/***/ 31450: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.IoTClient = void 0; +const runtimeConfig_1 = __nccwpck_require__(67490); +const config_resolver_1 = __nccwpck_require__(87229); +const middleware_content_length_1 = __nccwpck_require__(69323); +const middleware_host_header_1 = __nccwpck_require__(58645); +const middleware_logger_1 = __nccwpck_require__(98685); +const middleware_retry_1 = __nccwpck_require__(7000); +const middleware_signing_1 = __nccwpck_require__(82487); +const middleware_user_agent_1 = __nccwpck_require__(55976); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *AWS IoT provides secure, bi-directional communication between Internet-connected + * devices (such as sensors, actuators, embedded devices, or smart appliances) and the AWS + * cloud. You can discover your custom IoT-Data endpoint to communicate with, configure + * rules for data processing and integration with other services, organize resources + * associated with each device (Registry), configure logging, and create and manage + * policies and credentials to authenticate devices.
+ *The service endpoints that expose this API are listed in + * AWS IoT Core Endpoints and Quotas. + * You must use the endpoint for the region that has the resources you want to access.
+ *The service name used by AWS + * Signature Version 4 to sign the request is: + * execute-api.
+ *For more information about how AWS IoT works, see the Developer + * Guide.
+ *For information about how to use the credentials provider for AWS IoT, see Authorizing Direct Calls to AWS Services.
+ */ +class IoTClient extends smithy_client_1.Client { + constructor(configuration) { + let _config_0 = { + ...runtimeConfig_1.ClientDefaultValues, + ...configuration, + }; + let _config_1 = config_resolver_1.resolveRegionConfig(_config_0); + let _config_2 = config_resolver_1.resolveEndpointsConfig(_config_1); + let _config_3 = middleware_signing_1.resolveAwsAuthConfig(_config_2); + let _config_4 = middleware_retry_1.resolveRetryConfig(_config_3); + let _config_5 = middleware_host_header_1.resolveHostHeaderConfig(_config_4); + let _config_6 = middleware_user_agent_1.resolveUserAgentConfig(_config_5); + super(_config_6); + this.config = _config_6; + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(this.config)); + this.middlewareStack.use(middleware_retry_1.getRetryPlugin(this.config)); + this.middlewareStack.use(middleware_content_length_1.getContentLengthPlugin(this.config)); + this.middlewareStack.use(middleware_host_header_1.getHostHeaderPlugin(this.config)); + this.middlewareStack.use(middleware_logger_1.getLoggerPlugin(this.config)); + this.middlewareStack.use(middleware_user_agent_1.getUserAgentPlugin(this.config)); + this.middlewareStack.use(middleware_retry_1.getOmitRetryHeadersPlugin(this.config)); + } + destroy() { + super.destroy(); + } +} +exports.IoTClient = IoTClient; +//# sourceMappingURL=IoTClient.js.map + +/***/ }), + +/***/ 56298: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AcceptCertificateTransferCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Accepts a pending certificate transfer. The default state of the certificate is + * INACTIVE.
+ *To check for pending certificate transfers, call ListCertificates + * to enumerate your certificates.
+ */ +class AcceptCertificateTransferCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "AcceptCertificateTransferCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AcceptCertificateTransferRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1AcceptCertificateTransferCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1AcceptCertificateTransferCommand(output, context); + } +} +exports.AcceptCertificateTransferCommand = AcceptCertificateTransferCommand; +//# sourceMappingURL=AcceptCertificateTransferCommand.js.map + +/***/ }), + +/***/ 50444: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AddThingToBillingGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Adds a thing to a billing group.
+ */ +class AddThingToBillingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "AddThingToBillingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AddThingToBillingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AddThingToBillingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1AddThingToBillingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1AddThingToBillingGroupCommand(output, context); + } +} +exports.AddThingToBillingGroupCommand = AddThingToBillingGroupCommand; +//# sourceMappingURL=AddThingToBillingGroupCommand.js.map + +/***/ }), + +/***/ 70565: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AddThingToThingGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Adds a thing to a thing group.
+ */ +class AddThingToThingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "AddThingToThingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AddThingToThingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AddThingToThingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1AddThingToThingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1AddThingToThingGroupCommand(output, context); + } +} +exports.AddThingToThingGroupCommand = AddThingToThingGroupCommand; +//# sourceMappingURL=AddThingToThingGroupCommand.js.map + +/***/ }), + +/***/ 35126: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AssociateTargetsWithJobCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Associates a group with a continuous job. The following criteria must be met:
+ *The job must have been created with the targetSelection
field set to
+ * "CONTINUOUS".
The job status must currently be "IN_PROGRESS".
+ *The total number of targets associated with a job must not exceed 100.
+ *Attaches a policy to the specified target.
+ */ +class AttachPolicyCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "AttachPolicyCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AttachPolicyRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1AttachPolicyCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1AttachPolicyCommand(output, context); + } +} +exports.AttachPolicyCommand = AttachPolicyCommand; +//# sourceMappingURL=AttachPolicyCommand.js.map + +/***/ }), + +/***/ 4077: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AttachPrincipalPolicyCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + * @deprecated + * + *Attaches the specified policy to the specified principal (certificate or other + * credential).
+ *+ * Note: This API is deprecated. Please use AttachPolicy instead.
+ */ +class AttachPrincipalPolicyCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "AttachPrincipalPolicyCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AttachPrincipalPolicyRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1AttachPrincipalPolicyCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1AttachPrincipalPolicyCommand(output, context); + } +} +exports.AttachPrincipalPolicyCommand = AttachPrincipalPolicyCommand; +//# sourceMappingURL=AttachPrincipalPolicyCommand.js.map + +/***/ }), + +/***/ 36378: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AttachSecurityProfileCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Associates a Device Defender security profile with a thing group or this account. Each + * thing group or account can have up to five security profiles associated with it.
+ */ +class AttachSecurityProfileCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "AttachSecurityProfileCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AttachSecurityProfileRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AttachSecurityProfileResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1AttachSecurityProfileCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1AttachSecurityProfileCommand(output, context); + } +} +exports.AttachSecurityProfileCommand = AttachSecurityProfileCommand; +//# sourceMappingURL=AttachSecurityProfileCommand.js.map + +/***/ }), + +/***/ 92532: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AttachThingPrincipalCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Attaches the specified principal to the specified thing. A principal can be X.509 + * certificates, IAM users, groups, and roles, Amazon Cognito identities or federated + * identities.
+ */ +class AttachThingPrincipalCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "AttachThingPrincipalCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.AttachThingPrincipalRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.AttachThingPrincipalResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1AttachThingPrincipalCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1AttachThingPrincipalCommand(output, context); + } +} +exports.AttachThingPrincipalCommand = AttachThingPrincipalCommand; +//# sourceMappingURL=AttachThingPrincipalCommand.js.map + +/***/ }), + +/***/ 84: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CancelAuditMitigationActionsTaskCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Cancels a mitigation action task that is in progress. If the task is not in progress, an InvalidRequestException occurs.
+ */ +class CancelAuditMitigationActionsTaskCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CancelAuditMitigationActionsTaskCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CancelAuditMitigationActionsTaskRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CancelAuditMitigationActionsTaskResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CancelAuditMitigationActionsTaskCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CancelAuditMitigationActionsTaskCommand(output, context); + } +} +exports.CancelAuditMitigationActionsTaskCommand = CancelAuditMitigationActionsTaskCommand; +//# sourceMappingURL=CancelAuditMitigationActionsTaskCommand.js.map + +/***/ }), + +/***/ 58801: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CancelAuditTaskCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Cancels an audit that is in progress. The audit can be either scheduled or on-demand. + * If the audit is not in progress, an "InvalidRequestException" occurs.
+ */ +class CancelAuditTaskCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CancelAuditTaskCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CancelAuditTaskRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CancelAuditTaskResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CancelAuditTaskCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CancelAuditTaskCommand(output, context); + } +} +exports.CancelAuditTaskCommand = CancelAuditTaskCommand; +//# sourceMappingURL=CancelAuditTaskCommand.js.map + +/***/ }), + +/***/ 69974: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CancelCertificateTransferCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Cancels a pending transfer for the specified certificate.
+ *+ * Note Only the transfer source account can use this + * operation to cancel a transfer. (Transfer destinations can use RejectCertificateTransfer instead.) After transfer, AWS IoT returns the + * certificate to the source account in the INACTIVE state. After the destination account has + * accepted the transfer, the transfer cannot be cancelled.
+ *After a certificate transfer is cancelled, the status of the certificate changes from + * PENDING_TRANSFER to INACTIVE.
+ */ +class CancelCertificateTransferCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CancelCertificateTransferCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CancelCertificateTransferRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CancelCertificateTransferCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CancelCertificateTransferCommand(output, context); + } +} +exports.CancelCertificateTransferCommand = CancelCertificateTransferCommand; +//# sourceMappingURL=CancelCertificateTransferCommand.js.map + +/***/ }), + +/***/ 62205: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CancelJobCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Cancels a job.
+ */ +class CancelJobCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CancelJobCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CancelJobRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CancelJobResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CancelJobCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CancelJobCommand(output, context); + } +} +exports.CancelJobCommand = CancelJobCommand; +//# sourceMappingURL=CancelJobCommand.js.map + +/***/ }), + +/***/ 21972: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CancelJobExecutionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Cancels the execution of a job for a given thing.
+ */ +class CancelJobExecutionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CancelJobExecutionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CancelJobExecutionRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CancelJobExecutionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CancelJobExecutionCommand(output, context); + } +} +exports.CancelJobExecutionCommand = CancelJobExecutionCommand; +//# sourceMappingURL=CancelJobExecutionCommand.js.map + +/***/ }), + +/***/ 97176: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ClearDefaultAuthorizerCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Clears the default authorizer.
+ */ +class ClearDefaultAuthorizerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ClearDefaultAuthorizerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ClearDefaultAuthorizerRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ClearDefaultAuthorizerResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ClearDefaultAuthorizerCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ClearDefaultAuthorizerCommand(output, context); + } +} +exports.ClearDefaultAuthorizerCommand = ClearDefaultAuthorizerCommand; +//# sourceMappingURL=ClearDefaultAuthorizerCommand.js.map + +/***/ }), + +/***/ 83239: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ConfirmTopicRuleDestinationCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Confirms a topic rule destination. When you create a rule requiring a destination, AWS
+ * IoT sends a confirmation message to the endpoint or base address you specify. The message
+ * includes a token which you pass back when calling ConfirmTopicRuleDestination
+ * to confirm that you own or have access to the endpoint.
+ * Creates a Device Defender audit suppression. + *
+ */ +class CreateAuditSuppressionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateAuditSuppressionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateAuditSuppressionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateAuditSuppressionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateAuditSuppressionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateAuditSuppressionCommand(output, context); + } +} +exports.CreateAuditSuppressionCommand = CreateAuditSuppressionCommand; +//# sourceMappingURL=CreateAuditSuppressionCommand.js.map + +/***/ }), + +/***/ 57959: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateAuthorizerCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates an authorizer.
+ */ +class CreateAuthorizerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateAuthorizerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateAuthorizerRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateAuthorizerResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateAuthorizerCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateAuthorizerCommand(output, context); + } +} +exports.CreateAuthorizerCommand = CreateAuthorizerCommand; +//# sourceMappingURL=CreateAuthorizerCommand.js.map + +/***/ }), + +/***/ 81102: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateBillingGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a billing group.
+ */ +class CreateBillingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateBillingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateBillingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateBillingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateBillingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateBillingGroupCommand(output, context); + } +} +exports.CreateBillingGroupCommand = CreateBillingGroupCommand; +//# sourceMappingURL=CreateBillingGroupCommand.js.map + +/***/ }), + +/***/ 26470: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateCertificateFromCsrCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates an X.509 certificate using the specified certificate signing + * request.
+ *+ * Note: The CSR must include a public key that is either an + * RSA key with a length of at least 2048 bits or an ECC key from NIST P-256 or NIST P-384 + * curves.
+ *+ * Note: Reusing the same certificate signing request (CSR) + * results in a distinct certificate.
+ *You can create multiple certificates in a batch by creating a directory, copying + * multiple .csr files into that directory, and then specifying that directory on the command + * line. The following commands show how to create a batch of certificates given a batch of + * CSRs.
+ *Assuming a set of CSRs are located inside of the directory + * my-csr-directory:
+ * + *On Linux and OS X, the command is:
+ * + *$ ls my-csr-directory/ | xargs -I {} aws iot create-certificate-from-csr + * --certificate-signing-request file://my-csr-directory/{}
+ *This command lists all of the CSRs in my-csr-directory and pipes each CSR file name + * to the aws iot create-certificate-from-csr AWS CLI command to create a certificate for the + * corresponding CSR.
+ *The aws iot create-certificate-from-csr part of the command can also be run in + * parallel to speed up the certificate creation process:
+ *$ ls my-csr-directory/ | xargs -P 10 -I {} aws iot create-certificate-from-csr + * --certificate-signing-request file://my-csr-directory/{}
+ *On Windows PowerShell, the command to create certificates for all CSRs in + * my-csr-directory is:
+ *> ls -Name my-csr-directory | %{aws iot create-certificate-from-csr + * --certificate-signing-request file://my-csr-directory/$_}
+ *On a Windows command prompt, the command to create certificates for all CSRs in + * my-csr-directory is:
+ *> forfiles /p my-csr-directory /c "cmd /c aws iot create-certificate-from-csr + * --certificate-signing-request file://@path"
+ */ +class CreateCertificateFromCsrCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateCertificateFromCsrCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateCertificateFromCsrRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateCertificateFromCsrResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateCertificateFromCsrCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateCertificateFromCsrCommand(output, context); + } +} +exports.CreateCertificateFromCsrCommand = CreateCertificateFromCsrCommand; +//# sourceMappingURL=CreateCertificateFromCsrCommand.js.map + +/***/ }), + +/***/ 71146: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateDimensionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Create a dimension that you can use to limit the scope of a metric used in a security profile for AWS IoT Device Defender. For example, using a TOPIC_FILTER
dimension, you can narrow down the scope of the metric only to MQTT topics whose name match the pattern specified in the dimension.
Creates a domain configuration.
+ *The domain configuration feature is in public preview and is subject to change.
+ *Creates a dynamic thing group.
+ */ +class CreateDynamicThingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateDynamicThingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateDynamicThingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateDynamicThingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateDynamicThingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateDynamicThingGroupCommand(output, context); + } +} +exports.CreateDynamicThingGroupCommand = CreateDynamicThingGroupCommand; +//# sourceMappingURL=CreateDynamicThingGroupCommand.js.map + +/***/ }), + +/***/ 14059: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateJobCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a job.
+ */ +class CreateJobCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateJobCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateJobRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateJobResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateJobCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateJobCommand(output, context); + } +} +exports.CreateJobCommand = CreateJobCommand; +//# sourceMappingURL=CreateJobCommand.js.map + +/***/ }), + +/***/ 4848: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateKeysAndCertificateCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a 2048-bit RSA key pair and issues an X.509 certificate using the issued
+ * public key. You can also call CreateKeysAndCertificate
over MQTT from a
+ * device, for more information, see Provisioning MQTT API.
+ * Note This is the only time AWS IoT issues the private key + * for this certificate, so it is important to keep it in a secure location.
+ */ +class CreateKeysAndCertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateKeysAndCertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateKeysAndCertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateKeysAndCertificateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateKeysAndCertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateKeysAndCertificateCommand(output, context); + } +} +exports.CreateKeysAndCertificateCommand = CreateKeysAndCertificateCommand; +//# sourceMappingURL=CreateKeysAndCertificateCommand.js.map + +/***/ }), + +/***/ 19583: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateMitigationActionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Defines an action that can be applied to audit findings by using StartAuditMitigationActionsTask. Only certain types of mitigation actions can be applied to specific check names. For more information, see Mitigation actions. Each mitigation action can apply only one type of change.
+ */ +class CreateMitigationActionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateMitigationActionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateMitigationActionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateMitigationActionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateMitigationActionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateMitigationActionCommand(output, context); + } +} +exports.CreateMitigationActionCommand = CreateMitigationActionCommand; +//# sourceMappingURL=CreateMitigationActionCommand.js.map + +/***/ }), + +/***/ 45447: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateOTAUpdateCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates an AWS IoT OTAUpdate on a target group of things or groups.
+ */ +class CreateOTAUpdateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateOTAUpdateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateOTAUpdateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateOTAUpdateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateOTAUpdateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateOTAUpdateCommand(output, context); + } +} +exports.CreateOTAUpdateCommand = CreateOTAUpdateCommand; +//# sourceMappingURL=CreateOTAUpdateCommand.js.map + +/***/ }), + +/***/ 35362: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreatePolicyCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates an AWS IoT policy.
+ *The created policy is the default version for the policy. This operation creates a + * policy version with a version identifier of 1 and sets + * 1 as the policy's default version.
+ */ +class CreatePolicyCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreatePolicyCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreatePolicyRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreatePolicyResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreatePolicyCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreatePolicyCommand(output, context); + } +} +exports.CreatePolicyCommand = CreatePolicyCommand; +//# sourceMappingURL=CreatePolicyCommand.js.map + +/***/ }), + +/***/ 72718: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreatePolicyVersionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a new version of the specified AWS IoT policy. To update a policy, create a + * new policy version. A managed policy can have up to five versions. If the policy has five + * versions, you must use DeletePolicyVersion to delete an existing version + * before you create a new one.
+ *Optionally, you can set the new version as the policy's default version. The default + * version is the operative version (that is, the version that is in effect for the + * certificates to which the policy is attached).
+ */ +class CreatePolicyVersionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreatePolicyVersionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreatePolicyVersionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreatePolicyVersionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreatePolicyVersionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreatePolicyVersionCommand(output, context); + } +} +exports.CreatePolicyVersionCommand = CreatePolicyVersionCommand; +//# sourceMappingURL=CreatePolicyVersionCommand.js.map + +/***/ }), + +/***/ 38826: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateProvisioningClaimCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a provisioning claim.
+ */ +class CreateProvisioningClaimCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateProvisioningClaimCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateProvisioningClaimRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateProvisioningClaimResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateProvisioningClaimCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateProvisioningClaimCommand(output, context); + } +} +exports.CreateProvisioningClaimCommand = CreateProvisioningClaimCommand; +//# sourceMappingURL=CreateProvisioningClaimCommand.js.map + +/***/ }), + +/***/ 79093: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateProvisioningTemplateCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a fleet provisioning template.
+ */ +class CreateProvisioningTemplateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateProvisioningTemplateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateProvisioningTemplateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateProvisioningTemplateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateProvisioningTemplateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateProvisioningTemplateCommand(output, context); + } +} +exports.CreateProvisioningTemplateCommand = CreateProvisioningTemplateCommand; +//# sourceMappingURL=CreateProvisioningTemplateCommand.js.map + +/***/ }), + +/***/ 28951: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateProvisioningTemplateVersionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a new version of a fleet provisioning template.
+ */ +class CreateProvisioningTemplateVersionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateProvisioningTemplateVersionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateProvisioningTemplateVersionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateProvisioningTemplateVersionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateProvisioningTemplateVersionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateProvisioningTemplateVersionCommand(output, context); + } +} +exports.CreateProvisioningTemplateVersionCommand = CreateProvisioningTemplateVersionCommand; +//# sourceMappingURL=CreateProvisioningTemplateVersionCommand.js.map + +/***/ }), + +/***/ 78443: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateRoleAliasCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a role alias.
+ */ +class CreateRoleAliasCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateRoleAliasCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateRoleAliasRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateRoleAliasResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateRoleAliasCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateRoleAliasCommand(output, context); + } +} +exports.CreateRoleAliasCommand = CreateRoleAliasCommand; +//# sourceMappingURL=CreateRoleAliasCommand.js.map + +/***/ }), + +/***/ 6809: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateScheduledAuditCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a scheduled audit that is run at a specified + * time interval.
+ */ +class CreateScheduledAuditCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateScheduledAuditCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateScheduledAuditRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateScheduledAuditResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateScheduledAuditCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateScheduledAuditCommand(output, context); + } +} +exports.CreateScheduledAuditCommand = CreateScheduledAuditCommand; +//# sourceMappingURL=CreateScheduledAuditCommand.js.map + +/***/ }), + +/***/ 56822: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateSecurityProfileCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a Device Defender security profile.
+ */ +class CreateSecurityProfileCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateSecurityProfileCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateSecurityProfileRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateSecurityProfileResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateSecurityProfileCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateSecurityProfileCommand(output, context); + } +} +exports.CreateSecurityProfileCommand = CreateSecurityProfileCommand; +//# sourceMappingURL=CreateSecurityProfileCommand.js.map + +/***/ }), + +/***/ 312: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateStreamCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a stream for delivering one or more large files in chunks over MQTT. A stream transports data + * bytes in chunks or blocks packaged as MQTT messages from a source like S3. You can have one or more files + * associated with a stream.
+ */ +class CreateStreamCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateStreamCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateStreamRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateStreamResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateStreamCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateStreamCommand(output, context); + } +} +exports.CreateStreamCommand = CreateStreamCommand; +//# sourceMappingURL=CreateStreamCommand.js.map + +/***/ }), + +/***/ 60949: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateThingCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a thing record in the registry. If this call is made multiple times using
+ * the same thing name and configuration, the call will succeed. If this call is made with
+ * the same thing name but different configuration a
+ * ResourceAlreadyExistsException
is thrown.
This is a control plane operation. See Authorization for + * information about authorizing control plane actions.
+ *Create a thing group.
+ *This is a control plane operation. See Authorization for + * information about authorizing control plane actions.
+ *Creates a new thing type.
+ */ +class CreateThingTypeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateThingTypeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateThingTypeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateThingTypeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateThingTypeCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateThingTypeCommand(output, context); + } +} +exports.CreateThingTypeCommand = CreateThingTypeCommand; +//# sourceMappingURL=CreateThingTypeCommand.js.map + +/***/ }), + +/***/ 96982: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateTopicRuleCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a rule. Creating rules is an administrator-level action. Any user who has + * permission to create rules will be able to access data processed by the rule.
+ */ +class CreateTopicRuleCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateTopicRuleCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateTopicRuleRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateTopicRuleCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateTopicRuleCommand(output, context); + } +} +exports.CreateTopicRuleCommand = CreateTopicRuleCommand; +//# sourceMappingURL=CreateTopicRuleCommand.js.map + +/***/ }), + +/***/ 15724: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.CreateTopicRuleDestinationCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a topic rule destination. The destination must be confirmed prior to use.
+ */ +class CreateTopicRuleDestinationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "CreateTopicRuleDestinationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.CreateTopicRuleDestinationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.CreateTopicRuleDestinationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1CreateTopicRuleDestinationCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1CreateTopicRuleDestinationCommand(output, context); + } +} +exports.CreateTopicRuleDestinationCommand = CreateTopicRuleDestinationCommand; +//# sourceMappingURL=CreateTopicRuleDestinationCommand.js.map + +/***/ }), + +/***/ 4430: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteAccountAuditConfigurationCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Restores the default settings for Device Defender audits for this account. Any + * configuration data you entered is deleted and all audit checks are reset to + * disabled.
+ */ +class DeleteAccountAuditConfigurationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteAccountAuditConfigurationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteAccountAuditConfigurationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteAccountAuditConfigurationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteAccountAuditConfigurationCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteAccountAuditConfigurationCommand(output, context); + } +} +exports.DeleteAccountAuditConfigurationCommand = DeleteAccountAuditConfigurationCommand; +//# sourceMappingURL=DeleteAccountAuditConfigurationCommand.js.map + +/***/ }), + +/***/ 90704: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteAuditSuppressionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *+ * Deletes a Device Defender audit suppression. + *
+ */ +class DeleteAuditSuppressionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteAuditSuppressionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteAuditSuppressionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteAuditSuppressionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteAuditSuppressionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteAuditSuppressionCommand(output, context); + } +} +exports.DeleteAuditSuppressionCommand = DeleteAuditSuppressionCommand; +//# sourceMappingURL=DeleteAuditSuppressionCommand.js.map + +/***/ }), + +/***/ 32183: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteAuthorizerCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes an authorizer.
+ */ +class DeleteAuthorizerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteAuthorizerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteAuthorizerRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteAuthorizerResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteAuthorizerCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteAuthorizerCommand(output, context); + } +} +exports.DeleteAuthorizerCommand = DeleteAuthorizerCommand; +//# sourceMappingURL=DeleteAuthorizerCommand.js.map + +/***/ }), + +/***/ 56409: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteBillingGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the billing group.
+ */ +class DeleteBillingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteBillingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteBillingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteBillingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteBillingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteBillingGroupCommand(output, context); + } +} +exports.DeleteBillingGroupCommand = DeleteBillingGroupCommand; +//# sourceMappingURL=DeleteBillingGroupCommand.js.map + +/***/ }), + +/***/ 73697: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteCACertificateCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a registered CA certificate.
+ */ +class DeleteCACertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteCACertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteCACertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteCACertificateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteCACertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteCACertificateCommand(output, context); + } +} +exports.DeleteCACertificateCommand = DeleteCACertificateCommand; +//# sourceMappingURL=DeleteCACertificateCommand.js.map + +/***/ }), + +/***/ 63911: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteCertificateCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the specified certificate.
+ *A certificate cannot be deleted if it has a policy or IoT thing attached to it or if + * its status is set to ACTIVE. To delete a certificate, first use the DetachPrincipalPolicy API to detach all policies. Next, use the UpdateCertificate API to set the certificate to the INACTIVE + * status.
+ */ +class DeleteCertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteCertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteCertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteCertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteCertificateCommand(output, context); + } +} +exports.DeleteCertificateCommand = DeleteCertificateCommand; +//# sourceMappingURL=DeleteCertificateCommand.js.map + +/***/ }), + +/***/ 91697: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteDimensionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Removes the specified dimension from your AWS account.
+ */ +class DeleteDimensionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteDimensionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteDimensionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteDimensionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteDimensionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteDimensionCommand(output, context); + } +} +exports.DeleteDimensionCommand = DeleteDimensionCommand; +//# sourceMappingURL=DeleteDimensionCommand.js.map + +/***/ }), + +/***/ 38666: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteDomainConfigurationCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the specified domain configuration.
+ *The domain configuration feature is in public preview and is subject to change.
+ *Deletes a dynamic thing group.
+ */ +class DeleteDynamicThingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteDynamicThingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteDynamicThingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteDynamicThingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteDynamicThingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteDynamicThingGroupCommand(output, context); + } +} +exports.DeleteDynamicThingGroupCommand = DeleteDynamicThingGroupCommand; +//# sourceMappingURL=DeleteDynamicThingGroupCommand.js.map + +/***/ }), + +/***/ 22855: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteJobCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a job and its related job executions.
+ *Deleting a job may take time, depending on the number of job + * executions created for the job and various other factors. While the job + * is being deleted, the status of the job will be shown as + * "DELETION_IN_PROGRESS". Attempting to delete or cancel a job whose status + * is already "DELETION_IN_PROGRESS" will result in an error.
+ *Only 10 jobs may have status "DELETION_IN_PROGRESS" at the same time, or + * a LimitExceededException will occur.
+ */ +class DeleteJobCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteJobCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteJobRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteJobCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteJobCommand(output, context); + } +} +exports.DeleteJobCommand = DeleteJobCommand; +//# sourceMappingURL=DeleteJobCommand.js.map + +/***/ }), + +/***/ 39671: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteJobExecutionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a job execution.
+ */ +class DeleteJobExecutionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteJobExecutionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteJobExecutionRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteJobExecutionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteJobExecutionCommand(output, context); + } +} +exports.DeleteJobExecutionCommand = DeleteJobExecutionCommand; +//# sourceMappingURL=DeleteJobExecutionCommand.js.map + +/***/ }), + +/***/ 45947: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteMitigationActionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a defined mitigation action from your AWS account.
+ */ +class DeleteMitigationActionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteMitigationActionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteMitigationActionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteMitigationActionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteMitigationActionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteMitigationActionCommand(output, context); + } +} +exports.DeleteMitigationActionCommand = DeleteMitigationActionCommand; +//# sourceMappingURL=DeleteMitigationActionCommand.js.map + +/***/ }), + +/***/ 52941: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteOTAUpdateCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Delete an OTA update.
+ */ +class DeleteOTAUpdateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteOTAUpdateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteOTAUpdateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteOTAUpdateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteOTAUpdateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteOTAUpdateCommand(output, context); + } +} +exports.DeleteOTAUpdateCommand = DeleteOTAUpdateCommand; +//# sourceMappingURL=DeleteOTAUpdateCommand.js.map + +/***/ }), + +/***/ 26106: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeletePolicyCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the specified policy.
+ *A policy cannot be deleted if it has non-default versions or it is attached to any + * certificate.
+ *To delete a policy, use the DeletePolicyVersion API to delete all non-default + * versions of the policy; use the DetachPrincipalPolicy API to detach the policy from any + * certificate; and then use the DeletePolicy API to delete the policy.
+ *When a policy is deleted using DeletePolicy, its default version is deleted with + * it.
+ */ +class DeletePolicyCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeletePolicyCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeletePolicyRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeletePolicyCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeletePolicyCommand(output, context); + } +} +exports.DeletePolicyCommand = DeletePolicyCommand; +//# sourceMappingURL=DeletePolicyCommand.js.map + +/***/ }), + +/***/ 67779: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeletePolicyVersionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the specified version of the specified policy. You cannot delete the default + * version of a policy using this API. To delete the default version of a policy, use DeletePolicy. To find out which version of a policy is marked as the default + * version, use ListPolicyVersions.
+ */ +class DeletePolicyVersionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeletePolicyVersionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeletePolicyVersionRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeletePolicyVersionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeletePolicyVersionCommand(output, context); + } +} +exports.DeletePolicyVersionCommand = DeletePolicyVersionCommand; +//# sourceMappingURL=DeletePolicyVersionCommand.js.map + +/***/ }), + +/***/ 11659: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteProvisioningTemplateCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a fleet provisioning template.
+ */ +class DeleteProvisioningTemplateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteProvisioningTemplateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteProvisioningTemplateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteProvisioningTemplateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteProvisioningTemplateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteProvisioningTemplateCommand(output, context); + } +} +exports.DeleteProvisioningTemplateCommand = DeleteProvisioningTemplateCommand; +//# sourceMappingURL=DeleteProvisioningTemplateCommand.js.map + +/***/ }), + +/***/ 37562: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteProvisioningTemplateVersionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a fleet provisioning template version.
+ */ +class DeleteProvisioningTemplateVersionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteProvisioningTemplateVersionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteProvisioningTemplateVersionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteProvisioningTemplateVersionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteProvisioningTemplateVersionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteProvisioningTemplateVersionCommand(output, context); + } +} +exports.DeleteProvisioningTemplateVersionCommand = DeleteProvisioningTemplateVersionCommand; +//# sourceMappingURL=DeleteProvisioningTemplateVersionCommand.js.map + +/***/ }), + +/***/ 23235: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteRegistrationCodeCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a CA certificate registration code.
+ */ +class DeleteRegistrationCodeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteRegistrationCodeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteRegistrationCodeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteRegistrationCodeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteRegistrationCodeCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteRegistrationCodeCommand(output, context); + } +} +exports.DeleteRegistrationCodeCommand = DeleteRegistrationCodeCommand; +//# sourceMappingURL=DeleteRegistrationCodeCommand.js.map + +/***/ }), + +/***/ 42187: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteRoleAliasCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a role alias
+ */ +class DeleteRoleAliasCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteRoleAliasCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteRoleAliasRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteRoleAliasResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteRoleAliasCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteRoleAliasCommand(output, context); + } +} +exports.DeleteRoleAliasCommand = DeleteRoleAliasCommand; +//# sourceMappingURL=DeleteRoleAliasCommand.js.map + +/***/ }), + +/***/ 61685: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteScheduledAuditCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a scheduled audit.
+ */ +class DeleteScheduledAuditCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteScheduledAuditCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteScheduledAuditRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteScheduledAuditResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteScheduledAuditCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteScheduledAuditCommand(output, context); + } +} +exports.DeleteScheduledAuditCommand = DeleteScheduledAuditCommand; +//# sourceMappingURL=DeleteScheduledAuditCommand.js.map + +/***/ }), + +/***/ 77857: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteSecurityProfileCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a Device Defender security profile.
+ */ +class DeleteSecurityProfileCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteSecurityProfileCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteSecurityProfileRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteSecurityProfileResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteSecurityProfileCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteSecurityProfileCommand(output, context); + } +} +exports.DeleteSecurityProfileCommand = DeleteSecurityProfileCommand; +//# sourceMappingURL=DeleteSecurityProfileCommand.js.map + +/***/ }), + +/***/ 68349: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteStreamCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a stream.
+ */ +class DeleteStreamCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteStreamCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteStreamRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteStreamResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteStreamCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteStreamCommand(output, context); + } +} +exports.DeleteStreamCommand = DeleteStreamCommand; +//# sourceMappingURL=DeleteStreamCommand.js.map + +/***/ }), + +/***/ 31281: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteThingCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the specified thing. Returns successfully with no error if the deletion is + * successful or you specify a thing that doesn't exist.
+ */ +class DeleteThingCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteThingCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteThingRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteThingResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteThingCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteThingCommand(output, context); + } +} +exports.DeleteThingCommand = DeleteThingCommand; +//# sourceMappingURL=DeleteThingCommand.js.map + +/***/ }), + +/***/ 73451: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteThingGroupCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a thing group.
+ */ +class DeleteThingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteThingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteThingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteThingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteThingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteThingGroupCommand(output, context); + } +} +exports.DeleteThingGroupCommand = DeleteThingGroupCommand; +//# sourceMappingURL=DeleteThingGroupCommand.js.map + +/***/ }), + +/***/ 36024: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteThingTypeCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the specified thing type. You cannot delete a thing type if it has things + * associated with it. To delete a thing type, first mark it as deprecated by calling DeprecateThingType, then remove any associated things by calling UpdateThing to change the thing type on any associated thing, and + * finally use DeleteThingType to delete the thing type.
+ */ +class DeleteThingTypeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteThingTypeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteThingTypeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteThingTypeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteThingTypeCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteThingTypeCommand(output, context); + } +} +exports.DeleteThingTypeCommand = DeleteThingTypeCommand; +//# sourceMappingURL=DeleteThingTypeCommand.js.map + +/***/ }), + +/***/ 32270: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteTopicRuleCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes the rule.
+ */ +class DeleteTopicRuleCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteTopicRuleCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteTopicRuleRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteTopicRuleCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteTopicRuleCommand(output, context); + } +} +exports.DeleteTopicRuleCommand = DeleteTopicRuleCommand; +//# sourceMappingURL=DeleteTopicRuleCommand.js.map + +/***/ }), + +/***/ 62838: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteTopicRuleDestinationCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a topic rule destination.
+ */ +class DeleteTopicRuleDestinationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteTopicRuleDestinationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteTopicRuleDestinationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeleteTopicRuleDestinationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteTopicRuleDestinationCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteTopicRuleDestinationCommand(output, context); + } +} +exports.DeleteTopicRuleDestinationCommand = DeleteTopicRuleDestinationCommand; +//# sourceMappingURL=DeleteTopicRuleDestinationCommand.js.map + +/***/ }), + +/***/ 35964: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeleteV2LoggingLevelCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deletes a logging level.
+ */ +class DeleteV2LoggingLevelCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeleteV2LoggingLevelCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeleteV2LoggingLevelRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeleteV2LoggingLevelCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeleteV2LoggingLevelCommand(output, context); + } +} +exports.DeleteV2LoggingLevelCommand = DeleteV2LoggingLevelCommand; +//# sourceMappingURL=DeleteV2LoggingLevelCommand.js.map + +/***/ }), + +/***/ 13748: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DeprecateThingTypeCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Deprecates a thing type. You can not associate new things with deprecated thing + * type.
+ */ +class DeprecateThingTypeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DeprecateThingTypeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DeprecateThingTypeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DeprecateThingTypeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DeprecateThingTypeCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DeprecateThingTypeCommand(output, context); + } +} +exports.DeprecateThingTypeCommand = DeprecateThingTypeCommand; +//# sourceMappingURL=DeprecateThingTypeCommand.js.map + +/***/ }), + +/***/ 13811: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeAccountAuditConfigurationCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about the Device Defender audit settings for this account. + * Settings include how audit notifications are sent and which audit checks are + * enabled or disabled.
+ */ +class DescribeAccountAuditConfigurationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeAccountAuditConfigurationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeAccountAuditConfigurationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeAccountAuditConfigurationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeAccountAuditConfigurationCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeAccountAuditConfigurationCommand(output, context); + } +} +exports.DescribeAccountAuditConfigurationCommand = DescribeAccountAuditConfigurationCommand; +//# sourceMappingURL=DescribeAccountAuditConfigurationCommand.js.map + +/***/ }), + +/***/ 91538: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeAuditFindingCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about a single audit finding. Properties include the reason for noncompliance, the severity of the issue, and when the audit that returned the finding was started.
+ */ +class DescribeAuditFindingCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeAuditFindingCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeAuditFindingRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeAuditFindingResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeAuditFindingCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeAuditFindingCommand(output, context); + } +} +exports.DescribeAuditFindingCommand = DescribeAuditFindingCommand; +//# sourceMappingURL=DescribeAuditFindingCommand.js.map + +/***/ }), + +/***/ 16532: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeAuditMitigationActionsTaskCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about an audit mitigation task that is used to apply mitigation actions to a set of audit findings. Properties include the actions being applied, the audit checks to which they're being applied, the task status, and aggregated task statistics.
+ */ +class DescribeAuditMitigationActionsTaskCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeAuditMitigationActionsTaskCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeAuditMitigationActionsTaskRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeAuditMitigationActionsTaskResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeAuditMitigationActionsTaskCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeAuditMitigationActionsTaskCommand(output, context); + } +} +exports.DescribeAuditMitigationActionsTaskCommand = DescribeAuditMitigationActionsTaskCommand; +//# sourceMappingURL=DescribeAuditMitigationActionsTaskCommand.js.map + +/***/ }), + +/***/ 84970: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeAuditSuppressionCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *+ * Gets information about a Device Defender audit suppression. + *
+ */ +class DescribeAuditSuppressionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeAuditSuppressionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeAuditSuppressionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.DescribeAuditSuppressionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeAuditSuppressionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeAuditSuppressionCommand(output, context); + } +} +exports.DescribeAuditSuppressionCommand = DescribeAuditSuppressionCommand; +//# sourceMappingURL=DescribeAuditSuppressionCommand.js.map + +/***/ }), + +/***/ 74328: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeAuditTaskCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about a Device Defender audit.
+ */ +class DescribeAuditTaskCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeAuditTaskCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.DescribeAuditTaskRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeAuditTaskResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeAuditTaskCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeAuditTaskCommand(output, context); + } +} +exports.DescribeAuditTaskCommand = DescribeAuditTaskCommand; +//# sourceMappingURL=DescribeAuditTaskCommand.js.map + +/***/ }), + +/***/ 85629: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeAuthorizerCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes an authorizer.
+ */ +class DescribeAuthorizerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeAuthorizerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeAuthorizerRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeAuthorizerResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeAuthorizerCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeAuthorizerCommand(output, context); + } +} +exports.DescribeAuthorizerCommand = DescribeAuthorizerCommand; +//# sourceMappingURL=DescribeAuthorizerCommand.js.map + +/***/ }), + +/***/ 40564: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeBillingGroupCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns information about a billing group.
+ */ +class DescribeBillingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeBillingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeBillingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeBillingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeBillingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeBillingGroupCommand(output, context); + } +} +exports.DescribeBillingGroupCommand = DescribeBillingGroupCommand; +//# sourceMappingURL=DescribeBillingGroupCommand.js.map + +/***/ }), + +/***/ 42279: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeCACertificateCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes a registered CA certificate.
+ */ +class DescribeCACertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeCACertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeCACertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeCACertificateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeCACertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeCACertificateCommand(output, context); + } +} +exports.DescribeCACertificateCommand = DescribeCACertificateCommand; +//# sourceMappingURL=DescribeCACertificateCommand.js.map + +/***/ }), + +/***/ 78585: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeCertificateCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about the specified certificate.
+ */ +class DescribeCertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeCertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeCertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeCertificateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeCertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeCertificateCommand(output, context); + } +} +exports.DescribeCertificateCommand = DescribeCertificateCommand; +//# sourceMappingURL=DescribeCertificateCommand.js.map + +/***/ }), + +/***/ 68623: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeDefaultAuthorizerCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes the default authorizer.
+ */ +class DescribeDefaultAuthorizerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeDefaultAuthorizerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeDefaultAuthorizerRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeDefaultAuthorizerResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeDefaultAuthorizerCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeDefaultAuthorizerCommand(output, context); + } +} +exports.DescribeDefaultAuthorizerCommand = DescribeDefaultAuthorizerCommand; +//# sourceMappingURL=DescribeDefaultAuthorizerCommand.js.map + +/***/ }), + +/***/ 46755: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeDimensionCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Provides details about a dimension that is defined in your AWS account.
+ */ +class DescribeDimensionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeDimensionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeDimensionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeDimensionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeDimensionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeDimensionCommand(output, context); + } +} +exports.DescribeDimensionCommand = DescribeDimensionCommand; +//# sourceMappingURL=DescribeDimensionCommand.js.map + +/***/ }), + +/***/ 83673: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeDomainConfigurationCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets summary information about a domain configuration.
+ *The domain configuration feature is in public preview and is subject to change.
+ *Returns a unique endpoint specific to the AWS account making the call.
+ */ +class DescribeEndpointCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeEndpointCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeEndpointRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeEndpointResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeEndpointCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeEndpointCommand(output, context); + } +} +exports.DescribeEndpointCommand = DescribeEndpointCommand; +//# sourceMappingURL=DescribeEndpointCommand.js.map + +/***/ }), + +/***/ 87665: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeEventConfigurationsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes event configurations.
+ */ +class DescribeEventConfigurationsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeEventConfigurationsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeEventConfigurationsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeEventConfigurationsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeEventConfigurationsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeEventConfigurationsCommand(output, context); + } +} +exports.DescribeEventConfigurationsCommand = DescribeEventConfigurationsCommand; +//# sourceMappingURL=DescribeEventConfigurationsCommand.js.map + +/***/ }), + +/***/ 77948: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeIndexCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes a search index.
+ */ +class DescribeIndexCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeIndexCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeIndexRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeIndexResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeIndexCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeIndexCommand(output, context); + } +} +exports.DescribeIndexCommand = DescribeIndexCommand; +//# sourceMappingURL=DescribeIndexCommand.js.map + +/***/ }), + +/***/ 28980: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeJobCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes a job.
+ */ +class DescribeJobCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeJobCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeJobRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeJobResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeJobCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeJobCommand(output, context); + } +} +exports.DescribeJobCommand = DescribeJobCommand; +//# sourceMappingURL=DescribeJobCommand.js.map + +/***/ }), + +/***/ 65547: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeJobExecutionCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes a job execution.
+ */ +class DescribeJobExecutionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeJobExecutionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeJobExecutionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeJobExecutionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeJobExecutionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeJobExecutionCommand(output, context); + } +} +exports.DescribeJobExecutionCommand = DescribeJobExecutionCommand; +//# sourceMappingURL=DescribeJobExecutionCommand.js.map + +/***/ }), + +/***/ 1175: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeMitigationActionCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about a mitigation action.
+ */ +class DescribeMitigationActionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeMitigationActionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeMitigationActionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeMitigationActionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeMitigationActionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeMitigationActionCommand(output, context); + } +} +exports.DescribeMitigationActionCommand = DescribeMitigationActionCommand; +//# sourceMappingURL=DescribeMitigationActionCommand.js.map + +/***/ }), + +/***/ 44539: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeProvisioningTemplateCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns information about a fleet provisioning template.
+ */ +class DescribeProvisioningTemplateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeProvisioningTemplateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeProvisioningTemplateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeProvisioningTemplateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeProvisioningTemplateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeProvisioningTemplateCommand(output, context); + } +} +exports.DescribeProvisioningTemplateCommand = DescribeProvisioningTemplateCommand; +//# sourceMappingURL=DescribeProvisioningTemplateCommand.js.map + +/***/ }), + +/***/ 34488: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeProvisioningTemplateVersionCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns information about a fleet provisioning template version.
+ */ +class DescribeProvisioningTemplateVersionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeProvisioningTemplateVersionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeProvisioningTemplateVersionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeProvisioningTemplateVersionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeProvisioningTemplateVersionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeProvisioningTemplateVersionCommand(output, context); + } +} +exports.DescribeProvisioningTemplateVersionCommand = DescribeProvisioningTemplateVersionCommand; +//# sourceMappingURL=DescribeProvisioningTemplateVersionCommand.js.map + +/***/ }), + +/***/ 44504: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeRoleAliasCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes a role alias.
+ */ +class DescribeRoleAliasCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeRoleAliasCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeRoleAliasRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeRoleAliasResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeRoleAliasCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeRoleAliasCommand(output, context); + } +} +exports.DescribeRoleAliasCommand = DescribeRoleAliasCommand; +//# sourceMappingURL=DescribeRoleAliasCommand.js.map + +/***/ }), + +/***/ 61131: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeScheduledAuditCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about a scheduled audit.
+ */ +class DescribeScheduledAuditCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeScheduledAuditCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeScheduledAuditRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeScheduledAuditResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeScheduledAuditCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeScheduledAuditCommand(output, context); + } +} +exports.DescribeScheduledAuditCommand = DescribeScheduledAuditCommand; +//# sourceMappingURL=DescribeScheduledAuditCommand.js.map + +/***/ }), + +/***/ 22237: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeSecurityProfileCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about a Device Defender security profile.
+ */ +class DescribeSecurityProfileCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeSecurityProfileCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeSecurityProfileRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeSecurityProfileResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeSecurityProfileCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeSecurityProfileCommand(output, context); + } +} +exports.DescribeSecurityProfileCommand = DescribeSecurityProfileCommand; +//# sourceMappingURL=DescribeSecurityProfileCommand.js.map + +/***/ }), + +/***/ 90953: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeStreamCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about a stream.
+ */ +class DescribeStreamCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeStreamCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeStreamRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeStreamResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeStreamCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeStreamCommand(output, context); + } +} +exports.DescribeStreamCommand = DescribeStreamCommand; +//# sourceMappingURL=DescribeStreamCommand.js.map + +/***/ }), + +/***/ 44526: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeThingCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about the specified thing.
+ */ +class DescribeThingCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeThingCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeThingRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeThingResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeThingCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeThingCommand(output, context); + } +} +exports.DescribeThingCommand = DescribeThingCommand; +//# sourceMappingURL=DescribeThingCommand.js.map + +/***/ }), + +/***/ 19878: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeThingGroupCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describe a thing group.
+ */ +class DescribeThingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeThingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeThingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeThingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeThingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeThingGroupCommand(output, context); + } +} +exports.DescribeThingGroupCommand = DescribeThingGroupCommand; +//# sourceMappingURL=DescribeThingGroupCommand.js.map + +/***/ }), + +/***/ 83198: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeThingRegistrationTaskCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Describes a bulk thing provisioning task.
+ */ +class DescribeThingRegistrationTaskCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeThingRegistrationTaskCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeThingRegistrationTaskRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeThingRegistrationTaskResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeThingRegistrationTaskCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeThingRegistrationTaskCommand(output, context); + } +} +exports.DescribeThingRegistrationTaskCommand = DescribeThingRegistrationTaskCommand; +//# sourceMappingURL=DescribeThingRegistrationTaskCommand.js.map + +/***/ }), + +/***/ 50780: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeThingTypeCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about the specified thing type.
+ */ +class DescribeThingTypeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DescribeThingTypeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DescribeThingTypeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DescribeThingTypeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DescribeThingTypeCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DescribeThingTypeCommand(output, context); + } +} +exports.DescribeThingTypeCommand = DescribeThingTypeCommand; +//# sourceMappingURL=DescribeThingTypeCommand.js.map + +/***/ }), + +/***/ 17402: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DetachPolicyCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Detaches a policy from the specified target.
+ */ +class DetachPolicyCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DetachPolicyCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DetachPolicyRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DetachPolicyCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DetachPolicyCommand(output, context); + } +} +exports.DetachPolicyCommand = DetachPolicyCommand; +//# sourceMappingURL=DetachPolicyCommand.js.map + +/***/ }), + +/***/ 7189: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DetachPrincipalPolicyCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + * @deprecated + * + *Removes the specified policy from the specified certificate.
+ *+ * Note: This API is deprecated. Please use DetachPolicy instead.
+ */ +class DetachPrincipalPolicyCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DetachPrincipalPolicyCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DetachPrincipalPolicyRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DetachPrincipalPolicyCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DetachPrincipalPolicyCommand(output, context); + } +} +exports.DetachPrincipalPolicyCommand = DetachPrincipalPolicyCommand; +//# sourceMappingURL=DetachPrincipalPolicyCommand.js.map + +/***/ }), + +/***/ 9688: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DetachSecurityProfileCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Disassociates a Device Defender security profile from a thing group or from this account.
+ */ +class DetachSecurityProfileCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DetachSecurityProfileCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DetachSecurityProfileRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.DetachSecurityProfileResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DetachSecurityProfileCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DetachSecurityProfileCommand(output, context); + } +} +exports.DetachSecurityProfileCommand = DetachSecurityProfileCommand; +//# sourceMappingURL=DetachSecurityProfileCommand.js.map + +/***/ }), + +/***/ 71366: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DetachThingPrincipalCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Detaches the specified principal from the specified thing. A principal can be X.509 + * certificates, IAM users, groups, and roles, Amazon Cognito identities or federated + * identities.
+ *This call is asynchronous. It might take several seconds for the detachment to + * propagate.
+ *Disables the rule.
+ */ +class DisableTopicRuleCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "DisableTopicRuleCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.DisableTopicRuleRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1DisableTopicRuleCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1DisableTopicRuleCommand(output, context); + } +} +exports.DisableTopicRuleCommand = DisableTopicRuleCommand; +//# sourceMappingURL=DisableTopicRuleCommand.js.map + +/***/ }), + +/***/ 83282: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.EnableTopicRuleCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Enables the rule.
+ */ +class EnableTopicRuleCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "EnableTopicRuleCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.EnableTopicRuleRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1EnableTopicRuleCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1EnableTopicRuleCommand(output, context); + } +} +exports.EnableTopicRuleCommand = EnableTopicRuleCommand; +//# sourceMappingURL=EnableTopicRuleCommand.js.map + +/***/ }), + +/***/ 19687: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetCardinalityCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns the approximate count of unique values that match the query.
+ */ +class GetCardinalityCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetCardinalityCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetCardinalityRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetCardinalityResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetCardinalityCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetCardinalityCommand(output, context); + } +} +exports.GetCardinalityCommand = GetCardinalityCommand; +//# sourceMappingURL=GetCardinalityCommand.js.map + +/***/ }), + +/***/ 51757: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetEffectivePoliciesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets a list of the policies that have an effect on the authorization behavior of the + * specified device when it connects to the AWS IoT device gateway.
+ */ +class GetEffectivePoliciesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetEffectivePoliciesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetEffectivePoliciesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetEffectivePoliciesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetEffectivePoliciesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetEffectivePoliciesCommand(output, context); + } +} +exports.GetEffectivePoliciesCommand = GetEffectivePoliciesCommand; +//# sourceMappingURL=GetEffectivePoliciesCommand.js.map + +/***/ }), + +/***/ 189: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetIndexingConfigurationCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the indexing configuration.
+ */ +class GetIndexingConfigurationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetIndexingConfigurationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetIndexingConfigurationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetIndexingConfigurationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetIndexingConfigurationCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetIndexingConfigurationCommand(output, context); + } +} +exports.GetIndexingConfigurationCommand = GetIndexingConfigurationCommand; +//# sourceMappingURL=GetIndexingConfigurationCommand.js.map + +/***/ }), + +/***/ 91665: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetJobDocumentCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets a job document.
+ */ +class GetJobDocumentCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetJobDocumentCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetJobDocumentRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetJobDocumentResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetJobDocumentCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetJobDocumentCommand(output, context); + } +} +exports.GetJobDocumentCommand = GetJobDocumentCommand; +//# sourceMappingURL=GetJobDocumentCommand.js.map + +/***/ }), + +/***/ 57429: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetLoggingOptionsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the logging options.
+ *NOTE: use of this command is not recommended. Use GetV2LoggingOptions
+ * instead.
Gets an OTA update.
+ */ +class GetOTAUpdateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetOTAUpdateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetOTAUpdateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetOTAUpdateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetOTAUpdateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetOTAUpdateCommand(output, context); + } +} +exports.GetOTAUpdateCommand = GetOTAUpdateCommand; +//# sourceMappingURL=GetOTAUpdateCommand.js.map + +/***/ }), + +/***/ 33048: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetPercentilesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Groups the aggregated values that match the query into percentile groupings. The default
+ * percentile groupings are: 1,5,25,50,75,95,99, although you can specify your own
+ * when you call GetPercentiles
. This function returns a value for each
+ * percentile group specified (or the default percentile groupings). The percentile group
+ * "1" contains the aggregated field value that occurs in approximately one percent of the
+ * values that match the query. The percentile group "5" contains the aggregated field value
+ * that occurs in approximately five percent of the values that match the query, and so on.
+ * The result is an approximation, the more values that match the query, the more accurate
+ * the percentile values.
Gets information about the specified policy with the policy document of the default + * version.
+ */ +class GetPolicyCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetPolicyCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetPolicyRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetPolicyResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetPolicyCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetPolicyCommand(output, context); + } +} +exports.GetPolicyCommand = GetPolicyCommand; +//# sourceMappingURL=GetPolicyCommand.js.map + +/***/ }), + +/***/ 51843: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetPolicyVersionCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about the specified policy version.
+ */ +class GetPolicyVersionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetPolicyVersionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetPolicyVersionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetPolicyVersionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetPolicyVersionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetPolicyVersionCommand(output, context); + } +} +exports.GetPolicyVersionCommand = GetPolicyVersionCommand; +//# sourceMappingURL=GetPolicyVersionCommand.js.map + +/***/ }), + +/***/ 22069: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetRegistrationCodeCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets a registration code used to register a CA certificate with AWS IoT.
+ */ +class GetRegistrationCodeCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetRegistrationCodeCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetRegistrationCodeRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetRegistrationCodeResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetRegistrationCodeCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetRegistrationCodeCommand(output, context); + } +} +exports.GetRegistrationCodeCommand = GetRegistrationCodeCommand; +//# sourceMappingURL=GetRegistrationCodeCommand.js.map + +/***/ }), + +/***/ 36408: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetStatisticsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns the count, average, sum, minimum, maximum, sum of squares, variance,
+ * and standard deviation for the specified aggregated field. If the aggregation field is of type
+ * String
, only the count statistic is returned.
Gets information about the rule.
+ */ +class GetTopicRuleCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetTopicRuleCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetTopicRuleRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetTopicRuleResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetTopicRuleCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetTopicRuleCommand(output, context); + } +} +exports.GetTopicRuleCommand = GetTopicRuleCommand; +//# sourceMappingURL=GetTopicRuleCommand.js.map + +/***/ }), + +/***/ 93616: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetTopicRuleDestinationCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets information about a topic rule destination.
+ */ +class GetTopicRuleDestinationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetTopicRuleDestinationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetTopicRuleDestinationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetTopicRuleDestinationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetTopicRuleDestinationCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetTopicRuleDestinationCommand(output, context); + } +} +exports.GetTopicRuleDestinationCommand = GetTopicRuleDestinationCommand; +//# sourceMappingURL=GetTopicRuleDestinationCommand.js.map + +/***/ }), + +/***/ 23036: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetV2LoggingOptionsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the fine grained logging options.
+ */ +class GetV2LoggingOptionsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "GetV2LoggingOptionsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.GetV2LoggingOptionsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.GetV2LoggingOptionsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1GetV2LoggingOptionsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1GetV2LoggingOptionsCommand(output, context); + } +} +exports.GetV2LoggingOptionsCommand = GetV2LoggingOptionsCommand; +//# sourceMappingURL=GetV2LoggingOptionsCommand.js.map + +/***/ }), + +/***/ 90886: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListActiveViolationsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the active violations for a given Device Defender security profile.
+ */ +class ListActiveViolationsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListActiveViolationsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListActiveViolationsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListActiveViolationsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListActiveViolationsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListActiveViolationsCommand(output, context); + } +} +exports.ListActiveViolationsCommand = ListActiveViolationsCommand; +//# sourceMappingURL=ListActiveViolationsCommand.js.map + +/***/ }), + +/***/ 59388: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListAttachedPoliciesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the policies attached to the specified thing group.
+ */ +class ListAttachedPoliciesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListAttachedPoliciesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListAttachedPoliciesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListAttachedPoliciesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListAttachedPoliciesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListAttachedPoliciesCommand(output, context); + } +} +exports.ListAttachedPoliciesCommand = ListAttachedPoliciesCommand; +//# sourceMappingURL=ListAttachedPoliciesCommand.js.map + +/***/ }), + +/***/ 55133: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListAuditFindingsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the findings (results) of a Device Defender audit or of the audits + * performed during a specified time period. (Findings are retained for 90 days.)
+ */ +class ListAuditFindingsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListAuditFindingsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListAuditFindingsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListAuditFindingsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListAuditFindingsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListAuditFindingsCommand(output, context); + } +} +exports.ListAuditFindingsCommand = ListAuditFindingsCommand; +//# sourceMappingURL=ListAuditFindingsCommand.js.map + +/***/ }), + +/***/ 35836: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListAuditMitigationActionsExecutionsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets the status of audit mitigation action tasks that were executed.
+ */ +class ListAuditMitigationActionsExecutionsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListAuditMitigationActionsExecutionsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListAuditMitigationActionsExecutionsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListAuditMitigationActionsExecutionsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListAuditMitigationActionsExecutionsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListAuditMitigationActionsExecutionsCommand(output, context); + } +} +exports.ListAuditMitigationActionsExecutionsCommand = ListAuditMitigationActionsExecutionsCommand; +//# sourceMappingURL=ListAuditMitigationActionsExecutionsCommand.js.map + +/***/ }), + +/***/ 45704: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListAuditMitigationActionsTasksCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets a list of audit mitigation action tasks that match the specified filters.
+ */ +class ListAuditMitigationActionsTasksCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListAuditMitigationActionsTasksCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListAuditMitigationActionsTasksRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListAuditMitigationActionsTasksResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListAuditMitigationActionsTasksCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListAuditMitigationActionsTasksCommand(output, context); + } +} +exports.ListAuditMitigationActionsTasksCommand = ListAuditMitigationActionsTasksCommand; +//# sourceMappingURL=ListAuditMitigationActionsTasksCommand.js.map + +/***/ }), + +/***/ 60827: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListAuditSuppressionsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *+ * Lists your Device Defender audit listings. + *
+ */ +class ListAuditSuppressionsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListAuditSuppressionsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListAuditSuppressionsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListAuditSuppressionsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListAuditSuppressionsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListAuditSuppressionsCommand(output, context); + } +} +exports.ListAuditSuppressionsCommand = ListAuditSuppressionsCommand; +//# sourceMappingURL=ListAuditSuppressionsCommand.js.map + +/***/ }), + +/***/ 50108: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListAuditTasksCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the Device Defender audits that have been performed during a given + * time period.
+ */ +class ListAuditTasksCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListAuditTasksCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListAuditTasksRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListAuditTasksResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListAuditTasksCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListAuditTasksCommand(output, context); + } +} +exports.ListAuditTasksCommand = ListAuditTasksCommand; +//# sourceMappingURL=ListAuditTasksCommand.js.map + +/***/ }), + +/***/ 99389: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListAuthorizersCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the authorizers registered in your account.
+ */ +class ListAuthorizersCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListAuthorizersCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListAuthorizersRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListAuthorizersResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListAuthorizersCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListAuthorizersCommand(output, context); + } +} +exports.ListAuthorizersCommand = ListAuthorizersCommand; +//# sourceMappingURL=ListAuthorizersCommand.js.map + +/***/ }), + +/***/ 13648: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListBillingGroupsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the billing groups you have created.
+ */ +class ListBillingGroupsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListBillingGroupsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListBillingGroupsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListBillingGroupsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListBillingGroupsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListBillingGroupsCommand(output, context); + } +} +exports.ListBillingGroupsCommand = ListBillingGroupsCommand; +//# sourceMappingURL=ListBillingGroupsCommand.js.map + +/***/ }), + +/***/ 77650: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListCACertificatesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the CA certificates registered for your AWS account.
+ *The results are paginated with a default page size of 25. You can use the returned + * marker to retrieve additional results.
+ */ +class ListCACertificatesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListCACertificatesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListCACertificatesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListCACertificatesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListCACertificatesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListCACertificatesCommand(output, context); + } +} +exports.ListCACertificatesCommand = ListCACertificatesCommand; +//# sourceMappingURL=ListCACertificatesCommand.js.map + +/***/ }), + +/***/ 23163: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListCertificatesByCACommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *List the device certificates signed by the specified CA certificate.
+ */ +class ListCertificatesByCACommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListCertificatesByCACommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListCertificatesByCARequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListCertificatesByCAResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListCertificatesByCACommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListCertificatesByCACommand(output, context); + } +} +exports.ListCertificatesByCACommand = ListCertificatesByCACommand; +//# sourceMappingURL=ListCertificatesByCACommand.js.map + +/***/ }), + +/***/ 14749: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListCertificatesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the certificates registered in your AWS account.
+ *The results are paginated with a default page size of 25. You can use the returned + * marker to retrieve additional results.
+ */ +class ListCertificatesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListCertificatesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListCertificatesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListCertificatesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListCertificatesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListCertificatesCommand(output, context); + } +} +exports.ListCertificatesCommand = ListCertificatesCommand; +//# sourceMappingURL=ListCertificatesCommand.js.map + +/***/ }), + +/***/ 74775: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListDimensionsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *List the set of dimensions that are defined for your AWS account.
+ */ +class ListDimensionsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListDimensionsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListDimensionsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListDimensionsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListDimensionsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListDimensionsCommand(output, context); + } +} +exports.ListDimensionsCommand = ListDimensionsCommand; +//# sourceMappingURL=ListDimensionsCommand.js.map + +/***/ }), + +/***/ 75947: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListDomainConfigurationsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets a list of domain configurations for the user. This list is sorted alphabetically by domain configuration name.
+ *The domain configuration feature is in public preview and is subject to change.
+ *Lists the search indices.
+ */ +class ListIndicesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListIndicesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListIndicesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListIndicesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListIndicesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListIndicesCommand(output, context); + } +} +exports.ListIndicesCommand = ListIndicesCommand; +//# sourceMappingURL=ListIndicesCommand.js.map + +/***/ }), + +/***/ 68068: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListJobExecutionsForJobCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the job executions for a job.
+ */ +class ListJobExecutionsForJobCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListJobExecutionsForJobCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListJobExecutionsForJobRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListJobExecutionsForJobResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListJobExecutionsForJobCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListJobExecutionsForJobCommand(output, context); + } +} +exports.ListJobExecutionsForJobCommand = ListJobExecutionsForJobCommand; +//# sourceMappingURL=ListJobExecutionsForJobCommand.js.map + +/***/ }), + +/***/ 20874: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListJobExecutionsForThingCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the job executions for the specified thing.
+ */ +class ListJobExecutionsForThingCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListJobExecutionsForThingCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListJobExecutionsForThingRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListJobExecutionsForThingResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListJobExecutionsForThingCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListJobExecutionsForThingCommand(output, context); + } +} +exports.ListJobExecutionsForThingCommand = ListJobExecutionsForThingCommand; +//# sourceMappingURL=ListJobExecutionsForThingCommand.js.map + +/***/ }), + +/***/ 25341: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListJobsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists jobs.
+ */ +class ListJobsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListJobsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListJobsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListJobsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListJobsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListJobsCommand(output, context); + } +} +exports.ListJobsCommand = ListJobsCommand; +//# sourceMappingURL=ListJobsCommand.js.map + +/***/ }), + +/***/ 93159: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListMitigationActionsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Gets a list of all mitigation actions that match the specified filter criteria.
+ */ +class ListMitigationActionsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListMitigationActionsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListMitigationActionsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListMitigationActionsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListMitigationActionsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListMitigationActionsCommand(output, context); + } +} +exports.ListMitigationActionsCommand = ListMitigationActionsCommand; +//# sourceMappingURL=ListMitigationActionsCommand.js.map + +/***/ }), + +/***/ 76188: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListOTAUpdatesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists OTA updates.
+ */ +class ListOTAUpdatesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListOTAUpdatesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListOTAUpdatesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListOTAUpdatesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListOTAUpdatesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListOTAUpdatesCommand(output, context); + } +} +exports.ListOTAUpdatesCommand = ListOTAUpdatesCommand; +//# sourceMappingURL=ListOTAUpdatesCommand.js.map + +/***/ }), + +/***/ 90321: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListOutgoingCertificatesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists certificates that are being transferred but not yet accepted.
+ */ +class ListOutgoingCertificatesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListOutgoingCertificatesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListOutgoingCertificatesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListOutgoingCertificatesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListOutgoingCertificatesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListOutgoingCertificatesCommand(output, context); + } +} +exports.ListOutgoingCertificatesCommand = ListOutgoingCertificatesCommand; +//# sourceMappingURL=ListOutgoingCertificatesCommand.js.map + +/***/ }), + +/***/ 81192: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListPoliciesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists your policies.
+ */ +class ListPoliciesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListPoliciesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListPoliciesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListPoliciesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListPoliciesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListPoliciesCommand(output, context); + } +} +exports.ListPoliciesCommand = ListPoliciesCommand; +//# sourceMappingURL=ListPoliciesCommand.js.map + +/***/ }), + +/***/ 86657: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListPolicyPrincipalsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + * @deprecated + * + *Lists the principals associated with the specified policy.
+ *+ * Note: This API is deprecated. Please use ListTargetsForPolicy instead.
+ */ +class ListPolicyPrincipalsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListPolicyPrincipalsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListPolicyPrincipalsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListPolicyPrincipalsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListPolicyPrincipalsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListPolicyPrincipalsCommand(output, context); + } +} +exports.ListPolicyPrincipalsCommand = ListPolicyPrincipalsCommand; +//# sourceMappingURL=ListPolicyPrincipalsCommand.js.map + +/***/ }), + +/***/ 21085: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListPolicyVersionsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the versions of the specified policy and identifies the default + * version.
+ */ +class ListPolicyVersionsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListPolicyVersionsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListPolicyVersionsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListPolicyVersionsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListPolicyVersionsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListPolicyVersionsCommand(output, context); + } +} +exports.ListPolicyVersionsCommand = ListPolicyVersionsCommand; +//# sourceMappingURL=ListPolicyVersionsCommand.js.map + +/***/ }), + +/***/ 3702: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListPrincipalPoliciesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + * @deprecated + * + *Lists the policies attached to the specified principal. If you use an Cognito + * identity, the ID must be in AmazonCognito Identity format.
+ *+ * Note: This API is deprecated. Please use ListAttachedPolicies instead.
+ */ +class ListPrincipalPoliciesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListPrincipalPoliciesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListPrincipalPoliciesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListPrincipalPoliciesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListPrincipalPoliciesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListPrincipalPoliciesCommand(output, context); + } +} +exports.ListPrincipalPoliciesCommand = ListPrincipalPoliciesCommand; +//# sourceMappingURL=ListPrincipalPoliciesCommand.js.map + +/***/ }), + +/***/ 62558: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListPrincipalThingsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the things associated with the specified principal. A principal can be X.509 + * certificates, IAM users, groups, and roles, Amazon Cognito identities or federated + * identities.
+ */ +class ListPrincipalThingsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListPrincipalThingsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListPrincipalThingsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListPrincipalThingsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListPrincipalThingsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListPrincipalThingsCommand(output, context); + } +} +exports.ListPrincipalThingsCommand = ListPrincipalThingsCommand; +//# sourceMappingURL=ListPrincipalThingsCommand.js.map + +/***/ }), + +/***/ 48529: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListProvisioningTemplateVersionsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *A list of fleet provisioning template versions.
+ */ +class ListProvisioningTemplateVersionsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListProvisioningTemplateVersionsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListProvisioningTemplateVersionsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListProvisioningTemplateVersionsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListProvisioningTemplateVersionsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListProvisioningTemplateVersionsCommand(output, context); + } +} +exports.ListProvisioningTemplateVersionsCommand = ListProvisioningTemplateVersionsCommand; +//# sourceMappingURL=ListProvisioningTemplateVersionsCommand.js.map + +/***/ }), + +/***/ 59524: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListProvisioningTemplatesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the fleet provisioning templates in your AWS account.
+ */ +class ListProvisioningTemplatesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListProvisioningTemplatesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListProvisioningTemplatesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListProvisioningTemplatesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListProvisioningTemplatesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListProvisioningTemplatesCommand(output, context); + } +} +exports.ListProvisioningTemplatesCommand = ListProvisioningTemplatesCommand; +//# sourceMappingURL=ListProvisioningTemplatesCommand.js.map + +/***/ }), + +/***/ 31543: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListRoleAliasesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the role aliases registered in your account.
+ */ +class ListRoleAliasesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListRoleAliasesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListRoleAliasesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListRoleAliasesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListRoleAliasesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListRoleAliasesCommand(output, context); + } +} +exports.ListRoleAliasesCommand = ListRoleAliasesCommand; +//# sourceMappingURL=ListRoleAliasesCommand.js.map + +/***/ }), + +/***/ 79905: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListScheduledAuditsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists all of your scheduled audits.
+ */ +class ListScheduledAuditsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListScheduledAuditsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListScheduledAuditsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListScheduledAuditsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListScheduledAuditsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListScheduledAuditsCommand(output, context); + } +} +exports.ListScheduledAuditsCommand = ListScheduledAuditsCommand; +//# sourceMappingURL=ListScheduledAuditsCommand.js.map + +/***/ }), + +/***/ 17473: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListSecurityProfilesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the Device Defender security profiles you have created. You can use filters to list only those security + * profiles associated with a thing group or only those associated with your account.
+ */ +class ListSecurityProfilesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListSecurityProfilesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListSecurityProfilesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListSecurityProfilesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListSecurityProfilesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListSecurityProfilesCommand(output, context); + } +} +exports.ListSecurityProfilesCommand = ListSecurityProfilesCommand; +//# sourceMappingURL=ListSecurityProfilesCommand.js.map + +/***/ }), + +/***/ 26323: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListSecurityProfilesForTargetCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the Device Defender security profiles attached to a target (thing group).
+ */ +class ListSecurityProfilesForTargetCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListSecurityProfilesForTargetCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListSecurityProfilesForTargetRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListSecurityProfilesForTargetResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListSecurityProfilesForTargetCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListSecurityProfilesForTargetCommand(output, context); + } +} +exports.ListSecurityProfilesForTargetCommand = ListSecurityProfilesForTargetCommand; +//# sourceMappingURL=ListSecurityProfilesForTargetCommand.js.map + +/***/ }), + +/***/ 76326: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListStreamsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists all of the streams in your AWS account.
+ */ +class ListStreamsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListStreamsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListStreamsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListStreamsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListStreamsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListStreamsCommand(output, context); + } +} +exports.ListStreamsCommand = ListStreamsCommand; +//# sourceMappingURL=ListStreamsCommand.js.map + +/***/ }), + +/***/ 87749: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListTagsForResourceCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the tags (metadata) you have assigned to the resource.
+ */ +class ListTagsForResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListTagsForResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListTagsForResourceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListTagsForResourceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListTagsForResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListTagsForResourceCommand(output, context); + } +} +exports.ListTagsForResourceCommand = ListTagsForResourceCommand; +//# sourceMappingURL=ListTagsForResourceCommand.js.map + +/***/ }), + +/***/ 71438: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListTargetsForPolicyCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *List targets for the specified policy.
+ */ +class ListTargetsForPolicyCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListTargetsForPolicyCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListTargetsForPolicyRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListTargetsForPolicyResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListTargetsForPolicyCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListTargetsForPolicyCommand(output, context); + } +} +exports.ListTargetsForPolicyCommand = ListTargetsForPolicyCommand; +//# sourceMappingURL=ListTargetsForPolicyCommand.js.map + +/***/ }), + +/***/ 47470: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListTargetsForSecurityProfileCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the targets (thing groups) associated with a given Device Defender security profile.
+ */ +class ListTargetsForSecurityProfileCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListTargetsForSecurityProfileCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListTargetsForSecurityProfileRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListTargetsForSecurityProfileResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListTargetsForSecurityProfileCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListTargetsForSecurityProfileCommand(output, context); + } +} +exports.ListTargetsForSecurityProfileCommand = ListTargetsForSecurityProfileCommand; +//# sourceMappingURL=ListTargetsForSecurityProfileCommand.js.map + +/***/ }), + +/***/ 59885: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListThingGroupsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *List the thing groups in your account.
+ */ +class ListThingGroupsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListThingGroupsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListThingGroupsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListThingGroupsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListThingGroupsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListThingGroupsCommand(output, context); + } +} +exports.ListThingGroupsCommand = ListThingGroupsCommand; +//# sourceMappingURL=ListThingGroupsCommand.js.map + +/***/ }), + +/***/ 532: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListThingGroupsForThingCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *List the thing groups to which the specified thing belongs.
+ */ +class ListThingGroupsForThingCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListThingGroupsForThingCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListThingGroupsForThingRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListThingGroupsForThingResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListThingGroupsForThingCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListThingGroupsForThingCommand(output, context); + } +} +exports.ListThingGroupsForThingCommand = ListThingGroupsForThingCommand; +//# sourceMappingURL=ListThingGroupsForThingCommand.js.map + +/***/ }), + +/***/ 18466: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListThingPrincipalsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the principals associated with the specified thing. A principal can be X.509 + * certificates, IAM users, groups, and roles, Amazon Cognito identities or federated + * identities.
+ */ +class ListThingPrincipalsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListThingPrincipalsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListThingPrincipalsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListThingPrincipalsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListThingPrincipalsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListThingPrincipalsCommand(output, context); + } +} +exports.ListThingPrincipalsCommand = ListThingPrincipalsCommand; +//# sourceMappingURL=ListThingPrincipalsCommand.js.map + +/***/ }), + +/***/ 31905: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListThingRegistrationTaskReportsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Information about the thing registration tasks.
+ */ +class ListThingRegistrationTaskReportsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListThingRegistrationTaskReportsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListThingRegistrationTaskReportsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListThingRegistrationTaskReportsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListThingRegistrationTaskReportsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListThingRegistrationTaskReportsCommand(output, context); + } +} +exports.ListThingRegistrationTaskReportsCommand = ListThingRegistrationTaskReportsCommand; +//# sourceMappingURL=ListThingRegistrationTaskReportsCommand.js.map + +/***/ }), + +/***/ 74999: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListThingRegistrationTasksCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *List bulk thing provisioning tasks.
+ */ +class ListThingRegistrationTasksCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListThingRegistrationTasksCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListThingRegistrationTasksRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListThingRegistrationTasksResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListThingRegistrationTasksCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListThingRegistrationTasksCommand(output, context); + } +} +exports.ListThingRegistrationTasksCommand = ListThingRegistrationTasksCommand; +//# sourceMappingURL=ListThingRegistrationTasksCommand.js.map + +/***/ }), + +/***/ 28092: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListThingTypesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the existing thing types.
+ */ +class ListThingTypesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListThingTypesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListThingTypesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListThingTypesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListThingTypesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListThingTypesCommand(output, context); + } +} +exports.ListThingTypesCommand = ListThingTypesCommand; +//# sourceMappingURL=ListThingTypesCommand.js.map + +/***/ }), + +/***/ 1243: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListThingsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists your things. Use the attributeName and
+ * attributeValue parameters to filter your things.
+ * For example, calling ListThings
with attributeName=Color and
+ * attributeValue=Red retrieves all things in the registry that contain an attribute
+ * Color with the value Red.
You will not be charged for calling this API if an Access denied
error is returned. You will also not be charged if no attributes or pagination token was provided in request and no pagination token and no results were returned.
Lists the things you have added to the given billing group.
+ */ +class ListThingsInBillingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListThingsInBillingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListThingsInBillingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListThingsInBillingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListThingsInBillingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListThingsInBillingGroupCommand(output, context); + } +} +exports.ListThingsInBillingGroupCommand = ListThingsInBillingGroupCommand; +//# sourceMappingURL=ListThingsInBillingGroupCommand.js.map + +/***/ }), + +/***/ 33672: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListThingsInThingGroupCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the things in the specified group.
+ */ +class ListThingsInThingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListThingsInThingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListThingsInThingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListThingsInThingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListThingsInThingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListThingsInThingGroupCommand(output, context); + } +} +exports.ListThingsInThingGroupCommand = ListThingsInThingGroupCommand; +//# sourceMappingURL=ListThingsInThingGroupCommand.js.map + +/***/ }), + +/***/ 29621: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListTopicRuleDestinationsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists all the topic rule destinations in your AWS account.
+ */ +class ListTopicRuleDestinationsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListTopicRuleDestinationsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListTopicRuleDestinationsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListTopicRuleDestinationsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListTopicRuleDestinationsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListTopicRuleDestinationsCommand(output, context); + } +} +exports.ListTopicRuleDestinationsCommand = ListTopicRuleDestinationsCommand; +//# sourceMappingURL=ListTopicRuleDestinationsCommand.js.map + +/***/ }), + +/***/ 2823: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListTopicRulesCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the rules for the specific topic.
+ */ +class ListTopicRulesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListTopicRulesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListTopicRulesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListTopicRulesResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListTopicRulesCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListTopicRulesCommand(output, context); + } +} +exports.ListTopicRulesCommand = ListTopicRulesCommand; +//# sourceMappingURL=ListTopicRulesCommand.js.map + +/***/ }), + +/***/ 47492: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListV2LoggingLevelsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists logging levels.
+ */ +class ListV2LoggingLevelsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListV2LoggingLevelsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListV2LoggingLevelsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListV2LoggingLevelsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListV2LoggingLevelsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListV2LoggingLevelsCommand(output, context); + } +} +exports.ListV2LoggingLevelsCommand = ListV2LoggingLevelsCommand; +//# sourceMappingURL=ListV2LoggingLevelsCommand.js.map + +/***/ }), + +/***/ 77560: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListViolationEventsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Lists the Device Defender security profile violations discovered during the given time period. + * You can use filters to limit the results to those alerts issued for a particular security profile, + * behavior, or thing (device).
+ */ +class ListViolationEventsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ListViolationEventsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ListViolationEventsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.ListViolationEventsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ListViolationEventsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ListViolationEventsCommand(output, context); + } +} +exports.ListViolationEventsCommand = ListViolationEventsCommand; +//# sourceMappingURL=ListViolationEventsCommand.js.map + +/***/ }), + +/***/ 97568: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.RegisterCACertificateCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Registers a CA certificate with AWS IoT. This CA certificate can then be used to sign + * device certificates, which can be then registered with AWS IoT. You can register up to 10 + * CA certificates per AWS account that have the same subject field. This enables you to have + * up to 10 certificate authorities sign your device certificates. If you have more than one + * CA certificate registered, make sure you pass the CA certificate when you register your + * device certificates with the RegisterCertificate API.
+ */ +class RegisterCACertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "RegisterCACertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.RegisterCACertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.RegisterCACertificateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1RegisterCACertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1RegisterCACertificateCommand(output, context); + } +} +exports.RegisterCACertificateCommand = RegisterCACertificateCommand; +//# sourceMappingURL=RegisterCACertificateCommand.js.map + +/***/ }), + +/***/ 59389: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.RegisterCertificateCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Registers a device certificate with AWS IoT. If you have more than one CA certificate + * that has the same subject field, you must specify the CA certificate that was used to sign + * the device certificate being registered.
+ */ +class RegisterCertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "RegisterCertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.RegisterCertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.RegisterCertificateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1RegisterCertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1RegisterCertificateCommand(output, context); + } +} +exports.RegisterCertificateCommand = RegisterCertificateCommand; +//# sourceMappingURL=RegisterCertificateCommand.js.map + +/***/ }), + +/***/ 69343: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.RegisterCertificateWithoutCACommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Register a certificate that does not have a certificate authority (CA).
+ */ +class RegisterCertificateWithoutCACommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "RegisterCertificateWithoutCACommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.RegisterCertificateWithoutCARequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.RegisterCertificateWithoutCAResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1RegisterCertificateWithoutCACommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1RegisterCertificateWithoutCACommand(output, context); + } +} +exports.RegisterCertificateWithoutCACommand = RegisterCertificateWithoutCACommand; +//# sourceMappingURL=RegisterCertificateWithoutCACommand.js.map + +/***/ }), + +/***/ 35331: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.RegisterThingCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Provisions a thing in the device registry. RegisterThing calls other AWS IoT control + * plane APIs. These calls might exceed your account level + * AWS IoT Throttling Limits and cause throttle errors. Please contact AWS Customer Support to raise + * your throttling limits if necessary.
+ */ +class RegisterThingCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "RegisterThingCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.RegisterThingRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.RegisterThingResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1RegisterThingCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1RegisterThingCommand(output, context); + } +} +exports.RegisterThingCommand = RegisterThingCommand; +//# sourceMappingURL=RegisterThingCommand.js.map + +/***/ }), + +/***/ 75265: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.RejectCertificateTransferCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Rejects a pending certificate transfer. After AWS IoT rejects a certificate transfer, + * the certificate status changes from PENDING_TRANSFER to + * INACTIVE.
+ *To check for pending certificate transfers, call ListCertificates + * to enumerate your certificates.
+ *This operation can only be called by the transfer destination. After it is called, + * the certificate will be returned to the source's account in the INACTIVE state.
+ */ +class RejectCertificateTransferCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "RejectCertificateTransferCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.RejectCertificateTransferRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1RejectCertificateTransferCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1RejectCertificateTransferCommand(output, context); + } +} +exports.RejectCertificateTransferCommand = RejectCertificateTransferCommand; +//# sourceMappingURL=RejectCertificateTransferCommand.js.map + +/***/ }), + +/***/ 98700: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.RemoveThingFromBillingGroupCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Removes the given thing from the billing group.
+ */ +class RemoveThingFromBillingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "RemoveThingFromBillingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.RemoveThingFromBillingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.RemoveThingFromBillingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1RemoveThingFromBillingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1RemoveThingFromBillingGroupCommand(output, context); + } +} +exports.RemoveThingFromBillingGroupCommand = RemoveThingFromBillingGroupCommand; +//# sourceMappingURL=RemoveThingFromBillingGroupCommand.js.map + +/***/ }), + +/***/ 47706: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.RemoveThingFromThingGroupCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Remove the specified thing from the specified group.
+ *You must specify either a thingGroupArn
or a
+ * thingGroupName
to identify the thing group and
+ * either a thingArn
or a thingName
to
+ * identify the thing to remove from the thing group.
+ *
Replaces the rule. You must specify all parameters for the new rule. Creating rules + * is an administrator-level action. Any user who has permission to create rules will be able + * to access data processed by the rule.
+ */ +class ReplaceTopicRuleCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ReplaceTopicRuleCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.ReplaceTopicRuleRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ReplaceTopicRuleCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ReplaceTopicRuleCommand(output, context); + } +} +exports.ReplaceTopicRuleCommand = ReplaceTopicRuleCommand; +//# sourceMappingURL=ReplaceTopicRuleCommand.js.map + +/***/ }), + +/***/ 8101: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SearchIndexCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *The query search index.
+ */ +class SearchIndexCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "SearchIndexCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.SearchIndexRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.SearchIndexResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1SearchIndexCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1SearchIndexCommand(output, context); + } +} +exports.SearchIndexCommand = SearchIndexCommand; +//# sourceMappingURL=SearchIndexCommand.js.map + +/***/ }), + +/***/ 47153: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SetDefaultAuthorizerCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Sets the default authorizer. This will be used if a websocket connection is made + * without specifying an authorizer.
+ */ +class SetDefaultAuthorizerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "SetDefaultAuthorizerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.SetDefaultAuthorizerRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.SetDefaultAuthorizerResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1SetDefaultAuthorizerCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1SetDefaultAuthorizerCommand(output, context); + } +} +exports.SetDefaultAuthorizerCommand = SetDefaultAuthorizerCommand; +//# sourceMappingURL=SetDefaultAuthorizerCommand.js.map + +/***/ }), + +/***/ 93486: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SetDefaultPolicyVersionCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Sets the specified version of the specified policy as the policy's default + * (operative) version. This action affects all certificates to which the policy is attached. + * To list the principals the policy is attached to, use the ListPrincipalPolicy + * API.
+ */ +class SetDefaultPolicyVersionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "SetDefaultPolicyVersionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.SetDefaultPolicyVersionRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1SetDefaultPolicyVersionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1SetDefaultPolicyVersionCommand(output, context); + } +} +exports.SetDefaultPolicyVersionCommand = SetDefaultPolicyVersionCommand; +//# sourceMappingURL=SetDefaultPolicyVersionCommand.js.map + +/***/ }), + +/***/ 74975: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SetLoggingOptionsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Sets the logging options.
+ *NOTE: use of this command is not recommended. Use SetV2LoggingOptions
+ * instead.
Sets the logging level.
+ */ +class SetV2LoggingLevelCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "SetV2LoggingLevelCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.SetV2LoggingLevelRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1SetV2LoggingLevelCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1SetV2LoggingLevelCommand(output, context); + } +} +exports.SetV2LoggingLevelCommand = SetV2LoggingLevelCommand; +//# sourceMappingURL=SetV2LoggingLevelCommand.js.map + +/***/ }), + +/***/ 56768: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SetV2LoggingOptionsCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Sets the logging options for the V2 logging service.
+ */ +class SetV2LoggingOptionsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "SetV2LoggingOptionsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.SetV2LoggingOptionsRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1SetV2LoggingOptionsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1SetV2LoggingOptionsCommand(output, context); + } +} +exports.SetV2LoggingOptionsCommand = SetV2LoggingOptionsCommand; +//# sourceMappingURL=SetV2LoggingOptionsCommand.js.map + +/***/ }), + +/***/ 67796: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.StartAuditMitigationActionsTaskCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Starts a task that applies a set of mitigation actions to the specified target.
+ */ +class StartAuditMitigationActionsTaskCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "StartAuditMitigationActionsTaskCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.StartAuditMitigationActionsTaskRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.StartAuditMitigationActionsTaskResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1StartAuditMitigationActionsTaskCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1StartAuditMitigationActionsTaskCommand(output, context); + } +} +exports.StartAuditMitigationActionsTaskCommand = StartAuditMitigationActionsTaskCommand; +//# sourceMappingURL=StartAuditMitigationActionsTaskCommand.js.map + +/***/ }), + +/***/ 37467: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.StartOnDemandAuditTaskCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Starts an on-demand Device Defender audit.
+ */ +class StartOnDemandAuditTaskCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "StartOnDemandAuditTaskCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.StartOnDemandAuditTaskRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.StartOnDemandAuditTaskResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1StartOnDemandAuditTaskCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1StartOnDemandAuditTaskCommand(output, context); + } +} +exports.StartOnDemandAuditTaskCommand = StartOnDemandAuditTaskCommand; +//# sourceMappingURL=StartOnDemandAuditTaskCommand.js.map + +/***/ }), + +/***/ 47587: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.StartThingRegistrationTaskCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Creates a bulk thing provisioning task.
+ */ +class StartThingRegistrationTaskCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "StartThingRegistrationTaskCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.StartThingRegistrationTaskRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.StartThingRegistrationTaskResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1StartThingRegistrationTaskCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1StartThingRegistrationTaskCommand(output, context); + } +} +exports.StartThingRegistrationTaskCommand = StartThingRegistrationTaskCommand; +//# sourceMappingURL=StartThingRegistrationTaskCommand.js.map + +/***/ }), + +/***/ 84000: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.StopThingRegistrationTaskCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Cancels a bulk thing provisioning task.
+ */ +class StopThingRegistrationTaskCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "StopThingRegistrationTaskCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.StopThingRegistrationTaskRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.StopThingRegistrationTaskResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1StopThingRegistrationTaskCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1StopThingRegistrationTaskCommand(output, context); + } +} +exports.StopThingRegistrationTaskCommand = StopThingRegistrationTaskCommand; +//# sourceMappingURL=StopThingRegistrationTaskCommand.js.map + +/***/ }), + +/***/ 94545: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.TagResourceCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Adds to or modifies the tags of the given resource. Tags are metadata which can be + * used to manage a resource.
+ */ +class TagResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "TagResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.TagResourceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.TagResourceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1TagResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1TagResourceCommand(output, context); + } +} +exports.TagResourceCommand = TagResourceCommand; +//# sourceMappingURL=TagResourceCommand.js.map + +/***/ }), + +/***/ 31855: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.TestAuthorizationCommand = void 0; +const models_1_1 = __nccwpck_require__(29889); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Tests if a specified principal is authorized to perform an AWS IoT action on a + * specified resource. Use this to test and debug the authorization behavior of devices that + * connect to the AWS IoT device gateway.
+ */ +class TestAuthorizationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "TestAuthorizationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_1_1.TestAuthorizationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_1_1.TestAuthorizationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1TestAuthorizationCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1TestAuthorizationCommand(output, context); + } +} +exports.TestAuthorizationCommand = TestAuthorizationCommand; +//# sourceMappingURL=TestAuthorizationCommand.js.map + +/***/ }), + +/***/ 21145: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.TestInvokeAuthorizerCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Tests a custom authorization behavior by invoking a specified custom authorizer. Use + * this to test and debug the custom authorization behavior of devices that connect to the AWS + * IoT device gateway.
+ */ +class TestInvokeAuthorizerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "TestInvokeAuthorizerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.TestInvokeAuthorizerRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.TestInvokeAuthorizerResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1TestInvokeAuthorizerCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1TestInvokeAuthorizerCommand(output, context); + } +} +exports.TestInvokeAuthorizerCommand = TestInvokeAuthorizerCommand; +//# sourceMappingURL=TestInvokeAuthorizerCommand.js.map + +/***/ }), + +/***/ 96463: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.TransferCertificateCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Transfers the specified certificate to the specified AWS account.
+ *You can cancel the transfer until it is acknowledged by the recipient.
+ *No notification is sent to the transfer destination's account. It is up to the caller + * to notify the transfer target.
+ *The certificate being transferred must not be in the ACTIVE state. You can use the + * UpdateCertificate API to deactivate it.
+ *The certificate must not have any policies attached to it. You can use the + * DetachPrincipalPolicy API to detach them.
+ */ +class TransferCertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "TransferCertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.TransferCertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.TransferCertificateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1TransferCertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1TransferCertificateCommand(output, context); + } +} +exports.TransferCertificateCommand = TransferCertificateCommand; +//# sourceMappingURL=TransferCertificateCommand.js.map + +/***/ }), + +/***/ 15850: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UntagResourceCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Removes the given tags (metadata) from the resource.
+ */ +class UntagResourceCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UntagResourceCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UntagResourceRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UntagResourceResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UntagResourceCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UntagResourceCommand(output, context); + } +} +exports.UntagResourceCommand = UntagResourceCommand; +//# sourceMappingURL=UntagResourceCommand.js.map + +/***/ }), + +/***/ 12283: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateAccountAuditConfigurationCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Configures or reconfigures the Device Defender audit settings for this account. + * Settings include how audit notifications are sent and which audit checks are + * enabled or disabled.
+ */ +class UpdateAccountAuditConfigurationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateAccountAuditConfigurationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateAccountAuditConfigurationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateAccountAuditConfigurationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateAccountAuditConfigurationCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateAccountAuditConfigurationCommand(output, context); + } +} +exports.UpdateAccountAuditConfigurationCommand = UpdateAccountAuditConfigurationCommand; +//# sourceMappingURL=UpdateAccountAuditConfigurationCommand.js.map + +/***/ }), + +/***/ 13125: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateAuditSuppressionCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *+ * Updates a Device Defender audit suppression. + *
+ */ +class UpdateAuditSuppressionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateAuditSuppressionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateAuditSuppressionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateAuditSuppressionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateAuditSuppressionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateAuditSuppressionCommand(output, context); + } +} +exports.UpdateAuditSuppressionCommand = UpdateAuditSuppressionCommand; +//# sourceMappingURL=UpdateAuditSuppressionCommand.js.map + +/***/ }), + +/***/ 27955: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateAuthorizerCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates an authorizer.
+ */ +class UpdateAuthorizerCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateAuthorizerCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateAuthorizerRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateAuthorizerResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateAuthorizerCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateAuthorizerCommand(output, context); + } +} +exports.UpdateAuthorizerCommand = UpdateAuthorizerCommand; +//# sourceMappingURL=UpdateAuthorizerCommand.js.map + +/***/ }), + +/***/ 14430: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateBillingGroupCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates information about the billing group.
+ */ +class UpdateBillingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateBillingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateBillingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateBillingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateBillingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateBillingGroupCommand(output, context); + } +} +exports.UpdateBillingGroupCommand = UpdateBillingGroupCommand; +//# sourceMappingURL=UpdateBillingGroupCommand.js.map + +/***/ }), + +/***/ 18036: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateCACertificateCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates a registered CA certificate.
+ */ +class UpdateCACertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateCACertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateCACertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateCACertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateCACertificateCommand(output, context); + } +} +exports.UpdateCACertificateCommand = UpdateCACertificateCommand; +//# sourceMappingURL=UpdateCACertificateCommand.js.map + +/***/ }), + +/***/ 30885: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateCertificateCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the status of the specified certificate. This operation is + * idempotent.
+ *Certificates must be in the ACTIVE state to authenticate devices that use + * a certificate to connect to AWS IoT.
+ *Within a few minutes of updating a certificate from the ACTIVE state to any other + * state, AWS IoT disconnects all devices that used that certificate to connect. Devices cannot + * use a certificate that is not in the ACTIVE state to reconnect.
+ */ +class UpdateCertificateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateCertificateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateCertificateRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateCertificateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateCertificateCommand(output, context); + } +} +exports.UpdateCertificateCommand = UpdateCertificateCommand; +//# sourceMappingURL=UpdateCertificateCommand.js.map + +/***/ }), + +/***/ 52162: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateDimensionCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the definition for a dimension. You cannot change the type of a dimension after it is created (you can delete it and re-create it).
+ */ +class UpdateDimensionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateDimensionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateDimensionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateDimensionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateDimensionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateDimensionCommand(output, context); + } +} +exports.UpdateDimensionCommand = UpdateDimensionCommand; +//# sourceMappingURL=UpdateDimensionCommand.js.map + +/***/ }), + +/***/ 89212: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateDomainConfigurationCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates values stored in the domain configuration. Domain configurations for default endpoints can't be updated.
+ *The domain configuration feature is in public preview and is subject to change.
+ *Updates a dynamic thing group.
+ */ +class UpdateDynamicThingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateDynamicThingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateDynamicThingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateDynamicThingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateDynamicThingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateDynamicThingGroupCommand(output, context); + } +} +exports.UpdateDynamicThingGroupCommand = UpdateDynamicThingGroupCommand; +//# sourceMappingURL=UpdateDynamicThingGroupCommand.js.map + +/***/ }), + +/***/ 90134: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateEventConfigurationsCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the event configurations.
+ */ +class UpdateEventConfigurationsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateEventConfigurationsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateEventConfigurationsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateEventConfigurationsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateEventConfigurationsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateEventConfigurationsCommand(output, context); + } +} +exports.UpdateEventConfigurationsCommand = UpdateEventConfigurationsCommand; +//# sourceMappingURL=UpdateEventConfigurationsCommand.js.map + +/***/ }), + +/***/ 40352: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateIndexingConfigurationCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the search configuration.
+ */ +class UpdateIndexingConfigurationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateIndexingConfigurationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateIndexingConfigurationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateIndexingConfigurationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateIndexingConfigurationCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateIndexingConfigurationCommand(output, context); + } +} +exports.UpdateIndexingConfigurationCommand = UpdateIndexingConfigurationCommand; +//# sourceMappingURL=UpdateIndexingConfigurationCommand.js.map + +/***/ }), + +/***/ 22654: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateJobCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates supported fields of the specified job.
+ */ +class UpdateJobCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateJobCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateJobRequest.filterSensitiveLog, + outputFilterSensitiveLog: (output) => output, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateJobCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateJobCommand(output, context); + } +} +exports.UpdateJobCommand = UpdateJobCommand; +//# sourceMappingURL=UpdateJobCommand.js.map + +/***/ }), + +/***/ 57468: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateMitigationActionCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the definition for the specified mitigation action.
+ */ +class UpdateMitigationActionCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateMitigationActionCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateMitigationActionRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateMitigationActionResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateMitigationActionCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateMitigationActionCommand(output, context); + } +} +exports.UpdateMitigationActionCommand = UpdateMitigationActionCommand; +//# sourceMappingURL=UpdateMitigationActionCommand.js.map + +/***/ }), + +/***/ 72154: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateProvisioningTemplateCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates a fleet provisioning template.
+ */ +class UpdateProvisioningTemplateCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateProvisioningTemplateCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateProvisioningTemplateRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateProvisioningTemplateResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateProvisioningTemplateCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateProvisioningTemplateCommand(output, context); + } +} +exports.UpdateProvisioningTemplateCommand = UpdateProvisioningTemplateCommand; +//# sourceMappingURL=UpdateProvisioningTemplateCommand.js.map + +/***/ }), + +/***/ 47584: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateRoleAliasCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates a role alias.
+ */ +class UpdateRoleAliasCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateRoleAliasCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateRoleAliasRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateRoleAliasResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateRoleAliasCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateRoleAliasCommand(output, context); + } +} +exports.UpdateRoleAliasCommand = UpdateRoleAliasCommand; +//# sourceMappingURL=UpdateRoleAliasCommand.js.map + +/***/ }), + +/***/ 45277: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateScheduledAuditCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates a scheduled audit, including which checks are performed and + * how often the audit takes place.
+ */ +class UpdateScheduledAuditCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateScheduledAuditCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateScheduledAuditRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateScheduledAuditResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateScheduledAuditCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateScheduledAuditCommand(output, context); + } +} +exports.UpdateScheduledAuditCommand = UpdateScheduledAuditCommand; +//# sourceMappingURL=UpdateScheduledAuditCommand.js.map + +/***/ }), + +/***/ 21654: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateSecurityProfileCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates a Device Defender security profile.
+ */ +class UpdateSecurityProfileCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateSecurityProfileCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateSecurityProfileRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateSecurityProfileResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateSecurityProfileCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateSecurityProfileCommand(output, context); + } +} +exports.UpdateSecurityProfileCommand = UpdateSecurityProfileCommand; +//# sourceMappingURL=UpdateSecurityProfileCommand.js.map + +/***/ }), + +/***/ 98689: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateStreamCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates an existing stream. The stream version will be incremented by one.
+ */ +class UpdateStreamCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateStreamCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateStreamRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateStreamResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateStreamCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateStreamCommand(output, context); + } +} +exports.UpdateStreamCommand = UpdateStreamCommand; +//# sourceMappingURL=UpdateStreamCommand.js.map + +/***/ }), + +/***/ 51903: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateThingCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the data for a thing.
+ */ +class UpdateThingCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateThingCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateThingRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateThingResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateThingCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateThingCommand(output, context); + } +} +exports.UpdateThingCommand = UpdateThingCommand; +//# sourceMappingURL=UpdateThingCommand.js.map + +/***/ }), + +/***/ 46410: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateThingGroupCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Update a thing group.
+ */ +class UpdateThingGroupCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateThingGroupCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateThingGroupRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateThingGroupResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateThingGroupCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateThingGroupCommand(output, context); + } +} +exports.UpdateThingGroupCommand = UpdateThingGroupCommand; +//# sourceMappingURL=UpdateThingGroupCommand.js.map + +/***/ }), + +/***/ 71585: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateThingGroupsForThingCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates the groups to which the thing belongs.
+ */ +class UpdateThingGroupsForThingCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateThingGroupsForThingCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateThingGroupsForThingRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateThingGroupsForThingResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateThingGroupsForThingCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateThingGroupsForThingCommand(output, context); + } +} +exports.UpdateThingGroupsForThingCommand = UpdateThingGroupsForThingCommand; +//# sourceMappingURL=UpdateThingGroupsForThingCommand.js.map + +/***/ }), + +/***/ 18671: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.UpdateTopicRuleDestinationCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Updates a topic rule destination. You use this to change the status, endpoint URL, or + * confirmation URL of the destination.
+ */ +class UpdateTopicRuleDestinationCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "UpdateTopicRuleDestinationCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.UpdateTopicRuleDestinationRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.UpdateTopicRuleDestinationResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1UpdateTopicRuleDestinationCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1UpdateTopicRuleDestinationCommand(output, context); + } +} +exports.UpdateTopicRuleDestinationCommand = UpdateTopicRuleDestinationCommand; +//# sourceMappingURL=UpdateTopicRuleDestinationCommand.js.map + +/***/ }), + +/***/ 91452: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ValidateSecurityProfileBehaviorsCommand = void 0; +const models_2_1 = __nccwpck_require__(18560); +const Aws_restJson1_1 = __nccwpck_require__(66639); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Validates a Device Defender security profile behaviors specification.
+ */ +class ValidateSecurityProfileBehaviorsCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "IoTClient"; + const commandName = "ValidateSecurityProfileBehaviorsCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_2_1.ValidateSecurityProfileBehaviorsRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_2_1.ValidateSecurityProfileBehaviorsResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_restJson1_1.serializeAws_restJson1ValidateSecurityProfileBehaviorsCommand(input, context); + } + deserialize(output, context) { + return Aws_restJson1_1.deserializeAws_restJson1ValidateSecurityProfileBehaviorsCommand(output, context); + } +} +exports.ValidateSecurityProfileBehaviorsCommand = ValidateSecurityProfileBehaviorsCommand; +//# sourceMappingURL=ValidateSecurityProfileBehaviorsCommand.js.map + +/***/ }), + +/***/ 37987: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.defaultRegionInfoProvider = void 0; +// Partition default templates +const AWS_TEMPLATE = "iot.{region}.amazonaws.com"; +const AWS_CN_TEMPLATE = "iot.{region}.amazonaws.com.cn"; +const AWS_ISO_TEMPLATE = "iot.{region}.c2s.ic.gov"; +const AWS_ISO_B_TEMPLATE = "iot.{region}.sc2s.sgov.gov"; +const AWS_US_GOV_TEMPLATE = "iot.{region}.amazonaws.com"; +// Partition regions +const AWS_REGIONS = new Set([ + "af-south-1", + "ap-east-1", + "ap-northeast-1", + "ap-northeast-2", + "ap-south-1", + "ap-southeast-1", + "ap-southeast-2", + "ca-central-1", + "eu-central-1", + "eu-north-1", + "eu-south-1", + "eu-west-1", + "eu-west-2", + "eu-west-3", + "me-south-1", + "sa-east-1", + "us-east-1", + "us-east-2", + "us-west-1", + "us-west-2", +]); +const AWS_CN_REGIONS = new Set(["cn-north-1", "cn-northwest-1"]); +const AWS_ISO_REGIONS = new Set(["us-iso-east-1"]); +const AWS_ISO_B_REGIONS = new Set(["us-isob-east-1"]); +const AWS_US_GOV_REGIONS = new Set(["us-gov-east-1", "us-gov-west-1"]); +const defaultRegionInfoProvider = (region, options) => { + let regionInfo = undefined; + switch (region) { + // First, try to match exact region names. + case "ap-east-1": + regionInfo = { + hostname: "iot.ap-east-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "ap-northeast-1": + regionInfo = { + hostname: "iot.ap-northeast-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "ap-northeast-2": + regionInfo = { + hostname: "iot.ap-northeast-2.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "ap-south-1": + regionInfo = { + hostname: "iot.ap-south-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "ap-southeast-1": + regionInfo = { + hostname: "iot.ap-southeast-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "ap-southeast-2": + regionInfo = { + hostname: "iot.ap-southeast-2.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "ca-central-1": + regionInfo = { + hostname: "iot.ca-central-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "cn-north-1": + regionInfo = { + hostname: "iot.cn-north-1.amazonaws.com.cn", + partition: "aws-cn", + signingService: "execute-api", + }; + break; + case "cn-northwest-1": + regionInfo = { + hostname: "iot.cn-northwest-1.amazonaws.com.cn", + partition: "aws-cn", + signingService: "execute-api", + }; + break; + case "eu-central-1": + regionInfo = { + hostname: "iot.eu-central-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "eu-north-1": + regionInfo = { + hostname: "iot.eu-north-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "eu-west-1": + regionInfo = { + hostname: "iot.eu-west-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "eu-west-2": + regionInfo = { + hostname: "iot.eu-west-2.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "eu-west-3": + regionInfo = { + hostname: "iot.eu-west-3.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "me-south-1": + regionInfo = { + hostname: "iot.me-south-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "sa-east-1": + regionInfo = { + hostname: "iot.sa-east-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "us-east-1": + regionInfo = { + hostname: "iot.us-east-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "us-east-2": + regionInfo = { + hostname: "iot.us-east-2.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "us-gov-east-1": + regionInfo = { + hostname: "iot.us-gov-east-1.amazonaws.com", + partition: "aws-us-gov", + signingService: "execute-api", + }; + break; + case "us-gov-west-1": + regionInfo = { + hostname: "iot.us-gov-west-1.amazonaws.com", + partition: "aws-us-gov", + signingService: "execute-api", + }; + break; + case "us-west-1": + regionInfo = { + hostname: "iot.us-west-1.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + case "us-west-2": + regionInfo = { + hostname: "iot.us-west-2.amazonaws.com", + partition: "aws", + signingService: "execute-api", + }; + break; + // Next, try to match partition endpoints. + default: + if (AWS_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_TEMPLATE.replace("{region}", region), + partition: "aws", + signingService: "execute-api", + }; + } + if (AWS_CN_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_CN_TEMPLATE.replace("{region}", region), + partition: "aws-cn", + signingService: "execute-api", + }; + } + if (AWS_ISO_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_ISO_TEMPLATE.replace("{region}", region), + partition: "aws-iso", + }; + } + if (AWS_ISO_B_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_ISO_B_TEMPLATE.replace("{region}", region), + partition: "aws-iso-b", + }; + } + if (AWS_US_GOV_REGIONS.has(region)) { + regionInfo = { + hostname: AWS_US_GOV_TEMPLATE.replace("{region}", region), + partition: "aws-us-gov", + signingService: "execute-api", + }; + } + // Finally, assume it's an AWS partition endpoint. + if (regionInfo === undefined) { + regionInfo = { + hostname: AWS_TEMPLATE.replace("{region}", region), + partition: "aws", + signingService: "execute-api", + }; + } + } + return Promise.resolve({ signingService: "execute-api", ...regionInfo }); +}; +exports.defaultRegionInfoProvider = defaultRegionInfoProvider; +//# sourceMappingURL=endpoints.js.map + +/***/ }), + +/***/ 81222: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +const tslib_1 = __nccwpck_require__(3153); +tslib_1.__exportStar(__nccwpck_require__(31450), exports); +tslib_1.__exportStar(__nccwpck_require__(37811), exports); +tslib_1.__exportStar(__nccwpck_require__(56298), exports); +tslib_1.__exportStar(__nccwpck_require__(50444), exports); +tslib_1.__exportStar(__nccwpck_require__(70565), exports); +tslib_1.__exportStar(__nccwpck_require__(35126), exports); +tslib_1.__exportStar(__nccwpck_require__(90420), exports); +tslib_1.__exportStar(__nccwpck_require__(4077), exports); +tslib_1.__exportStar(__nccwpck_require__(36378), exports); +tslib_1.__exportStar(__nccwpck_require__(92532), exports); +tslib_1.__exportStar(__nccwpck_require__(84), exports); +tslib_1.__exportStar(__nccwpck_require__(58801), exports); +tslib_1.__exportStar(__nccwpck_require__(69974), exports); +tslib_1.__exportStar(__nccwpck_require__(62205), exports); +tslib_1.__exportStar(__nccwpck_require__(21972), exports); +tslib_1.__exportStar(__nccwpck_require__(97176), exports); +tslib_1.__exportStar(__nccwpck_require__(83239), exports); +tslib_1.__exportStar(__nccwpck_require__(27690), exports); +tslib_1.__exportStar(__nccwpck_require__(57959), exports); +tslib_1.__exportStar(__nccwpck_require__(81102), exports); +tslib_1.__exportStar(__nccwpck_require__(26470), exports); +tslib_1.__exportStar(__nccwpck_require__(71146), exports); +tslib_1.__exportStar(__nccwpck_require__(18664), exports); +tslib_1.__exportStar(__nccwpck_require__(22271), exports); +tslib_1.__exportStar(__nccwpck_require__(14059), exports); +tslib_1.__exportStar(__nccwpck_require__(4848), exports); +tslib_1.__exportStar(__nccwpck_require__(19583), exports); +tslib_1.__exportStar(__nccwpck_require__(45447), exports); +tslib_1.__exportStar(__nccwpck_require__(35362), exports); +tslib_1.__exportStar(__nccwpck_require__(72718), exports); +tslib_1.__exportStar(__nccwpck_require__(38826), exports); +tslib_1.__exportStar(__nccwpck_require__(79093), exports); +tslib_1.__exportStar(__nccwpck_require__(28951), exports); +tslib_1.__exportStar(__nccwpck_require__(78443), exports); +tslib_1.__exportStar(__nccwpck_require__(6809), exports); +tslib_1.__exportStar(__nccwpck_require__(56822), exports); +tslib_1.__exportStar(__nccwpck_require__(312), exports); +tslib_1.__exportStar(__nccwpck_require__(60949), exports); +tslib_1.__exportStar(__nccwpck_require__(99585), exports); +tslib_1.__exportStar(__nccwpck_require__(76406), exports); +tslib_1.__exportStar(__nccwpck_require__(96982), exports); +tslib_1.__exportStar(__nccwpck_require__(15724), exports); +tslib_1.__exportStar(__nccwpck_require__(4430), exports); +tslib_1.__exportStar(__nccwpck_require__(90704), exports); +tslib_1.__exportStar(__nccwpck_require__(32183), exports); +tslib_1.__exportStar(__nccwpck_require__(56409), exports); +tslib_1.__exportStar(__nccwpck_require__(73697), exports); +tslib_1.__exportStar(__nccwpck_require__(63911), exports); +tslib_1.__exportStar(__nccwpck_require__(91697), exports); +tslib_1.__exportStar(__nccwpck_require__(38666), exports); +tslib_1.__exportStar(__nccwpck_require__(17557), exports); +tslib_1.__exportStar(__nccwpck_require__(22855), exports); +tslib_1.__exportStar(__nccwpck_require__(39671), exports); +tslib_1.__exportStar(__nccwpck_require__(45947), exports); +tslib_1.__exportStar(__nccwpck_require__(52941), exports); +tslib_1.__exportStar(__nccwpck_require__(26106), exports); +tslib_1.__exportStar(__nccwpck_require__(67779), exports); +tslib_1.__exportStar(__nccwpck_require__(11659), exports); +tslib_1.__exportStar(__nccwpck_require__(37562), exports); +tslib_1.__exportStar(__nccwpck_require__(23235), exports); +tslib_1.__exportStar(__nccwpck_require__(42187), exports); +tslib_1.__exportStar(__nccwpck_require__(61685), exports); +tslib_1.__exportStar(__nccwpck_require__(77857), exports); +tslib_1.__exportStar(__nccwpck_require__(68349), exports); +tslib_1.__exportStar(__nccwpck_require__(31281), exports); +tslib_1.__exportStar(__nccwpck_require__(73451), exports); +tslib_1.__exportStar(__nccwpck_require__(36024), exports); +tslib_1.__exportStar(__nccwpck_require__(32270), exports); +tslib_1.__exportStar(__nccwpck_require__(62838), exports); +tslib_1.__exportStar(__nccwpck_require__(35964), exports); +tslib_1.__exportStar(__nccwpck_require__(13748), exports); +tslib_1.__exportStar(__nccwpck_require__(13811), exports); +tslib_1.__exportStar(__nccwpck_require__(91538), exports); +tslib_1.__exportStar(__nccwpck_require__(16532), exports); +tslib_1.__exportStar(__nccwpck_require__(84970), exports); +tslib_1.__exportStar(__nccwpck_require__(74328), exports); +tslib_1.__exportStar(__nccwpck_require__(85629), exports); +tslib_1.__exportStar(__nccwpck_require__(40564), exports); +tslib_1.__exportStar(__nccwpck_require__(42279), exports); +tslib_1.__exportStar(__nccwpck_require__(78585), exports); +tslib_1.__exportStar(__nccwpck_require__(68623), exports); +tslib_1.__exportStar(__nccwpck_require__(46755), exports); +tslib_1.__exportStar(__nccwpck_require__(83673), exports); +tslib_1.__exportStar(__nccwpck_require__(77554), exports); +tslib_1.__exportStar(__nccwpck_require__(87665), exports); +tslib_1.__exportStar(__nccwpck_require__(77948), exports); +tslib_1.__exportStar(__nccwpck_require__(28980), exports); +tslib_1.__exportStar(__nccwpck_require__(65547), exports); +tslib_1.__exportStar(__nccwpck_require__(1175), exports); +tslib_1.__exportStar(__nccwpck_require__(44539), exports); +tslib_1.__exportStar(__nccwpck_require__(34488), exports); +tslib_1.__exportStar(__nccwpck_require__(44504), exports); +tslib_1.__exportStar(__nccwpck_require__(61131), exports); +tslib_1.__exportStar(__nccwpck_require__(22237), exports); +tslib_1.__exportStar(__nccwpck_require__(90953), exports); +tslib_1.__exportStar(__nccwpck_require__(44526), exports); +tslib_1.__exportStar(__nccwpck_require__(19878), exports); +tslib_1.__exportStar(__nccwpck_require__(83198), exports); +tslib_1.__exportStar(__nccwpck_require__(50780), exports); +tslib_1.__exportStar(__nccwpck_require__(17402), exports); +tslib_1.__exportStar(__nccwpck_require__(7189), exports); +tslib_1.__exportStar(__nccwpck_require__(9688), exports); +tslib_1.__exportStar(__nccwpck_require__(71366), exports); +tslib_1.__exportStar(__nccwpck_require__(79248), exports); +tslib_1.__exportStar(__nccwpck_require__(83282), exports); +tslib_1.__exportStar(__nccwpck_require__(19687), exports); +tslib_1.__exportStar(__nccwpck_require__(51757), exports); +tslib_1.__exportStar(__nccwpck_require__(189), exports); +tslib_1.__exportStar(__nccwpck_require__(91665), exports); +tslib_1.__exportStar(__nccwpck_require__(57429), exports); +tslib_1.__exportStar(__nccwpck_require__(24694), exports); +tslib_1.__exportStar(__nccwpck_require__(33048), exports); +tslib_1.__exportStar(__nccwpck_require__(22965), exports); +tslib_1.__exportStar(__nccwpck_require__(51843), exports); +tslib_1.__exportStar(__nccwpck_require__(22069), exports); +tslib_1.__exportStar(__nccwpck_require__(36408), exports); +tslib_1.__exportStar(__nccwpck_require__(82246), exports); +tslib_1.__exportStar(__nccwpck_require__(93616), exports); +tslib_1.__exportStar(__nccwpck_require__(23036), exports); +tslib_1.__exportStar(__nccwpck_require__(90886), exports); +tslib_1.__exportStar(__nccwpck_require__(68814), exports); +tslib_1.__exportStar(__nccwpck_require__(59388), exports); +tslib_1.__exportStar(__nccwpck_require__(58222), exports); +tslib_1.__exportStar(__nccwpck_require__(55133), exports); +tslib_1.__exportStar(__nccwpck_require__(58370), exports); +tslib_1.__exportStar(__nccwpck_require__(35836), exports); +tslib_1.__exportStar(__nccwpck_require__(92447), exports); +tslib_1.__exportStar(__nccwpck_require__(45704), exports); +tslib_1.__exportStar(__nccwpck_require__(67042), exports); +tslib_1.__exportStar(__nccwpck_require__(60827), exports); +tslib_1.__exportStar(__nccwpck_require__(69192), exports); +tslib_1.__exportStar(__nccwpck_require__(50108), exports); +tslib_1.__exportStar(__nccwpck_require__(27418), exports); +tslib_1.__exportStar(__nccwpck_require__(99389), exports); +tslib_1.__exportStar(__nccwpck_require__(92292), exports); +tslib_1.__exportStar(__nccwpck_require__(13648), exports); +tslib_1.__exportStar(__nccwpck_require__(18259), exports); +tslib_1.__exportStar(__nccwpck_require__(77650), exports); +tslib_1.__exportStar(__nccwpck_require__(68779), exports); +tslib_1.__exportStar(__nccwpck_require__(14749), exports); +tslib_1.__exportStar(__nccwpck_require__(6910), exports); +tslib_1.__exportStar(__nccwpck_require__(23163), exports); +tslib_1.__exportStar(__nccwpck_require__(14659), exports); +tslib_1.__exportStar(__nccwpck_require__(74775), exports); +tslib_1.__exportStar(__nccwpck_require__(9723), exports); +tslib_1.__exportStar(__nccwpck_require__(75947), exports); +tslib_1.__exportStar(__nccwpck_require__(138), exports); +tslib_1.__exportStar(__nccwpck_require__(36240), exports); +tslib_1.__exportStar(__nccwpck_require__(5668), exports); +tslib_1.__exportStar(__nccwpck_require__(68068), exports); +tslib_1.__exportStar(__nccwpck_require__(74053), exports); +tslib_1.__exportStar(__nccwpck_require__(20874), exports); +tslib_1.__exportStar(__nccwpck_require__(21477), exports); +tslib_1.__exportStar(__nccwpck_require__(25341), exports); +tslib_1.__exportStar(__nccwpck_require__(7859), exports); +tslib_1.__exportStar(__nccwpck_require__(93159), exports); +tslib_1.__exportStar(__nccwpck_require__(57331), exports); +tslib_1.__exportStar(__nccwpck_require__(76188), exports); +tslib_1.__exportStar(__nccwpck_require__(41916), exports); +tslib_1.__exportStar(__nccwpck_require__(90321), exports); +tslib_1.__exportStar(__nccwpck_require__(92342), exports); +tslib_1.__exportStar(__nccwpck_require__(81192), exports); +tslib_1.__exportStar(__nccwpck_require__(37844), exports); +tslib_1.__exportStar(__nccwpck_require__(86657), exports); +tslib_1.__exportStar(__nccwpck_require__(57302), exports); +tslib_1.__exportStar(__nccwpck_require__(21085), exports); +tslib_1.__exportStar(__nccwpck_require__(3702), exports); +tslib_1.__exportStar(__nccwpck_require__(42167), exports); +tslib_1.__exportStar(__nccwpck_require__(62558), exports); +tslib_1.__exportStar(__nccwpck_require__(24220), exports); +tslib_1.__exportStar(__nccwpck_require__(59524), exports); +tslib_1.__exportStar(__nccwpck_require__(14156), exports); +tslib_1.__exportStar(__nccwpck_require__(48529), exports); +tslib_1.__exportStar(__nccwpck_require__(54754), exports); +tslib_1.__exportStar(__nccwpck_require__(31543), exports); +tslib_1.__exportStar(__nccwpck_require__(9058), exports); +tslib_1.__exportStar(__nccwpck_require__(79905), exports); +tslib_1.__exportStar(__nccwpck_require__(47065), exports); +tslib_1.__exportStar(__nccwpck_require__(17473), exports); +tslib_1.__exportStar(__nccwpck_require__(70383), exports); +tslib_1.__exportStar(__nccwpck_require__(26323), exports); +tslib_1.__exportStar(__nccwpck_require__(99728), exports); +tslib_1.__exportStar(__nccwpck_require__(76326), exports); +tslib_1.__exportStar(__nccwpck_require__(53265), exports); +tslib_1.__exportStar(__nccwpck_require__(87749), exports); +tslib_1.__exportStar(__nccwpck_require__(35733), exports); +tslib_1.__exportStar(__nccwpck_require__(71438), exports); +tslib_1.__exportStar(__nccwpck_require__(12956), exports); +tslib_1.__exportStar(__nccwpck_require__(47470), exports); +tslib_1.__exportStar(__nccwpck_require__(95814), exports); +tslib_1.__exportStar(__nccwpck_require__(59885), exports); +tslib_1.__exportStar(__nccwpck_require__(95068), exports); +tslib_1.__exportStar(__nccwpck_require__(532), exports); +tslib_1.__exportStar(__nccwpck_require__(30363), exports); +tslib_1.__exportStar(__nccwpck_require__(18466), exports); +tslib_1.__exportStar(__nccwpck_require__(3030), exports); +tslib_1.__exportStar(__nccwpck_require__(31905), exports); +tslib_1.__exportStar(__nccwpck_require__(26240), exports); +tslib_1.__exportStar(__nccwpck_require__(74999), exports); +tslib_1.__exportStar(__nccwpck_require__(92400), exports); +tslib_1.__exportStar(__nccwpck_require__(1243), exports); +tslib_1.__exportStar(__nccwpck_require__(36161), exports); +tslib_1.__exportStar(__nccwpck_require__(51357), exports); +tslib_1.__exportStar(__nccwpck_require__(70873), exports); +tslib_1.__exportStar(__nccwpck_require__(33672), exports); +tslib_1.__exportStar(__nccwpck_require__(90446), exports); +tslib_1.__exportStar(__nccwpck_require__(28092), exports); +tslib_1.__exportStar(__nccwpck_require__(38172), exports); +tslib_1.__exportStar(__nccwpck_require__(29621), exports); +tslib_1.__exportStar(__nccwpck_require__(90598), exports); +tslib_1.__exportStar(__nccwpck_require__(2823), exports); +tslib_1.__exportStar(__nccwpck_require__(21749), exports); +tslib_1.__exportStar(__nccwpck_require__(47492), exports); +tslib_1.__exportStar(__nccwpck_require__(56717), exports); +tslib_1.__exportStar(__nccwpck_require__(77560), exports); +tslib_1.__exportStar(__nccwpck_require__(72581), exports); +tslib_1.__exportStar(__nccwpck_require__(97568), exports); +tslib_1.__exportStar(__nccwpck_require__(59389), exports); +tslib_1.__exportStar(__nccwpck_require__(69343), exports); +tslib_1.__exportStar(__nccwpck_require__(35331), exports); +tslib_1.__exportStar(__nccwpck_require__(75265), exports); +tslib_1.__exportStar(__nccwpck_require__(98700), exports); +tslib_1.__exportStar(__nccwpck_require__(47706), exports); +tslib_1.__exportStar(__nccwpck_require__(22174), exports); +tslib_1.__exportStar(__nccwpck_require__(8101), exports); +tslib_1.__exportStar(__nccwpck_require__(47153), exports); +tslib_1.__exportStar(__nccwpck_require__(93486), exports); +tslib_1.__exportStar(__nccwpck_require__(74975), exports); +tslib_1.__exportStar(__nccwpck_require__(63248), exports); +tslib_1.__exportStar(__nccwpck_require__(56768), exports); +tslib_1.__exportStar(__nccwpck_require__(67796), exports); +tslib_1.__exportStar(__nccwpck_require__(37467), exports); +tslib_1.__exportStar(__nccwpck_require__(47587), exports); +tslib_1.__exportStar(__nccwpck_require__(84000), exports); +tslib_1.__exportStar(__nccwpck_require__(94545), exports); +tslib_1.__exportStar(__nccwpck_require__(31855), exports); +tslib_1.__exportStar(__nccwpck_require__(21145), exports); +tslib_1.__exportStar(__nccwpck_require__(96463), exports); +tslib_1.__exportStar(__nccwpck_require__(15850), exports); +tslib_1.__exportStar(__nccwpck_require__(12283), exports); +tslib_1.__exportStar(__nccwpck_require__(13125), exports); +tslib_1.__exportStar(__nccwpck_require__(27955), exports); +tslib_1.__exportStar(__nccwpck_require__(14430), exports); +tslib_1.__exportStar(__nccwpck_require__(18036), exports); +tslib_1.__exportStar(__nccwpck_require__(30885), exports); +tslib_1.__exportStar(__nccwpck_require__(52162), exports); +tslib_1.__exportStar(__nccwpck_require__(89212), exports); +tslib_1.__exportStar(__nccwpck_require__(39452), exports); +tslib_1.__exportStar(__nccwpck_require__(90134), exports); +tslib_1.__exportStar(__nccwpck_require__(40352), exports); +tslib_1.__exportStar(__nccwpck_require__(22654), exports); +tslib_1.__exportStar(__nccwpck_require__(57468), exports); +tslib_1.__exportStar(__nccwpck_require__(72154), exports); +tslib_1.__exportStar(__nccwpck_require__(47584), exports); +tslib_1.__exportStar(__nccwpck_require__(45277), exports); +tslib_1.__exportStar(__nccwpck_require__(21654), exports); +tslib_1.__exportStar(__nccwpck_require__(98689), exports); +tslib_1.__exportStar(__nccwpck_require__(51903), exports); +tslib_1.__exportStar(__nccwpck_require__(46410), exports); +tslib_1.__exportStar(__nccwpck_require__(71585), exports); +tslib_1.__exportStar(__nccwpck_require__(18671), exports); +tslib_1.__exportStar(__nccwpck_require__(91452), exports); +tslib_1.__exportStar(__nccwpck_require__(84794), exports); +tslib_1.__exportStar(__nccwpck_require__(4417), exports); +//# sourceMappingURL=index.js.map + +/***/ }), + +/***/ 4417: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +const tslib_1 = __nccwpck_require__(3153); +tslib_1.__exportStar(__nccwpck_require__(34387), exports); +tslib_1.__exportStar(__nccwpck_require__(29889), exports); +tslib_1.__exportStar(__nccwpck_require__(18560), exports); +//# sourceMappingURL=index.js.map + +/***/ }), + +/***/ 34387: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.MetricValue = exports.StatisticalThreshold = exports.ComparisonOperator = exports.ActionType = exports.Action = exports.TimestreamAction = exports.TimestreamTimestamp = exports.TimestreamDimension = exports.StepFunctionsAction = exports.SqsAction = exports.SnsAction = exports.MessageFormat = exports.SalesforceAction = exports.S3Action = exports.CannedAccessControlList = exports.RepublishAction = exports.LambdaAction = exports.KinesisAction = exports.IotSiteWiseAction = exports.PutAssetPropertyValueEntry = exports.AssetPropertyValue = exports.AssetPropertyVariant = exports.AssetPropertyTimestamp = exports.IotEventsAction = exports.IotAnalyticsAction = exports.HttpAction = exports.HttpActionHeader = exports.HttpAuthorization = exports.SigV4Authorization = exports.FirehoseAction = exports.ElasticsearchAction = exports.DynamoDBv2Action = exports.PutItemInput = exports.DynamoDBAction = exports.DynamoKeyType = exports.CloudwatchMetricAction = exports.CloudwatchLogsAction = exports.CloudwatchAlarmAction = exports.UnauthorizedException = exports.TransferAlreadyCompletedException = exports.ThrottlingException = exports.ServiceUnavailableException = exports.ResourceNotFoundException = exports.InvalidRequestException = exports.InternalFailureException = exports.AcceptCertificateTransferRequest = exports.AbortConfig = exports.AbortCriteria = exports.JobExecutionFailureType = exports.AbortAction = void 0; +exports.AuthDecision = exports.AuditTaskMetadata = exports.AuditTaskType = exports.AuditTaskStatus = exports.AuditSuppression = exports.AuditNotificationType = exports.AuditNotificationTarget = exports.AuditMitigationActionsTaskTarget = exports.TaskStatisticsForAuditCheck = exports.AuditMitigationActionsTaskMetadata = exports.AuditMitigationActionsTaskStatus = exports.AuditMitigationActionExecutionMetadata = exports.AuditMitigationActionsExecutionStatus = exports.AuditFrequency = exports.AuditFinding = exports.AuditFindingSeverity = exports.RelatedResource = exports.NonCompliantResource = exports.ResourceType = exports.ResourceIdentifier = exports.PolicyVersionIdentifier = exports.AuditCheckDetails = exports.AuditCheckRunStatus = exports.AuditCheckConfiguration = exports.AttributePayload = exports.AttachThingPrincipalResponse = exports.AttachThingPrincipalRequest = exports.VersionConflictException = exports.AttachSecurityProfileResponse = exports.AttachSecurityProfileRequest = exports.AttachPrincipalPolicyRequest = exports.AttachPolicyRequest = exports.LimitExceededException = exports.AssociateTargetsWithJobResponse = exports.AssociateTargetsWithJobRequest = exports.Allowed = exports.Policy = exports.AlertTargetType = exports.AlertTarget = exports.AddThingToThingGroupResponse = exports.AddThingToThingGroupRequest = exports.AddThingToBillingGroupResponse = exports.AddThingToBillingGroupRequest = exports.AddThingsToThingGroupParams = exports.MetricToRetain = exports.ActiveViolation = exports.Behavior = exports.MetricDimension = exports.DimensionValueOperator = exports.BehaviorCriteria = void 0; +exports.JobExecutionsRolloutConfig = exports.ExponentialRolloutRate = exports.RateIncreaseCriteria = exports.InvalidQueryException = exports.CreateDynamicThingGroupResponse = exports.CreateDynamicThingGroupRequest = exports.ThingGroupProperties = exports.CreateDomainConfigurationResponse = exports.CreateDomainConfigurationRequest = exports.ServiceType = exports.CertificateValidationException = exports.CreateDimensionResponse = exports.CreateDimensionRequest = exports.DimensionType = exports.CreateCertificateFromCsrResponse = exports.CreateCertificateFromCsrRequest = exports.CreateBillingGroupResponse = exports.CreateBillingGroupRequest = exports.BillingGroupProperties = exports.CreateAuthorizerResponse = exports.CreateAuthorizerRequest = exports.Tag = exports.ResourceAlreadyExistsException = exports.CreateAuditSuppressionResponse = exports.CreateAuditSuppressionRequest = exports.InternalException = exports.ConflictingResourceUpdateException = exports.ConfirmTopicRuleDestinationResponse = exports.ConfirmTopicRuleDestinationRequest = exports.ClearDefaultAuthorizerResponse = exports.ClearDefaultAuthorizerRequest = exports.InvalidStateTransitionException = exports.CancelJobExecutionRequest = exports.CancelJobResponse = exports.CancelJobRequest = exports.CancelCertificateTransferRequest = exports.CancelAuditTaskResponse = exports.CancelAuditTaskRequest = exports.CancelAuditMitigationActionsTaskResponse = exports.CancelAuditMitigationActionsTaskRequest = exports.AutoRegistrationStatus = exports.AuthResult = exports.Denied = exports.ImplicitDeny = exports.ExplicitDeny = exports.AuthorizerSummary = exports.AuthorizerDescription = exports.AuthorizerStatus = exports.AuthorizerConfig = exports.AuthInfo = void 0; +exports.CreatePolicyVersionResponse = exports.CreatePolicyVersionRequest = exports.MalformedPolicyException = exports.CreatePolicyResponse = exports.CreatePolicyRequest = exports.CreateOTAUpdateResponse = exports.OTAUpdateStatus = exports.CreateOTAUpdateRequest = exports.Protocol = exports.OTAUpdateFile = exports.FileLocation = exports._Stream = exports.S3Location = exports.CodeSigning = exports.StartSigningJobParameter = exports.SigningProfileParameter = exports.Destination = exports.S3Destination = exports.CustomCodeSigning = exports.CodeSigningSignature = exports.CodeSigningCertificateChain = exports.AwsJobTimeoutConfig = exports.AwsJobPresignedUrlConfig = exports.AwsJobExecutionsRolloutConfig = exports.AwsJobExponentialRolloutRate = exports.AwsJobRateIncreaseCriteria = exports.AwsJobAbortConfig = exports.AwsJobAbortCriteria = exports.AwsJobAbortCriteriaFailureType = exports.AwsJobAbortCriteriaAbortAction = exports.CreateMitigationActionResponse = exports.CreateMitigationActionRequest = exports.MitigationActionParams = exports.UpdateDeviceCertificateParams = exports.DeviceCertificateUpdateAction = exports.UpdateCACertificateParams = exports.CACertificateUpdateAction = exports.ReplaceDefaultPolicyVersionParams = exports.PolicyTemplateName = exports.PublishFindingToSnsParams = exports.EnableIoTLoggingParams = exports.LogLevel = exports.CreateKeysAndCertificateResponse = exports.KeyPair = exports.CreateKeysAndCertificateRequest = exports.CreateJobResponse = exports.CreateJobRequest = exports.TimeoutConfig = exports.TargetSelection = exports.PresignedUrlConfig = void 0; +exports.DeleteDimensionResponse = exports.DeleteDimensionRequest = exports.DeleteCertificateRequest = exports.DeleteCACertificateResponse = exports.DeleteCACertificateRequest = exports.CertificateStateException = exports.DeleteBillingGroupResponse = exports.DeleteBillingGroupRequest = exports.DeleteConflictException = exports.DeleteAuthorizerResponse = exports.DeleteAuthorizerRequest = exports.DeleteAuditSuppressionResponse = exports.DeleteAuditSuppressionRequest = exports.DeleteAccountAuditConfigurationResponse = exports.DeleteAccountAuditConfigurationRequest = exports.CreateTopicRuleDestinationResponse = exports.TopicRuleDestination = exports.TopicRuleDestinationStatus = exports.HttpUrlDestinationProperties = exports.CreateTopicRuleDestinationRequest = exports.TopicRuleDestinationConfiguration = exports.HttpUrlDestinationConfiguration = exports.SqlParseException = exports.CreateTopicRuleRequest = exports.TopicRulePayload = exports.CreateThingTypeResponse = exports.CreateThingTypeRequest = exports.ThingTypeProperties = exports.CreateThingGroupResponse = exports.CreateThingGroupRequest = exports.CreateThingResponse = exports.CreateThingRequest = exports.CreateStreamResponse = exports.CreateStreamRequest = exports.StreamFile = exports.CreateSecurityProfileResponse = exports.CreateSecurityProfileRequest = exports.CreateScheduledAuditResponse = exports.CreateScheduledAuditRequest = exports.DayOfWeek = exports.CreateRoleAliasResponse = exports.CreateRoleAliasRequest = exports.CreateProvisioningTemplateVersionResponse = exports.CreateProvisioningTemplateVersionRequest = exports.CreateProvisioningTemplateResponse = exports.CreateProvisioningTemplateRequest = exports.ProvisioningHook = exports.CreateProvisioningClaimResponse = exports.CreateProvisioningClaimRequest = exports.VersionsLimitExceededException = void 0; +exports.TaskStatistics = exports.DescribeAuditTaskRequest = exports.DescribeAuditSuppressionResponse = exports.DescribeAuditSuppressionRequest = exports.DescribeAuditMitigationActionsTaskResponse = exports.MitigationAction = exports.DescribeAuditMitigationActionsTaskRequest = exports.DescribeAuditFindingResponse = exports.DescribeAuditFindingRequest = exports.DescribeAccountAuditConfigurationResponse = exports.DescribeAccountAuditConfigurationRequest = exports.DeprecateThingTypeResponse = exports.DeprecateThingTypeRequest = exports.DeleteV2LoggingLevelRequest = exports.LogTargetType = exports.DeleteTopicRuleDestinationResponse = exports.DeleteTopicRuleDestinationRequest = exports.DeleteTopicRuleRequest = exports.DeleteThingTypeResponse = exports.DeleteThingTypeRequest = exports.DeleteThingGroupResponse = exports.DeleteThingGroupRequest = exports.DeleteThingResponse = exports.DeleteThingRequest = exports.DeleteStreamResponse = exports.DeleteStreamRequest = exports.DeleteSecurityProfileResponse = exports.DeleteSecurityProfileRequest = exports.DeleteScheduledAuditResponse = exports.DeleteScheduledAuditRequest = exports.DeleteRoleAliasResponse = exports.DeleteRoleAliasRequest = exports.DeleteRegistrationCodeResponse = exports.DeleteRegistrationCodeRequest = exports.DeleteProvisioningTemplateVersionResponse = exports.DeleteProvisioningTemplateVersionRequest = exports.DeleteProvisioningTemplateResponse = exports.DeleteProvisioningTemplateRequest = exports.DeletePolicyVersionRequest = exports.DeletePolicyRequest = exports.DeleteOTAUpdateResponse = exports.DeleteOTAUpdateRequest = exports.DeleteMitigationActionResponse = exports.DeleteMitigationActionRequest = exports.DeleteJobExecutionRequest = exports.DeleteJobRequest = exports.DeleteDynamicThingGroupResponse = exports.DeleteDynamicThingGroupRequest = exports.DeleteDomainConfigurationResponse = exports.DeleteDomainConfigurationRequest = void 0; +const smithy_client_1 = __nccwpck_require__(84060); +var AbortAction; +(function (AbortAction) { + AbortAction["CANCEL"] = "CANCEL"; +})(AbortAction = exports.AbortAction || (exports.AbortAction = {})); +var JobExecutionFailureType; +(function (JobExecutionFailureType) { + JobExecutionFailureType["ALL"] = "ALL"; + JobExecutionFailureType["FAILED"] = "FAILED"; + JobExecutionFailureType["REJECTED"] = "REJECTED"; + JobExecutionFailureType["TIMED_OUT"] = "TIMED_OUT"; +})(JobExecutionFailureType = exports.JobExecutionFailureType || (exports.JobExecutionFailureType = {})); +var AbortCriteria; +(function (AbortCriteria) { + AbortCriteria.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AbortCriteria = exports.AbortCriteria || (exports.AbortCriteria = {})); +var AbortConfig; +(function (AbortConfig) { + AbortConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AbortConfig = exports.AbortConfig || (exports.AbortConfig = {})); +var AcceptCertificateTransferRequest; +(function (AcceptCertificateTransferRequest) { + AcceptCertificateTransferRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AcceptCertificateTransferRequest = exports.AcceptCertificateTransferRequest || (exports.AcceptCertificateTransferRequest = {})); +var InternalFailureException; +(function (InternalFailureException) { + InternalFailureException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InternalFailureException = exports.InternalFailureException || (exports.InternalFailureException = {})); +var InvalidRequestException; +(function (InvalidRequestException) { + InvalidRequestException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidRequestException = exports.InvalidRequestException || (exports.InvalidRequestException = {})); +var ResourceNotFoundException; +(function (ResourceNotFoundException) { + ResourceNotFoundException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceNotFoundException = exports.ResourceNotFoundException || (exports.ResourceNotFoundException = {})); +var ServiceUnavailableException; +(function (ServiceUnavailableException) { + ServiceUnavailableException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ServiceUnavailableException = exports.ServiceUnavailableException || (exports.ServiceUnavailableException = {})); +var ThrottlingException; +(function (ThrottlingException) { + ThrottlingException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThrottlingException = exports.ThrottlingException || (exports.ThrottlingException = {})); +var TransferAlreadyCompletedException; +(function (TransferAlreadyCompletedException) { + TransferAlreadyCompletedException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TransferAlreadyCompletedException = exports.TransferAlreadyCompletedException || (exports.TransferAlreadyCompletedException = {})); +var UnauthorizedException; +(function (UnauthorizedException) { + UnauthorizedException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UnauthorizedException = exports.UnauthorizedException || (exports.UnauthorizedException = {})); +var CloudwatchAlarmAction; +(function (CloudwatchAlarmAction) { + CloudwatchAlarmAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CloudwatchAlarmAction = exports.CloudwatchAlarmAction || (exports.CloudwatchAlarmAction = {})); +var CloudwatchLogsAction; +(function (CloudwatchLogsAction) { + CloudwatchLogsAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CloudwatchLogsAction = exports.CloudwatchLogsAction || (exports.CloudwatchLogsAction = {})); +var CloudwatchMetricAction; +(function (CloudwatchMetricAction) { + CloudwatchMetricAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CloudwatchMetricAction = exports.CloudwatchMetricAction || (exports.CloudwatchMetricAction = {})); +var DynamoKeyType; +(function (DynamoKeyType) { + DynamoKeyType["NUMBER"] = "NUMBER"; + DynamoKeyType["STRING"] = "STRING"; +})(DynamoKeyType = exports.DynamoKeyType || (exports.DynamoKeyType = {})); +var DynamoDBAction; +(function (DynamoDBAction) { + DynamoDBAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DynamoDBAction = exports.DynamoDBAction || (exports.DynamoDBAction = {})); +var PutItemInput; +(function (PutItemInput) { + PutItemInput.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PutItemInput = exports.PutItemInput || (exports.PutItemInput = {})); +var DynamoDBv2Action; +(function (DynamoDBv2Action) { + DynamoDBv2Action.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DynamoDBv2Action = exports.DynamoDBv2Action || (exports.DynamoDBv2Action = {})); +var ElasticsearchAction; +(function (ElasticsearchAction) { + ElasticsearchAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ElasticsearchAction = exports.ElasticsearchAction || (exports.ElasticsearchAction = {})); +var FirehoseAction; +(function (FirehoseAction) { + FirehoseAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(FirehoseAction = exports.FirehoseAction || (exports.FirehoseAction = {})); +var SigV4Authorization; +(function (SigV4Authorization) { + SigV4Authorization.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SigV4Authorization = exports.SigV4Authorization || (exports.SigV4Authorization = {})); +var HttpAuthorization; +(function (HttpAuthorization) { + HttpAuthorization.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(HttpAuthorization = exports.HttpAuthorization || (exports.HttpAuthorization = {})); +var HttpActionHeader; +(function (HttpActionHeader) { + HttpActionHeader.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(HttpActionHeader = exports.HttpActionHeader || (exports.HttpActionHeader = {})); +var HttpAction; +(function (HttpAction) { + HttpAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(HttpAction = exports.HttpAction || (exports.HttpAction = {})); +var IotAnalyticsAction; +(function (IotAnalyticsAction) { + IotAnalyticsAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(IotAnalyticsAction = exports.IotAnalyticsAction || (exports.IotAnalyticsAction = {})); +var IotEventsAction; +(function (IotEventsAction) { + IotEventsAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(IotEventsAction = exports.IotEventsAction || (exports.IotEventsAction = {})); +var AssetPropertyTimestamp; +(function (AssetPropertyTimestamp) { + AssetPropertyTimestamp.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AssetPropertyTimestamp = exports.AssetPropertyTimestamp || (exports.AssetPropertyTimestamp = {})); +var AssetPropertyVariant; +(function (AssetPropertyVariant) { + AssetPropertyVariant.visit = (value, visitor) => { + if (value.stringValue !== undefined) + return visitor.stringValue(value.stringValue); + if (value.integerValue !== undefined) + return visitor.integerValue(value.integerValue); + if (value.doubleValue !== undefined) + return visitor.doubleValue(value.doubleValue); + if (value.booleanValue !== undefined) + return visitor.booleanValue(value.booleanValue); + return visitor._(value.$unknown[0], value.$unknown[1]); + }; + AssetPropertyVariant.filterSensitiveLog = (obj) => { + if (obj.stringValue !== undefined) + return { stringValue: obj.stringValue }; + if (obj.integerValue !== undefined) + return { integerValue: obj.integerValue }; + if (obj.doubleValue !== undefined) + return { doubleValue: obj.doubleValue }; + if (obj.booleanValue !== undefined) + return { booleanValue: obj.booleanValue }; + if (obj.$unknown !== undefined) + return { [obj.$unknown[0]]: "UNKNOWN" }; + }; +})(AssetPropertyVariant = exports.AssetPropertyVariant || (exports.AssetPropertyVariant = {})); +var AssetPropertyValue; +(function (AssetPropertyValue) { + AssetPropertyValue.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.value && { value: AssetPropertyVariant.filterSensitiveLog(obj.value) }), + }); +})(AssetPropertyValue = exports.AssetPropertyValue || (exports.AssetPropertyValue = {})); +var PutAssetPropertyValueEntry; +(function (PutAssetPropertyValueEntry) { + PutAssetPropertyValueEntry.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.propertyValues && { + propertyValues: obj.propertyValues.map((item) => AssetPropertyValue.filterSensitiveLog(item)), + }), + }); +})(PutAssetPropertyValueEntry = exports.PutAssetPropertyValueEntry || (exports.PutAssetPropertyValueEntry = {})); +var IotSiteWiseAction; +(function (IotSiteWiseAction) { + IotSiteWiseAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(IotSiteWiseAction = exports.IotSiteWiseAction || (exports.IotSiteWiseAction = {})); +var KinesisAction; +(function (KinesisAction) { + KinesisAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(KinesisAction = exports.KinesisAction || (exports.KinesisAction = {})); +var LambdaAction; +(function (LambdaAction) { + LambdaAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LambdaAction = exports.LambdaAction || (exports.LambdaAction = {})); +var RepublishAction; +(function (RepublishAction) { + RepublishAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RepublishAction = exports.RepublishAction || (exports.RepublishAction = {})); +var CannedAccessControlList; +(function (CannedAccessControlList) { + CannedAccessControlList["AuthenticatedRead"] = "authenticated-read"; + CannedAccessControlList["AwsExecRead"] = "aws-exec-read"; + CannedAccessControlList["BucketOwnerFullControl"] = "bucket-owner-full-control"; + CannedAccessControlList["BucketOwnerRead"] = "bucket-owner-read"; + CannedAccessControlList["LogDeliveryWrite"] = "log-delivery-write"; + CannedAccessControlList["Private"] = "private"; + CannedAccessControlList["PublicRead"] = "public-read"; + CannedAccessControlList["PublicReadWrite"] = "public-read-write"; +})(CannedAccessControlList = exports.CannedAccessControlList || (exports.CannedAccessControlList = {})); +var S3Action; +(function (S3Action) { + S3Action.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(S3Action = exports.S3Action || (exports.S3Action = {})); +var SalesforceAction; +(function (SalesforceAction) { + SalesforceAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SalesforceAction = exports.SalesforceAction || (exports.SalesforceAction = {})); +var MessageFormat; +(function (MessageFormat) { + MessageFormat["JSON"] = "JSON"; + MessageFormat["RAW"] = "RAW"; +})(MessageFormat = exports.MessageFormat || (exports.MessageFormat = {})); +var SnsAction; +(function (SnsAction) { + SnsAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SnsAction = exports.SnsAction || (exports.SnsAction = {})); +var SqsAction; +(function (SqsAction) { + SqsAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SqsAction = exports.SqsAction || (exports.SqsAction = {})); +var StepFunctionsAction; +(function (StepFunctionsAction) { + StepFunctionsAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StepFunctionsAction = exports.StepFunctionsAction || (exports.StepFunctionsAction = {})); +var TimestreamDimension; +(function (TimestreamDimension) { + TimestreamDimension.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TimestreamDimension = exports.TimestreamDimension || (exports.TimestreamDimension = {})); +var TimestreamTimestamp; +(function (TimestreamTimestamp) { + TimestreamTimestamp.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TimestreamTimestamp = exports.TimestreamTimestamp || (exports.TimestreamTimestamp = {})); +var TimestreamAction; +(function (TimestreamAction) { + TimestreamAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TimestreamAction = exports.TimestreamAction || (exports.TimestreamAction = {})); +var Action; +(function (Action) { + Action.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Action = exports.Action || (exports.Action = {})); +var ActionType; +(function (ActionType) { + ActionType["CONNECT"] = "CONNECT"; + ActionType["PUBLISH"] = "PUBLISH"; + ActionType["RECEIVE"] = "RECEIVE"; + ActionType["SUBSCRIBE"] = "SUBSCRIBE"; +})(ActionType = exports.ActionType || (exports.ActionType = {})); +var ComparisonOperator; +(function (ComparisonOperator) { + ComparisonOperator["GREATER_THAN"] = "greater-than"; + ComparisonOperator["GREATER_THAN_EQUALS"] = "greater-than-equals"; + ComparisonOperator["IN_CIDR_SET"] = "in-cidr-set"; + ComparisonOperator["IN_PORT_SET"] = "in-port-set"; + ComparisonOperator["LESS_THAN"] = "less-than"; + ComparisonOperator["LESS_THAN_EQUALS"] = "less-than-equals"; + ComparisonOperator["NOT_IN_CIDR_SET"] = "not-in-cidr-set"; + ComparisonOperator["NOT_IN_PORT_SET"] = "not-in-port-set"; +})(ComparisonOperator = exports.ComparisonOperator || (exports.ComparisonOperator = {})); +var StatisticalThreshold; +(function (StatisticalThreshold) { + StatisticalThreshold.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StatisticalThreshold = exports.StatisticalThreshold || (exports.StatisticalThreshold = {})); +var MetricValue; +(function (MetricValue) { + MetricValue.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MetricValue = exports.MetricValue || (exports.MetricValue = {})); +var BehaviorCriteria; +(function (BehaviorCriteria) { + BehaviorCriteria.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(BehaviorCriteria = exports.BehaviorCriteria || (exports.BehaviorCriteria = {})); +var DimensionValueOperator; +(function (DimensionValueOperator) { + DimensionValueOperator["IN"] = "IN"; + DimensionValueOperator["NOT_IN"] = "NOT_IN"; +})(DimensionValueOperator = exports.DimensionValueOperator || (exports.DimensionValueOperator = {})); +var MetricDimension; +(function (MetricDimension) { + MetricDimension.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MetricDimension = exports.MetricDimension || (exports.MetricDimension = {})); +var Behavior; +(function (Behavior) { + Behavior.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Behavior = exports.Behavior || (exports.Behavior = {})); +var ActiveViolation; +(function (ActiveViolation) { + ActiveViolation.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ActiveViolation = exports.ActiveViolation || (exports.ActiveViolation = {})); +var MetricToRetain; +(function (MetricToRetain) { + MetricToRetain.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MetricToRetain = exports.MetricToRetain || (exports.MetricToRetain = {})); +var AddThingsToThingGroupParams; +(function (AddThingsToThingGroupParams) { + AddThingsToThingGroupParams.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AddThingsToThingGroupParams = exports.AddThingsToThingGroupParams || (exports.AddThingsToThingGroupParams = {})); +var AddThingToBillingGroupRequest; +(function (AddThingToBillingGroupRequest) { + AddThingToBillingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AddThingToBillingGroupRequest = exports.AddThingToBillingGroupRequest || (exports.AddThingToBillingGroupRequest = {})); +var AddThingToBillingGroupResponse; +(function (AddThingToBillingGroupResponse) { + AddThingToBillingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AddThingToBillingGroupResponse = exports.AddThingToBillingGroupResponse || (exports.AddThingToBillingGroupResponse = {})); +var AddThingToThingGroupRequest; +(function (AddThingToThingGroupRequest) { + AddThingToThingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AddThingToThingGroupRequest = exports.AddThingToThingGroupRequest || (exports.AddThingToThingGroupRequest = {})); +var AddThingToThingGroupResponse; +(function (AddThingToThingGroupResponse) { + AddThingToThingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AddThingToThingGroupResponse = exports.AddThingToThingGroupResponse || (exports.AddThingToThingGroupResponse = {})); +var AlertTarget; +(function (AlertTarget) { + AlertTarget.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AlertTarget = exports.AlertTarget || (exports.AlertTarget = {})); +var AlertTargetType; +(function (AlertTargetType) { + AlertTargetType["SNS"] = "SNS"; +})(AlertTargetType = exports.AlertTargetType || (exports.AlertTargetType = {})); +var Policy; +(function (Policy) { + Policy.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Policy = exports.Policy || (exports.Policy = {})); +var Allowed; +(function (Allowed) { + Allowed.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Allowed = exports.Allowed || (exports.Allowed = {})); +var AssociateTargetsWithJobRequest; +(function (AssociateTargetsWithJobRequest) { + AssociateTargetsWithJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AssociateTargetsWithJobRequest = exports.AssociateTargetsWithJobRequest || (exports.AssociateTargetsWithJobRequest = {})); +var AssociateTargetsWithJobResponse; +(function (AssociateTargetsWithJobResponse) { + AssociateTargetsWithJobResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AssociateTargetsWithJobResponse = exports.AssociateTargetsWithJobResponse || (exports.AssociateTargetsWithJobResponse = {})); +var LimitExceededException; +(function (LimitExceededException) { + LimitExceededException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LimitExceededException = exports.LimitExceededException || (exports.LimitExceededException = {})); +var AttachPolicyRequest; +(function (AttachPolicyRequest) { + AttachPolicyRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AttachPolicyRequest = exports.AttachPolicyRequest || (exports.AttachPolicyRequest = {})); +var AttachPrincipalPolicyRequest; +(function (AttachPrincipalPolicyRequest) { + AttachPrincipalPolicyRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AttachPrincipalPolicyRequest = exports.AttachPrincipalPolicyRequest || (exports.AttachPrincipalPolicyRequest = {})); +var AttachSecurityProfileRequest; +(function (AttachSecurityProfileRequest) { + AttachSecurityProfileRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AttachSecurityProfileRequest = exports.AttachSecurityProfileRequest || (exports.AttachSecurityProfileRequest = {})); +var AttachSecurityProfileResponse; +(function (AttachSecurityProfileResponse) { + AttachSecurityProfileResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AttachSecurityProfileResponse = exports.AttachSecurityProfileResponse || (exports.AttachSecurityProfileResponse = {})); +var VersionConflictException; +(function (VersionConflictException) { + VersionConflictException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(VersionConflictException = exports.VersionConflictException || (exports.VersionConflictException = {})); +var AttachThingPrincipalRequest; +(function (AttachThingPrincipalRequest) { + AttachThingPrincipalRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AttachThingPrincipalRequest = exports.AttachThingPrincipalRequest || (exports.AttachThingPrincipalRequest = {})); +var AttachThingPrincipalResponse; +(function (AttachThingPrincipalResponse) { + AttachThingPrincipalResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AttachThingPrincipalResponse = exports.AttachThingPrincipalResponse || (exports.AttachThingPrincipalResponse = {})); +var AttributePayload; +(function (AttributePayload) { + AttributePayload.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AttributePayload = exports.AttributePayload || (exports.AttributePayload = {})); +var AuditCheckConfiguration; +(function (AuditCheckConfiguration) { + AuditCheckConfiguration.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuditCheckConfiguration = exports.AuditCheckConfiguration || (exports.AuditCheckConfiguration = {})); +var AuditCheckRunStatus; +(function (AuditCheckRunStatus) { + AuditCheckRunStatus["CANCELED"] = "CANCELED"; + AuditCheckRunStatus["COMPLETED_COMPLIANT"] = "COMPLETED_COMPLIANT"; + AuditCheckRunStatus["COMPLETED_NON_COMPLIANT"] = "COMPLETED_NON_COMPLIANT"; + AuditCheckRunStatus["FAILED"] = "FAILED"; + AuditCheckRunStatus["IN_PROGRESS"] = "IN_PROGRESS"; + AuditCheckRunStatus["WAITING_FOR_DATA_COLLECTION"] = "WAITING_FOR_DATA_COLLECTION"; +})(AuditCheckRunStatus = exports.AuditCheckRunStatus || (exports.AuditCheckRunStatus = {})); +var AuditCheckDetails; +(function (AuditCheckDetails) { + AuditCheckDetails.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuditCheckDetails = exports.AuditCheckDetails || (exports.AuditCheckDetails = {})); +var PolicyVersionIdentifier; +(function (PolicyVersionIdentifier) { + PolicyVersionIdentifier.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PolicyVersionIdentifier = exports.PolicyVersionIdentifier || (exports.PolicyVersionIdentifier = {})); +var ResourceIdentifier; +(function (ResourceIdentifier) { + ResourceIdentifier.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceIdentifier = exports.ResourceIdentifier || (exports.ResourceIdentifier = {})); +var ResourceType; +(function (ResourceType) { + ResourceType["ACCOUNT_SETTINGS"] = "ACCOUNT_SETTINGS"; + ResourceType["CA_CERTIFICATE"] = "CA_CERTIFICATE"; + ResourceType["CLIENT_ID"] = "CLIENT_ID"; + ResourceType["COGNITO_IDENTITY_POOL"] = "COGNITO_IDENTITY_POOL"; + ResourceType["DEVICE_CERTIFICATE"] = "DEVICE_CERTIFICATE"; + ResourceType["IAM_ROLE"] = "IAM_ROLE"; + ResourceType["IOT_POLICY"] = "IOT_POLICY"; + ResourceType["ROLE_ALIAS"] = "ROLE_ALIAS"; +})(ResourceType = exports.ResourceType || (exports.ResourceType = {})); +var NonCompliantResource; +(function (NonCompliantResource) { + NonCompliantResource.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(NonCompliantResource = exports.NonCompliantResource || (exports.NonCompliantResource = {})); +var RelatedResource; +(function (RelatedResource) { + RelatedResource.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RelatedResource = exports.RelatedResource || (exports.RelatedResource = {})); +var AuditFindingSeverity; +(function (AuditFindingSeverity) { + AuditFindingSeverity["CRITICAL"] = "CRITICAL"; + AuditFindingSeverity["HIGH"] = "HIGH"; + AuditFindingSeverity["LOW"] = "LOW"; + AuditFindingSeverity["MEDIUM"] = "MEDIUM"; +})(AuditFindingSeverity = exports.AuditFindingSeverity || (exports.AuditFindingSeverity = {})); +var AuditFinding; +(function (AuditFinding) { + AuditFinding.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuditFinding = exports.AuditFinding || (exports.AuditFinding = {})); +var AuditFrequency; +(function (AuditFrequency) { + AuditFrequency["BIWEEKLY"] = "BIWEEKLY"; + AuditFrequency["DAILY"] = "DAILY"; + AuditFrequency["MONTHLY"] = "MONTHLY"; + AuditFrequency["WEEKLY"] = "WEEKLY"; +})(AuditFrequency = exports.AuditFrequency || (exports.AuditFrequency = {})); +var AuditMitigationActionsExecutionStatus; +(function (AuditMitigationActionsExecutionStatus) { + AuditMitigationActionsExecutionStatus["CANCELED"] = "CANCELED"; + AuditMitigationActionsExecutionStatus["COMPLETED"] = "COMPLETED"; + AuditMitigationActionsExecutionStatus["FAILED"] = "FAILED"; + AuditMitigationActionsExecutionStatus["IN_PROGRESS"] = "IN_PROGRESS"; + AuditMitigationActionsExecutionStatus["PENDING"] = "PENDING"; + AuditMitigationActionsExecutionStatus["SKIPPED"] = "SKIPPED"; +})(AuditMitigationActionsExecutionStatus = exports.AuditMitigationActionsExecutionStatus || (exports.AuditMitigationActionsExecutionStatus = {})); +var AuditMitigationActionExecutionMetadata; +(function (AuditMitigationActionExecutionMetadata) { + AuditMitigationActionExecutionMetadata.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuditMitigationActionExecutionMetadata = exports.AuditMitigationActionExecutionMetadata || (exports.AuditMitigationActionExecutionMetadata = {})); +var AuditMitigationActionsTaskStatus; +(function (AuditMitigationActionsTaskStatus) { + AuditMitigationActionsTaskStatus["CANCELED"] = "CANCELED"; + AuditMitigationActionsTaskStatus["COMPLETED"] = "COMPLETED"; + AuditMitigationActionsTaskStatus["FAILED"] = "FAILED"; + AuditMitigationActionsTaskStatus["IN_PROGRESS"] = "IN_PROGRESS"; +})(AuditMitigationActionsTaskStatus = exports.AuditMitigationActionsTaskStatus || (exports.AuditMitigationActionsTaskStatus = {})); +var AuditMitigationActionsTaskMetadata; +(function (AuditMitigationActionsTaskMetadata) { + AuditMitigationActionsTaskMetadata.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuditMitigationActionsTaskMetadata = exports.AuditMitigationActionsTaskMetadata || (exports.AuditMitigationActionsTaskMetadata = {})); +var TaskStatisticsForAuditCheck; +(function (TaskStatisticsForAuditCheck) { + TaskStatisticsForAuditCheck.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TaskStatisticsForAuditCheck = exports.TaskStatisticsForAuditCheck || (exports.TaskStatisticsForAuditCheck = {})); +var AuditMitigationActionsTaskTarget; +(function (AuditMitigationActionsTaskTarget) { + AuditMitigationActionsTaskTarget.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuditMitigationActionsTaskTarget = exports.AuditMitigationActionsTaskTarget || (exports.AuditMitigationActionsTaskTarget = {})); +var AuditNotificationTarget; +(function (AuditNotificationTarget) { + AuditNotificationTarget.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuditNotificationTarget = exports.AuditNotificationTarget || (exports.AuditNotificationTarget = {})); +var AuditNotificationType; +(function (AuditNotificationType) { + AuditNotificationType["SNS"] = "SNS"; +})(AuditNotificationType = exports.AuditNotificationType || (exports.AuditNotificationType = {})); +var AuditSuppression; +(function (AuditSuppression) { + AuditSuppression.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuditSuppression = exports.AuditSuppression || (exports.AuditSuppression = {})); +var AuditTaskStatus; +(function (AuditTaskStatus) { + AuditTaskStatus["CANCELED"] = "CANCELED"; + AuditTaskStatus["COMPLETED"] = "COMPLETED"; + AuditTaskStatus["FAILED"] = "FAILED"; + AuditTaskStatus["IN_PROGRESS"] = "IN_PROGRESS"; +})(AuditTaskStatus = exports.AuditTaskStatus || (exports.AuditTaskStatus = {})); +var AuditTaskType; +(function (AuditTaskType) { + AuditTaskType["ON_DEMAND_AUDIT_TASK"] = "ON_DEMAND_AUDIT_TASK"; + AuditTaskType["SCHEDULED_AUDIT_TASK"] = "SCHEDULED_AUDIT_TASK"; +})(AuditTaskType = exports.AuditTaskType || (exports.AuditTaskType = {})); +var AuditTaskMetadata; +(function (AuditTaskMetadata) { + AuditTaskMetadata.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuditTaskMetadata = exports.AuditTaskMetadata || (exports.AuditTaskMetadata = {})); +var AuthDecision; +(function (AuthDecision) { + AuthDecision["ALLOWED"] = "ALLOWED"; + AuthDecision["EXPLICIT_DENY"] = "EXPLICIT_DENY"; + AuthDecision["IMPLICIT_DENY"] = "IMPLICIT_DENY"; +})(AuthDecision = exports.AuthDecision || (exports.AuthDecision = {})); +var AuthInfo; +(function (AuthInfo) { + AuthInfo.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuthInfo = exports.AuthInfo || (exports.AuthInfo = {})); +var AuthorizerConfig; +(function (AuthorizerConfig) { + AuthorizerConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuthorizerConfig = exports.AuthorizerConfig || (exports.AuthorizerConfig = {})); +var AuthorizerStatus; +(function (AuthorizerStatus) { + AuthorizerStatus["ACTIVE"] = "ACTIVE"; + AuthorizerStatus["INACTIVE"] = "INACTIVE"; +})(AuthorizerStatus = exports.AuthorizerStatus || (exports.AuthorizerStatus = {})); +var AuthorizerDescription; +(function (AuthorizerDescription) { + AuthorizerDescription.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuthorizerDescription = exports.AuthorizerDescription || (exports.AuthorizerDescription = {})); +var AuthorizerSummary; +(function (AuthorizerSummary) { + AuthorizerSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuthorizerSummary = exports.AuthorizerSummary || (exports.AuthorizerSummary = {})); +var ExplicitDeny; +(function (ExplicitDeny) { + ExplicitDeny.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ExplicitDeny = exports.ExplicitDeny || (exports.ExplicitDeny = {})); +var ImplicitDeny; +(function (ImplicitDeny) { + ImplicitDeny.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ImplicitDeny = exports.ImplicitDeny || (exports.ImplicitDeny = {})); +var Denied; +(function (Denied) { + Denied.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Denied = exports.Denied || (exports.Denied = {})); +var AuthResult; +(function (AuthResult) { + AuthResult.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AuthResult = exports.AuthResult || (exports.AuthResult = {})); +var AutoRegistrationStatus; +(function (AutoRegistrationStatus) { + AutoRegistrationStatus["DISABLE"] = "DISABLE"; + AutoRegistrationStatus["ENABLE"] = "ENABLE"; +})(AutoRegistrationStatus = exports.AutoRegistrationStatus || (exports.AutoRegistrationStatus = {})); +var CancelAuditMitigationActionsTaskRequest; +(function (CancelAuditMitigationActionsTaskRequest) { + CancelAuditMitigationActionsTaskRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CancelAuditMitigationActionsTaskRequest = exports.CancelAuditMitigationActionsTaskRequest || (exports.CancelAuditMitigationActionsTaskRequest = {})); +var CancelAuditMitigationActionsTaskResponse; +(function (CancelAuditMitigationActionsTaskResponse) { + CancelAuditMitigationActionsTaskResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CancelAuditMitigationActionsTaskResponse = exports.CancelAuditMitigationActionsTaskResponse || (exports.CancelAuditMitigationActionsTaskResponse = {})); +var CancelAuditTaskRequest; +(function (CancelAuditTaskRequest) { + CancelAuditTaskRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CancelAuditTaskRequest = exports.CancelAuditTaskRequest || (exports.CancelAuditTaskRequest = {})); +var CancelAuditTaskResponse; +(function (CancelAuditTaskResponse) { + CancelAuditTaskResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CancelAuditTaskResponse = exports.CancelAuditTaskResponse || (exports.CancelAuditTaskResponse = {})); +var CancelCertificateTransferRequest; +(function (CancelCertificateTransferRequest) { + CancelCertificateTransferRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CancelCertificateTransferRequest = exports.CancelCertificateTransferRequest || (exports.CancelCertificateTransferRequest = {})); +var CancelJobRequest; +(function (CancelJobRequest) { + CancelJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CancelJobRequest = exports.CancelJobRequest || (exports.CancelJobRequest = {})); +var CancelJobResponse; +(function (CancelJobResponse) { + CancelJobResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CancelJobResponse = exports.CancelJobResponse || (exports.CancelJobResponse = {})); +var CancelJobExecutionRequest; +(function (CancelJobExecutionRequest) { + CancelJobExecutionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CancelJobExecutionRequest = exports.CancelJobExecutionRequest || (exports.CancelJobExecutionRequest = {})); +var InvalidStateTransitionException; +(function (InvalidStateTransitionException) { + InvalidStateTransitionException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidStateTransitionException = exports.InvalidStateTransitionException || (exports.InvalidStateTransitionException = {})); +var ClearDefaultAuthorizerRequest; +(function (ClearDefaultAuthorizerRequest) { + ClearDefaultAuthorizerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ClearDefaultAuthorizerRequest = exports.ClearDefaultAuthorizerRequest || (exports.ClearDefaultAuthorizerRequest = {})); +var ClearDefaultAuthorizerResponse; +(function (ClearDefaultAuthorizerResponse) { + ClearDefaultAuthorizerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ClearDefaultAuthorizerResponse = exports.ClearDefaultAuthorizerResponse || (exports.ClearDefaultAuthorizerResponse = {})); +var ConfirmTopicRuleDestinationRequest; +(function (ConfirmTopicRuleDestinationRequest) { + ConfirmTopicRuleDestinationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ConfirmTopicRuleDestinationRequest = exports.ConfirmTopicRuleDestinationRequest || (exports.ConfirmTopicRuleDestinationRequest = {})); +var ConfirmTopicRuleDestinationResponse; +(function (ConfirmTopicRuleDestinationResponse) { + ConfirmTopicRuleDestinationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ConfirmTopicRuleDestinationResponse = exports.ConfirmTopicRuleDestinationResponse || (exports.ConfirmTopicRuleDestinationResponse = {})); +var ConflictingResourceUpdateException; +(function (ConflictingResourceUpdateException) { + ConflictingResourceUpdateException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ConflictingResourceUpdateException = exports.ConflictingResourceUpdateException || (exports.ConflictingResourceUpdateException = {})); +var InternalException; +(function (InternalException) { + InternalException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InternalException = exports.InternalException || (exports.InternalException = {})); +var CreateAuditSuppressionRequest; +(function (CreateAuditSuppressionRequest) { + CreateAuditSuppressionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateAuditSuppressionRequest = exports.CreateAuditSuppressionRequest || (exports.CreateAuditSuppressionRequest = {})); +var CreateAuditSuppressionResponse; +(function (CreateAuditSuppressionResponse) { + CreateAuditSuppressionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateAuditSuppressionResponse = exports.CreateAuditSuppressionResponse || (exports.CreateAuditSuppressionResponse = {})); +var ResourceAlreadyExistsException; +(function (ResourceAlreadyExistsException) { + ResourceAlreadyExistsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceAlreadyExistsException = exports.ResourceAlreadyExistsException || (exports.ResourceAlreadyExistsException = {})); +var Tag; +(function (Tag) { + Tag.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Tag = exports.Tag || (exports.Tag = {})); +var CreateAuthorizerRequest; +(function (CreateAuthorizerRequest) { + CreateAuthorizerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateAuthorizerRequest = exports.CreateAuthorizerRequest || (exports.CreateAuthorizerRequest = {})); +var CreateAuthorizerResponse; +(function (CreateAuthorizerResponse) { + CreateAuthorizerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateAuthorizerResponse = exports.CreateAuthorizerResponse || (exports.CreateAuthorizerResponse = {})); +var BillingGroupProperties; +(function (BillingGroupProperties) { + BillingGroupProperties.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(BillingGroupProperties = exports.BillingGroupProperties || (exports.BillingGroupProperties = {})); +var CreateBillingGroupRequest; +(function (CreateBillingGroupRequest) { + CreateBillingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateBillingGroupRequest = exports.CreateBillingGroupRequest || (exports.CreateBillingGroupRequest = {})); +var CreateBillingGroupResponse; +(function (CreateBillingGroupResponse) { + CreateBillingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateBillingGroupResponse = exports.CreateBillingGroupResponse || (exports.CreateBillingGroupResponse = {})); +var CreateCertificateFromCsrRequest; +(function (CreateCertificateFromCsrRequest) { + CreateCertificateFromCsrRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateCertificateFromCsrRequest = exports.CreateCertificateFromCsrRequest || (exports.CreateCertificateFromCsrRequest = {})); +var CreateCertificateFromCsrResponse; +(function (CreateCertificateFromCsrResponse) { + CreateCertificateFromCsrResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateCertificateFromCsrResponse = exports.CreateCertificateFromCsrResponse || (exports.CreateCertificateFromCsrResponse = {})); +var DimensionType; +(function (DimensionType) { + DimensionType["TOPIC_FILTER"] = "TOPIC_FILTER"; +})(DimensionType = exports.DimensionType || (exports.DimensionType = {})); +var CreateDimensionRequest; +(function (CreateDimensionRequest) { + CreateDimensionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateDimensionRequest = exports.CreateDimensionRequest || (exports.CreateDimensionRequest = {})); +var CreateDimensionResponse; +(function (CreateDimensionResponse) { + CreateDimensionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateDimensionResponse = exports.CreateDimensionResponse || (exports.CreateDimensionResponse = {})); +var CertificateValidationException; +(function (CertificateValidationException) { + CertificateValidationException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CertificateValidationException = exports.CertificateValidationException || (exports.CertificateValidationException = {})); +var ServiceType; +(function (ServiceType) { + ServiceType["CREDENTIAL_PROVIDER"] = "CREDENTIAL_PROVIDER"; + ServiceType["DATA"] = "DATA"; + ServiceType["JOBS"] = "JOBS"; +})(ServiceType = exports.ServiceType || (exports.ServiceType = {})); +var CreateDomainConfigurationRequest; +(function (CreateDomainConfigurationRequest) { + CreateDomainConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateDomainConfigurationRequest = exports.CreateDomainConfigurationRequest || (exports.CreateDomainConfigurationRequest = {})); +var CreateDomainConfigurationResponse; +(function (CreateDomainConfigurationResponse) { + CreateDomainConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateDomainConfigurationResponse = exports.CreateDomainConfigurationResponse || (exports.CreateDomainConfigurationResponse = {})); +var ThingGroupProperties; +(function (ThingGroupProperties) { + ThingGroupProperties.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingGroupProperties = exports.ThingGroupProperties || (exports.ThingGroupProperties = {})); +var CreateDynamicThingGroupRequest; +(function (CreateDynamicThingGroupRequest) { + CreateDynamicThingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateDynamicThingGroupRequest = exports.CreateDynamicThingGroupRequest || (exports.CreateDynamicThingGroupRequest = {})); +var CreateDynamicThingGroupResponse; +(function (CreateDynamicThingGroupResponse) { + CreateDynamicThingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateDynamicThingGroupResponse = exports.CreateDynamicThingGroupResponse || (exports.CreateDynamicThingGroupResponse = {})); +var InvalidQueryException; +(function (InvalidQueryException) { + InvalidQueryException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidQueryException = exports.InvalidQueryException || (exports.InvalidQueryException = {})); +var RateIncreaseCriteria; +(function (RateIncreaseCriteria) { + RateIncreaseCriteria.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RateIncreaseCriteria = exports.RateIncreaseCriteria || (exports.RateIncreaseCriteria = {})); +var ExponentialRolloutRate; +(function (ExponentialRolloutRate) { + ExponentialRolloutRate.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ExponentialRolloutRate = exports.ExponentialRolloutRate || (exports.ExponentialRolloutRate = {})); +var JobExecutionsRolloutConfig; +(function (JobExecutionsRolloutConfig) { + JobExecutionsRolloutConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(JobExecutionsRolloutConfig = exports.JobExecutionsRolloutConfig || (exports.JobExecutionsRolloutConfig = {})); +var PresignedUrlConfig; +(function (PresignedUrlConfig) { + PresignedUrlConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PresignedUrlConfig = exports.PresignedUrlConfig || (exports.PresignedUrlConfig = {})); +var TargetSelection; +(function (TargetSelection) { + TargetSelection["CONTINUOUS"] = "CONTINUOUS"; + TargetSelection["SNAPSHOT"] = "SNAPSHOT"; +})(TargetSelection = exports.TargetSelection || (exports.TargetSelection = {})); +var TimeoutConfig; +(function (TimeoutConfig) { + TimeoutConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TimeoutConfig = exports.TimeoutConfig || (exports.TimeoutConfig = {})); +var CreateJobRequest; +(function (CreateJobRequest) { + CreateJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateJobRequest = exports.CreateJobRequest || (exports.CreateJobRequest = {})); +var CreateJobResponse; +(function (CreateJobResponse) { + CreateJobResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateJobResponse = exports.CreateJobResponse || (exports.CreateJobResponse = {})); +var CreateKeysAndCertificateRequest; +(function (CreateKeysAndCertificateRequest) { + CreateKeysAndCertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateKeysAndCertificateRequest = exports.CreateKeysAndCertificateRequest || (exports.CreateKeysAndCertificateRequest = {})); +var KeyPair; +(function (KeyPair) { + KeyPair.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.PrivateKey && { PrivateKey: smithy_client_1.SENSITIVE_STRING }), + }); +})(KeyPair = exports.KeyPair || (exports.KeyPair = {})); +var CreateKeysAndCertificateResponse; +(function (CreateKeysAndCertificateResponse) { + CreateKeysAndCertificateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.keyPair && { keyPair: KeyPair.filterSensitiveLog(obj.keyPair) }), + }); +})(CreateKeysAndCertificateResponse = exports.CreateKeysAndCertificateResponse || (exports.CreateKeysAndCertificateResponse = {})); +var LogLevel; +(function (LogLevel) { + LogLevel["DEBUG"] = "DEBUG"; + LogLevel["DISABLED"] = "DISABLED"; + LogLevel["ERROR"] = "ERROR"; + LogLevel["INFO"] = "INFO"; + LogLevel["WARN"] = "WARN"; +})(LogLevel = exports.LogLevel || (exports.LogLevel = {})); +var EnableIoTLoggingParams; +(function (EnableIoTLoggingParams) { + EnableIoTLoggingParams.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(EnableIoTLoggingParams = exports.EnableIoTLoggingParams || (exports.EnableIoTLoggingParams = {})); +var PublishFindingToSnsParams; +(function (PublishFindingToSnsParams) { + PublishFindingToSnsParams.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PublishFindingToSnsParams = exports.PublishFindingToSnsParams || (exports.PublishFindingToSnsParams = {})); +var PolicyTemplateName; +(function (PolicyTemplateName) { + PolicyTemplateName["BLANK_POLICY"] = "BLANK_POLICY"; +})(PolicyTemplateName = exports.PolicyTemplateName || (exports.PolicyTemplateName = {})); +var ReplaceDefaultPolicyVersionParams; +(function (ReplaceDefaultPolicyVersionParams) { + ReplaceDefaultPolicyVersionParams.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ReplaceDefaultPolicyVersionParams = exports.ReplaceDefaultPolicyVersionParams || (exports.ReplaceDefaultPolicyVersionParams = {})); +var CACertificateUpdateAction; +(function (CACertificateUpdateAction) { + CACertificateUpdateAction["DEACTIVATE"] = "DEACTIVATE"; +})(CACertificateUpdateAction = exports.CACertificateUpdateAction || (exports.CACertificateUpdateAction = {})); +var UpdateCACertificateParams; +(function (UpdateCACertificateParams) { + UpdateCACertificateParams.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateCACertificateParams = exports.UpdateCACertificateParams || (exports.UpdateCACertificateParams = {})); +var DeviceCertificateUpdateAction; +(function (DeviceCertificateUpdateAction) { + DeviceCertificateUpdateAction["DEACTIVATE"] = "DEACTIVATE"; +})(DeviceCertificateUpdateAction = exports.DeviceCertificateUpdateAction || (exports.DeviceCertificateUpdateAction = {})); +var UpdateDeviceCertificateParams; +(function (UpdateDeviceCertificateParams) { + UpdateDeviceCertificateParams.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateDeviceCertificateParams = exports.UpdateDeviceCertificateParams || (exports.UpdateDeviceCertificateParams = {})); +var MitigationActionParams; +(function (MitigationActionParams) { + MitigationActionParams.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MitigationActionParams = exports.MitigationActionParams || (exports.MitigationActionParams = {})); +var CreateMitigationActionRequest; +(function (CreateMitigationActionRequest) { + CreateMitigationActionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateMitigationActionRequest = exports.CreateMitigationActionRequest || (exports.CreateMitigationActionRequest = {})); +var CreateMitigationActionResponse; +(function (CreateMitigationActionResponse) { + CreateMitigationActionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateMitigationActionResponse = exports.CreateMitigationActionResponse || (exports.CreateMitigationActionResponse = {})); +var AwsJobAbortCriteriaAbortAction; +(function (AwsJobAbortCriteriaAbortAction) { + AwsJobAbortCriteriaAbortAction["CANCEL"] = "CANCEL"; +})(AwsJobAbortCriteriaAbortAction = exports.AwsJobAbortCriteriaAbortAction || (exports.AwsJobAbortCriteriaAbortAction = {})); +var AwsJobAbortCriteriaFailureType; +(function (AwsJobAbortCriteriaFailureType) { + AwsJobAbortCriteriaFailureType["ALL"] = "ALL"; + AwsJobAbortCriteriaFailureType["FAILED"] = "FAILED"; + AwsJobAbortCriteriaFailureType["REJECTED"] = "REJECTED"; + AwsJobAbortCriteriaFailureType["TIMED_OUT"] = "TIMED_OUT"; +})(AwsJobAbortCriteriaFailureType = exports.AwsJobAbortCriteriaFailureType || (exports.AwsJobAbortCriteriaFailureType = {})); +var AwsJobAbortCriteria; +(function (AwsJobAbortCriteria) { + AwsJobAbortCriteria.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AwsJobAbortCriteria = exports.AwsJobAbortCriteria || (exports.AwsJobAbortCriteria = {})); +var AwsJobAbortConfig; +(function (AwsJobAbortConfig) { + AwsJobAbortConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AwsJobAbortConfig = exports.AwsJobAbortConfig || (exports.AwsJobAbortConfig = {})); +var AwsJobRateIncreaseCriteria; +(function (AwsJobRateIncreaseCriteria) { + AwsJobRateIncreaseCriteria.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AwsJobRateIncreaseCriteria = exports.AwsJobRateIncreaseCriteria || (exports.AwsJobRateIncreaseCriteria = {})); +var AwsJobExponentialRolloutRate; +(function (AwsJobExponentialRolloutRate) { + AwsJobExponentialRolloutRate.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AwsJobExponentialRolloutRate = exports.AwsJobExponentialRolloutRate || (exports.AwsJobExponentialRolloutRate = {})); +var AwsJobExecutionsRolloutConfig; +(function (AwsJobExecutionsRolloutConfig) { + AwsJobExecutionsRolloutConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AwsJobExecutionsRolloutConfig = exports.AwsJobExecutionsRolloutConfig || (exports.AwsJobExecutionsRolloutConfig = {})); +var AwsJobPresignedUrlConfig; +(function (AwsJobPresignedUrlConfig) { + AwsJobPresignedUrlConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AwsJobPresignedUrlConfig = exports.AwsJobPresignedUrlConfig || (exports.AwsJobPresignedUrlConfig = {})); +var AwsJobTimeoutConfig; +(function (AwsJobTimeoutConfig) { + AwsJobTimeoutConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(AwsJobTimeoutConfig = exports.AwsJobTimeoutConfig || (exports.AwsJobTimeoutConfig = {})); +var CodeSigningCertificateChain; +(function (CodeSigningCertificateChain) { + CodeSigningCertificateChain.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CodeSigningCertificateChain = exports.CodeSigningCertificateChain || (exports.CodeSigningCertificateChain = {})); +var CodeSigningSignature; +(function (CodeSigningSignature) { + CodeSigningSignature.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CodeSigningSignature = exports.CodeSigningSignature || (exports.CodeSigningSignature = {})); +var CustomCodeSigning; +(function (CustomCodeSigning) { + CustomCodeSigning.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CustomCodeSigning = exports.CustomCodeSigning || (exports.CustomCodeSigning = {})); +var S3Destination; +(function (S3Destination) { + S3Destination.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(S3Destination = exports.S3Destination || (exports.S3Destination = {})); +var Destination; +(function (Destination) { + Destination.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Destination = exports.Destination || (exports.Destination = {})); +var SigningProfileParameter; +(function (SigningProfileParameter) { + SigningProfileParameter.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SigningProfileParameter = exports.SigningProfileParameter || (exports.SigningProfileParameter = {})); +var StartSigningJobParameter; +(function (StartSigningJobParameter) { + StartSigningJobParameter.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StartSigningJobParameter = exports.StartSigningJobParameter || (exports.StartSigningJobParameter = {})); +var CodeSigning; +(function (CodeSigning) { + CodeSigning.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CodeSigning = exports.CodeSigning || (exports.CodeSigning = {})); +var S3Location; +(function (S3Location) { + S3Location.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(S3Location = exports.S3Location || (exports.S3Location = {})); +var _Stream; +(function (_Stream) { + _Stream.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(_Stream = exports._Stream || (exports._Stream = {})); +var FileLocation; +(function (FileLocation) { + FileLocation.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(FileLocation = exports.FileLocation || (exports.FileLocation = {})); +var OTAUpdateFile; +(function (OTAUpdateFile) { + OTAUpdateFile.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(OTAUpdateFile = exports.OTAUpdateFile || (exports.OTAUpdateFile = {})); +var Protocol; +(function (Protocol) { + Protocol["HTTP"] = "HTTP"; + Protocol["MQTT"] = "MQTT"; +})(Protocol = exports.Protocol || (exports.Protocol = {})); +var CreateOTAUpdateRequest; +(function (CreateOTAUpdateRequest) { + CreateOTAUpdateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateOTAUpdateRequest = exports.CreateOTAUpdateRequest || (exports.CreateOTAUpdateRequest = {})); +var OTAUpdateStatus; +(function (OTAUpdateStatus) { + OTAUpdateStatus["CREATE_COMPLETE"] = "CREATE_COMPLETE"; + OTAUpdateStatus["CREATE_FAILED"] = "CREATE_FAILED"; + OTAUpdateStatus["CREATE_IN_PROGRESS"] = "CREATE_IN_PROGRESS"; + OTAUpdateStatus["CREATE_PENDING"] = "CREATE_PENDING"; +})(OTAUpdateStatus = exports.OTAUpdateStatus || (exports.OTAUpdateStatus = {})); +var CreateOTAUpdateResponse; +(function (CreateOTAUpdateResponse) { + CreateOTAUpdateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateOTAUpdateResponse = exports.CreateOTAUpdateResponse || (exports.CreateOTAUpdateResponse = {})); +var CreatePolicyRequest; +(function (CreatePolicyRequest) { + CreatePolicyRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreatePolicyRequest = exports.CreatePolicyRequest || (exports.CreatePolicyRequest = {})); +var CreatePolicyResponse; +(function (CreatePolicyResponse) { + CreatePolicyResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreatePolicyResponse = exports.CreatePolicyResponse || (exports.CreatePolicyResponse = {})); +var MalformedPolicyException; +(function (MalformedPolicyException) { + MalformedPolicyException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MalformedPolicyException = exports.MalformedPolicyException || (exports.MalformedPolicyException = {})); +var CreatePolicyVersionRequest; +(function (CreatePolicyVersionRequest) { + CreatePolicyVersionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreatePolicyVersionRequest = exports.CreatePolicyVersionRequest || (exports.CreatePolicyVersionRequest = {})); +var CreatePolicyVersionResponse; +(function (CreatePolicyVersionResponse) { + CreatePolicyVersionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreatePolicyVersionResponse = exports.CreatePolicyVersionResponse || (exports.CreatePolicyVersionResponse = {})); +var VersionsLimitExceededException; +(function (VersionsLimitExceededException) { + VersionsLimitExceededException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(VersionsLimitExceededException = exports.VersionsLimitExceededException || (exports.VersionsLimitExceededException = {})); +var CreateProvisioningClaimRequest; +(function (CreateProvisioningClaimRequest) { + CreateProvisioningClaimRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateProvisioningClaimRequest = exports.CreateProvisioningClaimRequest || (exports.CreateProvisioningClaimRequest = {})); +var CreateProvisioningClaimResponse; +(function (CreateProvisioningClaimResponse) { + CreateProvisioningClaimResponse.filterSensitiveLog = (obj) => ({ + ...obj, + ...(obj.keyPair && { keyPair: KeyPair.filterSensitiveLog(obj.keyPair) }), + }); +})(CreateProvisioningClaimResponse = exports.CreateProvisioningClaimResponse || (exports.CreateProvisioningClaimResponse = {})); +var ProvisioningHook; +(function (ProvisioningHook) { + ProvisioningHook.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ProvisioningHook = exports.ProvisioningHook || (exports.ProvisioningHook = {})); +var CreateProvisioningTemplateRequest; +(function (CreateProvisioningTemplateRequest) { + CreateProvisioningTemplateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateProvisioningTemplateRequest = exports.CreateProvisioningTemplateRequest || (exports.CreateProvisioningTemplateRequest = {})); +var CreateProvisioningTemplateResponse; +(function (CreateProvisioningTemplateResponse) { + CreateProvisioningTemplateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateProvisioningTemplateResponse = exports.CreateProvisioningTemplateResponse || (exports.CreateProvisioningTemplateResponse = {})); +var CreateProvisioningTemplateVersionRequest; +(function (CreateProvisioningTemplateVersionRequest) { + CreateProvisioningTemplateVersionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateProvisioningTemplateVersionRequest = exports.CreateProvisioningTemplateVersionRequest || (exports.CreateProvisioningTemplateVersionRequest = {})); +var CreateProvisioningTemplateVersionResponse; +(function (CreateProvisioningTemplateVersionResponse) { + CreateProvisioningTemplateVersionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateProvisioningTemplateVersionResponse = exports.CreateProvisioningTemplateVersionResponse || (exports.CreateProvisioningTemplateVersionResponse = {})); +var CreateRoleAliasRequest; +(function (CreateRoleAliasRequest) { + CreateRoleAliasRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateRoleAliasRequest = exports.CreateRoleAliasRequest || (exports.CreateRoleAliasRequest = {})); +var CreateRoleAliasResponse; +(function (CreateRoleAliasResponse) { + CreateRoleAliasResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateRoleAliasResponse = exports.CreateRoleAliasResponse || (exports.CreateRoleAliasResponse = {})); +var DayOfWeek; +(function (DayOfWeek) { + DayOfWeek["FRI"] = "FRI"; + DayOfWeek["MON"] = "MON"; + DayOfWeek["SAT"] = "SAT"; + DayOfWeek["SUN"] = "SUN"; + DayOfWeek["THU"] = "THU"; + DayOfWeek["TUE"] = "TUE"; + DayOfWeek["WED"] = "WED"; +})(DayOfWeek = exports.DayOfWeek || (exports.DayOfWeek = {})); +var CreateScheduledAuditRequest; +(function (CreateScheduledAuditRequest) { + CreateScheduledAuditRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateScheduledAuditRequest = exports.CreateScheduledAuditRequest || (exports.CreateScheduledAuditRequest = {})); +var CreateScheduledAuditResponse; +(function (CreateScheduledAuditResponse) { + CreateScheduledAuditResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateScheduledAuditResponse = exports.CreateScheduledAuditResponse || (exports.CreateScheduledAuditResponse = {})); +var CreateSecurityProfileRequest; +(function (CreateSecurityProfileRequest) { + CreateSecurityProfileRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateSecurityProfileRequest = exports.CreateSecurityProfileRequest || (exports.CreateSecurityProfileRequest = {})); +var CreateSecurityProfileResponse; +(function (CreateSecurityProfileResponse) { + CreateSecurityProfileResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateSecurityProfileResponse = exports.CreateSecurityProfileResponse || (exports.CreateSecurityProfileResponse = {})); +var StreamFile; +(function (StreamFile) { + StreamFile.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StreamFile = exports.StreamFile || (exports.StreamFile = {})); +var CreateStreamRequest; +(function (CreateStreamRequest) { + CreateStreamRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateStreamRequest = exports.CreateStreamRequest || (exports.CreateStreamRequest = {})); +var CreateStreamResponse; +(function (CreateStreamResponse) { + CreateStreamResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateStreamResponse = exports.CreateStreamResponse || (exports.CreateStreamResponse = {})); +var CreateThingRequest; +(function (CreateThingRequest) { + CreateThingRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateThingRequest = exports.CreateThingRequest || (exports.CreateThingRequest = {})); +var CreateThingResponse; +(function (CreateThingResponse) { + CreateThingResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateThingResponse = exports.CreateThingResponse || (exports.CreateThingResponse = {})); +var CreateThingGroupRequest; +(function (CreateThingGroupRequest) { + CreateThingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateThingGroupRequest = exports.CreateThingGroupRequest || (exports.CreateThingGroupRequest = {})); +var CreateThingGroupResponse; +(function (CreateThingGroupResponse) { + CreateThingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateThingGroupResponse = exports.CreateThingGroupResponse || (exports.CreateThingGroupResponse = {})); +var ThingTypeProperties; +(function (ThingTypeProperties) { + ThingTypeProperties.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingTypeProperties = exports.ThingTypeProperties || (exports.ThingTypeProperties = {})); +var CreateThingTypeRequest; +(function (CreateThingTypeRequest) { + CreateThingTypeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateThingTypeRequest = exports.CreateThingTypeRequest || (exports.CreateThingTypeRequest = {})); +var CreateThingTypeResponse; +(function (CreateThingTypeResponse) { + CreateThingTypeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateThingTypeResponse = exports.CreateThingTypeResponse || (exports.CreateThingTypeResponse = {})); +var TopicRulePayload; +(function (TopicRulePayload) { + TopicRulePayload.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TopicRulePayload = exports.TopicRulePayload || (exports.TopicRulePayload = {})); +var CreateTopicRuleRequest; +(function (CreateTopicRuleRequest) { + CreateTopicRuleRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateTopicRuleRequest = exports.CreateTopicRuleRequest || (exports.CreateTopicRuleRequest = {})); +var SqlParseException; +(function (SqlParseException) { + SqlParseException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SqlParseException = exports.SqlParseException || (exports.SqlParseException = {})); +var HttpUrlDestinationConfiguration; +(function (HttpUrlDestinationConfiguration) { + HttpUrlDestinationConfiguration.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(HttpUrlDestinationConfiguration = exports.HttpUrlDestinationConfiguration || (exports.HttpUrlDestinationConfiguration = {})); +var TopicRuleDestinationConfiguration; +(function (TopicRuleDestinationConfiguration) { + TopicRuleDestinationConfiguration.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TopicRuleDestinationConfiguration = exports.TopicRuleDestinationConfiguration || (exports.TopicRuleDestinationConfiguration = {})); +var CreateTopicRuleDestinationRequest; +(function (CreateTopicRuleDestinationRequest) { + CreateTopicRuleDestinationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateTopicRuleDestinationRequest = exports.CreateTopicRuleDestinationRequest || (exports.CreateTopicRuleDestinationRequest = {})); +var HttpUrlDestinationProperties; +(function (HttpUrlDestinationProperties) { + HttpUrlDestinationProperties.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(HttpUrlDestinationProperties = exports.HttpUrlDestinationProperties || (exports.HttpUrlDestinationProperties = {})); +var TopicRuleDestinationStatus; +(function (TopicRuleDestinationStatus) { + TopicRuleDestinationStatus["DISABLED"] = "DISABLED"; + TopicRuleDestinationStatus["ENABLED"] = "ENABLED"; + TopicRuleDestinationStatus["ERROR"] = "ERROR"; + TopicRuleDestinationStatus["IN_PROGRESS"] = "IN_PROGRESS"; +})(TopicRuleDestinationStatus = exports.TopicRuleDestinationStatus || (exports.TopicRuleDestinationStatus = {})); +var TopicRuleDestination; +(function (TopicRuleDestination) { + TopicRuleDestination.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TopicRuleDestination = exports.TopicRuleDestination || (exports.TopicRuleDestination = {})); +var CreateTopicRuleDestinationResponse; +(function (CreateTopicRuleDestinationResponse) { + CreateTopicRuleDestinationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CreateTopicRuleDestinationResponse = exports.CreateTopicRuleDestinationResponse || (exports.CreateTopicRuleDestinationResponse = {})); +var DeleteAccountAuditConfigurationRequest; +(function (DeleteAccountAuditConfigurationRequest) { + DeleteAccountAuditConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteAccountAuditConfigurationRequest = exports.DeleteAccountAuditConfigurationRequest || (exports.DeleteAccountAuditConfigurationRequest = {})); +var DeleteAccountAuditConfigurationResponse; +(function (DeleteAccountAuditConfigurationResponse) { + DeleteAccountAuditConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteAccountAuditConfigurationResponse = exports.DeleteAccountAuditConfigurationResponse || (exports.DeleteAccountAuditConfigurationResponse = {})); +var DeleteAuditSuppressionRequest; +(function (DeleteAuditSuppressionRequest) { + DeleteAuditSuppressionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteAuditSuppressionRequest = exports.DeleteAuditSuppressionRequest || (exports.DeleteAuditSuppressionRequest = {})); +var DeleteAuditSuppressionResponse; +(function (DeleteAuditSuppressionResponse) { + DeleteAuditSuppressionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteAuditSuppressionResponse = exports.DeleteAuditSuppressionResponse || (exports.DeleteAuditSuppressionResponse = {})); +var DeleteAuthorizerRequest; +(function (DeleteAuthorizerRequest) { + DeleteAuthorizerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteAuthorizerRequest = exports.DeleteAuthorizerRequest || (exports.DeleteAuthorizerRequest = {})); +var DeleteAuthorizerResponse; +(function (DeleteAuthorizerResponse) { + DeleteAuthorizerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteAuthorizerResponse = exports.DeleteAuthorizerResponse || (exports.DeleteAuthorizerResponse = {})); +var DeleteConflictException; +(function (DeleteConflictException) { + DeleteConflictException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteConflictException = exports.DeleteConflictException || (exports.DeleteConflictException = {})); +var DeleteBillingGroupRequest; +(function (DeleteBillingGroupRequest) { + DeleteBillingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteBillingGroupRequest = exports.DeleteBillingGroupRequest || (exports.DeleteBillingGroupRequest = {})); +var DeleteBillingGroupResponse; +(function (DeleteBillingGroupResponse) { + DeleteBillingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteBillingGroupResponse = exports.DeleteBillingGroupResponse || (exports.DeleteBillingGroupResponse = {})); +var CertificateStateException; +(function (CertificateStateException) { + CertificateStateException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CertificateStateException = exports.CertificateStateException || (exports.CertificateStateException = {})); +var DeleteCACertificateRequest; +(function (DeleteCACertificateRequest) { + DeleteCACertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteCACertificateRequest = exports.DeleteCACertificateRequest || (exports.DeleteCACertificateRequest = {})); +var DeleteCACertificateResponse; +(function (DeleteCACertificateResponse) { + DeleteCACertificateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteCACertificateResponse = exports.DeleteCACertificateResponse || (exports.DeleteCACertificateResponse = {})); +var DeleteCertificateRequest; +(function (DeleteCertificateRequest) { + DeleteCertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteCertificateRequest = exports.DeleteCertificateRequest || (exports.DeleteCertificateRequest = {})); +var DeleteDimensionRequest; +(function (DeleteDimensionRequest) { + DeleteDimensionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteDimensionRequest = exports.DeleteDimensionRequest || (exports.DeleteDimensionRequest = {})); +var DeleteDimensionResponse; +(function (DeleteDimensionResponse) { + DeleteDimensionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteDimensionResponse = exports.DeleteDimensionResponse || (exports.DeleteDimensionResponse = {})); +var DeleteDomainConfigurationRequest; +(function (DeleteDomainConfigurationRequest) { + DeleteDomainConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteDomainConfigurationRequest = exports.DeleteDomainConfigurationRequest || (exports.DeleteDomainConfigurationRequest = {})); +var DeleteDomainConfigurationResponse; +(function (DeleteDomainConfigurationResponse) { + DeleteDomainConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteDomainConfigurationResponse = exports.DeleteDomainConfigurationResponse || (exports.DeleteDomainConfigurationResponse = {})); +var DeleteDynamicThingGroupRequest; +(function (DeleteDynamicThingGroupRequest) { + DeleteDynamicThingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteDynamicThingGroupRequest = exports.DeleteDynamicThingGroupRequest || (exports.DeleteDynamicThingGroupRequest = {})); +var DeleteDynamicThingGroupResponse; +(function (DeleteDynamicThingGroupResponse) { + DeleteDynamicThingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteDynamicThingGroupResponse = exports.DeleteDynamicThingGroupResponse || (exports.DeleteDynamicThingGroupResponse = {})); +var DeleteJobRequest; +(function (DeleteJobRequest) { + DeleteJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteJobRequest = exports.DeleteJobRequest || (exports.DeleteJobRequest = {})); +var DeleteJobExecutionRequest; +(function (DeleteJobExecutionRequest) { + DeleteJobExecutionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteJobExecutionRequest = exports.DeleteJobExecutionRequest || (exports.DeleteJobExecutionRequest = {})); +var DeleteMitigationActionRequest; +(function (DeleteMitigationActionRequest) { + DeleteMitigationActionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteMitigationActionRequest = exports.DeleteMitigationActionRequest || (exports.DeleteMitigationActionRequest = {})); +var DeleteMitigationActionResponse; +(function (DeleteMitigationActionResponse) { + DeleteMitigationActionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteMitigationActionResponse = exports.DeleteMitigationActionResponse || (exports.DeleteMitigationActionResponse = {})); +var DeleteOTAUpdateRequest; +(function (DeleteOTAUpdateRequest) { + DeleteOTAUpdateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteOTAUpdateRequest = exports.DeleteOTAUpdateRequest || (exports.DeleteOTAUpdateRequest = {})); +var DeleteOTAUpdateResponse; +(function (DeleteOTAUpdateResponse) { + DeleteOTAUpdateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteOTAUpdateResponse = exports.DeleteOTAUpdateResponse || (exports.DeleteOTAUpdateResponse = {})); +var DeletePolicyRequest; +(function (DeletePolicyRequest) { + DeletePolicyRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeletePolicyRequest = exports.DeletePolicyRequest || (exports.DeletePolicyRequest = {})); +var DeletePolicyVersionRequest; +(function (DeletePolicyVersionRequest) { + DeletePolicyVersionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeletePolicyVersionRequest = exports.DeletePolicyVersionRequest || (exports.DeletePolicyVersionRequest = {})); +var DeleteProvisioningTemplateRequest; +(function (DeleteProvisioningTemplateRequest) { + DeleteProvisioningTemplateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteProvisioningTemplateRequest = exports.DeleteProvisioningTemplateRequest || (exports.DeleteProvisioningTemplateRequest = {})); +var DeleteProvisioningTemplateResponse; +(function (DeleteProvisioningTemplateResponse) { + DeleteProvisioningTemplateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteProvisioningTemplateResponse = exports.DeleteProvisioningTemplateResponse || (exports.DeleteProvisioningTemplateResponse = {})); +var DeleteProvisioningTemplateVersionRequest; +(function (DeleteProvisioningTemplateVersionRequest) { + DeleteProvisioningTemplateVersionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteProvisioningTemplateVersionRequest = exports.DeleteProvisioningTemplateVersionRequest || (exports.DeleteProvisioningTemplateVersionRequest = {})); +var DeleteProvisioningTemplateVersionResponse; +(function (DeleteProvisioningTemplateVersionResponse) { + DeleteProvisioningTemplateVersionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteProvisioningTemplateVersionResponse = exports.DeleteProvisioningTemplateVersionResponse || (exports.DeleteProvisioningTemplateVersionResponse = {})); +var DeleteRegistrationCodeRequest; +(function (DeleteRegistrationCodeRequest) { + DeleteRegistrationCodeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteRegistrationCodeRequest = exports.DeleteRegistrationCodeRequest || (exports.DeleteRegistrationCodeRequest = {})); +var DeleteRegistrationCodeResponse; +(function (DeleteRegistrationCodeResponse) { + DeleteRegistrationCodeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteRegistrationCodeResponse = exports.DeleteRegistrationCodeResponse || (exports.DeleteRegistrationCodeResponse = {})); +var DeleteRoleAliasRequest; +(function (DeleteRoleAliasRequest) { + DeleteRoleAliasRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteRoleAliasRequest = exports.DeleteRoleAliasRequest || (exports.DeleteRoleAliasRequest = {})); +var DeleteRoleAliasResponse; +(function (DeleteRoleAliasResponse) { + DeleteRoleAliasResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteRoleAliasResponse = exports.DeleteRoleAliasResponse || (exports.DeleteRoleAliasResponse = {})); +var DeleteScheduledAuditRequest; +(function (DeleteScheduledAuditRequest) { + DeleteScheduledAuditRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteScheduledAuditRequest = exports.DeleteScheduledAuditRequest || (exports.DeleteScheduledAuditRequest = {})); +var DeleteScheduledAuditResponse; +(function (DeleteScheduledAuditResponse) { + DeleteScheduledAuditResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteScheduledAuditResponse = exports.DeleteScheduledAuditResponse || (exports.DeleteScheduledAuditResponse = {})); +var DeleteSecurityProfileRequest; +(function (DeleteSecurityProfileRequest) { + DeleteSecurityProfileRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteSecurityProfileRequest = exports.DeleteSecurityProfileRequest || (exports.DeleteSecurityProfileRequest = {})); +var DeleteSecurityProfileResponse; +(function (DeleteSecurityProfileResponse) { + DeleteSecurityProfileResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteSecurityProfileResponse = exports.DeleteSecurityProfileResponse || (exports.DeleteSecurityProfileResponse = {})); +var DeleteStreamRequest; +(function (DeleteStreamRequest) { + DeleteStreamRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteStreamRequest = exports.DeleteStreamRequest || (exports.DeleteStreamRequest = {})); +var DeleteStreamResponse; +(function (DeleteStreamResponse) { + DeleteStreamResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteStreamResponse = exports.DeleteStreamResponse || (exports.DeleteStreamResponse = {})); +var DeleteThingRequest; +(function (DeleteThingRequest) { + DeleteThingRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteThingRequest = exports.DeleteThingRequest || (exports.DeleteThingRequest = {})); +var DeleteThingResponse; +(function (DeleteThingResponse) { + DeleteThingResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteThingResponse = exports.DeleteThingResponse || (exports.DeleteThingResponse = {})); +var DeleteThingGroupRequest; +(function (DeleteThingGroupRequest) { + DeleteThingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteThingGroupRequest = exports.DeleteThingGroupRequest || (exports.DeleteThingGroupRequest = {})); +var DeleteThingGroupResponse; +(function (DeleteThingGroupResponse) { + DeleteThingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteThingGroupResponse = exports.DeleteThingGroupResponse || (exports.DeleteThingGroupResponse = {})); +var DeleteThingTypeRequest; +(function (DeleteThingTypeRequest) { + DeleteThingTypeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteThingTypeRequest = exports.DeleteThingTypeRequest || (exports.DeleteThingTypeRequest = {})); +var DeleteThingTypeResponse; +(function (DeleteThingTypeResponse) { + DeleteThingTypeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteThingTypeResponse = exports.DeleteThingTypeResponse || (exports.DeleteThingTypeResponse = {})); +var DeleteTopicRuleRequest; +(function (DeleteTopicRuleRequest) { + DeleteTopicRuleRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteTopicRuleRequest = exports.DeleteTopicRuleRequest || (exports.DeleteTopicRuleRequest = {})); +var DeleteTopicRuleDestinationRequest; +(function (DeleteTopicRuleDestinationRequest) { + DeleteTopicRuleDestinationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteTopicRuleDestinationRequest = exports.DeleteTopicRuleDestinationRequest || (exports.DeleteTopicRuleDestinationRequest = {})); +var DeleteTopicRuleDestinationResponse; +(function (DeleteTopicRuleDestinationResponse) { + DeleteTopicRuleDestinationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteTopicRuleDestinationResponse = exports.DeleteTopicRuleDestinationResponse || (exports.DeleteTopicRuleDestinationResponse = {})); +var LogTargetType; +(function (LogTargetType) { + LogTargetType["DEFAULT"] = "DEFAULT"; + LogTargetType["THING_GROUP"] = "THING_GROUP"; +})(LogTargetType = exports.LogTargetType || (exports.LogTargetType = {})); +var DeleteV2LoggingLevelRequest; +(function (DeleteV2LoggingLevelRequest) { + DeleteV2LoggingLevelRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeleteV2LoggingLevelRequest = exports.DeleteV2LoggingLevelRequest || (exports.DeleteV2LoggingLevelRequest = {})); +var DeprecateThingTypeRequest; +(function (DeprecateThingTypeRequest) { + DeprecateThingTypeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeprecateThingTypeRequest = exports.DeprecateThingTypeRequest || (exports.DeprecateThingTypeRequest = {})); +var DeprecateThingTypeResponse; +(function (DeprecateThingTypeResponse) { + DeprecateThingTypeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DeprecateThingTypeResponse = exports.DeprecateThingTypeResponse || (exports.DeprecateThingTypeResponse = {})); +var DescribeAccountAuditConfigurationRequest; +(function (DescribeAccountAuditConfigurationRequest) { + DescribeAccountAuditConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAccountAuditConfigurationRequest = exports.DescribeAccountAuditConfigurationRequest || (exports.DescribeAccountAuditConfigurationRequest = {})); +var DescribeAccountAuditConfigurationResponse; +(function (DescribeAccountAuditConfigurationResponse) { + DescribeAccountAuditConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAccountAuditConfigurationResponse = exports.DescribeAccountAuditConfigurationResponse || (exports.DescribeAccountAuditConfigurationResponse = {})); +var DescribeAuditFindingRequest; +(function (DescribeAuditFindingRequest) { + DescribeAuditFindingRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAuditFindingRequest = exports.DescribeAuditFindingRequest || (exports.DescribeAuditFindingRequest = {})); +var DescribeAuditFindingResponse; +(function (DescribeAuditFindingResponse) { + DescribeAuditFindingResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAuditFindingResponse = exports.DescribeAuditFindingResponse || (exports.DescribeAuditFindingResponse = {})); +var DescribeAuditMitigationActionsTaskRequest; +(function (DescribeAuditMitigationActionsTaskRequest) { + DescribeAuditMitigationActionsTaskRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAuditMitigationActionsTaskRequest = exports.DescribeAuditMitigationActionsTaskRequest || (exports.DescribeAuditMitigationActionsTaskRequest = {})); +var MitigationAction; +(function (MitigationAction) { + MitigationAction.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MitigationAction = exports.MitigationAction || (exports.MitigationAction = {})); +var DescribeAuditMitigationActionsTaskResponse; +(function (DescribeAuditMitigationActionsTaskResponse) { + DescribeAuditMitigationActionsTaskResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAuditMitigationActionsTaskResponse = exports.DescribeAuditMitigationActionsTaskResponse || (exports.DescribeAuditMitigationActionsTaskResponse = {})); +var DescribeAuditSuppressionRequest; +(function (DescribeAuditSuppressionRequest) { + DescribeAuditSuppressionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAuditSuppressionRequest = exports.DescribeAuditSuppressionRequest || (exports.DescribeAuditSuppressionRequest = {})); +var DescribeAuditSuppressionResponse; +(function (DescribeAuditSuppressionResponse) { + DescribeAuditSuppressionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAuditSuppressionResponse = exports.DescribeAuditSuppressionResponse || (exports.DescribeAuditSuppressionResponse = {})); +var DescribeAuditTaskRequest; +(function (DescribeAuditTaskRequest) { + DescribeAuditTaskRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAuditTaskRequest = exports.DescribeAuditTaskRequest || (exports.DescribeAuditTaskRequest = {})); +var TaskStatistics; +(function (TaskStatistics) { + TaskStatistics.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TaskStatistics = exports.TaskStatistics || (exports.TaskStatistics = {})); +//# sourceMappingURL=models_0.js.map + +/***/ }), + +/***/ 29889: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.DescribeMitigationActionResponse = exports.MitigationActionType = exports.DescribeMitigationActionRequest = exports.DescribeJobExecutionResponse = exports.JobExecution = exports.JobExecutionStatusDetails = exports.JobExecutionStatus = exports.DescribeJobExecutionRequest = exports.DescribeJobResponse = exports.Job = exports.JobStatus = exports.JobProcessDetails = exports.DescribeJobRequest = exports.DescribeIndexResponse = exports.IndexStatus = exports.DescribeIndexRequest = exports.DescribeEventConfigurationsResponse = exports.Configuration = exports.EventType = exports.DescribeEventConfigurationsRequest = exports.DescribeEndpointResponse = exports.DescribeEndpointRequest = exports.DescribeDomainConfigurationResponse = exports.ServerCertificateSummary = exports.ServerCertificateStatus = exports.DomainType = exports.DomainConfigurationStatus = exports.DescribeDomainConfigurationRequest = exports.DescribeDimensionResponse = exports.DescribeDimensionRequest = exports.DescribeDefaultAuthorizerResponse = exports.DescribeDefaultAuthorizerRequest = exports.DescribeCertificateResponse = exports.CertificateDescription = exports.TransferData = exports.CertificateStatus = exports.CertificateMode = exports.DescribeCertificateRequest = exports.DescribeCACertificateResponse = exports.RegistrationConfig = exports.CACertificateDescription = exports.CertificateValidity = exports.CACertificateStatus = exports.DescribeCACertificateRequest = exports.DescribeBillingGroupResponse = exports.BillingGroupMetadata = exports.DescribeBillingGroupRequest = exports.DescribeAuthorizerResponse = exports.DescribeAuthorizerRequest = exports.DescribeAuditTaskResponse = void 0; +exports.ThingIndexingConfiguration = exports.ThingIndexingMode = exports.ThingConnectivityIndexingMode = exports.ThingGroupIndexingConfiguration = exports.ThingGroupIndexingMode = exports.Field = exports.FieldType = exports.GetIndexingConfigurationRequest = exports.GetEffectivePoliciesResponse = exports.EffectivePolicy = exports.GetEffectivePoliciesRequest = exports.InvalidAggregationException = exports.IndexNotReadyException = exports.GetCardinalityResponse = exports.GetCardinalityRequest = exports.EnableTopicRuleRequest = exports.DisableTopicRuleRequest = exports.DetachThingPrincipalResponse = exports.DetachThingPrincipalRequest = exports.DetachSecurityProfileResponse = exports.DetachSecurityProfileRequest = exports.DetachPrincipalPolicyRequest = exports.DetachPolicyRequest = exports.DescribeThingTypeResponse = exports.ThingTypeMetadata = exports.DescribeThingTypeRequest = exports.DescribeThingRegistrationTaskResponse = exports.Status = exports.DescribeThingRegistrationTaskRequest = exports.DescribeThingGroupResponse = exports.ThingGroupMetadata = exports.GroupNameAndArn = exports.DynamicGroupStatus = exports.DescribeThingGroupRequest = exports.DescribeThingResponse = exports.DescribeThingRequest = exports.DescribeStreamResponse = exports.StreamInfo = exports.DescribeStreamRequest = exports.DescribeSecurityProfileResponse = exports.DescribeSecurityProfileRequest = exports.DescribeScheduledAuditResponse = exports.DescribeScheduledAuditRequest = exports.DescribeRoleAliasResponse = exports.RoleAliasDescription = exports.DescribeRoleAliasRequest = exports.DescribeProvisioningTemplateVersionResponse = exports.DescribeProvisioningTemplateVersionRequest = exports.DescribeProvisioningTemplateResponse = exports.DescribeProvisioningTemplateRequest = void 0; +exports.ListCACertificatesResponse = exports.CACertificate = exports.ListCACertificatesRequest = exports.ListBillingGroupsResponse = exports.ListBillingGroupsRequest = exports.ListAuthorizersResponse = exports.ListAuthorizersRequest = exports.ListAuditTasksResponse = exports.ListAuditTasksRequest = exports.ListAuditSuppressionsResponse = exports.ListAuditSuppressionsRequest = exports.ListAuditMitigationActionsTasksResponse = exports.ListAuditMitigationActionsTasksRequest = exports.ListAuditMitigationActionsExecutionsResponse = exports.ListAuditMitigationActionsExecutionsRequest = exports.ListAuditFindingsResponse = exports.ListAuditFindingsRequest = exports.ListAttachedPoliciesResponse = exports.ListAttachedPoliciesRequest = exports.ListActiveViolationsResponse = exports.ListActiveViolationsRequest = exports.NotConfiguredException = exports.GetV2LoggingOptionsResponse = exports.GetV2LoggingOptionsRequest = exports.GetTopicRuleDestinationResponse = exports.GetTopicRuleDestinationRequest = exports.GetTopicRuleResponse = exports.TopicRule = exports.GetTopicRuleRequest = exports.GetStatisticsResponse = exports.Statistics = exports.GetStatisticsRequest = exports.GetRegistrationCodeResponse = exports.GetRegistrationCodeRequest = exports.GetPolicyVersionResponse = exports.GetPolicyVersionRequest = exports.GetPolicyResponse = exports.GetPolicyRequest = exports.GetPercentilesResponse = exports.PercentPair = exports.GetPercentilesRequest = exports.GetOTAUpdateResponse = exports.OTAUpdateInfo = exports.ErrorInfo = exports.GetOTAUpdateRequest = exports.GetLoggingOptionsResponse = exports.GetLoggingOptionsRequest = exports.GetJobDocumentResponse = exports.GetJobDocumentRequest = exports.GetIndexingConfigurationResponse = void 0; +exports.ListRoleAliasesResponse = exports.ListRoleAliasesRequest = exports.ListProvisioningTemplateVersionsResponse = exports.ProvisioningTemplateVersionSummary = exports.ListProvisioningTemplateVersionsRequest = exports.ListProvisioningTemplatesResponse = exports.ProvisioningTemplateSummary = exports.ListProvisioningTemplatesRequest = exports.ListPrincipalThingsResponse = exports.ListPrincipalThingsRequest = exports.ListPrincipalPoliciesResponse = exports.ListPrincipalPoliciesRequest = exports.ListPolicyVersionsResponse = exports.PolicyVersion = exports.ListPolicyVersionsRequest = exports.ListPolicyPrincipalsResponse = exports.ListPolicyPrincipalsRequest = exports.ListPoliciesResponse = exports.ListPoliciesRequest = exports.ListOutgoingCertificatesResponse = exports.OutgoingCertificate = exports.ListOutgoingCertificatesRequest = exports.ListOTAUpdatesResponse = exports.OTAUpdateSummary = exports.ListOTAUpdatesRequest = exports.ListMitigationActionsResponse = exports.MitigationActionIdentifier = exports.ListMitigationActionsRequest = exports.ListJobsResponse = exports.JobSummary = exports.ListJobsRequest = exports.ListJobExecutionsForThingResponse = exports.JobExecutionSummaryForThing = exports.ListJobExecutionsForThingRequest = exports.ListJobExecutionsForJobResponse = exports.JobExecutionSummaryForJob = exports.JobExecutionSummary = exports.ListJobExecutionsForJobRequest = exports.ListIndicesResponse = exports.ListIndicesRequest = exports.ListDomainConfigurationsResponse = exports.DomainConfigurationSummary = exports.ListDomainConfigurationsRequest = exports.ListDimensionsResponse = exports.ListDimensionsRequest = exports.ListCertificatesByCAResponse = exports.ListCertificatesByCARequest = exports.ListCertificatesResponse = exports.Certificate = exports.ListCertificatesRequest = void 0; +exports.LogTargetConfiguration = exports.LogTarget = exports.ListV2LoggingLevelsRequest = exports.ListTopicRulesResponse = exports.TopicRuleListItem = exports.ListTopicRulesRequest = exports.ListTopicRuleDestinationsResponse = exports.TopicRuleDestinationSummary = exports.HttpUrlDestinationSummary = exports.ListTopicRuleDestinationsRequest = exports.ListThingTypesResponse = exports.ThingTypeDefinition = exports.ListThingTypesRequest = exports.ListThingsInThingGroupResponse = exports.ListThingsInThingGroupRequest = exports.ListThingsInBillingGroupResponse = exports.ListThingsInBillingGroupRequest = exports.ListThingsResponse = exports.ThingAttribute = exports.ListThingsRequest = exports.ListThingRegistrationTasksResponse = exports.ListThingRegistrationTasksRequest = exports.ListThingRegistrationTaskReportsResponse = exports.ListThingRegistrationTaskReportsRequest = exports.ReportType = exports.ListThingPrincipalsResponse = exports.ListThingPrincipalsRequest = exports.ListThingGroupsForThingResponse = exports.ListThingGroupsForThingRequest = exports.ListThingGroupsResponse = exports.ListThingGroupsRequest = exports.ListTargetsForSecurityProfileResponse = exports.ListTargetsForSecurityProfileRequest = exports.ListTargetsForPolicyResponse = exports.ListTargetsForPolicyRequest = exports.ListTagsForResourceResponse = exports.ListTagsForResourceRequest = exports.ListStreamsResponse = exports.StreamSummary = exports.ListStreamsRequest = exports.ListSecurityProfilesForTargetResponse = exports.SecurityProfileTargetMapping = exports.SecurityProfileTarget = exports.ListSecurityProfilesForTargetRequest = exports.ListSecurityProfilesResponse = exports.SecurityProfileIdentifier = exports.ListSecurityProfilesRequest = exports.ListScheduledAuditsResponse = exports.ScheduledAuditMetadata = exports.ListScheduledAuditsRequest = void 0; +exports.MqttContext = exports.HttpContext = exports.InvalidResponseException = exports.TestAuthorizationResponse = exports.TestAuthorizationRequest = exports.TagResourceResponse = exports.TagResourceRequest = exports.StopThingRegistrationTaskResponse = exports.StopThingRegistrationTaskRequest = exports.StartThingRegistrationTaskResponse = exports.StartThingRegistrationTaskRequest = exports.StartOnDemandAuditTaskResponse = exports.StartOnDemandAuditTaskRequest = exports.TaskAlreadyExistsException = exports.StartAuditMitigationActionsTaskResponse = exports.StartAuditMitigationActionsTaskRequest = exports.SetV2LoggingOptionsRequest = exports.SetV2LoggingLevelRequest = exports.SetLoggingOptionsRequest = exports.LoggingOptionsPayload = exports.SetDefaultPolicyVersionRequest = exports.SetDefaultAuthorizerResponse = exports.SetDefaultAuthorizerRequest = exports.SearchIndexResponse = exports.ThingDocument = exports.ThingConnectivity = exports.ThingGroupDocument = exports.SearchIndexRequest = exports.ReplaceTopicRuleRequest = exports.RemoveThingFromThingGroupResponse = exports.RemoveThingFromThingGroupRequest = exports.RemoveThingFromBillingGroupResponse = exports.RemoveThingFromBillingGroupRequest = exports.RejectCertificateTransferRequest = exports.ResourceRegistrationFailureException = exports.RegisterThingResponse = exports.RegisterThingRequest = exports.RegisterCertificateWithoutCAResponse = exports.RegisterCertificateWithoutCARequest = exports.RegisterCertificateResponse = exports.RegisterCertificateRequest = exports.CertificateConflictException = exports.RegistrationCodeValidationException = exports.RegisterCACertificateResponse = exports.RegisterCACertificateRequest = exports.ListViolationEventsResponse = exports.ViolationEvent = exports.ViolationEventType = exports.ListViolationEventsRequest = exports.ListV2LoggingLevelsResponse = void 0; +var DescribeAuditTaskResponse; +(function (DescribeAuditTaskResponse) { + DescribeAuditTaskResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAuditTaskResponse = exports.DescribeAuditTaskResponse || (exports.DescribeAuditTaskResponse = {})); +var DescribeAuthorizerRequest; +(function (DescribeAuthorizerRequest) { + DescribeAuthorizerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAuthorizerRequest = exports.DescribeAuthorizerRequest || (exports.DescribeAuthorizerRequest = {})); +var DescribeAuthorizerResponse; +(function (DescribeAuthorizerResponse) { + DescribeAuthorizerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeAuthorizerResponse = exports.DescribeAuthorizerResponse || (exports.DescribeAuthorizerResponse = {})); +var DescribeBillingGroupRequest; +(function (DescribeBillingGroupRequest) { + DescribeBillingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeBillingGroupRequest = exports.DescribeBillingGroupRequest || (exports.DescribeBillingGroupRequest = {})); +var BillingGroupMetadata; +(function (BillingGroupMetadata) { + BillingGroupMetadata.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(BillingGroupMetadata = exports.BillingGroupMetadata || (exports.BillingGroupMetadata = {})); +var DescribeBillingGroupResponse; +(function (DescribeBillingGroupResponse) { + DescribeBillingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeBillingGroupResponse = exports.DescribeBillingGroupResponse || (exports.DescribeBillingGroupResponse = {})); +var DescribeCACertificateRequest; +(function (DescribeCACertificateRequest) { + DescribeCACertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeCACertificateRequest = exports.DescribeCACertificateRequest || (exports.DescribeCACertificateRequest = {})); +var CACertificateStatus; +(function (CACertificateStatus) { + CACertificateStatus["ACTIVE"] = "ACTIVE"; + CACertificateStatus["INACTIVE"] = "INACTIVE"; +})(CACertificateStatus = exports.CACertificateStatus || (exports.CACertificateStatus = {})); +var CertificateValidity; +(function (CertificateValidity) { + CertificateValidity.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CertificateValidity = exports.CertificateValidity || (exports.CertificateValidity = {})); +var CACertificateDescription; +(function (CACertificateDescription) { + CACertificateDescription.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CACertificateDescription = exports.CACertificateDescription || (exports.CACertificateDescription = {})); +var RegistrationConfig; +(function (RegistrationConfig) { + RegistrationConfig.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegistrationConfig = exports.RegistrationConfig || (exports.RegistrationConfig = {})); +var DescribeCACertificateResponse; +(function (DescribeCACertificateResponse) { + DescribeCACertificateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeCACertificateResponse = exports.DescribeCACertificateResponse || (exports.DescribeCACertificateResponse = {})); +var DescribeCertificateRequest; +(function (DescribeCertificateRequest) { + DescribeCertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeCertificateRequest = exports.DescribeCertificateRequest || (exports.DescribeCertificateRequest = {})); +var CertificateMode; +(function (CertificateMode) { + CertificateMode["DEFAULT"] = "DEFAULT"; + CertificateMode["SNI_ONLY"] = "SNI_ONLY"; +})(CertificateMode = exports.CertificateMode || (exports.CertificateMode = {})); +var CertificateStatus; +(function (CertificateStatus) { + CertificateStatus["ACTIVE"] = "ACTIVE"; + CertificateStatus["INACTIVE"] = "INACTIVE"; + CertificateStatus["PENDING_ACTIVATION"] = "PENDING_ACTIVATION"; + CertificateStatus["PENDING_TRANSFER"] = "PENDING_TRANSFER"; + CertificateStatus["REGISTER_INACTIVE"] = "REGISTER_INACTIVE"; + CertificateStatus["REVOKED"] = "REVOKED"; +})(CertificateStatus = exports.CertificateStatus || (exports.CertificateStatus = {})); +var TransferData; +(function (TransferData) { + TransferData.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TransferData = exports.TransferData || (exports.TransferData = {})); +var CertificateDescription; +(function (CertificateDescription) { + CertificateDescription.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CertificateDescription = exports.CertificateDescription || (exports.CertificateDescription = {})); +var DescribeCertificateResponse; +(function (DescribeCertificateResponse) { + DescribeCertificateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeCertificateResponse = exports.DescribeCertificateResponse || (exports.DescribeCertificateResponse = {})); +var DescribeDefaultAuthorizerRequest; +(function (DescribeDefaultAuthorizerRequest) { + DescribeDefaultAuthorizerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeDefaultAuthorizerRequest = exports.DescribeDefaultAuthorizerRequest || (exports.DescribeDefaultAuthorizerRequest = {})); +var DescribeDefaultAuthorizerResponse; +(function (DescribeDefaultAuthorizerResponse) { + DescribeDefaultAuthorizerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeDefaultAuthorizerResponse = exports.DescribeDefaultAuthorizerResponse || (exports.DescribeDefaultAuthorizerResponse = {})); +var DescribeDimensionRequest; +(function (DescribeDimensionRequest) { + DescribeDimensionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeDimensionRequest = exports.DescribeDimensionRequest || (exports.DescribeDimensionRequest = {})); +var DescribeDimensionResponse; +(function (DescribeDimensionResponse) { + DescribeDimensionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeDimensionResponse = exports.DescribeDimensionResponse || (exports.DescribeDimensionResponse = {})); +var DescribeDomainConfigurationRequest; +(function (DescribeDomainConfigurationRequest) { + DescribeDomainConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeDomainConfigurationRequest = exports.DescribeDomainConfigurationRequest || (exports.DescribeDomainConfigurationRequest = {})); +var DomainConfigurationStatus; +(function (DomainConfigurationStatus) { + DomainConfigurationStatus["DISABLED"] = "DISABLED"; + DomainConfigurationStatus["ENABLED"] = "ENABLED"; +})(DomainConfigurationStatus = exports.DomainConfigurationStatus || (exports.DomainConfigurationStatus = {})); +var DomainType; +(function (DomainType) { + DomainType["AWS_MANAGED"] = "AWS_MANAGED"; + DomainType["CUSTOMER_MANAGED"] = "CUSTOMER_MANAGED"; + DomainType["ENDPOINT"] = "ENDPOINT"; +})(DomainType = exports.DomainType || (exports.DomainType = {})); +var ServerCertificateStatus; +(function (ServerCertificateStatus) { + ServerCertificateStatus["INVALID"] = "INVALID"; + ServerCertificateStatus["VALID"] = "VALID"; +})(ServerCertificateStatus = exports.ServerCertificateStatus || (exports.ServerCertificateStatus = {})); +var ServerCertificateSummary; +(function (ServerCertificateSummary) { + ServerCertificateSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ServerCertificateSummary = exports.ServerCertificateSummary || (exports.ServerCertificateSummary = {})); +var DescribeDomainConfigurationResponse; +(function (DescribeDomainConfigurationResponse) { + DescribeDomainConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeDomainConfigurationResponse = exports.DescribeDomainConfigurationResponse || (exports.DescribeDomainConfigurationResponse = {})); +var DescribeEndpointRequest; +(function (DescribeEndpointRequest) { + DescribeEndpointRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeEndpointRequest = exports.DescribeEndpointRequest || (exports.DescribeEndpointRequest = {})); +var DescribeEndpointResponse; +(function (DescribeEndpointResponse) { + DescribeEndpointResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeEndpointResponse = exports.DescribeEndpointResponse || (exports.DescribeEndpointResponse = {})); +var DescribeEventConfigurationsRequest; +(function (DescribeEventConfigurationsRequest) { + DescribeEventConfigurationsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeEventConfigurationsRequest = exports.DescribeEventConfigurationsRequest || (exports.DescribeEventConfigurationsRequest = {})); +var EventType; +(function (EventType) { + EventType["CA_CERTIFICATE"] = "CA_CERTIFICATE"; + EventType["CERTIFICATE"] = "CERTIFICATE"; + EventType["JOB"] = "JOB"; + EventType["JOB_EXECUTION"] = "JOB_EXECUTION"; + EventType["POLICY"] = "POLICY"; + EventType["THING"] = "THING"; + EventType["THING_GROUP"] = "THING_GROUP"; + EventType["THING_GROUP_HIERARCHY"] = "THING_GROUP_HIERARCHY"; + EventType["THING_GROUP_MEMBERSHIP"] = "THING_GROUP_MEMBERSHIP"; + EventType["THING_TYPE"] = "THING_TYPE"; + EventType["THING_TYPE_ASSOCIATION"] = "THING_TYPE_ASSOCIATION"; +})(EventType = exports.EventType || (exports.EventType = {})); +var Configuration; +(function (Configuration) { + Configuration.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Configuration = exports.Configuration || (exports.Configuration = {})); +var DescribeEventConfigurationsResponse; +(function (DescribeEventConfigurationsResponse) { + DescribeEventConfigurationsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeEventConfigurationsResponse = exports.DescribeEventConfigurationsResponse || (exports.DescribeEventConfigurationsResponse = {})); +var DescribeIndexRequest; +(function (DescribeIndexRequest) { + DescribeIndexRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeIndexRequest = exports.DescribeIndexRequest || (exports.DescribeIndexRequest = {})); +var IndexStatus; +(function (IndexStatus) { + IndexStatus["ACTIVE"] = "ACTIVE"; + IndexStatus["BUILDING"] = "BUILDING"; + IndexStatus["REBUILDING"] = "REBUILDING"; +})(IndexStatus = exports.IndexStatus || (exports.IndexStatus = {})); +var DescribeIndexResponse; +(function (DescribeIndexResponse) { + DescribeIndexResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeIndexResponse = exports.DescribeIndexResponse || (exports.DescribeIndexResponse = {})); +var DescribeJobRequest; +(function (DescribeJobRequest) { + DescribeJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeJobRequest = exports.DescribeJobRequest || (exports.DescribeJobRequest = {})); +var JobProcessDetails; +(function (JobProcessDetails) { + JobProcessDetails.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(JobProcessDetails = exports.JobProcessDetails || (exports.JobProcessDetails = {})); +var JobStatus; +(function (JobStatus) { + JobStatus["CANCELED"] = "CANCELED"; + JobStatus["COMPLETED"] = "COMPLETED"; + JobStatus["DELETION_IN_PROGRESS"] = "DELETION_IN_PROGRESS"; + JobStatus["IN_PROGRESS"] = "IN_PROGRESS"; +})(JobStatus = exports.JobStatus || (exports.JobStatus = {})); +var Job; +(function (Job) { + Job.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Job = exports.Job || (exports.Job = {})); +var DescribeJobResponse; +(function (DescribeJobResponse) { + DescribeJobResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeJobResponse = exports.DescribeJobResponse || (exports.DescribeJobResponse = {})); +var DescribeJobExecutionRequest; +(function (DescribeJobExecutionRequest) { + DescribeJobExecutionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeJobExecutionRequest = exports.DescribeJobExecutionRequest || (exports.DescribeJobExecutionRequest = {})); +var JobExecutionStatus; +(function (JobExecutionStatus) { + JobExecutionStatus["CANCELED"] = "CANCELED"; + JobExecutionStatus["FAILED"] = "FAILED"; + JobExecutionStatus["IN_PROGRESS"] = "IN_PROGRESS"; + JobExecutionStatus["QUEUED"] = "QUEUED"; + JobExecutionStatus["REJECTED"] = "REJECTED"; + JobExecutionStatus["REMOVED"] = "REMOVED"; + JobExecutionStatus["SUCCEEDED"] = "SUCCEEDED"; + JobExecutionStatus["TIMED_OUT"] = "TIMED_OUT"; +})(JobExecutionStatus = exports.JobExecutionStatus || (exports.JobExecutionStatus = {})); +var JobExecutionStatusDetails; +(function (JobExecutionStatusDetails) { + JobExecutionStatusDetails.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(JobExecutionStatusDetails = exports.JobExecutionStatusDetails || (exports.JobExecutionStatusDetails = {})); +var JobExecution; +(function (JobExecution) { + JobExecution.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(JobExecution = exports.JobExecution || (exports.JobExecution = {})); +var DescribeJobExecutionResponse; +(function (DescribeJobExecutionResponse) { + DescribeJobExecutionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeJobExecutionResponse = exports.DescribeJobExecutionResponse || (exports.DescribeJobExecutionResponse = {})); +var DescribeMitigationActionRequest; +(function (DescribeMitigationActionRequest) { + DescribeMitigationActionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeMitigationActionRequest = exports.DescribeMitigationActionRequest || (exports.DescribeMitigationActionRequest = {})); +var MitigationActionType; +(function (MitigationActionType) { + MitigationActionType["ADD_THINGS_TO_THING_GROUP"] = "ADD_THINGS_TO_THING_GROUP"; + MitigationActionType["ENABLE_IOT_LOGGING"] = "ENABLE_IOT_LOGGING"; + MitigationActionType["PUBLISH_FINDING_TO_SNS"] = "PUBLISH_FINDING_TO_SNS"; + MitigationActionType["REPLACE_DEFAULT_POLICY_VERSION"] = "REPLACE_DEFAULT_POLICY_VERSION"; + MitigationActionType["UPDATE_CA_CERTIFICATE"] = "UPDATE_CA_CERTIFICATE"; + MitigationActionType["UPDATE_DEVICE_CERTIFICATE"] = "UPDATE_DEVICE_CERTIFICATE"; +})(MitigationActionType = exports.MitigationActionType || (exports.MitigationActionType = {})); +var DescribeMitigationActionResponse; +(function (DescribeMitigationActionResponse) { + DescribeMitigationActionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeMitigationActionResponse = exports.DescribeMitigationActionResponse || (exports.DescribeMitigationActionResponse = {})); +var DescribeProvisioningTemplateRequest; +(function (DescribeProvisioningTemplateRequest) { + DescribeProvisioningTemplateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeProvisioningTemplateRequest = exports.DescribeProvisioningTemplateRequest || (exports.DescribeProvisioningTemplateRequest = {})); +var DescribeProvisioningTemplateResponse; +(function (DescribeProvisioningTemplateResponse) { + DescribeProvisioningTemplateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeProvisioningTemplateResponse = exports.DescribeProvisioningTemplateResponse || (exports.DescribeProvisioningTemplateResponse = {})); +var DescribeProvisioningTemplateVersionRequest; +(function (DescribeProvisioningTemplateVersionRequest) { + DescribeProvisioningTemplateVersionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeProvisioningTemplateVersionRequest = exports.DescribeProvisioningTemplateVersionRequest || (exports.DescribeProvisioningTemplateVersionRequest = {})); +var DescribeProvisioningTemplateVersionResponse; +(function (DescribeProvisioningTemplateVersionResponse) { + DescribeProvisioningTemplateVersionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeProvisioningTemplateVersionResponse = exports.DescribeProvisioningTemplateVersionResponse || (exports.DescribeProvisioningTemplateVersionResponse = {})); +var DescribeRoleAliasRequest; +(function (DescribeRoleAliasRequest) { + DescribeRoleAliasRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeRoleAliasRequest = exports.DescribeRoleAliasRequest || (exports.DescribeRoleAliasRequest = {})); +var RoleAliasDescription; +(function (RoleAliasDescription) { + RoleAliasDescription.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RoleAliasDescription = exports.RoleAliasDescription || (exports.RoleAliasDescription = {})); +var DescribeRoleAliasResponse; +(function (DescribeRoleAliasResponse) { + DescribeRoleAliasResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeRoleAliasResponse = exports.DescribeRoleAliasResponse || (exports.DescribeRoleAliasResponse = {})); +var DescribeScheduledAuditRequest; +(function (DescribeScheduledAuditRequest) { + DescribeScheduledAuditRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeScheduledAuditRequest = exports.DescribeScheduledAuditRequest || (exports.DescribeScheduledAuditRequest = {})); +var DescribeScheduledAuditResponse; +(function (DescribeScheduledAuditResponse) { + DescribeScheduledAuditResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeScheduledAuditResponse = exports.DescribeScheduledAuditResponse || (exports.DescribeScheduledAuditResponse = {})); +var DescribeSecurityProfileRequest; +(function (DescribeSecurityProfileRequest) { + DescribeSecurityProfileRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeSecurityProfileRequest = exports.DescribeSecurityProfileRequest || (exports.DescribeSecurityProfileRequest = {})); +var DescribeSecurityProfileResponse; +(function (DescribeSecurityProfileResponse) { + DescribeSecurityProfileResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeSecurityProfileResponse = exports.DescribeSecurityProfileResponse || (exports.DescribeSecurityProfileResponse = {})); +var DescribeStreamRequest; +(function (DescribeStreamRequest) { + DescribeStreamRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStreamRequest = exports.DescribeStreamRequest || (exports.DescribeStreamRequest = {})); +var StreamInfo; +(function (StreamInfo) { + StreamInfo.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StreamInfo = exports.StreamInfo || (exports.StreamInfo = {})); +var DescribeStreamResponse; +(function (DescribeStreamResponse) { + DescribeStreamResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeStreamResponse = exports.DescribeStreamResponse || (exports.DescribeStreamResponse = {})); +var DescribeThingRequest; +(function (DescribeThingRequest) { + DescribeThingRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeThingRequest = exports.DescribeThingRequest || (exports.DescribeThingRequest = {})); +var DescribeThingResponse; +(function (DescribeThingResponse) { + DescribeThingResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeThingResponse = exports.DescribeThingResponse || (exports.DescribeThingResponse = {})); +var DescribeThingGroupRequest; +(function (DescribeThingGroupRequest) { + DescribeThingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeThingGroupRequest = exports.DescribeThingGroupRequest || (exports.DescribeThingGroupRequest = {})); +var DynamicGroupStatus; +(function (DynamicGroupStatus) { + DynamicGroupStatus["ACTIVE"] = "ACTIVE"; + DynamicGroupStatus["BUILDING"] = "BUILDING"; + DynamicGroupStatus["REBUILDING"] = "REBUILDING"; +})(DynamicGroupStatus = exports.DynamicGroupStatus || (exports.DynamicGroupStatus = {})); +var GroupNameAndArn; +(function (GroupNameAndArn) { + GroupNameAndArn.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GroupNameAndArn = exports.GroupNameAndArn || (exports.GroupNameAndArn = {})); +var ThingGroupMetadata; +(function (ThingGroupMetadata) { + ThingGroupMetadata.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingGroupMetadata = exports.ThingGroupMetadata || (exports.ThingGroupMetadata = {})); +var DescribeThingGroupResponse; +(function (DescribeThingGroupResponse) { + DescribeThingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeThingGroupResponse = exports.DescribeThingGroupResponse || (exports.DescribeThingGroupResponse = {})); +var DescribeThingRegistrationTaskRequest; +(function (DescribeThingRegistrationTaskRequest) { + DescribeThingRegistrationTaskRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeThingRegistrationTaskRequest = exports.DescribeThingRegistrationTaskRequest || (exports.DescribeThingRegistrationTaskRequest = {})); +var Status; +(function (Status) { + Status["Cancelled"] = "Cancelled"; + Status["Cancelling"] = "Cancelling"; + Status["Completed"] = "Completed"; + Status["Failed"] = "Failed"; + Status["InProgress"] = "InProgress"; +})(Status = exports.Status || (exports.Status = {})); +var DescribeThingRegistrationTaskResponse; +(function (DescribeThingRegistrationTaskResponse) { + DescribeThingRegistrationTaskResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeThingRegistrationTaskResponse = exports.DescribeThingRegistrationTaskResponse || (exports.DescribeThingRegistrationTaskResponse = {})); +var DescribeThingTypeRequest; +(function (DescribeThingTypeRequest) { + DescribeThingTypeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeThingTypeRequest = exports.DescribeThingTypeRequest || (exports.DescribeThingTypeRequest = {})); +var ThingTypeMetadata; +(function (ThingTypeMetadata) { + ThingTypeMetadata.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingTypeMetadata = exports.ThingTypeMetadata || (exports.ThingTypeMetadata = {})); +var DescribeThingTypeResponse; +(function (DescribeThingTypeResponse) { + DescribeThingTypeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DescribeThingTypeResponse = exports.DescribeThingTypeResponse || (exports.DescribeThingTypeResponse = {})); +var DetachPolicyRequest; +(function (DetachPolicyRequest) { + DetachPolicyRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetachPolicyRequest = exports.DetachPolicyRequest || (exports.DetachPolicyRequest = {})); +var DetachPrincipalPolicyRequest; +(function (DetachPrincipalPolicyRequest) { + DetachPrincipalPolicyRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetachPrincipalPolicyRequest = exports.DetachPrincipalPolicyRequest || (exports.DetachPrincipalPolicyRequest = {})); +var DetachSecurityProfileRequest; +(function (DetachSecurityProfileRequest) { + DetachSecurityProfileRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetachSecurityProfileRequest = exports.DetachSecurityProfileRequest || (exports.DetachSecurityProfileRequest = {})); +var DetachSecurityProfileResponse; +(function (DetachSecurityProfileResponse) { + DetachSecurityProfileResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetachSecurityProfileResponse = exports.DetachSecurityProfileResponse || (exports.DetachSecurityProfileResponse = {})); +var DetachThingPrincipalRequest; +(function (DetachThingPrincipalRequest) { + DetachThingPrincipalRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetachThingPrincipalRequest = exports.DetachThingPrincipalRequest || (exports.DetachThingPrincipalRequest = {})); +var DetachThingPrincipalResponse; +(function (DetachThingPrincipalResponse) { + DetachThingPrincipalResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DetachThingPrincipalResponse = exports.DetachThingPrincipalResponse || (exports.DetachThingPrincipalResponse = {})); +var DisableTopicRuleRequest; +(function (DisableTopicRuleRequest) { + DisableTopicRuleRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DisableTopicRuleRequest = exports.DisableTopicRuleRequest || (exports.DisableTopicRuleRequest = {})); +var EnableTopicRuleRequest; +(function (EnableTopicRuleRequest) { + EnableTopicRuleRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(EnableTopicRuleRequest = exports.EnableTopicRuleRequest || (exports.EnableTopicRuleRequest = {})); +var GetCardinalityRequest; +(function (GetCardinalityRequest) { + GetCardinalityRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetCardinalityRequest = exports.GetCardinalityRequest || (exports.GetCardinalityRequest = {})); +var GetCardinalityResponse; +(function (GetCardinalityResponse) { + GetCardinalityResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetCardinalityResponse = exports.GetCardinalityResponse || (exports.GetCardinalityResponse = {})); +var IndexNotReadyException; +(function (IndexNotReadyException) { + IndexNotReadyException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(IndexNotReadyException = exports.IndexNotReadyException || (exports.IndexNotReadyException = {})); +var InvalidAggregationException; +(function (InvalidAggregationException) { + InvalidAggregationException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidAggregationException = exports.InvalidAggregationException || (exports.InvalidAggregationException = {})); +var GetEffectivePoliciesRequest; +(function (GetEffectivePoliciesRequest) { + GetEffectivePoliciesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetEffectivePoliciesRequest = exports.GetEffectivePoliciesRequest || (exports.GetEffectivePoliciesRequest = {})); +var EffectivePolicy; +(function (EffectivePolicy) { + EffectivePolicy.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(EffectivePolicy = exports.EffectivePolicy || (exports.EffectivePolicy = {})); +var GetEffectivePoliciesResponse; +(function (GetEffectivePoliciesResponse) { + GetEffectivePoliciesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetEffectivePoliciesResponse = exports.GetEffectivePoliciesResponse || (exports.GetEffectivePoliciesResponse = {})); +var GetIndexingConfigurationRequest; +(function (GetIndexingConfigurationRequest) { + GetIndexingConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetIndexingConfigurationRequest = exports.GetIndexingConfigurationRequest || (exports.GetIndexingConfigurationRequest = {})); +var FieldType; +(function (FieldType) { + FieldType["BOOLEAN"] = "Boolean"; + FieldType["NUMBER"] = "Number"; + FieldType["STRING"] = "String"; +})(FieldType = exports.FieldType || (exports.FieldType = {})); +var Field; +(function (Field) { + Field.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Field = exports.Field || (exports.Field = {})); +var ThingGroupIndexingMode; +(function (ThingGroupIndexingMode) { + ThingGroupIndexingMode["OFF"] = "OFF"; + ThingGroupIndexingMode["ON"] = "ON"; +})(ThingGroupIndexingMode = exports.ThingGroupIndexingMode || (exports.ThingGroupIndexingMode = {})); +var ThingGroupIndexingConfiguration; +(function (ThingGroupIndexingConfiguration) { + ThingGroupIndexingConfiguration.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingGroupIndexingConfiguration = exports.ThingGroupIndexingConfiguration || (exports.ThingGroupIndexingConfiguration = {})); +var ThingConnectivityIndexingMode; +(function (ThingConnectivityIndexingMode) { + ThingConnectivityIndexingMode["OFF"] = "OFF"; + ThingConnectivityIndexingMode["STATUS"] = "STATUS"; +})(ThingConnectivityIndexingMode = exports.ThingConnectivityIndexingMode || (exports.ThingConnectivityIndexingMode = {})); +var ThingIndexingMode; +(function (ThingIndexingMode) { + ThingIndexingMode["OFF"] = "OFF"; + ThingIndexingMode["REGISTRY"] = "REGISTRY"; + ThingIndexingMode["REGISTRY_AND_SHADOW"] = "REGISTRY_AND_SHADOW"; +})(ThingIndexingMode = exports.ThingIndexingMode || (exports.ThingIndexingMode = {})); +var ThingIndexingConfiguration; +(function (ThingIndexingConfiguration) { + ThingIndexingConfiguration.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingIndexingConfiguration = exports.ThingIndexingConfiguration || (exports.ThingIndexingConfiguration = {})); +var GetIndexingConfigurationResponse; +(function (GetIndexingConfigurationResponse) { + GetIndexingConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetIndexingConfigurationResponse = exports.GetIndexingConfigurationResponse || (exports.GetIndexingConfigurationResponse = {})); +var GetJobDocumentRequest; +(function (GetJobDocumentRequest) { + GetJobDocumentRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetJobDocumentRequest = exports.GetJobDocumentRequest || (exports.GetJobDocumentRequest = {})); +var GetJobDocumentResponse; +(function (GetJobDocumentResponse) { + GetJobDocumentResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetJobDocumentResponse = exports.GetJobDocumentResponse || (exports.GetJobDocumentResponse = {})); +var GetLoggingOptionsRequest; +(function (GetLoggingOptionsRequest) { + GetLoggingOptionsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetLoggingOptionsRequest = exports.GetLoggingOptionsRequest || (exports.GetLoggingOptionsRequest = {})); +var GetLoggingOptionsResponse; +(function (GetLoggingOptionsResponse) { + GetLoggingOptionsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetLoggingOptionsResponse = exports.GetLoggingOptionsResponse || (exports.GetLoggingOptionsResponse = {})); +var GetOTAUpdateRequest; +(function (GetOTAUpdateRequest) { + GetOTAUpdateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetOTAUpdateRequest = exports.GetOTAUpdateRequest || (exports.GetOTAUpdateRequest = {})); +var ErrorInfo; +(function (ErrorInfo) { + ErrorInfo.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ErrorInfo = exports.ErrorInfo || (exports.ErrorInfo = {})); +var OTAUpdateInfo; +(function (OTAUpdateInfo) { + OTAUpdateInfo.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(OTAUpdateInfo = exports.OTAUpdateInfo || (exports.OTAUpdateInfo = {})); +var GetOTAUpdateResponse; +(function (GetOTAUpdateResponse) { + GetOTAUpdateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetOTAUpdateResponse = exports.GetOTAUpdateResponse || (exports.GetOTAUpdateResponse = {})); +var GetPercentilesRequest; +(function (GetPercentilesRequest) { + GetPercentilesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetPercentilesRequest = exports.GetPercentilesRequest || (exports.GetPercentilesRequest = {})); +var PercentPair; +(function (PercentPair) { + PercentPair.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PercentPair = exports.PercentPair || (exports.PercentPair = {})); +var GetPercentilesResponse; +(function (GetPercentilesResponse) { + GetPercentilesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetPercentilesResponse = exports.GetPercentilesResponse || (exports.GetPercentilesResponse = {})); +var GetPolicyRequest; +(function (GetPolicyRequest) { + GetPolicyRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetPolicyRequest = exports.GetPolicyRequest || (exports.GetPolicyRequest = {})); +var GetPolicyResponse; +(function (GetPolicyResponse) { + GetPolicyResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetPolicyResponse = exports.GetPolicyResponse || (exports.GetPolicyResponse = {})); +var GetPolicyVersionRequest; +(function (GetPolicyVersionRequest) { + GetPolicyVersionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetPolicyVersionRequest = exports.GetPolicyVersionRequest || (exports.GetPolicyVersionRequest = {})); +var GetPolicyVersionResponse; +(function (GetPolicyVersionResponse) { + GetPolicyVersionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetPolicyVersionResponse = exports.GetPolicyVersionResponse || (exports.GetPolicyVersionResponse = {})); +var GetRegistrationCodeRequest; +(function (GetRegistrationCodeRequest) { + GetRegistrationCodeRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetRegistrationCodeRequest = exports.GetRegistrationCodeRequest || (exports.GetRegistrationCodeRequest = {})); +var GetRegistrationCodeResponse; +(function (GetRegistrationCodeResponse) { + GetRegistrationCodeResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetRegistrationCodeResponse = exports.GetRegistrationCodeResponse || (exports.GetRegistrationCodeResponse = {})); +var GetStatisticsRequest; +(function (GetStatisticsRequest) { + GetStatisticsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetStatisticsRequest = exports.GetStatisticsRequest || (exports.GetStatisticsRequest = {})); +var Statistics; +(function (Statistics) { + Statistics.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Statistics = exports.Statistics || (exports.Statistics = {})); +var GetStatisticsResponse; +(function (GetStatisticsResponse) { + GetStatisticsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetStatisticsResponse = exports.GetStatisticsResponse || (exports.GetStatisticsResponse = {})); +var GetTopicRuleRequest; +(function (GetTopicRuleRequest) { + GetTopicRuleRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetTopicRuleRequest = exports.GetTopicRuleRequest || (exports.GetTopicRuleRequest = {})); +var TopicRule; +(function (TopicRule) { + TopicRule.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TopicRule = exports.TopicRule || (exports.TopicRule = {})); +var GetTopicRuleResponse; +(function (GetTopicRuleResponse) { + GetTopicRuleResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetTopicRuleResponse = exports.GetTopicRuleResponse || (exports.GetTopicRuleResponse = {})); +var GetTopicRuleDestinationRequest; +(function (GetTopicRuleDestinationRequest) { + GetTopicRuleDestinationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetTopicRuleDestinationRequest = exports.GetTopicRuleDestinationRequest || (exports.GetTopicRuleDestinationRequest = {})); +var GetTopicRuleDestinationResponse; +(function (GetTopicRuleDestinationResponse) { + GetTopicRuleDestinationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetTopicRuleDestinationResponse = exports.GetTopicRuleDestinationResponse || (exports.GetTopicRuleDestinationResponse = {})); +var GetV2LoggingOptionsRequest; +(function (GetV2LoggingOptionsRequest) { + GetV2LoggingOptionsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetV2LoggingOptionsRequest = exports.GetV2LoggingOptionsRequest || (exports.GetV2LoggingOptionsRequest = {})); +var GetV2LoggingOptionsResponse; +(function (GetV2LoggingOptionsResponse) { + GetV2LoggingOptionsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(GetV2LoggingOptionsResponse = exports.GetV2LoggingOptionsResponse || (exports.GetV2LoggingOptionsResponse = {})); +var NotConfiguredException; +(function (NotConfiguredException) { + NotConfiguredException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(NotConfiguredException = exports.NotConfiguredException || (exports.NotConfiguredException = {})); +var ListActiveViolationsRequest; +(function (ListActiveViolationsRequest) { + ListActiveViolationsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListActiveViolationsRequest = exports.ListActiveViolationsRequest || (exports.ListActiveViolationsRequest = {})); +var ListActiveViolationsResponse; +(function (ListActiveViolationsResponse) { + ListActiveViolationsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListActiveViolationsResponse = exports.ListActiveViolationsResponse || (exports.ListActiveViolationsResponse = {})); +var ListAttachedPoliciesRequest; +(function (ListAttachedPoliciesRequest) { + ListAttachedPoliciesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAttachedPoliciesRequest = exports.ListAttachedPoliciesRequest || (exports.ListAttachedPoliciesRequest = {})); +var ListAttachedPoliciesResponse; +(function (ListAttachedPoliciesResponse) { + ListAttachedPoliciesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAttachedPoliciesResponse = exports.ListAttachedPoliciesResponse || (exports.ListAttachedPoliciesResponse = {})); +var ListAuditFindingsRequest; +(function (ListAuditFindingsRequest) { + ListAuditFindingsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuditFindingsRequest = exports.ListAuditFindingsRequest || (exports.ListAuditFindingsRequest = {})); +var ListAuditFindingsResponse; +(function (ListAuditFindingsResponse) { + ListAuditFindingsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuditFindingsResponse = exports.ListAuditFindingsResponse || (exports.ListAuditFindingsResponse = {})); +var ListAuditMitigationActionsExecutionsRequest; +(function (ListAuditMitigationActionsExecutionsRequest) { + ListAuditMitigationActionsExecutionsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuditMitigationActionsExecutionsRequest = exports.ListAuditMitigationActionsExecutionsRequest || (exports.ListAuditMitigationActionsExecutionsRequest = {})); +var ListAuditMitigationActionsExecutionsResponse; +(function (ListAuditMitigationActionsExecutionsResponse) { + ListAuditMitigationActionsExecutionsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuditMitigationActionsExecutionsResponse = exports.ListAuditMitigationActionsExecutionsResponse || (exports.ListAuditMitigationActionsExecutionsResponse = {})); +var ListAuditMitigationActionsTasksRequest; +(function (ListAuditMitigationActionsTasksRequest) { + ListAuditMitigationActionsTasksRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuditMitigationActionsTasksRequest = exports.ListAuditMitigationActionsTasksRequest || (exports.ListAuditMitigationActionsTasksRequest = {})); +var ListAuditMitigationActionsTasksResponse; +(function (ListAuditMitigationActionsTasksResponse) { + ListAuditMitigationActionsTasksResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuditMitigationActionsTasksResponse = exports.ListAuditMitigationActionsTasksResponse || (exports.ListAuditMitigationActionsTasksResponse = {})); +var ListAuditSuppressionsRequest; +(function (ListAuditSuppressionsRequest) { + ListAuditSuppressionsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuditSuppressionsRequest = exports.ListAuditSuppressionsRequest || (exports.ListAuditSuppressionsRequest = {})); +var ListAuditSuppressionsResponse; +(function (ListAuditSuppressionsResponse) { + ListAuditSuppressionsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuditSuppressionsResponse = exports.ListAuditSuppressionsResponse || (exports.ListAuditSuppressionsResponse = {})); +var ListAuditTasksRequest; +(function (ListAuditTasksRequest) { + ListAuditTasksRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuditTasksRequest = exports.ListAuditTasksRequest || (exports.ListAuditTasksRequest = {})); +var ListAuditTasksResponse; +(function (ListAuditTasksResponse) { + ListAuditTasksResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuditTasksResponse = exports.ListAuditTasksResponse || (exports.ListAuditTasksResponse = {})); +var ListAuthorizersRequest; +(function (ListAuthorizersRequest) { + ListAuthorizersRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuthorizersRequest = exports.ListAuthorizersRequest || (exports.ListAuthorizersRequest = {})); +var ListAuthorizersResponse; +(function (ListAuthorizersResponse) { + ListAuthorizersResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListAuthorizersResponse = exports.ListAuthorizersResponse || (exports.ListAuthorizersResponse = {})); +var ListBillingGroupsRequest; +(function (ListBillingGroupsRequest) { + ListBillingGroupsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListBillingGroupsRequest = exports.ListBillingGroupsRequest || (exports.ListBillingGroupsRequest = {})); +var ListBillingGroupsResponse; +(function (ListBillingGroupsResponse) { + ListBillingGroupsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListBillingGroupsResponse = exports.ListBillingGroupsResponse || (exports.ListBillingGroupsResponse = {})); +var ListCACertificatesRequest; +(function (ListCACertificatesRequest) { + ListCACertificatesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListCACertificatesRequest = exports.ListCACertificatesRequest || (exports.ListCACertificatesRequest = {})); +var CACertificate; +(function (CACertificate) { + CACertificate.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CACertificate = exports.CACertificate || (exports.CACertificate = {})); +var ListCACertificatesResponse; +(function (ListCACertificatesResponse) { + ListCACertificatesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListCACertificatesResponse = exports.ListCACertificatesResponse || (exports.ListCACertificatesResponse = {})); +var ListCertificatesRequest; +(function (ListCertificatesRequest) { + ListCertificatesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListCertificatesRequest = exports.ListCertificatesRequest || (exports.ListCertificatesRequest = {})); +var Certificate; +(function (Certificate) { + Certificate.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(Certificate = exports.Certificate || (exports.Certificate = {})); +var ListCertificatesResponse; +(function (ListCertificatesResponse) { + ListCertificatesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListCertificatesResponse = exports.ListCertificatesResponse || (exports.ListCertificatesResponse = {})); +var ListCertificatesByCARequest; +(function (ListCertificatesByCARequest) { + ListCertificatesByCARequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListCertificatesByCARequest = exports.ListCertificatesByCARequest || (exports.ListCertificatesByCARequest = {})); +var ListCertificatesByCAResponse; +(function (ListCertificatesByCAResponse) { + ListCertificatesByCAResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListCertificatesByCAResponse = exports.ListCertificatesByCAResponse || (exports.ListCertificatesByCAResponse = {})); +var ListDimensionsRequest; +(function (ListDimensionsRequest) { + ListDimensionsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListDimensionsRequest = exports.ListDimensionsRequest || (exports.ListDimensionsRequest = {})); +var ListDimensionsResponse; +(function (ListDimensionsResponse) { + ListDimensionsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListDimensionsResponse = exports.ListDimensionsResponse || (exports.ListDimensionsResponse = {})); +var ListDomainConfigurationsRequest; +(function (ListDomainConfigurationsRequest) { + ListDomainConfigurationsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListDomainConfigurationsRequest = exports.ListDomainConfigurationsRequest || (exports.ListDomainConfigurationsRequest = {})); +var DomainConfigurationSummary; +(function (DomainConfigurationSummary) { + DomainConfigurationSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(DomainConfigurationSummary = exports.DomainConfigurationSummary || (exports.DomainConfigurationSummary = {})); +var ListDomainConfigurationsResponse; +(function (ListDomainConfigurationsResponse) { + ListDomainConfigurationsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListDomainConfigurationsResponse = exports.ListDomainConfigurationsResponse || (exports.ListDomainConfigurationsResponse = {})); +var ListIndicesRequest; +(function (ListIndicesRequest) { + ListIndicesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListIndicesRequest = exports.ListIndicesRequest || (exports.ListIndicesRequest = {})); +var ListIndicesResponse; +(function (ListIndicesResponse) { + ListIndicesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListIndicesResponse = exports.ListIndicesResponse || (exports.ListIndicesResponse = {})); +var ListJobExecutionsForJobRequest; +(function (ListJobExecutionsForJobRequest) { + ListJobExecutionsForJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListJobExecutionsForJobRequest = exports.ListJobExecutionsForJobRequest || (exports.ListJobExecutionsForJobRequest = {})); +var JobExecutionSummary; +(function (JobExecutionSummary) { + JobExecutionSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(JobExecutionSummary = exports.JobExecutionSummary || (exports.JobExecutionSummary = {})); +var JobExecutionSummaryForJob; +(function (JobExecutionSummaryForJob) { + JobExecutionSummaryForJob.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(JobExecutionSummaryForJob = exports.JobExecutionSummaryForJob || (exports.JobExecutionSummaryForJob = {})); +var ListJobExecutionsForJobResponse; +(function (ListJobExecutionsForJobResponse) { + ListJobExecutionsForJobResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListJobExecutionsForJobResponse = exports.ListJobExecutionsForJobResponse || (exports.ListJobExecutionsForJobResponse = {})); +var ListJobExecutionsForThingRequest; +(function (ListJobExecutionsForThingRequest) { + ListJobExecutionsForThingRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListJobExecutionsForThingRequest = exports.ListJobExecutionsForThingRequest || (exports.ListJobExecutionsForThingRequest = {})); +var JobExecutionSummaryForThing; +(function (JobExecutionSummaryForThing) { + JobExecutionSummaryForThing.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(JobExecutionSummaryForThing = exports.JobExecutionSummaryForThing || (exports.JobExecutionSummaryForThing = {})); +var ListJobExecutionsForThingResponse; +(function (ListJobExecutionsForThingResponse) { + ListJobExecutionsForThingResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListJobExecutionsForThingResponse = exports.ListJobExecutionsForThingResponse || (exports.ListJobExecutionsForThingResponse = {})); +var ListJobsRequest; +(function (ListJobsRequest) { + ListJobsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListJobsRequest = exports.ListJobsRequest || (exports.ListJobsRequest = {})); +var JobSummary; +(function (JobSummary) { + JobSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(JobSummary = exports.JobSummary || (exports.JobSummary = {})); +var ListJobsResponse; +(function (ListJobsResponse) { + ListJobsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListJobsResponse = exports.ListJobsResponse || (exports.ListJobsResponse = {})); +var ListMitigationActionsRequest; +(function (ListMitigationActionsRequest) { + ListMitigationActionsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListMitigationActionsRequest = exports.ListMitigationActionsRequest || (exports.ListMitigationActionsRequest = {})); +var MitigationActionIdentifier; +(function (MitigationActionIdentifier) { + MitigationActionIdentifier.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MitigationActionIdentifier = exports.MitigationActionIdentifier || (exports.MitigationActionIdentifier = {})); +var ListMitigationActionsResponse; +(function (ListMitigationActionsResponse) { + ListMitigationActionsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListMitigationActionsResponse = exports.ListMitigationActionsResponse || (exports.ListMitigationActionsResponse = {})); +var ListOTAUpdatesRequest; +(function (ListOTAUpdatesRequest) { + ListOTAUpdatesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListOTAUpdatesRequest = exports.ListOTAUpdatesRequest || (exports.ListOTAUpdatesRequest = {})); +var OTAUpdateSummary; +(function (OTAUpdateSummary) { + OTAUpdateSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(OTAUpdateSummary = exports.OTAUpdateSummary || (exports.OTAUpdateSummary = {})); +var ListOTAUpdatesResponse; +(function (ListOTAUpdatesResponse) { + ListOTAUpdatesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListOTAUpdatesResponse = exports.ListOTAUpdatesResponse || (exports.ListOTAUpdatesResponse = {})); +var ListOutgoingCertificatesRequest; +(function (ListOutgoingCertificatesRequest) { + ListOutgoingCertificatesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListOutgoingCertificatesRequest = exports.ListOutgoingCertificatesRequest || (exports.ListOutgoingCertificatesRequest = {})); +var OutgoingCertificate; +(function (OutgoingCertificate) { + OutgoingCertificate.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(OutgoingCertificate = exports.OutgoingCertificate || (exports.OutgoingCertificate = {})); +var ListOutgoingCertificatesResponse; +(function (ListOutgoingCertificatesResponse) { + ListOutgoingCertificatesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListOutgoingCertificatesResponse = exports.ListOutgoingCertificatesResponse || (exports.ListOutgoingCertificatesResponse = {})); +var ListPoliciesRequest; +(function (ListPoliciesRequest) { + ListPoliciesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListPoliciesRequest = exports.ListPoliciesRequest || (exports.ListPoliciesRequest = {})); +var ListPoliciesResponse; +(function (ListPoliciesResponse) { + ListPoliciesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListPoliciesResponse = exports.ListPoliciesResponse || (exports.ListPoliciesResponse = {})); +var ListPolicyPrincipalsRequest; +(function (ListPolicyPrincipalsRequest) { + ListPolicyPrincipalsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListPolicyPrincipalsRequest = exports.ListPolicyPrincipalsRequest || (exports.ListPolicyPrincipalsRequest = {})); +var ListPolicyPrincipalsResponse; +(function (ListPolicyPrincipalsResponse) { + ListPolicyPrincipalsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListPolicyPrincipalsResponse = exports.ListPolicyPrincipalsResponse || (exports.ListPolicyPrincipalsResponse = {})); +var ListPolicyVersionsRequest; +(function (ListPolicyVersionsRequest) { + ListPolicyVersionsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListPolicyVersionsRequest = exports.ListPolicyVersionsRequest || (exports.ListPolicyVersionsRequest = {})); +var PolicyVersion; +(function (PolicyVersion) { + PolicyVersion.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(PolicyVersion = exports.PolicyVersion || (exports.PolicyVersion = {})); +var ListPolicyVersionsResponse; +(function (ListPolicyVersionsResponse) { + ListPolicyVersionsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListPolicyVersionsResponse = exports.ListPolicyVersionsResponse || (exports.ListPolicyVersionsResponse = {})); +var ListPrincipalPoliciesRequest; +(function (ListPrincipalPoliciesRequest) { + ListPrincipalPoliciesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListPrincipalPoliciesRequest = exports.ListPrincipalPoliciesRequest || (exports.ListPrincipalPoliciesRequest = {})); +var ListPrincipalPoliciesResponse; +(function (ListPrincipalPoliciesResponse) { + ListPrincipalPoliciesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListPrincipalPoliciesResponse = exports.ListPrincipalPoliciesResponse || (exports.ListPrincipalPoliciesResponse = {})); +var ListPrincipalThingsRequest; +(function (ListPrincipalThingsRequest) { + ListPrincipalThingsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListPrincipalThingsRequest = exports.ListPrincipalThingsRequest || (exports.ListPrincipalThingsRequest = {})); +var ListPrincipalThingsResponse; +(function (ListPrincipalThingsResponse) { + ListPrincipalThingsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListPrincipalThingsResponse = exports.ListPrincipalThingsResponse || (exports.ListPrincipalThingsResponse = {})); +var ListProvisioningTemplatesRequest; +(function (ListProvisioningTemplatesRequest) { + ListProvisioningTemplatesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListProvisioningTemplatesRequest = exports.ListProvisioningTemplatesRequest || (exports.ListProvisioningTemplatesRequest = {})); +var ProvisioningTemplateSummary; +(function (ProvisioningTemplateSummary) { + ProvisioningTemplateSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ProvisioningTemplateSummary = exports.ProvisioningTemplateSummary || (exports.ProvisioningTemplateSummary = {})); +var ListProvisioningTemplatesResponse; +(function (ListProvisioningTemplatesResponse) { + ListProvisioningTemplatesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListProvisioningTemplatesResponse = exports.ListProvisioningTemplatesResponse || (exports.ListProvisioningTemplatesResponse = {})); +var ListProvisioningTemplateVersionsRequest; +(function (ListProvisioningTemplateVersionsRequest) { + ListProvisioningTemplateVersionsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListProvisioningTemplateVersionsRequest = exports.ListProvisioningTemplateVersionsRequest || (exports.ListProvisioningTemplateVersionsRequest = {})); +var ProvisioningTemplateVersionSummary; +(function (ProvisioningTemplateVersionSummary) { + ProvisioningTemplateVersionSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ProvisioningTemplateVersionSummary = exports.ProvisioningTemplateVersionSummary || (exports.ProvisioningTemplateVersionSummary = {})); +var ListProvisioningTemplateVersionsResponse; +(function (ListProvisioningTemplateVersionsResponse) { + ListProvisioningTemplateVersionsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListProvisioningTemplateVersionsResponse = exports.ListProvisioningTemplateVersionsResponse || (exports.ListProvisioningTemplateVersionsResponse = {})); +var ListRoleAliasesRequest; +(function (ListRoleAliasesRequest) { + ListRoleAliasesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListRoleAliasesRequest = exports.ListRoleAliasesRequest || (exports.ListRoleAliasesRequest = {})); +var ListRoleAliasesResponse; +(function (ListRoleAliasesResponse) { + ListRoleAliasesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListRoleAliasesResponse = exports.ListRoleAliasesResponse || (exports.ListRoleAliasesResponse = {})); +var ListScheduledAuditsRequest; +(function (ListScheduledAuditsRequest) { + ListScheduledAuditsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListScheduledAuditsRequest = exports.ListScheduledAuditsRequest || (exports.ListScheduledAuditsRequest = {})); +var ScheduledAuditMetadata; +(function (ScheduledAuditMetadata) { + ScheduledAuditMetadata.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ScheduledAuditMetadata = exports.ScheduledAuditMetadata || (exports.ScheduledAuditMetadata = {})); +var ListScheduledAuditsResponse; +(function (ListScheduledAuditsResponse) { + ListScheduledAuditsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListScheduledAuditsResponse = exports.ListScheduledAuditsResponse || (exports.ListScheduledAuditsResponse = {})); +var ListSecurityProfilesRequest; +(function (ListSecurityProfilesRequest) { + ListSecurityProfilesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListSecurityProfilesRequest = exports.ListSecurityProfilesRequest || (exports.ListSecurityProfilesRequest = {})); +var SecurityProfileIdentifier; +(function (SecurityProfileIdentifier) { + SecurityProfileIdentifier.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SecurityProfileIdentifier = exports.SecurityProfileIdentifier || (exports.SecurityProfileIdentifier = {})); +var ListSecurityProfilesResponse; +(function (ListSecurityProfilesResponse) { + ListSecurityProfilesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListSecurityProfilesResponse = exports.ListSecurityProfilesResponse || (exports.ListSecurityProfilesResponse = {})); +var ListSecurityProfilesForTargetRequest; +(function (ListSecurityProfilesForTargetRequest) { + ListSecurityProfilesForTargetRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListSecurityProfilesForTargetRequest = exports.ListSecurityProfilesForTargetRequest || (exports.ListSecurityProfilesForTargetRequest = {})); +var SecurityProfileTarget; +(function (SecurityProfileTarget) { + SecurityProfileTarget.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SecurityProfileTarget = exports.SecurityProfileTarget || (exports.SecurityProfileTarget = {})); +var SecurityProfileTargetMapping; +(function (SecurityProfileTargetMapping) { + SecurityProfileTargetMapping.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SecurityProfileTargetMapping = exports.SecurityProfileTargetMapping || (exports.SecurityProfileTargetMapping = {})); +var ListSecurityProfilesForTargetResponse; +(function (ListSecurityProfilesForTargetResponse) { + ListSecurityProfilesForTargetResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListSecurityProfilesForTargetResponse = exports.ListSecurityProfilesForTargetResponse || (exports.ListSecurityProfilesForTargetResponse = {})); +var ListStreamsRequest; +(function (ListStreamsRequest) { + ListStreamsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStreamsRequest = exports.ListStreamsRequest || (exports.ListStreamsRequest = {})); +var StreamSummary; +(function (StreamSummary) { + StreamSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StreamSummary = exports.StreamSummary || (exports.StreamSummary = {})); +var ListStreamsResponse; +(function (ListStreamsResponse) { + ListStreamsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListStreamsResponse = exports.ListStreamsResponse || (exports.ListStreamsResponse = {})); +var ListTagsForResourceRequest; +(function (ListTagsForResourceRequest) { + ListTagsForResourceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTagsForResourceRequest = exports.ListTagsForResourceRequest || (exports.ListTagsForResourceRequest = {})); +var ListTagsForResourceResponse; +(function (ListTagsForResourceResponse) { + ListTagsForResourceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTagsForResourceResponse = exports.ListTagsForResourceResponse || (exports.ListTagsForResourceResponse = {})); +var ListTargetsForPolicyRequest; +(function (ListTargetsForPolicyRequest) { + ListTargetsForPolicyRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTargetsForPolicyRequest = exports.ListTargetsForPolicyRequest || (exports.ListTargetsForPolicyRequest = {})); +var ListTargetsForPolicyResponse; +(function (ListTargetsForPolicyResponse) { + ListTargetsForPolicyResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTargetsForPolicyResponse = exports.ListTargetsForPolicyResponse || (exports.ListTargetsForPolicyResponse = {})); +var ListTargetsForSecurityProfileRequest; +(function (ListTargetsForSecurityProfileRequest) { + ListTargetsForSecurityProfileRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTargetsForSecurityProfileRequest = exports.ListTargetsForSecurityProfileRequest || (exports.ListTargetsForSecurityProfileRequest = {})); +var ListTargetsForSecurityProfileResponse; +(function (ListTargetsForSecurityProfileResponse) { + ListTargetsForSecurityProfileResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTargetsForSecurityProfileResponse = exports.ListTargetsForSecurityProfileResponse || (exports.ListTargetsForSecurityProfileResponse = {})); +var ListThingGroupsRequest; +(function (ListThingGroupsRequest) { + ListThingGroupsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingGroupsRequest = exports.ListThingGroupsRequest || (exports.ListThingGroupsRequest = {})); +var ListThingGroupsResponse; +(function (ListThingGroupsResponse) { + ListThingGroupsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingGroupsResponse = exports.ListThingGroupsResponse || (exports.ListThingGroupsResponse = {})); +var ListThingGroupsForThingRequest; +(function (ListThingGroupsForThingRequest) { + ListThingGroupsForThingRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingGroupsForThingRequest = exports.ListThingGroupsForThingRequest || (exports.ListThingGroupsForThingRequest = {})); +var ListThingGroupsForThingResponse; +(function (ListThingGroupsForThingResponse) { + ListThingGroupsForThingResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingGroupsForThingResponse = exports.ListThingGroupsForThingResponse || (exports.ListThingGroupsForThingResponse = {})); +var ListThingPrincipalsRequest; +(function (ListThingPrincipalsRequest) { + ListThingPrincipalsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingPrincipalsRequest = exports.ListThingPrincipalsRequest || (exports.ListThingPrincipalsRequest = {})); +var ListThingPrincipalsResponse; +(function (ListThingPrincipalsResponse) { + ListThingPrincipalsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingPrincipalsResponse = exports.ListThingPrincipalsResponse || (exports.ListThingPrincipalsResponse = {})); +var ReportType; +(function (ReportType) { + ReportType["ERRORS"] = "ERRORS"; + ReportType["RESULTS"] = "RESULTS"; +})(ReportType = exports.ReportType || (exports.ReportType = {})); +var ListThingRegistrationTaskReportsRequest; +(function (ListThingRegistrationTaskReportsRequest) { + ListThingRegistrationTaskReportsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingRegistrationTaskReportsRequest = exports.ListThingRegistrationTaskReportsRequest || (exports.ListThingRegistrationTaskReportsRequest = {})); +var ListThingRegistrationTaskReportsResponse; +(function (ListThingRegistrationTaskReportsResponse) { + ListThingRegistrationTaskReportsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingRegistrationTaskReportsResponse = exports.ListThingRegistrationTaskReportsResponse || (exports.ListThingRegistrationTaskReportsResponse = {})); +var ListThingRegistrationTasksRequest; +(function (ListThingRegistrationTasksRequest) { + ListThingRegistrationTasksRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingRegistrationTasksRequest = exports.ListThingRegistrationTasksRequest || (exports.ListThingRegistrationTasksRequest = {})); +var ListThingRegistrationTasksResponse; +(function (ListThingRegistrationTasksResponse) { + ListThingRegistrationTasksResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingRegistrationTasksResponse = exports.ListThingRegistrationTasksResponse || (exports.ListThingRegistrationTasksResponse = {})); +var ListThingsRequest; +(function (ListThingsRequest) { + ListThingsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingsRequest = exports.ListThingsRequest || (exports.ListThingsRequest = {})); +var ThingAttribute; +(function (ThingAttribute) { + ThingAttribute.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingAttribute = exports.ThingAttribute || (exports.ThingAttribute = {})); +var ListThingsResponse; +(function (ListThingsResponse) { + ListThingsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingsResponse = exports.ListThingsResponse || (exports.ListThingsResponse = {})); +var ListThingsInBillingGroupRequest; +(function (ListThingsInBillingGroupRequest) { + ListThingsInBillingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingsInBillingGroupRequest = exports.ListThingsInBillingGroupRequest || (exports.ListThingsInBillingGroupRequest = {})); +var ListThingsInBillingGroupResponse; +(function (ListThingsInBillingGroupResponse) { + ListThingsInBillingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingsInBillingGroupResponse = exports.ListThingsInBillingGroupResponse || (exports.ListThingsInBillingGroupResponse = {})); +var ListThingsInThingGroupRequest; +(function (ListThingsInThingGroupRequest) { + ListThingsInThingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingsInThingGroupRequest = exports.ListThingsInThingGroupRequest || (exports.ListThingsInThingGroupRequest = {})); +var ListThingsInThingGroupResponse; +(function (ListThingsInThingGroupResponse) { + ListThingsInThingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingsInThingGroupResponse = exports.ListThingsInThingGroupResponse || (exports.ListThingsInThingGroupResponse = {})); +var ListThingTypesRequest; +(function (ListThingTypesRequest) { + ListThingTypesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingTypesRequest = exports.ListThingTypesRequest || (exports.ListThingTypesRequest = {})); +var ThingTypeDefinition; +(function (ThingTypeDefinition) { + ThingTypeDefinition.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingTypeDefinition = exports.ThingTypeDefinition || (exports.ThingTypeDefinition = {})); +var ListThingTypesResponse; +(function (ListThingTypesResponse) { + ListThingTypesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListThingTypesResponse = exports.ListThingTypesResponse || (exports.ListThingTypesResponse = {})); +var ListTopicRuleDestinationsRequest; +(function (ListTopicRuleDestinationsRequest) { + ListTopicRuleDestinationsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTopicRuleDestinationsRequest = exports.ListTopicRuleDestinationsRequest || (exports.ListTopicRuleDestinationsRequest = {})); +var HttpUrlDestinationSummary; +(function (HttpUrlDestinationSummary) { + HttpUrlDestinationSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(HttpUrlDestinationSummary = exports.HttpUrlDestinationSummary || (exports.HttpUrlDestinationSummary = {})); +var TopicRuleDestinationSummary; +(function (TopicRuleDestinationSummary) { + TopicRuleDestinationSummary.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TopicRuleDestinationSummary = exports.TopicRuleDestinationSummary || (exports.TopicRuleDestinationSummary = {})); +var ListTopicRuleDestinationsResponse; +(function (ListTopicRuleDestinationsResponse) { + ListTopicRuleDestinationsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTopicRuleDestinationsResponse = exports.ListTopicRuleDestinationsResponse || (exports.ListTopicRuleDestinationsResponse = {})); +var ListTopicRulesRequest; +(function (ListTopicRulesRequest) { + ListTopicRulesRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTopicRulesRequest = exports.ListTopicRulesRequest || (exports.ListTopicRulesRequest = {})); +var TopicRuleListItem; +(function (TopicRuleListItem) { + TopicRuleListItem.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TopicRuleListItem = exports.TopicRuleListItem || (exports.TopicRuleListItem = {})); +var ListTopicRulesResponse; +(function (ListTopicRulesResponse) { + ListTopicRulesResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListTopicRulesResponse = exports.ListTopicRulesResponse || (exports.ListTopicRulesResponse = {})); +var ListV2LoggingLevelsRequest; +(function (ListV2LoggingLevelsRequest) { + ListV2LoggingLevelsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListV2LoggingLevelsRequest = exports.ListV2LoggingLevelsRequest || (exports.ListV2LoggingLevelsRequest = {})); +var LogTarget; +(function (LogTarget) { + LogTarget.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LogTarget = exports.LogTarget || (exports.LogTarget = {})); +var LogTargetConfiguration; +(function (LogTargetConfiguration) { + LogTargetConfiguration.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LogTargetConfiguration = exports.LogTargetConfiguration || (exports.LogTargetConfiguration = {})); +var ListV2LoggingLevelsResponse; +(function (ListV2LoggingLevelsResponse) { + ListV2LoggingLevelsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListV2LoggingLevelsResponse = exports.ListV2LoggingLevelsResponse || (exports.ListV2LoggingLevelsResponse = {})); +var ListViolationEventsRequest; +(function (ListViolationEventsRequest) { + ListViolationEventsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListViolationEventsRequest = exports.ListViolationEventsRequest || (exports.ListViolationEventsRequest = {})); +var ViolationEventType; +(function (ViolationEventType) { + ViolationEventType["ALARM_CLEARED"] = "alarm-cleared"; + ViolationEventType["ALARM_INVALIDATED"] = "alarm-invalidated"; + ViolationEventType["IN_ALARM"] = "in-alarm"; +})(ViolationEventType = exports.ViolationEventType || (exports.ViolationEventType = {})); +var ViolationEvent; +(function (ViolationEvent) { + ViolationEvent.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ViolationEvent = exports.ViolationEvent || (exports.ViolationEvent = {})); +var ListViolationEventsResponse; +(function (ListViolationEventsResponse) { + ListViolationEventsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ListViolationEventsResponse = exports.ListViolationEventsResponse || (exports.ListViolationEventsResponse = {})); +var RegisterCACertificateRequest; +(function (RegisterCACertificateRequest) { + RegisterCACertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegisterCACertificateRequest = exports.RegisterCACertificateRequest || (exports.RegisterCACertificateRequest = {})); +var RegisterCACertificateResponse; +(function (RegisterCACertificateResponse) { + RegisterCACertificateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegisterCACertificateResponse = exports.RegisterCACertificateResponse || (exports.RegisterCACertificateResponse = {})); +var RegistrationCodeValidationException; +(function (RegistrationCodeValidationException) { + RegistrationCodeValidationException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegistrationCodeValidationException = exports.RegistrationCodeValidationException || (exports.RegistrationCodeValidationException = {})); +var CertificateConflictException; +(function (CertificateConflictException) { + CertificateConflictException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(CertificateConflictException = exports.CertificateConflictException || (exports.CertificateConflictException = {})); +var RegisterCertificateRequest; +(function (RegisterCertificateRequest) { + RegisterCertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegisterCertificateRequest = exports.RegisterCertificateRequest || (exports.RegisterCertificateRequest = {})); +var RegisterCertificateResponse; +(function (RegisterCertificateResponse) { + RegisterCertificateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegisterCertificateResponse = exports.RegisterCertificateResponse || (exports.RegisterCertificateResponse = {})); +var RegisterCertificateWithoutCARequest; +(function (RegisterCertificateWithoutCARequest) { + RegisterCertificateWithoutCARequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegisterCertificateWithoutCARequest = exports.RegisterCertificateWithoutCARequest || (exports.RegisterCertificateWithoutCARequest = {})); +var RegisterCertificateWithoutCAResponse; +(function (RegisterCertificateWithoutCAResponse) { + RegisterCertificateWithoutCAResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegisterCertificateWithoutCAResponse = exports.RegisterCertificateWithoutCAResponse || (exports.RegisterCertificateWithoutCAResponse = {})); +var RegisterThingRequest; +(function (RegisterThingRequest) { + RegisterThingRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegisterThingRequest = exports.RegisterThingRequest || (exports.RegisterThingRequest = {})); +var RegisterThingResponse; +(function (RegisterThingResponse) { + RegisterThingResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RegisterThingResponse = exports.RegisterThingResponse || (exports.RegisterThingResponse = {})); +var ResourceRegistrationFailureException; +(function (ResourceRegistrationFailureException) { + ResourceRegistrationFailureException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ResourceRegistrationFailureException = exports.ResourceRegistrationFailureException || (exports.ResourceRegistrationFailureException = {})); +var RejectCertificateTransferRequest; +(function (RejectCertificateTransferRequest) { + RejectCertificateTransferRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RejectCertificateTransferRequest = exports.RejectCertificateTransferRequest || (exports.RejectCertificateTransferRequest = {})); +var RemoveThingFromBillingGroupRequest; +(function (RemoveThingFromBillingGroupRequest) { + RemoveThingFromBillingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RemoveThingFromBillingGroupRequest = exports.RemoveThingFromBillingGroupRequest || (exports.RemoveThingFromBillingGroupRequest = {})); +var RemoveThingFromBillingGroupResponse; +(function (RemoveThingFromBillingGroupResponse) { + RemoveThingFromBillingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RemoveThingFromBillingGroupResponse = exports.RemoveThingFromBillingGroupResponse || (exports.RemoveThingFromBillingGroupResponse = {})); +var RemoveThingFromThingGroupRequest; +(function (RemoveThingFromThingGroupRequest) { + RemoveThingFromThingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RemoveThingFromThingGroupRequest = exports.RemoveThingFromThingGroupRequest || (exports.RemoveThingFromThingGroupRequest = {})); +var RemoveThingFromThingGroupResponse; +(function (RemoveThingFromThingGroupResponse) { + RemoveThingFromThingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(RemoveThingFromThingGroupResponse = exports.RemoveThingFromThingGroupResponse || (exports.RemoveThingFromThingGroupResponse = {})); +var ReplaceTopicRuleRequest; +(function (ReplaceTopicRuleRequest) { + ReplaceTopicRuleRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ReplaceTopicRuleRequest = exports.ReplaceTopicRuleRequest || (exports.ReplaceTopicRuleRequest = {})); +var SearchIndexRequest; +(function (SearchIndexRequest) { + SearchIndexRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SearchIndexRequest = exports.SearchIndexRequest || (exports.SearchIndexRequest = {})); +var ThingGroupDocument; +(function (ThingGroupDocument) { + ThingGroupDocument.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingGroupDocument = exports.ThingGroupDocument || (exports.ThingGroupDocument = {})); +var ThingConnectivity; +(function (ThingConnectivity) { + ThingConnectivity.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingConnectivity = exports.ThingConnectivity || (exports.ThingConnectivity = {})); +var ThingDocument; +(function (ThingDocument) { + ThingDocument.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ThingDocument = exports.ThingDocument || (exports.ThingDocument = {})); +var SearchIndexResponse; +(function (SearchIndexResponse) { + SearchIndexResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SearchIndexResponse = exports.SearchIndexResponse || (exports.SearchIndexResponse = {})); +var SetDefaultAuthorizerRequest; +(function (SetDefaultAuthorizerRequest) { + SetDefaultAuthorizerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetDefaultAuthorizerRequest = exports.SetDefaultAuthorizerRequest || (exports.SetDefaultAuthorizerRequest = {})); +var SetDefaultAuthorizerResponse; +(function (SetDefaultAuthorizerResponse) { + SetDefaultAuthorizerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetDefaultAuthorizerResponse = exports.SetDefaultAuthorizerResponse || (exports.SetDefaultAuthorizerResponse = {})); +var SetDefaultPolicyVersionRequest; +(function (SetDefaultPolicyVersionRequest) { + SetDefaultPolicyVersionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetDefaultPolicyVersionRequest = exports.SetDefaultPolicyVersionRequest || (exports.SetDefaultPolicyVersionRequest = {})); +var LoggingOptionsPayload; +(function (LoggingOptionsPayload) { + LoggingOptionsPayload.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(LoggingOptionsPayload = exports.LoggingOptionsPayload || (exports.LoggingOptionsPayload = {})); +var SetLoggingOptionsRequest; +(function (SetLoggingOptionsRequest) { + SetLoggingOptionsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetLoggingOptionsRequest = exports.SetLoggingOptionsRequest || (exports.SetLoggingOptionsRequest = {})); +var SetV2LoggingLevelRequest; +(function (SetV2LoggingLevelRequest) { + SetV2LoggingLevelRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetV2LoggingLevelRequest = exports.SetV2LoggingLevelRequest || (exports.SetV2LoggingLevelRequest = {})); +var SetV2LoggingOptionsRequest; +(function (SetV2LoggingOptionsRequest) { + SetV2LoggingOptionsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(SetV2LoggingOptionsRequest = exports.SetV2LoggingOptionsRequest || (exports.SetV2LoggingOptionsRequest = {})); +var StartAuditMitigationActionsTaskRequest; +(function (StartAuditMitigationActionsTaskRequest) { + StartAuditMitigationActionsTaskRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StartAuditMitigationActionsTaskRequest = exports.StartAuditMitigationActionsTaskRequest || (exports.StartAuditMitigationActionsTaskRequest = {})); +var StartAuditMitigationActionsTaskResponse; +(function (StartAuditMitigationActionsTaskResponse) { + StartAuditMitigationActionsTaskResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StartAuditMitigationActionsTaskResponse = exports.StartAuditMitigationActionsTaskResponse || (exports.StartAuditMitigationActionsTaskResponse = {})); +var TaskAlreadyExistsException; +(function (TaskAlreadyExistsException) { + TaskAlreadyExistsException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TaskAlreadyExistsException = exports.TaskAlreadyExistsException || (exports.TaskAlreadyExistsException = {})); +var StartOnDemandAuditTaskRequest; +(function (StartOnDemandAuditTaskRequest) { + StartOnDemandAuditTaskRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StartOnDemandAuditTaskRequest = exports.StartOnDemandAuditTaskRequest || (exports.StartOnDemandAuditTaskRequest = {})); +var StartOnDemandAuditTaskResponse; +(function (StartOnDemandAuditTaskResponse) { + StartOnDemandAuditTaskResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StartOnDemandAuditTaskResponse = exports.StartOnDemandAuditTaskResponse || (exports.StartOnDemandAuditTaskResponse = {})); +var StartThingRegistrationTaskRequest; +(function (StartThingRegistrationTaskRequest) { + StartThingRegistrationTaskRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StartThingRegistrationTaskRequest = exports.StartThingRegistrationTaskRequest || (exports.StartThingRegistrationTaskRequest = {})); +var StartThingRegistrationTaskResponse; +(function (StartThingRegistrationTaskResponse) { + StartThingRegistrationTaskResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StartThingRegistrationTaskResponse = exports.StartThingRegistrationTaskResponse || (exports.StartThingRegistrationTaskResponse = {})); +var StopThingRegistrationTaskRequest; +(function (StopThingRegistrationTaskRequest) { + StopThingRegistrationTaskRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StopThingRegistrationTaskRequest = exports.StopThingRegistrationTaskRequest || (exports.StopThingRegistrationTaskRequest = {})); +var StopThingRegistrationTaskResponse; +(function (StopThingRegistrationTaskResponse) { + StopThingRegistrationTaskResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(StopThingRegistrationTaskResponse = exports.StopThingRegistrationTaskResponse || (exports.StopThingRegistrationTaskResponse = {})); +var TagResourceRequest; +(function (TagResourceRequest) { + TagResourceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TagResourceRequest = exports.TagResourceRequest || (exports.TagResourceRequest = {})); +var TagResourceResponse; +(function (TagResourceResponse) { + TagResourceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TagResourceResponse = exports.TagResourceResponse || (exports.TagResourceResponse = {})); +var TestAuthorizationRequest; +(function (TestAuthorizationRequest) { + TestAuthorizationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TestAuthorizationRequest = exports.TestAuthorizationRequest || (exports.TestAuthorizationRequest = {})); +var TestAuthorizationResponse; +(function (TestAuthorizationResponse) { + TestAuthorizationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TestAuthorizationResponse = exports.TestAuthorizationResponse || (exports.TestAuthorizationResponse = {})); +var InvalidResponseException; +(function (InvalidResponseException) { + InvalidResponseException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(InvalidResponseException = exports.InvalidResponseException || (exports.InvalidResponseException = {})); +var HttpContext; +(function (HttpContext) { + HttpContext.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(HttpContext = exports.HttpContext || (exports.HttpContext = {})); +var MqttContext; +(function (MqttContext) { + MqttContext.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(MqttContext = exports.MqttContext || (exports.MqttContext = {})); +//# sourceMappingURL=models_1.js.map + +/***/ }), + +/***/ 18560: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ValidateSecurityProfileBehaviorsRequest = exports.UpdateTopicRuleDestinationResponse = exports.UpdateTopicRuleDestinationRequest = exports.UpdateThingGroupsForThingResponse = exports.UpdateThingGroupsForThingRequest = exports.UpdateThingGroupResponse = exports.UpdateThingGroupRequest = exports.UpdateThingResponse = exports.UpdateThingRequest = exports.UpdateStreamResponse = exports.UpdateStreamRequest = exports.UpdateSecurityProfileResponse = exports.UpdateSecurityProfileRequest = exports.UpdateScheduledAuditResponse = exports.UpdateScheduledAuditRequest = exports.UpdateRoleAliasResponse = exports.UpdateRoleAliasRequest = exports.UpdateProvisioningTemplateResponse = exports.UpdateProvisioningTemplateRequest = exports.UpdateMitigationActionResponse = exports.UpdateMitigationActionRequest = exports.UpdateJobRequest = exports.UpdateIndexingConfigurationResponse = exports.UpdateIndexingConfigurationRequest = exports.UpdateEventConfigurationsResponse = exports.UpdateEventConfigurationsRequest = exports.UpdateDynamicThingGroupResponse = exports.UpdateDynamicThingGroupRequest = exports.UpdateDomainConfigurationResponse = exports.UpdateDomainConfigurationRequest = exports.UpdateDimensionResponse = exports.UpdateDimensionRequest = exports.UpdateCertificateRequest = exports.UpdateCACertificateRequest = exports.UpdateBillingGroupResponse = exports.UpdateBillingGroupRequest = exports.UpdateAuthorizerResponse = exports.UpdateAuthorizerRequest = exports.UpdateAuditSuppressionResponse = exports.UpdateAuditSuppressionRequest = exports.UpdateAccountAuditConfigurationResponse = exports.UpdateAccountAuditConfigurationRequest = exports.UntagResourceResponse = exports.UntagResourceRequest = exports.TransferConflictException = exports.TransferCertificateResponse = exports.TransferCertificateRequest = exports.TestInvokeAuthorizerResponse = exports.TestInvokeAuthorizerRequest = exports.TlsContext = void 0; +exports.ValidateSecurityProfileBehaviorsResponse = exports.ValidationError = void 0; +var TlsContext; +(function (TlsContext) { + TlsContext.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TlsContext = exports.TlsContext || (exports.TlsContext = {})); +var TestInvokeAuthorizerRequest; +(function (TestInvokeAuthorizerRequest) { + TestInvokeAuthorizerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TestInvokeAuthorizerRequest = exports.TestInvokeAuthorizerRequest || (exports.TestInvokeAuthorizerRequest = {})); +var TestInvokeAuthorizerResponse; +(function (TestInvokeAuthorizerResponse) { + TestInvokeAuthorizerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TestInvokeAuthorizerResponse = exports.TestInvokeAuthorizerResponse || (exports.TestInvokeAuthorizerResponse = {})); +var TransferCertificateRequest; +(function (TransferCertificateRequest) { + TransferCertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TransferCertificateRequest = exports.TransferCertificateRequest || (exports.TransferCertificateRequest = {})); +var TransferCertificateResponse; +(function (TransferCertificateResponse) { + TransferCertificateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TransferCertificateResponse = exports.TransferCertificateResponse || (exports.TransferCertificateResponse = {})); +var TransferConflictException; +(function (TransferConflictException) { + TransferConflictException.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(TransferConflictException = exports.TransferConflictException || (exports.TransferConflictException = {})); +var UntagResourceRequest; +(function (UntagResourceRequest) { + UntagResourceRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UntagResourceRequest = exports.UntagResourceRequest || (exports.UntagResourceRequest = {})); +var UntagResourceResponse; +(function (UntagResourceResponse) { + UntagResourceResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UntagResourceResponse = exports.UntagResourceResponse || (exports.UntagResourceResponse = {})); +var UpdateAccountAuditConfigurationRequest; +(function (UpdateAccountAuditConfigurationRequest) { + UpdateAccountAuditConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateAccountAuditConfigurationRequest = exports.UpdateAccountAuditConfigurationRequest || (exports.UpdateAccountAuditConfigurationRequest = {})); +var UpdateAccountAuditConfigurationResponse; +(function (UpdateAccountAuditConfigurationResponse) { + UpdateAccountAuditConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateAccountAuditConfigurationResponse = exports.UpdateAccountAuditConfigurationResponse || (exports.UpdateAccountAuditConfigurationResponse = {})); +var UpdateAuditSuppressionRequest; +(function (UpdateAuditSuppressionRequest) { + UpdateAuditSuppressionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateAuditSuppressionRequest = exports.UpdateAuditSuppressionRequest || (exports.UpdateAuditSuppressionRequest = {})); +var UpdateAuditSuppressionResponse; +(function (UpdateAuditSuppressionResponse) { + UpdateAuditSuppressionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateAuditSuppressionResponse = exports.UpdateAuditSuppressionResponse || (exports.UpdateAuditSuppressionResponse = {})); +var UpdateAuthorizerRequest; +(function (UpdateAuthorizerRequest) { + UpdateAuthorizerRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateAuthorizerRequest = exports.UpdateAuthorizerRequest || (exports.UpdateAuthorizerRequest = {})); +var UpdateAuthorizerResponse; +(function (UpdateAuthorizerResponse) { + UpdateAuthorizerResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateAuthorizerResponse = exports.UpdateAuthorizerResponse || (exports.UpdateAuthorizerResponse = {})); +var UpdateBillingGroupRequest; +(function (UpdateBillingGroupRequest) { + UpdateBillingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateBillingGroupRequest = exports.UpdateBillingGroupRequest || (exports.UpdateBillingGroupRequest = {})); +var UpdateBillingGroupResponse; +(function (UpdateBillingGroupResponse) { + UpdateBillingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateBillingGroupResponse = exports.UpdateBillingGroupResponse || (exports.UpdateBillingGroupResponse = {})); +var UpdateCACertificateRequest; +(function (UpdateCACertificateRequest) { + UpdateCACertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateCACertificateRequest = exports.UpdateCACertificateRequest || (exports.UpdateCACertificateRequest = {})); +var UpdateCertificateRequest; +(function (UpdateCertificateRequest) { + UpdateCertificateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateCertificateRequest = exports.UpdateCertificateRequest || (exports.UpdateCertificateRequest = {})); +var UpdateDimensionRequest; +(function (UpdateDimensionRequest) { + UpdateDimensionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateDimensionRequest = exports.UpdateDimensionRequest || (exports.UpdateDimensionRequest = {})); +var UpdateDimensionResponse; +(function (UpdateDimensionResponse) { + UpdateDimensionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateDimensionResponse = exports.UpdateDimensionResponse || (exports.UpdateDimensionResponse = {})); +var UpdateDomainConfigurationRequest; +(function (UpdateDomainConfigurationRequest) { + UpdateDomainConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateDomainConfigurationRequest = exports.UpdateDomainConfigurationRequest || (exports.UpdateDomainConfigurationRequest = {})); +var UpdateDomainConfigurationResponse; +(function (UpdateDomainConfigurationResponse) { + UpdateDomainConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateDomainConfigurationResponse = exports.UpdateDomainConfigurationResponse || (exports.UpdateDomainConfigurationResponse = {})); +var UpdateDynamicThingGroupRequest; +(function (UpdateDynamicThingGroupRequest) { + UpdateDynamicThingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateDynamicThingGroupRequest = exports.UpdateDynamicThingGroupRequest || (exports.UpdateDynamicThingGroupRequest = {})); +var UpdateDynamicThingGroupResponse; +(function (UpdateDynamicThingGroupResponse) { + UpdateDynamicThingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateDynamicThingGroupResponse = exports.UpdateDynamicThingGroupResponse || (exports.UpdateDynamicThingGroupResponse = {})); +var UpdateEventConfigurationsRequest; +(function (UpdateEventConfigurationsRequest) { + UpdateEventConfigurationsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateEventConfigurationsRequest = exports.UpdateEventConfigurationsRequest || (exports.UpdateEventConfigurationsRequest = {})); +var UpdateEventConfigurationsResponse; +(function (UpdateEventConfigurationsResponse) { + UpdateEventConfigurationsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateEventConfigurationsResponse = exports.UpdateEventConfigurationsResponse || (exports.UpdateEventConfigurationsResponse = {})); +var UpdateIndexingConfigurationRequest; +(function (UpdateIndexingConfigurationRequest) { + UpdateIndexingConfigurationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateIndexingConfigurationRequest = exports.UpdateIndexingConfigurationRequest || (exports.UpdateIndexingConfigurationRequest = {})); +var UpdateIndexingConfigurationResponse; +(function (UpdateIndexingConfigurationResponse) { + UpdateIndexingConfigurationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateIndexingConfigurationResponse = exports.UpdateIndexingConfigurationResponse || (exports.UpdateIndexingConfigurationResponse = {})); +var UpdateJobRequest; +(function (UpdateJobRequest) { + UpdateJobRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateJobRequest = exports.UpdateJobRequest || (exports.UpdateJobRequest = {})); +var UpdateMitigationActionRequest; +(function (UpdateMitigationActionRequest) { + UpdateMitigationActionRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateMitigationActionRequest = exports.UpdateMitigationActionRequest || (exports.UpdateMitigationActionRequest = {})); +var UpdateMitigationActionResponse; +(function (UpdateMitigationActionResponse) { + UpdateMitigationActionResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateMitigationActionResponse = exports.UpdateMitigationActionResponse || (exports.UpdateMitigationActionResponse = {})); +var UpdateProvisioningTemplateRequest; +(function (UpdateProvisioningTemplateRequest) { + UpdateProvisioningTemplateRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateProvisioningTemplateRequest = exports.UpdateProvisioningTemplateRequest || (exports.UpdateProvisioningTemplateRequest = {})); +var UpdateProvisioningTemplateResponse; +(function (UpdateProvisioningTemplateResponse) { + UpdateProvisioningTemplateResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateProvisioningTemplateResponse = exports.UpdateProvisioningTemplateResponse || (exports.UpdateProvisioningTemplateResponse = {})); +var UpdateRoleAliasRequest; +(function (UpdateRoleAliasRequest) { + UpdateRoleAliasRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateRoleAliasRequest = exports.UpdateRoleAliasRequest || (exports.UpdateRoleAliasRequest = {})); +var UpdateRoleAliasResponse; +(function (UpdateRoleAliasResponse) { + UpdateRoleAliasResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateRoleAliasResponse = exports.UpdateRoleAliasResponse || (exports.UpdateRoleAliasResponse = {})); +var UpdateScheduledAuditRequest; +(function (UpdateScheduledAuditRequest) { + UpdateScheduledAuditRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateScheduledAuditRequest = exports.UpdateScheduledAuditRequest || (exports.UpdateScheduledAuditRequest = {})); +var UpdateScheduledAuditResponse; +(function (UpdateScheduledAuditResponse) { + UpdateScheduledAuditResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateScheduledAuditResponse = exports.UpdateScheduledAuditResponse || (exports.UpdateScheduledAuditResponse = {})); +var UpdateSecurityProfileRequest; +(function (UpdateSecurityProfileRequest) { + UpdateSecurityProfileRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateSecurityProfileRequest = exports.UpdateSecurityProfileRequest || (exports.UpdateSecurityProfileRequest = {})); +var UpdateSecurityProfileResponse; +(function (UpdateSecurityProfileResponse) { + UpdateSecurityProfileResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateSecurityProfileResponse = exports.UpdateSecurityProfileResponse || (exports.UpdateSecurityProfileResponse = {})); +var UpdateStreamRequest; +(function (UpdateStreamRequest) { + UpdateStreamRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateStreamRequest = exports.UpdateStreamRequest || (exports.UpdateStreamRequest = {})); +var UpdateStreamResponse; +(function (UpdateStreamResponse) { + UpdateStreamResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateStreamResponse = exports.UpdateStreamResponse || (exports.UpdateStreamResponse = {})); +var UpdateThingRequest; +(function (UpdateThingRequest) { + UpdateThingRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateThingRequest = exports.UpdateThingRequest || (exports.UpdateThingRequest = {})); +var UpdateThingResponse; +(function (UpdateThingResponse) { + UpdateThingResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateThingResponse = exports.UpdateThingResponse || (exports.UpdateThingResponse = {})); +var UpdateThingGroupRequest; +(function (UpdateThingGroupRequest) { + UpdateThingGroupRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateThingGroupRequest = exports.UpdateThingGroupRequest || (exports.UpdateThingGroupRequest = {})); +var UpdateThingGroupResponse; +(function (UpdateThingGroupResponse) { + UpdateThingGroupResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateThingGroupResponse = exports.UpdateThingGroupResponse || (exports.UpdateThingGroupResponse = {})); +var UpdateThingGroupsForThingRequest; +(function (UpdateThingGroupsForThingRequest) { + UpdateThingGroupsForThingRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateThingGroupsForThingRequest = exports.UpdateThingGroupsForThingRequest || (exports.UpdateThingGroupsForThingRequest = {})); +var UpdateThingGroupsForThingResponse; +(function (UpdateThingGroupsForThingResponse) { + UpdateThingGroupsForThingResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateThingGroupsForThingResponse = exports.UpdateThingGroupsForThingResponse || (exports.UpdateThingGroupsForThingResponse = {})); +var UpdateTopicRuleDestinationRequest; +(function (UpdateTopicRuleDestinationRequest) { + UpdateTopicRuleDestinationRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateTopicRuleDestinationRequest = exports.UpdateTopicRuleDestinationRequest || (exports.UpdateTopicRuleDestinationRequest = {})); +var UpdateTopicRuleDestinationResponse; +(function (UpdateTopicRuleDestinationResponse) { + UpdateTopicRuleDestinationResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(UpdateTopicRuleDestinationResponse = exports.UpdateTopicRuleDestinationResponse || (exports.UpdateTopicRuleDestinationResponse = {})); +var ValidateSecurityProfileBehaviorsRequest; +(function (ValidateSecurityProfileBehaviorsRequest) { + ValidateSecurityProfileBehaviorsRequest.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ValidateSecurityProfileBehaviorsRequest = exports.ValidateSecurityProfileBehaviorsRequest || (exports.ValidateSecurityProfileBehaviorsRequest = {})); +var ValidationError; +(function (ValidationError) { + ValidationError.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ValidationError = exports.ValidationError || (exports.ValidationError = {})); +var ValidateSecurityProfileBehaviorsResponse; +(function (ValidateSecurityProfileBehaviorsResponse) { + ValidateSecurityProfileBehaviorsResponse.filterSensitiveLog = (obj) => ({ + ...obj, + }); +})(ValidateSecurityProfileBehaviorsResponse = exports.ValidateSecurityProfileBehaviorsResponse || (exports.ValidateSecurityProfileBehaviorsResponse = {})); +//# sourceMappingURL=models_2.js.map + +/***/ }), + +/***/ 84794: +/***/ ((__unused_webpack_module, exports) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +//# sourceMappingURL=Interfaces.js.map + +/***/ }), + +/***/ 68814: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListActiveViolations = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListActiveViolationsCommand_1 = __nccwpck_require__(90886); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListActiveViolationsCommand_1.ListActiveViolationsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listActiveViolations(input, ...args); +}; +async function* paginateListActiveViolations(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListActiveViolations = paginateListActiveViolations; +//# sourceMappingURL=ListActiveViolationsPaginator.js.map + +/***/ }), + +/***/ 58222: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListAttachedPolicies = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListAttachedPoliciesCommand_1 = __nccwpck_require__(59388); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListAttachedPoliciesCommand_1.ListAttachedPoliciesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listAttachedPolicies(input, ...args); +}; +async function* paginateListAttachedPolicies(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListAttachedPolicies = paginateListAttachedPolicies; +//# sourceMappingURL=ListAttachedPoliciesPaginator.js.map + +/***/ }), + +/***/ 58370: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListAuditFindings = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListAuditFindingsCommand_1 = __nccwpck_require__(55133); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListAuditFindingsCommand_1.ListAuditFindingsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listAuditFindings(input, ...args); +}; +async function* paginateListAuditFindings(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListAuditFindings = paginateListAuditFindings; +//# sourceMappingURL=ListAuditFindingsPaginator.js.map + +/***/ }), + +/***/ 92447: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListAuditMitigationActionsExecutions = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListAuditMitigationActionsExecutionsCommand_1 = __nccwpck_require__(35836); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListAuditMitigationActionsExecutionsCommand_1.ListAuditMitigationActionsExecutionsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listAuditMitigationActionsExecutions(input, ...args); +}; +async function* paginateListAuditMitigationActionsExecutions(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListAuditMitigationActionsExecutions = paginateListAuditMitigationActionsExecutions; +//# sourceMappingURL=ListAuditMitigationActionsExecutionsPaginator.js.map + +/***/ }), + +/***/ 67042: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListAuditMitigationActionsTasks = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListAuditMitigationActionsTasksCommand_1 = __nccwpck_require__(45704); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListAuditMitigationActionsTasksCommand_1.ListAuditMitigationActionsTasksCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listAuditMitigationActionsTasks(input, ...args); +}; +async function* paginateListAuditMitigationActionsTasks(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListAuditMitigationActionsTasks = paginateListAuditMitigationActionsTasks; +//# sourceMappingURL=ListAuditMitigationActionsTasksPaginator.js.map + +/***/ }), + +/***/ 69192: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListAuditSuppressions = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListAuditSuppressionsCommand_1 = __nccwpck_require__(60827); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListAuditSuppressionsCommand_1.ListAuditSuppressionsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listAuditSuppressions(input, ...args); +}; +async function* paginateListAuditSuppressions(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListAuditSuppressions = paginateListAuditSuppressions; +//# sourceMappingURL=ListAuditSuppressionsPaginator.js.map + +/***/ }), + +/***/ 27418: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListAuditTasks = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListAuditTasksCommand_1 = __nccwpck_require__(50108); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListAuditTasksCommand_1.ListAuditTasksCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listAuditTasks(input, ...args); +}; +async function* paginateListAuditTasks(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListAuditTasks = paginateListAuditTasks; +//# sourceMappingURL=ListAuditTasksPaginator.js.map + +/***/ }), + +/***/ 92292: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListAuthorizers = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListAuthorizersCommand_1 = __nccwpck_require__(99389); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListAuthorizersCommand_1.ListAuthorizersCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listAuthorizers(input, ...args); +}; +async function* paginateListAuthorizers(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListAuthorizers = paginateListAuthorizers; +//# sourceMappingURL=ListAuthorizersPaginator.js.map + +/***/ }), + +/***/ 18259: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListBillingGroups = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListBillingGroupsCommand_1 = __nccwpck_require__(13648); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListBillingGroupsCommand_1.ListBillingGroupsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listBillingGroups(input, ...args); +}; +async function* paginateListBillingGroups(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListBillingGroups = paginateListBillingGroups; +//# sourceMappingURL=ListBillingGroupsPaginator.js.map + +/***/ }), + +/***/ 68779: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListCACertificates = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListCACertificatesCommand_1 = __nccwpck_require__(77650); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListCACertificatesCommand_1.ListCACertificatesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listCACertificates(input, ...args); +}; +async function* paginateListCACertificates(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListCACertificates = paginateListCACertificates; +//# sourceMappingURL=ListCACertificatesPaginator.js.map + +/***/ }), + +/***/ 14659: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListCertificatesByCA = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListCertificatesByCACommand_1 = __nccwpck_require__(23163); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListCertificatesByCACommand_1.ListCertificatesByCACommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listCertificatesByCA(input, ...args); +}; +async function* paginateListCertificatesByCA(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListCertificatesByCA = paginateListCertificatesByCA; +//# sourceMappingURL=ListCertificatesByCAPaginator.js.map + +/***/ }), + +/***/ 6910: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListCertificates = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListCertificatesCommand_1 = __nccwpck_require__(14749); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListCertificatesCommand_1.ListCertificatesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listCertificates(input, ...args); +}; +async function* paginateListCertificates(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListCertificates = paginateListCertificates; +//# sourceMappingURL=ListCertificatesPaginator.js.map + +/***/ }), + +/***/ 9723: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListDimensions = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListDimensionsCommand_1 = __nccwpck_require__(74775); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListDimensionsCommand_1.ListDimensionsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listDimensions(input, ...args); +}; +async function* paginateListDimensions(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListDimensions = paginateListDimensions; +//# sourceMappingURL=ListDimensionsPaginator.js.map + +/***/ }), + +/***/ 138: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListDomainConfigurations = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListDomainConfigurationsCommand_1 = __nccwpck_require__(75947); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListDomainConfigurationsCommand_1.ListDomainConfigurationsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listDomainConfigurations(input, ...args); +}; +async function* paginateListDomainConfigurations(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListDomainConfigurations = paginateListDomainConfigurations; +//# sourceMappingURL=ListDomainConfigurationsPaginator.js.map + +/***/ }), + +/***/ 5668: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListIndices = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListIndicesCommand_1 = __nccwpck_require__(36240); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListIndicesCommand_1.ListIndicesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listIndices(input, ...args); +}; +async function* paginateListIndices(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListIndices = paginateListIndices; +//# sourceMappingURL=ListIndicesPaginator.js.map + +/***/ }), + +/***/ 74053: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListJobExecutionsForJob = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListJobExecutionsForJobCommand_1 = __nccwpck_require__(68068); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListJobExecutionsForJobCommand_1.ListJobExecutionsForJobCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listJobExecutionsForJob(input, ...args); +}; +async function* paginateListJobExecutionsForJob(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListJobExecutionsForJob = paginateListJobExecutionsForJob; +//# sourceMappingURL=ListJobExecutionsForJobPaginator.js.map + +/***/ }), + +/***/ 21477: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListJobExecutionsForThing = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListJobExecutionsForThingCommand_1 = __nccwpck_require__(20874); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListJobExecutionsForThingCommand_1.ListJobExecutionsForThingCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listJobExecutionsForThing(input, ...args); +}; +async function* paginateListJobExecutionsForThing(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListJobExecutionsForThing = paginateListJobExecutionsForThing; +//# sourceMappingURL=ListJobExecutionsForThingPaginator.js.map + +/***/ }), + +/***/ 7859: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListJobs = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListJobsCommand_1 = __nccwpck_require__(25341); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListJobsCommand_1.ListJobsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listJobs(input, ...args); +}; +async function* paginateListJobs(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListJobs = paginateListJobs; +//# sourceMappingURL=ListJobsPaginator.js.map + +/***/ }), + +/***/ 57331: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListMitigationActions = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListMitigationActionsCommand_1 = __nccwpck_require__(93159); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListMitigationActionsCommand_1.ListMitigationActionsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listMitigationActions(input, ...args); +}; +async function* paginateListMitigationActions(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListMitigationActions = paginateListMitigationActions; +//# sourceMappingURL=ListMitigationActionsPaginator.js.map + +/***/ }), + +/***/ 41916: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListOTAUpdates = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListOTAUpdatesCommand_1 = __nccwpck_require__(76188); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListOTAUpdatesCommand_1.ListOTAUpdatesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listOTAUpdates(input, ...args); +}; +async function* paginateListOTAUpdates(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListOTAUpdates = paginateListOTAUpdates; +//# sourceMappingURL=ListOTAUpdatesPaginator.js.map + +/***/ }), + +/***/ 92342: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListOutgoingCertificates = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListOutgoingCertificatesCommand_1 = __nccwpck_require__(90321); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListOutgoingCertificatesCommand_1.ListOutgoingCertificatesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listOutgoingCertificates(input, ...args); +}; +async function* paginateListOutgoingCertificates(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListOutgoingCertificates = paginateListOutgoingCertificates; +//# sourceMappingURL=ListOutgoingCertificatesPaginator.js.map + +/***/ }), + +/***/ 37844: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListPolicies = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListPoliciesCommand_1 = __nccwpck_require__(81192); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListPoliciesCommand_1.ListPoliciesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listPolicies(input, ...args); +}; +async function* paginateListPolicies(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListPolicies = paginateListPolicies; +//# sourceMappingURL=ListPoliciesPaginator.js.map + +/***/ }), + +/***/ 57302: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListPolicyPrincipals = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListPolicyPrincipalsCommand_1 = __nccwpck_require__(86657); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListPolicyPrincipalsCommand_1.ListPolicyPrincipalsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listPolicyPrincipals(input, ...args); +}; +async function* paginateListPolicyPrincipals(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListPolicyPrincipals = paginateListPolicyPrincipals; +//# sourceMappingURL=ListPolicyPrincipalsPaginator.js.map + +/***/ }), + +/***/ 42167: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListPrincipalPolicies = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListPrincipalPoliciesCommand_1 = __nccwpck_require__(3702); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListPrincipalPoliciesCommand_1.ListPrincipalPoliciesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listPrincipalPolicies(input, ...args); +}; +async function* paginateListPrincipalPolicies(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListPrincipalPolicies = paginateListPrincipalPolicies; +//# sourceMappingURL=ListPrincipalPoliciesPaginator.js.map + +/***/ }), + +/***/ 24220: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListPrincipalThings = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListPrincipalThingsCommand_1 = __nccwpck_require__(62558); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListPrincipalThingsCommand_1.ListPrincipalThingsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listPrincipalThings(input, ...args); +}; +async function* paginateListPrincipalThings(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListPrincipalThings = paginateListPrincipalThings; +//# sourceMappingURL=ListPrincipalThingsPaginator.js.map + +/***/ }), + +/***/ 54754: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListProvisioningTemplateVersions = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListProvisioningTemplateVersionsCommand_1 = __nccwpck_require__(48529); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListProvisioningTemplateVersionsCommand_1.ListProvisioningTemplateVersionsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listProvisioningTemplateVersions(input, ...args); +}; +async function* paginateListProvisioningTemplateVersions(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListProvisioningTemplateVersions = paginateListProvisioningTemplateVersions; +//# sourceMappingURL=ListProvisioningTemplateVersionsPaginator.js.map + +/***/ }), + +/***/ 14156: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListProvisioningTemplates = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListProvisioningTemplatesCommand_1 = __nccwpck_require__(59524); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListProvisioningTemplatesCommand_1.ListProvisioningTemplatesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listProvisioningTemplates(input, ...args); +}; +async function* paginateListProvisioningTemplates(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListProvisioningTemplates = paginateListProvisioningTemplates; +//# sourceMappingURL=ListProvisioningTemplatesPaginator.js.map + +/***/ }), + +/***/ 9058: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListRoleAliases = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListRoleAliasesCommand_1 = __nccwpck_require__(31543); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListRoleAliasesCommand_1.ListRoleAliasesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listRoleAliases(input, ...args); +}; +async function* paginateListRoleAliases(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListRoleAliases = paginateListRoleAliases; +//# sourceMappingURL=ListRoleAliasesPaginator.js.map + +/***/ }), + +/***/ 47065: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListScheduledAudits = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListScheduledAuditsCommand_1 = __nccwpck_require__(79905); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListScheduledAuditsCommand_1.ListScheduledAuditsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listScheduledAudits(input, ...args); +}; +async function* paginateListScheduledAudits(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListScheduledAudits = paginateListScheduledAudits; +//# sourceMappingURL=ListScheduledAuditsPaginator.js.map + +/***/ }), + +/***/ 99728: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListSecurityProfilesForTarget = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListSecurityProfilesForTargetCommand_1 = __nccwpck_require__(26323); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListSecurityProfilesForTargetCommand_1.ListSecurityProfilesForTargetCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listSecurityProfilesForTarget(input, ...args); +}; +async function* paginateListSecurityProfilesForTarget(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListSecurityProfilesForTarget = paginateListSecurityProfilesForTarget; +//# sourceMappingURL=ListSecurityProfilesForTargetPaginator.js.map + +/***/ }), + +/***/ 70383: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListSecurityProfiles = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListSecurityProfilesCommand_1 = __nccwpck_require__(17473); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListSecurityProfilesCommand_1.ListSecurityProfilesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listSecurityProfiles(input, ...args); +}; +async function* paginateListSecurityProfiles(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListSecurityProfiles = paginateListSecurityProfiles; +//# sourceMappingURL=ListSecurityProfilesPaginator.js.map + +/***/ }), + +/***/ 53265: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListStreams = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListStreamsCommand_1 = __nccwpck_require__(76326); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListStreamsCommand_1.ListStreamsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listStreams(input, ...args); +}; +async function* paginateListStreams(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListStreams = paginateListStreams; +//# sourceMappingURL=ListStreamsPaginator.js.map + +/***/ }), + +/***/ 35733: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListTagsForResource = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListTagsForResourceCommand_1 = __nccwpck_require__(87749); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListTagsForResourceCommand_1.ListTagsForResourceCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listTagsForResource(input, ...args); +}; +async function* paginateListTagsForResource(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListTagsForResource = paginateListTagsForResource; +//# sourceMappingURL=ListTagsForResourcePaginator.js.map + +/***/ }), + +/***/ 12956: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListTargetsForPolicy = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListTargetsForPolicyCommand_1 = __nccwpck_require__(71438); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListTargetsForPolicyCommand_1.ListTargetsForPolicyCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listTargetsForPolicy(input, ...args); +}; +async function* paginateListTargetsForPolicy(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.marker + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.marker = token; + input["pageSize"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextMarker; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListTargetsForPolicy = paginateListTargetsForPolicy; +//# sourceMappingURL=ListTargetsForPolicyPaginator.js.map + +/***/ }), + +/***/ 95814: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListTargetsForSecurityProfile = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListTargetsForSecurityProfileCommand_1 = __nccwpck_require__(47470); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListTargetsForSecurityProfileCommand_1.ListTargetsForSecurityProfileCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listTargetsForSecurityProfile(input, ...args); +}; +async function* paginateListTargetsForSecurityProfile(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListTargetsForSecurityProfile = paginateListTargetsForSecurityProfile; +//# sourceMappingURL=ListTargetsForSecurityProfilePaginator.js.map + +/***/ }), + +/***/ 30363: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListThingGroupsForThing = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListThingGroupsForThingCommand_1 = __nccwpck_require__(532); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListThingGroupsForThingCommand_1.ListThingGroupsForThingCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listThingGroupsForThing(input, ...args); +}; +async function* paginateListThingGroupsForThing(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListThingGroupsForThing = paginateListThingGroupsForThing; +//# sourceMappingURL=ListThingGroupsForThingPaginator.js.map + +/***/ }), + +/***/ 95068: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListThingGroups = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListThingGroupsCommand_1 = __nccwpck_require__(59885); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListThingGroupsCommand_1.ListThingGroupsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listThingGroups(input, ...args); +}; +async function* paginateListThingGroups(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListThingGroups = paginateListThingGroups; +//# sourceMappingURL=ListThingGroupsPaginator.js.map + +/***/ }), + +/***/ 3030: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListThingPrincipals = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListThingPrincipalsCommand_1 = __nccwpck_require__(18466); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListThingPrincipalsCommand_1.ListThingPrincipalsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listThingPrincipals(input, ...args); +}; +async function* paginateListThingPrincipals(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListThingPrincipals = paginateListThingPrincipals; +//# sourceMappingURL=ListThingPrincipalsPaginator.js.map + +/***/ }), + +/***/ 26240: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListThingRegistrationTaskReports = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListThingRegistrationTaskReportsCommand_1 = __nccwpck_require__(31905); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListThingRegistrationTaskReportsCommand_1.ListThingRegistrationTaskReportsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listThingRegistrationTaskReports(input, ...args); +}; +async function* paginateListThingRegistrationTaskReports(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListThingRegistrationTaskReports = paginateListThingRegistrationTaskReports; +//# sourceMappingURL=ListThingRegistrationTaskReportsPaginator.js.map + +/***/ }), + +/***/ 92400: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListThingRegistrationTasks = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListThingRegistrationTasksCommand_1 = __nccwpck_require__(74999); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListThingRegistrationTasksCommand_1.ListThingRegistrationTasksCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listThingRegistrationTasks(input, ...args); +}; +async function* paginateListThingRegistrationTasks(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListThingRegistrationTasks = paginateListThingRegistrationTasks; +//# sourceMappingURL=ListThingRegistrationTasksPaginator.js.map + +/***/ }), + +/***/ 38172: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListThingTypes = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListThingTypesCommand_1 = __nccwpck_require__(28092); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListThingTypesCommand_1.ListThingTypesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listThingTypes(input, ...args); +}; +async function* paginateListThingTypes(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListThingTypes = paginateListThingTypes; +//# sourceMappingURL=ListThingTypesPaginator.js.map + +/***/ }), + +/***/ 70873: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListThingsInBillingGroup = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListThingsInBillingGroupCommand_1 = __nccwpck_require__(51357); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListThingsInBillingGroupCommand_1.ListThingsInBillingGroupCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listThingsInBillingGroup(input, ...args); +}; +async function* paginateListThingsInBillingGroup(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListThingsInBillingGroup = paginateListThingsInBillingGroup; +//# sourceMappingURL=ListThingsInBillingGroupPaginator.js.map + +/***/ }), + +/***/ 90446: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListThingsInThingGroup = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListThingsInThingGroupCommand_1 = __nccwpck_require__(33672); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListThingsInThingGroupCommand_1.ListThingsInThingGroupCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listThingsInThingGroup(input, ...args); +}; +async function* paginateListThingsInThingGroup(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListThingsInThingGroup = paginateListThingsInThingGroup; +//# sourceMappingURL=ListThingsInThingGroupPaginator.js.map + +/***/ }), + +/***/ 36161: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListThings = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListThingsCommand_1 = __nccwpck_require__(1243); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListThingsCommand_1.ListThingsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listThings(input, ...args); +}; +async function* paginateListThings(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListThings = paginateListThings; +//# sourceMappingURL=ListThingsPaginator.js.map + +/***/ }), + +/***/ 90598: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListTopicRuleDestinations = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListTopicRuleDestinationsCommand_1 = __nccwpck_require__(29621); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListTopicRuleDestinationsCommand_1.ListTopicRuleDestinationsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listTopicRuleDestinations(input, ...args); +}; +async function* paginateListTopicRuleDestinations(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListTopicRuleDestinations = paginateListTopicRuleDestinations; +//# sourceMappingURL=ListTopicRuleDestinationsPaginator.js.map + +/***/ }), + +/***/ 21749: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListTopicRules = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListTopicRulesCommand_1 = __nccwpck_require__(2823); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListTopicRulesCommand_1.ListTopicRulesCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listTopicRules(input, ...args); +}; +async function* paginateListTopicRules(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListTopicRules = paginateListTopicRules; +//# sourceMappingURL=ListTopicRulesPaginator.js.map + +/***/ }), + +/***/ 56717: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListV2LoggingLevels = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListV2LoggingLevelsCommand_1 = __nccwpck_require__(47492); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListV2LoggingLevelsCommand_1.ListV2LoggingLevelsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listV2LoggingLevels(input, ...args); +}; +async function* paginateListV2LoggingLevels(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListV2LoggingLevels = paginateListV2LoggingLevels; +//# sourceMappingURL=ListV2LoggingLevelsPaginator.js.map + +/***/ }), + +/***/ 72581: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.paginateListViolationEvents = void 0; +const IoT_1 = __nccwpck_require__(37811); +const IoTClient_1 = __nccwpck_require__(31450); +const ListViolationEventsCommand_1 = __nccwpck_require__(77560); +/** + * @private + */ +const makePagedClientRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.send(new ListViolationEventsCommand_1.ListViolationEventsCommand(input), ...args); +}; +/** + * @private + */ +const makePagedRequest = async (client, input, ...args) => { + // @ts-ignore + return await client.listViolationEvents(input, ...args); +}; +async function* paginateListViolationEvents(config, input, ...additionalArguments) { + // ToDo: replace with actual type instead of typeof input.nextToken + let token = config.startingToken || undefined; + let hasNext = true; + let page; + while (hasNext) { + input.nextToken = token; + input["maxResults"] = config.pageSize; + if (config.client instanceof IoT_1.IoT) { + page = await makePagedRequest(config.client, input, ...additionalArguments); + } + else if (config.client instanceof IoTClient_1.IoTClient) { + page = await makePagedClientRequest(config.client, input, ...additionalArguments); + } + else { + throw new Error("Invalid client, expected IoT | IoTClient"); + } + yield page; + token = page.nextToken; + hasNext = !!token; + } + // @ts-ignore + return undefined; +} +exports.paginateListViolationEvents = paginateListViolationEvents; +//# sourceMappingURL=ListViolationEventsPaginator.js.map + +/***/ }), + +/***/ 66639: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.serializeAws_restJson1DeleteJobCommand = exports.serializeAws_restJson1DeleteDynamicThingGroupCommand = exports.serializeAws_restJson1DeleteDomainConfigurationCommand = exports.serializeAws_restJson1DeleteDimensionCommand = exports.serializeAws_restJson1DeleteCertificateCommand = exports.serializeAws_restJson1DeleteCACertificateCommand = exports.serializeAws_restJson1DeleteBillingGroupCommand = exports.serializeAws_restJson1DeleteAuthorizerCommand = exports.serializeAws_restJson1DeleteAuditSuppressionCommand = exports.serializeAws_restJson1DeleteAccountAuditConfigurationCommand = exports.serializeAws_restJson1CreateTopicRuleDestinationCommand = exports.serializeAws_restJson1CreateTopicRuleCommand = exports.serializeAws_restJson1CreateThingTypeCommand = exports.serializeAws_restJson1CreateThingGroupCommand = exports.serializeAws_restJson1CreateThingCommand = exports.serializeAws_restJson1CreateStreamCommand = exports.serializeAws_restJson1CreateSecurityProfileCommand = exports.serializeAws_restJson1CreateScheduledAuditCommand = exports.serializeAws_restJson1CreateRoleAliasCommand = exports.serializeAws_restJson1CreateProvisioningTemplateVersionCommand = exports.serializeAws_restJson1CreateProvisioningTemplateCommand = exports.serializeAws_restJson1CreateProvisioningClaimCommand = exports.serializeAws_restJson1CreatePolicyVersionCommand = exports.serializeAws_restJson1CreatePolicyCommand = exports.serializeAws_restJson1CreateOTAUpdateCommand = exports.serializeAws_restJson1CreateMitigationActionCommand = exports.serializeAws_restJson1CreateKeysAndCertificateCommand = exports.serializeAws_restJson1CreateJobCommand = exports.serializeAws_restJson1CreateDynamicThingGroupCommand = exports.serializeAws_restJson1CreateDomainConfigurationCommand = exports.serializeAws_restJson1CreateDimensionCommand = exports.serializeAws_restJson1CreateCertificateFromCsrCommand = exports.serializeAws_restJson1CreateBillingGroupCommand = exports.serializeAws_restJson1CreateAuthorizerCommand = exports.serializeAws_restJson1CreateAuditSuppressionCommand = exports.serializeAws_restJson1ConfirmTopicRuleDestinationCommand = exports.serializeAws_restJson1ClearDefaultAuthorizerCommand = exports.serializeAws_restJson1CancelJobExecutionCommand = exports.serializeAws_restJson1CancelJobCommand = exports.serializeAws_restJson1CancelCertificateTransferCommand = exports.serializeAws_restJson1CancelAuditTaskCommand = exports.serializeAws_restJson1CancelAuditMitigationActionsTaskCommand = exports.serializeAws_restJson1AttachThingPrincipalCommand = exports.serializeAws_restJson1AttachSecurityProfileCommand = exports.serializeAws_restJson1AttachPrincipalPolicyCommand = exports.serializeAws_restJson1AttachPolicyCommand = exports.serializeAws_restJson1AssociateTargetsWithJobCommand = exports.serializeAws_restJson1AddThingToThingGroupCommand = exports.serializeAws_restJson1AddThingToBillingGroupCommand = exports.serializeAws_restJson1AcceptCertificateTransferCommand = void 0; +exports.serializeAws_restJson1DetachSecurityProfileCommand = exports.serializeAws_restJson1DetachPrincipalPolicyCommand = exports.serializeAws_restJson1DetachPolicyCommand = exports.serializeAws_restJson1DescribeThingTypeCommand = exports.serializeAws_restJson1DescribeThingRegistrationTaskCommand = exports.serializeAws_restJson1DescribeThingGroupCommand = exports.serializeAws_restJson1DescribeThingCommand = exports.serializeAws_restJson1DescribeStreamCommand = exports.serializeAws_restJson1DescribeSecurityProfileCommand = exports.serializeAws_restJson1DescribeScheduledAuditCommand = exports.serializeAws_restJson1DescribeRoleAliasCommand = exports.serializeAws_restJson1DescribeProvisioningTemplateVersionCommand = exports.serializeAws_restJson1DescribeProvisioningTemplateCommand = exports.serializeAws_restJson1DescribeMitigationActionCommand = exports.serializeAws_restJson1DescribeJobExecutionCommand = exports.serializeAws_restJson1DescribeJobCommand = exports.serializeAws_restJson1DescribeIndexCommand = exports.serializeAws_restJson1DescribeEventConfigurationsCommand = exports.serializeAws_restJson1DescribeEndpointCommand = exports.serializeAws_restJson1DescribeDomainConfigurationCommand = exports.serializeAws_restJson1DescribeDimensionCommand = exports.serializeAws_restJson1DescribeDefaultAuthorizerCommand = exports.serializeAws_restJson1DescribeCertificateCommand = exports.serializeAws_restJson1DescribeCACertificateCommand = exports.serializeAws_restJson1DescribeBillingGroupCommand = exports.serializeAws_restJson1DescribeAuthorizerCommand = exports.serializeAws_restJson1DescribeAuditTaskCommand = exports.serializeAws_restJson1DescribeAuditSuppressionCommand = exports.serializeAws_restJson1DescribeAuditMitigationActionsTaskCommand = exports.serializeAws_restJson1DescribeAuditFindingCommand = exports.serializeAws_restJson1DescribeAccountAuditConfigurationCommand = exports.serializeAws_restJson1DeprecateThingTypeCommand = exports.serializeAws_restJson1DeleteV2LoggingLevelCommand = exports.serializeAws_restJson1DeleteTopicRuleDestinationCommand = exports.serializeAws_restJson1DeleteTopicRuleCommand = exports.serializeAws_restJson1DeleteThingTypeCommand = exports.serializeAws_restJson1DeleteThingGroupCommand = exports.serializeAws_restJson1DeleteThingCommand = exports.serializeAws_restJson1DeleteStreamCommand = exports.serializeAws_restJson1DeleteSecurityProfileCommand = exports.serializeAws_restJson1DeleteScheduledAuditCommand = exports.serializeAws_restJson1DeleteRoleAliasCommand = exports.serializeAws_restJson1DeleteRegistrationCodeCommand = exports.serializeAws_restJson1DeleteProvisioningTemplateVersionCommand = exports.serializeAws_restJson1DeleteProvisioningTemplateCommand = exports.serializeAws_restJson1DeletePolicyVersionCommand = exports.serializeAws_restJson1DeletePolicyCommand = exports.serializeAws_restJson1DeleteOTAUpdateCommand = exports.serializeAws_restJson1DeleteMitigationActionCommand = exports.serializeAws_restJson1DeleteJobExecutionCommand = void 0; +exports.serializeAws_restJson1ListStreamsCommand = exports.serializeAws_restJson1ListSecurityProfilesForTargetCommand = exports.serializeAws_restJson1ListSecurityProfilesCommand = exports.serializeAws_restJson1ListScheduledAuditsCommand = exports.serializeAws_restJson1ListRoleAliasesCommand = exports.serializeAws_restJson1ListProvisioningTemplateVersionsCommand = exports.serializeAws_restJson1ListProvisioningTemplatesCommand = exports.serializeAws_restJson1ListPrincipalThingsCommand = exports.serializeAws_restJson1ListPrincipalPoliciesCommand = exports.serializeAws_restJson1ListPolicyVersionsCommand = exports.serializeAws_restJson1ListPolicyPrincipalsCommand = exports.serializeAws_restJson1ListPoliciesCommand = exports.serializeAws_restJson1ListOutgoingCertificatesCommand = exports.serializeAws_restJson1ListOTAUpdatesCommand = exports.serializeAws_restJson1ListMitigationActionsCommand = exports.serializeAws_restJson1ListJobsCommand = exports.serializeAws_restJson1ListJobExecutionsForThingCommand = exports.serializeAws_restJson1ListJobExecutionsForJobCommand = exports.serializeAws_restJson1ListIndicesCommand = exports.serializeAws_restJson1ListDomainConfigurationsCommand = exports.serializeAws_restJson1ListDimensionsCommand = exports.serializeAws_restJson1ListCertificatesByCACommand = exports.serializeAws_restJson1ListCertificatesCommand = exports.serializeAws_restJson1ListCACertificatesCommand = exports.serializeAws_restJson1ListBillingGroupsCommand = exports.serializeAws_restJson1ListAuthorizersCommand = exports.serializeAws_restJson1ListAuditTasksCommand = exports.serializeAws_restJson1ListAuditSuppressionsCommand = exports.serializeAws_restJson1ListAuditMitigationActionsTasksCommand = exports.serializeAws_restJson1ListAuditMitigationActionsExecutionsCommand = exports.serializeAws_restJson1ListAuditFindingsCommand = exports.serializeAws_restJson1ListAttachedPoliciesCommand = exports.serializeAws_restJson1ListActiveViolationsCommand = exports.serializeAws_restJson1GetV2LoggingOptionsCommand = exports.serializeAws_restJson1GetTopicRuleDestinationCommand = exports.serializeAws_restJson1GetTopicRuleCommand = exports.serializeAws_restJson1GetStatisticsCommand = exports.serializeAws_restJson1GetRegistrationCodeCommand = exports.serializeAws_restJson1GetPolicyVersionCommand = exports.serializeAws_restJson1GetPolicyCommand = exports.serializeAws_restJson1GetPercentilesCommand = exports.serializeAws_restJson1GetOTAUpdateCommand = exports.serializeAws_restJson1GetLoggingOptionsCommand = exports.serializeAws_restJson1GetJobDocumentCommand = exports.serializeAws_restJson1GetIndexingConfigurationCommand = exports.serializeAws_restJson1GetEffectivePoliciesCommand = exports.serializeAws_restJson1GetCardinalityCommand = exports.serializeAws_restJson1EnableTopicRuleCommand = exports.serializeAws_restJson1DisableTopicRuleCommand = exports.serializeAws_restJson1DetachThingPrincipalCommand = void 0; +exports.serializeAws_restJson1UpdateIndexingConfigurationCommand = exports.serializeAws_restJson1UpdateEventConfigurationsCommand = exports.serializeAws_restJson1UpdateDynamicThingGroupCommand = exports.serializeAws_restJson1UpdateDomainConfigurationCommand = exports.serializeAws_restJson1UpdateDimensionCommand = exports.serializeAws_restJson1UpdateCertificateCommand = exports.serializeAws_restJson1UpdateCACertificateCommand = exports.serializeAws_restJson1UpdateBillingGroupCommand = exports.serializeAws_restJson1UpdateAuthorizerCommand = exports.serializeAws_restJson1UpdateAuditSuppressionCommand = exports.serializeAws_restJson1UpdateAccountAuditConfigurationCommand = exports.serializeAws_restJson1UntagResourceCommand = exports.serializeAws_restJson1TransferCertificateCommand = exports.serializeAws_restJson1TestInvokeAuthorizerCommand = exports.serializeAws_restJson1TestAuthorizationCommand = exports.serializeAws_restJson1TagResourceCommand = exports.serializeAws_restJson1StopThingRegistrationTaskCommand = exports.serializeAws_restJson1StartThingRegistrationTaskCommand = exports.serializeAws_restJson1StartOnDemandAuditTaskCommand = exports.serializeAws_restJson1StartAuditMitigationActionsTaskCommand = exports.serializeAws_restJson1SetV2LoggingOptionsCommand = exports.serializeAws_restJson1SetV2LoggingLevelCommand = exports.serializeAws_restJson1SetLoggingOptionsCommand = exports.serializeAws_restJson1SetDefaultPolicyVersionCommand = exports.serializeAws_restJson1SetDefaultAuthorizerCommand = exports.serializeAws_restJson1SearchIndexCommand = exports.serializeAws_restJson1ReplaceTopicRuleCommand = exports.serializeAws_restJson1RemoveThingFromThingGroupCommand = exports.serializeAws_restJson1RemoveThingFromBillingGroupCommand = exports.serializeAws_restJson1RejectCertificateTransferCommand = exports.serializeAws_restJson1RegisterThingCommand = exports.serializeAws_restJson1RegisterCertificateWithoutCACommand = exports.serializeAws_restJson1RegisterCertificateCommand = exports.serializeAws_restJson1RegisterCACertificateCommand = exports.serializeAws_restJson1ListViolationEventsCommand = exports.serializeAws_restJson1ListV2LoggingLevelsCommand = exports.serializeAws_restJson1ListTopicRulesCommand = exports.serializeAws_restJson1ListTopicRuleDestinationsCommand = exports.serializeAws_restJson1ListThingTypesCommand = exports.serializeAws_restJson1ListThingsInThingGroupCommand = exports.serializeAws_restJson1ListThingsInBillingGroupCommand = exports.serializeAws_restJson1ListThingsCommand = exports.serializeAws_restJson1ListThingRegistrationTasksCommand = exports.serializeAws_restJson1ListThingRegistrationTaskReportsCommand = exports.serializeAws_restJson1ListThingPrincipalsCommand = exports.serializeAws_restJson1ListThingGroupsForThingCommand = exports.serializeAws_restJson1ListThingGroupsCommand = exports.serializeAws_restJson1ListTargetsForSecurityProfileCommand = exports.serializeAws_restJson1ListTargetsForPolicyCommand = exports.serializeAws_restJson1ListTagsForResourceCommand = void 0; +exports.deserializeAws_restJson1CreateThingTypeCommand = exports.deserializeAws_restJson1CreateThingGroupCommand = exports.deserializeAws_restJson1CreateThingCommand = exports.deserializeAws_restJson1CreateStreamCommand = exports.deserializeAws_restJson1CreateSecurityProfileCommand = exports.deserializeAws_restJson1CreateScheduledAuditCommand = exports.deserializeAws_restJson1CreateRoleAliasCommand = exports.deserializeAws_restJson1CreateProvisioningTemplateVersionCommand = exports.deserializeAws_restJson1CreateProvisioningTemplateCommand = exports.deserializeAws_restJson1CreateProvisioningClaimCommand = exports.deserializeAws_restJson1CreatePolicyVersionCommand = exports.deserializeAws_restJson1CreatePolicyCommand = exports.deserializeAws_restJson1CreateOTAUpdateCommand = exports.deserializeAws_restJson1CreateMitigationActionCommand = exports.deserializeAws_restJson1CreateKeysAndCertificateCommand = exports.deserializeAws_restJson1CreateJobCommand = exports.deserializeAws_restJson1CreateDynamicThingGroupCommand = exports.deserializeAws_restJson1CreateDomainConfigurationCommand = exports.deserializeAws_restJson1CreateDimensionCommand = exports.deserializeAws_restJson1CreateCertificateFromCsrCommand = exports.deserializeAws_restJson1CreateBillingGroupCommand = exports.deserializeAws_restJson1CreateAuthorizerCommand = exports.deserializeAws_restJson1CreateAuditSuppressionCommand = exports.deserializeAws_restJson1ConfirmTopicRuleDestinationCommand = exports.deserializeAws_restJson1ClearDefaultAuthorizerCommand = exports.deserializeAws_restJson1CancelJobExecutionCommand = exports.deserializeAws_restJson1CancelJobCommand = exports.deserializeAws_restJson1CancelCertificateTransferCommand = exports.deserializeAws_restJson1CancelAuditTaskCommand = exports.deserializeAws_restJson1CancelAuditMitigationActionsTaskCommand = exports.deserializeAws_restJson1AttachThingPrincipalCommand = exports.deserializeAws_restJson1AttachSecurityProfileCommand = exports.deserializeAws_restJson1AttachPrincipalPolicyCommand = exports.deserializeAws_restJson1AttachPolicyCommand = exports.deserializeAws_restJson1AssociateTargetsWithJobCommand = exports.deserializeAws_restJson1AddThingToThingGroupCommand = exports.deserializeAws_restJson1AddThingToBillingGroupCommand = exports.deserializeAws_restJson1AcceptCertificateTransferCommand = exports.serializeAws_restJson1ValidateSecurityProfileBehaviorsCommand = exports.serializeAws_restJson1UpdateTopicRuleDestinationCommand = exports.serializeAws_restJson1UpdateThingGroupsForThingCommand = exports.serializeAws_restJson1UpdateThingGroupCommand = exports.serializeAws_restJson1UpdateThingCommand = exports.serializeAws_restJson1UpdateStreamCommand = exports.serializeAws_restJson1UpdateSecurityProfileCommand = exports.serializeAws_restJson1UpdateScheduledAuditCommand = exports.serializeAws_restJson1UpdateRoleAliasCommand = exports.serializeAws_restJson1UpdateProvisioningTemplateCommand = exports.serializeAws_restJson1UpdateMitigationActionCommand = exports.serializeAws_restJson1UpdateJobCommand = void 0; +exports.deserializeAws_restJson1DescribeProvisioningTemplateCommand = exports.deserializeAws_restJson1DescribeMitigationActionCommand = exports.deserializeAws_restJson1DescribeJobExecutionCommand = exports.deserializeAws_restJson1DescribeJobCommand = exports.deserializeAws_restJson1DescribeIndexCommand = exports.deserializeAws_restJson1DescribeEventConfigurationsCommand = exports.deserializeAws_restJson1DescribeEndpointCommand = exports.deserializeAws_restJson1DescribeDomainConfigurationCommand = exports.deserializeAws_restJson1DescribeDimensionCommand = exports.deserializeAws_restJson1DescribeDefaultAuthorizerCommand = exports.deserializeAws_restJson1DescribeCertificateCommand = exports.deserializeAws_restJson1DescribeCACertificateCommand = exports.deserializeAws_restJson1DescribeBillingGroupCommand = exports.deserializeAws_restJson1DescribeAuthorizerCommand = exports.deserializeAws_restJson1DescribeAuditTaskCommand = exports.deserializeAws_restJson1DescribeAuditSuppressionCommand = exports.deserializeAws_restJson1DescribeAuditMitigationActionsTaskCommand = exports.deserializeAws_restJson1DescribeAuditFindingCommand = exports.deserializeAws_restJson1DescribeAccountAuditConfigurationCommand = exports.deserializeAws_restJson1DeprecateThingTypeCommand = exports.deserializeAws_restJson1DeleteV2LoggingLevelCommand = exports.deserializeAws_restJson1DeleteTopicRuleDestinationCommand = exports.deserializeAws_restJson1DeleteTopicRuleCommand = exports.deserializeAws_restJson1DeleteThingTypeCommand = exports.deserializeAws_restJson1DeleteThingGroupCommand = exports.deserializeAws_restJson1DeleteThingCommand = exports.deserializeAws_restJson1DeleteStreamCommand = exports.deserializeAws_restJson1DeleteSecurityProfileCommand = exports.deserializeAws_restJson1DeleteScheduledAuditCommand = exports.deserializeAws_restJson1DeleteRoleAliasCommand = exports.deserializeAws_restJson1DeleteRegistrationCodeCommand = exports.deserializeAws_restJson1DeleteProvisioningTemplateVersionCommand = exports.deserializeAws_restJson1DeleteProvisioningTemplateCommand = exports.deserializeAws_restJson1DeletePolicyVersionCommand = exports.deserializeAws_restJson1DeletePolicyCommand = exports.deserializeAws_restJson1DeleteOTAUpdateCommand = exports.deserializeAws_restJson1DeleteMitigationActionCommand = exports.deserializeAws_restJson1DeleteJobExecutionCommand = exports.deserializeAws_restJson1DeleteJobCommand = exports.deserializeAws_restJson1DeleteDynamicThingGroupCommand = exports.deserializeAws_restJson1DeleteDomainConfigurationCommand = exports.deserializeAws_restJson1DeleteDimensionCommand = exports.deserializeAws_restJson1DeleteCertificateCommand = exports.deserializeAws_restJson1DeleteCACertificateCommand = exports.deserializeAws_restJson1DeleteBillingGroupCommand = exports.deserializeAws_restJson1DeleteAuthorizerCommand = exports.deserializeAws_restJson1DeleteAuditSuppressionCommand = exports.deserializeAws_restJson1DeleteAccountAuditConfigurationCommand = exports.deserializeAws_restJson1CreateTopicRuleDestinationCommand = exports.deserializeAws_restJson1CreateTopicRuleCommand = void 0; +exports.deserializeAws_restJson1ListOutgoingCertificatesCommand = exports.deserializeAws_restJson1ListOTAUpdatesCommand = exports.deserializeAws_restJson1ListMitigationActionsCommand = exports.deserializeAws_restJson1ListJobsCommand = exports.deserializeAws_restJson1ListJobExecutionsForThingCommand = exports.deserializeAws_restJson1ListJobExecutionsForJobCommand = exports.deserializeAws_restJson1ListIndicesCommand = exports.deserializeAws_restJson1ListDomainConfigurationsCommand = exports.deserializeAws_restJson1ListDimensionsCommand = exports.deserializeAws_restJson1ListCertificatesByCACommand = exports.deserializeAws_restJson1ListCertificatesCommand = exports.deserializeAws_restJson1ListCACertificatesCommand = exports.deserializeAws_restJson1ListBillingGroupsCommand = exports.deserializeAws_restJson1ListAuthorizersCommand = exports.deserializeAws_restJson1ListAuditTasksCommand = exports.deserializeAws_restJson1ListAuditSuppressionsCommand = exports.deserializeAws_restJson1ListAuditMitigationActionsTasksCommand = exports.deserializeAws_restJson1ListAuditMitigationActionsExecutionsCommand = exports.deserializeAws_restJson1ListAuditFindingsCommand = exports.deserializeAws_restJson1ListAttachedPoliciesCommand = exports.deserializeAws_restJson1ListActiveViolationsCommand = exports.deserializeAws_restJson1GetV2LoggingOptionsCommand = exports.deserializeAws_restJson1GetTopicRuleDestinationCommand = exports.deserializeAws_restJson1GetTopicRuleCommand = exports.deserializeAws_restJson1GetStatisticsCommand = exports.deserializeAws_restJson1GetRegistrationCodeCommand = exports.deserializeAws_restJson1GetPolicyVersionCommand = exports.deserializeAws_restJson1GetPolicyCommand = exports.deserializeAws_restJson1GetPercentilesCommand = exports.deserializeAws_restJson1GetOTAUpdateCommand = exports.deserializeAws_restJson1GetLoggingOptionsCommand = exports.deserializeAws_restJson1GetJobDocumentCommand = exports.deserializeAws_restJson1GetIndexingConfigurationCommand = exports.deserializeAws_restJson1GetEffectivePoliciesCommand = exports.deserializeAws_restJson1GetCardinalityCommand = exports.deserializeAws_restJson1EnableTopicRuleCommand = exports.deserializeAws_restJson1DisableTopicRuleCommand = exports.deserializeAws_restJson1DetachThingPrincipalCommand = exports.deserializeAws_restJson1DetachSecurityProfileCommand = exports.deserializeAws_restJson1DetachPrincipalPolicyCommand = exports.deserializeAws_restJson1DetachPolicyCommand = exports.deserializeAws_restJson1DescribeThingTypeCommand = exports.deserializeAws_restJson1DescribeThingRegistrationTaskCommand = exports.deserializeAws_restJson1DescribeThingGroupCommand = exports.deserializeAws_restJson1DescribeThingCommand = exports.deserializeAws_restJson1DescribeStreamCommand = exports.deserializeAws_restJson1DescribeSecurityProfileCommand = exports.deserializeAws_restJson1DescribeScheduledAuditCommand = exports.deserializeAws_restJson1DescribeRoleAliasCommand = exports.deserializeAws_restJson1DescribeProvisioningTemplateVersionCommand = void 0; +exports.deserializeAws_restJson1TransferCertificateCommand = exports.deserializeAws_restJson1TestInvokeAuthorizerCommand = exports.deserializeAws_restJson1TestAuthorizationCommand = exports.deserializeAws_restJson1TagResourceCommand = exports.deserializeAws_restJson1StopThingRegistrationTaskCommand = exports.deserializeAws_restJson1StartThingRegistrationTaskCommand = exports.deserializeAws_restJson1StartOnDemandAuditTaskCommand = exports.deserializeAws_restJson1StartAuditMitigationActionsTaskCommand = exports.deserializeAws_restJson1SetV2LoggingOptionsCommand = exports.deserializeAws_restJson1SetV2LoggingLevelCommand = exports.deserializeAws_restJson1SetLoggingOptionsCommand = exports.deserializeAws_restJson1SetDefaultPolicyVersionCommand = exports.deserializeAws_restJson1SetDefaultAuthorizerCommand = exports.deserializeAws_restJson1SearchIndexCommand = exports.deserializeAws_restJson1ReplaceTopicRuleCommand = exports.deserializeAws_restJson1RemoveThingFromThingGroupCommand = exports.deserializeAws_restJson1RemoveThingFromBillingGroupCommand = exports.deserializeAws_restJson1RejectCertificateTransferCommand = exports.deserializeAws_restJson1RegisterThingCommand = exports.deserializeAws_restJson1RegisterCertificateWithoutCACommand = exports.deserializeAws_restJson1RegisterCertificateCommand = exports.deserializeAws_restJson1RegisterCACertificateCommand = exports.deserializeAws_restJson1ListViolationEventsCommand = exports.deserializeAws_restJson1ListV2LoggingLevelsCommand = exports.deserializeAws_restJson1ListTopicRulesCommand = exports.deserializeAws_restJson1ListTopicRuleDestinationsCommand = exports.deserializeAws_restJson1ListThingTypesCommand = exports.deserializeAws_restJson1ListThingsInThingGroupCommand = exports.deserializeAws_restJson1ListThingsInBillingGroupCommand = exports.deserializeAws_restJson1ListThingsCommand = exports.deserializeAws_restJson1ListThingRegistrationTasksCommand = exports.deserializeAws_restJson1ListThingRegistrationTaskReportsCommand = exports.deserializeAws_restJson1ListThingPrincipalsCommand = exports.deserializeAws_restJson1ListThingGroupsForThingCommand = exports.deserializeAws_restJson1ListThingGroupsCommand = exports.deserializeAws_restJson1ListTargetsForSecurityProfileCommand = exports.deserializeAws_restJson1ListTargetsForPolicyCommand = exports.deserializeAws_restJson1ListTagsForResourceCommand = exports.deserializeAws_restJson1ListStreamsCommand = exports.deserializeAws_restJson1ListSecurityProfilesForTargetCommand = exports.deserializeAws_restJson1ListSecurityProfilesCommand = exports.deserializeAws_restJson1ListScheduledAuditsCommand = exports.deserializeAws_restJson1ListRoleAliasesCommand = exports.deserializeAws_restJson1ListProvisioningTemplateVersionsCommand = exports.deserializeAws_restJson1ListProvisioningTemplatesCommand = exports.deserializeAws_restJson1ListPrincipalThingsCommand = exports.deserializeAws_restJson1ListPrincipalPoliciesCommand = exports.deserializeAws_restJson1ListPolicyVersionsCommand = exports.deserializeAws_restJson1ListPolicyPrincipalsCommand = exports.deserializeAws_restJson1ListPoliciesCommand = void 0; +exports.deserializeAws_restJson1ValidateSecurityProfileBehaviorsCommand = exports.deserializeAws_restJson1UpdateTopicRuleDestinationCommand = exports.deserializeAws_restJson1UpdateThingGroupsForThingCommand = exports.deserializeAws_restJson1UpdateThingGroupCommand = exports.deserializeAws_restJson1UpdateThingCommand = exports.deserializeAws_restJson1UpdateStreamCommand = exports.deserializeAws_restJson1UpdateSecurityProfileCommand = exports.deserializeAws_restJson1UpdateScheduledAuditCommand = exports.deserializeAws_restJson1UpdateRoleAliasCommand = exports.deserializeAws_restJson1UpdateProvisioningTemplateCommand = exports.deserializeAws_restJson1UpdateMitigationActionCommand = exports.deserializeAws_restJson1UpdateJobCommand = exports.deserializeAws_restJson1UpdateIndexingConfigurationCommand = exports.deserializeAws_restJson1UpdateEventConfigurationsCommand = exports.deserializeAws_restJson1UpdateDynamicThingGroupCommand = exports.deserializeAws_restJson1UpdateDomainConfigurationCommand = exports.deserializeAws_restJson1UpdateDimensionCommand = exports.deserializeAws_restJson1UpdateCertificateCommand = exports.deserializeAws_restJson1UpdateCACertificateCommand = exports.deserializeAws_restJson1UpdateBillingGroupCommand = exports.deserializeAws_restJson1UpdateAuthorizerCommand = exports.deserializeAws_restJson1UpdateAuditSuppressionCommand = exports.deserializeAws_restJson1UpdateAccountAuditConfigurationCommand = exports.deserializeAws_restJson1UntagResourceCommand = void 0; +const models_0_1 = __nccwpck_require__(34387); +const protocol_http_1 = __nccwpck_require__(67498); +const smithy_client_1 = __nccwpck_require__(84060); +const uuid_1 = __nccwpck_require__(2155); +const serializeAws_restJson1AcceptCertificateTransferCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/accept-certificate-transfer/{certificateId}"; + if (input.certificateId !== undefined) { + const labelValue = input.certificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: certificateId."); + } + resolvedPath = resolvedPath.replace("{certificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: certificateId."); + } + const query = { + ...(input.setAsActive !== undefined && { setAsActive: input.setAsActive.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1AcceptCertificateTransferCommand = serializeAws_restJson1AcceptCertificateTransferCommand; +const serializeAws_restJson1AddThingToBillingGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/billing-groups/addThingToBillingGroup"; + let body; + body = JSON.stringify({ + ...(input.billingGroupArn !== undefined && + input.billingGroupArn !== null && { billingGroupArn: input.billingGroupArn }), + ...(input.billingGroupName !== undefined && + input.billingGroupName !== null && { billingGroupName: input.billingGroupName }), + ...(input.thingArn !== undefined && input.thingArn !== null && { thingArn: input.thingArn }), + ...(input.thingName !== undefined && input.thingName !== null && { thingName: input.thingName }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1AddThingToBillingGroupCommand = serializeAws_restJson1AddThingToBillingGroupCommand; +const serializeAws_restJson1AddThingToThingGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/thing-groups/addThingToThingGroup"; + let body; + body = JSON.stringify({ + ...(input.overrideDynamicGroups !== undefined && + input.overrideDynamicGroups !== null && { overrideDynamicGroups: input.overrideDynamicGroups }), + ...(input.thingArn !== undefined && input.thingArn !== null && { thingArn: input.thingArn }), + ...(input.thingGroupArn !== undefined && input.thingGroupArn !== null && { thingGroupArn: input.thingGroupArn }), + ...(input.thingGroupName !== undefined && + input.thingGroupName !== null && { thingGroupName: input.thingGroupName }), + ...(input.thingName !== undefined && input.thingName !== null && { thingName: input.thingName }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1AddThingToThingGroupCommand = serializeAws_restJson1AddThingToThingGroupCommand; +const serializeAws_restJson1AssociateTargetsWithJobCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/jobs/{jobId}/targets"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + const query = { + ...(input.namespaceId !== undefined && { namespaceId: input.namespaceId }), + }; + let body; + body = JSON.stringify({ + ...(input.comment !== undefined && input.comment !== null && { comment: input.comment }), + ...(input.targets !== undefined && + input.targets !== null && { targets: serializeAws_restJson1JobTargets(input.targets, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1AssociateTargetsWithJobCommand = serializeAws_restJson1AssociateTargetsWithJobCommand; +const serializeAws_restJson1AttachPolicyCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/target-policies/{policyName}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + let body; + body = JSON.stringify({ + ...(input.target !== undefined && input.target !== null && { target: input.target }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1AttachPolicyCommand = serializeAws_restJson1AttachPolicyCommand; +const serializeAws_restJson1AttachPrincipalPolicyCommand = async (input, context) => { + const headers = { + ...(isSerializableHeaderValue(input.principal) && { "x-amzn-iot-principal": input.principal }), + }; + let resolvedPath = "/principal-policies/{policyName}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1AttachPrincipalPolicyCommand = serializeAws_restJson1AttachPrincipalPolicyCommand; +const serializeAws_restJson1AttachSecurityProfileCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/security-profiles/{securityProfileName}/targets"; + if (input.securityProfileName !== undefined) { + const labelValue = input.securityProfileName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: securityProfileName."); + } + resolvedPath = resolvedPath.replace("{securityProfileName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: securityProfileName."); + } + const query = { + ...(input.securityProfileTargetArn !== undefined && { securityProfileTargetArn: input.securityProfileTargetArn }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1AttachSecurityProfileCommand = serializeAws_restJson1AttachSecurityProfileCommand; +const serializeAws_restJson1AttachThingPrincipalCommand = async (input, context) => { + const headers = { + ...(isSerializableHeaderValue(input.principal) && { "x-amzn-principal": input.principal }), + }; + let resolvedPath = "/things/{thingName}/principals"; + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1AttachThingPrincipalCommand = serializeAws_restJson1AttachThingPrincipalCommand; +const serializeAws_restJson1CancelAuditMitigationActionsTaskCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/mitigationactions/tasks/{taskId}/cancel"; + if (input.taskId !== undefined) { + const labelValue = input.taskId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: taskId."); + } + resolvedPath = resolvedPath.replace("{taskId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: taskId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CancelAuditMitigationActionsTaskCommand = serializeAws_restJson1CancelAuditMitigationActionsTaskCommand; +const serializeAws_restJson1CancelAuditTaskCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/tasks/{taskId}/cancel"; + if (input.taskId !== undefined) { + const labelValue = input.taskId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: taskId."); + } + resolvedPath = resolvedPath.replace("{taskId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: taskId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CancelAuditTaskCommand = serializeAws_restJson1CancelAuditTaskCommand; +const serializeAws_restJson1CancelCertificateTransferCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/cancel-certificate-transfer/{certificateId}"; + if (input.certificateId !== undefined) { + const labelValue = input.certificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: certificateId."); + } + resolvedPath = resolvedPath.replace("{certificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: certificateId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CancelCertificateTransferCommand = serializeAws_restJson1CancelCertificateTransferCommand; +const serializeAws_restJson1CancelJobCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/jobs/{jobId}/cancel"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + const query = { + ...(input.force !== undefined && { force: input.force.toString() }), + }; + let body; + body = JSON.stringify({ + ...(input.comment !== undefined && input.comment !== null && { comment: input.comment }), + ...(input.reasonCode !== undefined && input.reasonCode !== null && { reasonCode: input.reasonCode }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1CancelJobCommand = serializeAws_restJson1CancelJobCommand; +const serializeAws_restJson1CancelJobExecutionCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/things/{thingName}/jobs/{jobId}/cancel"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + const query = { + ...(input.force !== undefined && { force: input.force.toString() }), + }; + let body; + body = JSON.stringify({ + ...(input.expectedVersion !== undefined && + input.expectedVersion !== null && { expectedVersion: input.expectedVersion }), + ...(input.statusDetails !== undefined && + input.statusDetails !== null && { + statusDetails: serializeAws_restJson1DetailsMap(input.statusDetails, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1CancelJobExecutionCommand = serializeAws_restJson1CancelJobExecutionCommand; +const serializeAws_restJson1ClearDefaultAuthorizerCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/default-authorizer"; + let body; + body = ""; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1ClearDefaultAuthorizerCommand = serializeAws_restJson1ClearDefaultAuthorizerCommand; +const serializeAws_restJson1ConfirmTopicRuleDestinationCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/confirmdestination/{confirmationToken+}"; + if (input.confirmationToken !== undefined) { + const labelValue = input.confirmationToken; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: confirmationToken."); + } + resolvedPath = resolvedPath.replace("{confirmationToken+}", labelValue + .split("/") + .map((segment) => smithy_client_1.extendedEncodeURIComponent(segment)) + .join("/")); + } + else { + throw new Error("No value provided for input HTTP label: confirmationToken."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1ConfirmTopicRuleDestinationCommand = serializeAws_restJson1ConfirmTopicRuleDestinationCommand; +const serializeAws_restJson1CreateAuditSuppressionCommand = async (input, context) => { + var _a; + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/suppressions/create"; + let body; + body = JSON.stringify({ + ...(input.checkName !== undefined && input.checkName !== null && { checkName: input.checkName }), + clientRequestToken: (_a = input.clientRequestToken) !== null && _a !== void 0 ? _a : uuid_1.v4(), + ...(input.description !== undefined && input.description !== null && { description: input.description }), + ...(input.expirationDate !== undefined && + input.expirationDate !== null && { expirationDate: Math.round(input.expirationDate.getTime() / 1000) }), + ...(input.resourceIdentifier !== undefined && + input.resourceIdentifier !== null && { + resourceIdentifier: serializeAws_restJson1ResourceIdentifier(input.resourceIdentifier, context), + }), + ...(input.suppressIndefinitely !== undefined && + input.suppressIndefinitely !== null && { suppressIndefinitely: input.suppressIndefinitely }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateAuditSuppressionCommand = serializeAws_restJson1CreateAuditSuppressionCommand; +const serializeAws_restJson1CreateAuthorizerCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/authorizer/{authorizerName}"; + if (input.authorizerName !== undefined) { + const labelValue = input.authorizerName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: authorizerName."); + } + resolvedPath = resolvedPath.replace("{authorizerName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: authorizerName."); + } + let body; + body = JSON.stringify({ + ...(input.authorizerFunctionArn !== undefined && + input.authorizerFunctionArn !== null && { authorizerFunctionArn: input.authorizerFunctionArn }), + ...(input.signingDisabled !== undefined && + input.signingDisabled !== null && { signingDisabled: input.signingDisabled }), + ...(input.status !== undefined && input.status !== null && { status: input.status }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.tokenKeyName !== undefined && input.tokenKeyName !== null && { tokenKeyName: input.tokenKeyName }), + ...(input.tokenSigningPublicKeys !== undefined && + input.tokenSigningPublicKeys !== null && { + tokenSigningPublicKeys: serializeAws_restJson1PublicKeyMap(input.tokenSigningPublicKeys, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateAuthorizerCommand = serializeAws_restJson1CreateAuthorizerCommand; +const serializeAws_restJson1CreateBillingGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/billing-groups/{billingGroupName}"; + if (input.billingGroupName !== undefined) { + const labelValue = input.billingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: billingGroupName."); + } + resolvedPath = resolvedPath.replace("{billingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: billingGroupName."); + } + let body; + body = JSON.stringify({ + ...(input.billingGroupProperties !== undefined && + input.billingGroupProperties !== null && { + billingGroupProperties: serializeAws_restJson1BillingGroupProperties(input.billingGroupProperties, context), + }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateBillingGroupCommand = serializeAws_restJson1CreateBillingGroupCommand; +const serializeAws_restJson1CreateCertificateFromCsrCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/certificates"; + const query = { + ...(input.setAsActive !== undefined && { setAsActive: input.setAsActive.toString() }), + }; + let body; + body = JSON.stringify({ + ...(input.certificateSigningRequest !== undefined && + input.certificateSigningRequest !== null && { certificateSigningRequest: input.certificateSigningRequest }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1CreateCertificateFromCsrCommand = serializeAws_restJson1CreateCertificateFromCsrCommand; +const serializeAws_restJson1CreateDimensionCommand = async (input, context) => { + var _a; + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/dimensions/{name}"; + if (input.name !== undefined) { + const labelValue = input.name; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: name."); + } + resolvedPath = resolvedPath.replace("{name}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: name."); + } + let body; + body = JSON.stringify({ + clientRequestToken: (_a = input.clientRequestToken) !== null && _a !== void 0 ? _a : uuid_1.v4(), + ...(input.stringValues !== undefined && + input.stringValues !== null && { + stringValues: serializeAws_restJson1DimensionStringValues(input.stringValues, context), + }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.type !== undefined && input.type !== null && { type: input.type }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateDimensionCommand = serializeAws_restJson1CreateDimensionCommand; +const serializeAws_restJson1CreateDomainConfigurationCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/domainConfigurations/{domainConfigurationName}"; + if (input.domainConfigurationName !== undefined) { + const labelValue = input.domainConfigurationName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: domainConfigurationName."); + } + resolvedPath = resolvedPath.replace("{domainConfigurationName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: domainConfigurationName."); + } + let body; + body = JSON.stringify({ + ...(input.authorizerConfig !== undefined && + input.authorizerConfig !== null && { + authorizerConfig: serializeAws_restJson1AuthorizerConfig(input.authorizerConfig, context), + }), + ...(input.domainName !== undefined && input.domainName !== null && { domainName: input.domainName }), + ...(input.serverCertificateArns !== undefined && + input.serverCertificateArns !== null && { + serverCertificateArns: serializeAws_restJson1ServerCertificateArns(input.serverCertificateArns, context), + }), + ...(input.serviceType !== undefined && input.serviceType !== null && { serviceType: input.serviceType }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.validationCertificateArn !== undefined && + input.validationCertificateArn !== null && { validationCertificateArn: input.validationCertificateArn }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateDomainConfigurationCommand = serializeAws_restJson1CreateDomainConfigurationCommand; +const serializeAws_restJson1CreateDynamicThingGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/dynamic-thing-groups/{thingGroupName}"; + if (input.thingGroupName !== undefined) { + const labelValue = input.thingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingGroupName."); + } + resolvedPath = resolvedPath.replace("{thingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingGroupName."); + } + let body; + body = JSON.stringify({ + ...(input.indexName !== undefined && input.indexName !== null && { indexName: input.indexName }), + ...(input.queryString !== undefined && input.queryString !== null && { queryString: input.queryString }), + ...(input.queryVersion !== undefined && input.queryVersion !== null && { queryVersion: input.queryVersion }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.thingGroupProperties !== undefined && + input.thingGroupProperties !== null && { + thingGroupProperties: serializeAws_restJson1ThingGroupProperties(input.thingGroupProperties, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateDynamicThingGroupCommand = serializeAws_restJson1CreateDynamicThingGroupCommand; +const serializeAws_restJson1CreateJobCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/jobs/{jobId}"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + let body; + body = JSON.stringify({ + ...(input.abortConfig !== undefined && + input.abortConfig !== null && { abortConfig: serializeAws_restJson1AbortConfig(input.abortConfig, context) }), + ...(input.description !== undefined && input.description !== null && { description: input.description }), + ...(input.document !== undefined && input.document !== null && { document: input.document }), + ...(input.documentSource !== undefined && + input.documentSource !== null && { documentSource: input.documentSource }), + ...(input.jobExecutionsRolloutConfig !== undefined && + input.jobExecutionsRolloutConfig !== null && { + jobExecutionsRolloutConfig: serializeAws_restJson1JobExecutionsRolloutConfig(input.jobExecutionsRolloutConfig, context), + }), + ...(input.namespaceId !== undefined && input.namespaceId !== null && { namespaceId: input.namespaceId }), + ...(input.presignedUrlConfig !== undefined && + input.presignedUrlConfig !== null && { + presignedUrlConfig: serializeAws_restJson1PresignedUrlConfig(input.presignedUrlConfig, context), + }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.targetSelection !== undefined && + input.targetSelection !== null && { targetSelection: input.targetSelection }), + ...(input.targets !== undefined && + input.targets !== null && { targets: serializeAws_restJson1JobTargets(input.targets, context) }), + ...(input.timeoutConfig !== undefined && + input.timeoutConfig !== null && { + timeoutConfig: serializeAws_restJson1TimeoutConfig(input.timeoutConfig, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateJobCommand = serializeAws_restJson1CreateJobCommand; +const serializeAws_restJson1CreateKeysAndCertificateCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/keys-and-certificate"; + const query = { + ...(input.setAsActive !== undefined && { setAsActive: input.setAsActive.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1CreateKeysAndCertificateCommand = serializeAws_restJson1CreateKeysAndCertificateCommand; +const serializeAws_restJson1CreateMitigationActionCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/mitigationactions/actions/{actionName}"; + if (input.actionName !== undefined) { + const labelValue = input.actionName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: actionName."); + } + resolvedPath = resolvedPath.replace("{actionName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: actionName."); + } + let body; + body = JSON.stringify({ + ...(input.actionParams !== undefined && + input.actionParams !== null && { + actionParams: serializeAws_restJson1MitigationActionParams(input.actionParams, context), + }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateMitigationActionCommand = serializeAws_restJson1CreateMitigationActionCommand; +const serializeAws_restJson1CreateOTAUpdateCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/otaUpdates/{otaUpdateId}"; + if (input.otaUpdateId !== undefined) { + const labelValue = input.otaUpdateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: otaUpdateId."); + } + resolvedPath = resolvedPath.replace("{otaUpdateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: otaUpdateId."); + } + let body; + body = JSON.stringify({ + ...(input.additionalParameters !== undefined && + input.additionalParameters !== null && { + additionalParameters: serializeAws_restJson1AdditionalParameterMap(input.additionalParameters, context), + }), + ...(input.awsJobAbortConfig !== undefined && + input.awsJobAbortConfig !== null && { + awsJobAbortConfig: serializeAws_restJson1AwsJobAbortConfig(input.awsJobAbortConfig, context), + }), + ...(input.awsJobExecutionsRolloutConfig !== undefined && + input.awsJobExecutionsRolloutConfig !== null && { + awsJobExecutionsRolloutConfig: serializeAws_restJson1AwsJobExecutionsRolloutConfig(input.awsJobExecutionsRolloutConfig, context), + }), + ...(input.awsJobPresignedUrlConfig !== undefined && + input.awsJobPresignedUrlConfig !== null && { + awsJobPresignedUrlConfig: serializeAws_restJson1AwsJobPresignedUrlConfig(input.awsJobPresignedUrlConfig, context), + }), + ...(input.awsJobTimeoutConfig !== undefined && + input.awsJobTimeoutConfig !== null && { + awsJobTimeoutConfig: serializeAws_restJson1AwsJobTimeoutConfig(input.awsJobTimeoutConfig, context), + }), + ...(input.description !== undefined && input.description !== null && { description: input.description }), + ...(input.files !== undefined && + input.files !== null && { files: serializeAws_restJson1OTAUpdateFiles(input.files, context) }), + ...(input.protocols !== undefined && + input.protocols !== null && { protocols: serializeAws_restJson1Protocols(input.protocols, context) }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.targetSelection !== undefined && + input.targetSelection !== null && { targetSelection: input.targetSelection }), + ...(input.targets !== undefined && + input.targets !== null && { targets: serializeAws_restJson1Targets(input.targets, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateOTAUpdateCommand = serializeAws_restJson1CreateOTAUpdateCommand; +const serializeAws_restJson1CreatePolicyCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/policies/{policyName}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + let body; + body = JSON.stringify({ + ...(input.policyDocument !== undefined && + input.policyDocument !== null && { policyDocument: input.policyDocument }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreatePolicyCommand = serializeAws_restJson1CreatePolicyCommand; +const serializeAws_restJson1CreatePolicyVersionCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/policies/{policyName}/version"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + const query = { + ...(input.setAsDefault !== undefined && { setAsDefault: input.setAsDefault.toString() }), + }; + let body; + body = JSON.stringify({ + ...(input.policyDocument !== undefined && + input.policyDocument !== null && { policyDocument: input.policyDocument }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1CreatePolicyVersionCommand = serializeAws_restJson1CreatePolicyVersionCommand; +const serializeAws_restJson1CreateProvisioningClaimCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/provisioning-templates/{templateName}/provisioning-claim"; + if (input.templateName !== undefined) { + const labelValue = input.templateName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: templateName."); + } + resolvedPath = resolvedPath.replace("{templateName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: templateName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateProvisioningClaimCommand = serializeAws_restJson1CreateProvisioningClaimCommand; +const serializeAws_restJson1CreateProvisioningTemplateCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/provisioning-templates"; + let body; + body = JSON.stringify({ + ...(input.description !== undefined && input.description !== null && { description: input.description }), + ...(input.enabled !== undefined && input.enabled !== null && { enabled: input.enabled }), + ...(input.preProvisioningHook !== undefined && + input.preProvisioningHook !== null && { + preProvisioningHook: serializeAws_restJson1ProvisioningHook(input.preProvisioningHook, context), + }), + ...(input.provisioningRoleArn !== undefined && + input.provisioningRoleArn !== null && { provisioningRoleArn: input.provisioningRoleArn }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.templateBody !== undefined && input.templateBody !== null && { templateBody: input.templateBody }), + ...(input.templateName !== undefined && input.templateName !== null && { templateName: input.templateName }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateProvisioningTemplateCommand = serializeAws_restJson1CreateProvisioningTemplateCommand; +const serializeAws_restJson1CreateProvisioningTemplateVersionCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/provisioning-templates/{templateName}/versions"; + if (input.templateName !== undefined) { + const labelValue = input.templateName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: templateName."); + } + resolvedPath = resolvedPath.replace("{templateName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: templateName."); + } + const query = { + ...(input.setAsDefault !== undefined && { setAsDefault: input.setAsDefault.toString() }), + }; + let body; + body = JSON.stringify({ + ...(input.templateBody !== undefined && input.templateBody !== null && { templateBody: input.templateBody }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1CreateProvisioningTemplateVersionCommand = serializeAws_restJson1CreateProvisioningTemplateVersionCommand; +const serializeAws_restJson1CreateRoleAliasCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/role-aliases/{roleAlias}"; + if (input.roleAlias !== undefined) { + const labelValue = input.roleAlias; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: roleAlias."); + } + resolvedPath = resolvedPath.replace("{roleAlias}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: roleAlias."); + } + let body; + body = JSON.stringify({ + ...(input.credentialDurationSeconds !== undefined && + input.credentialDurationSeconds !== null && { credentialDurationSeconds: input.credentialDurationSeconds }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateRoleAliasCommand = serializeAws_restJson1CreateRoleAliasCommand; +const serializeAws_restJson1CreateScheduledAuditCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/scheduledaudits/{scheduledAuditName}"; + if (input.scheduledAuditName !== undefined) { + const labelValue = input.scheduledAuditName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: scheduledAuditName."); + } + resolvedPath = resolvedPath.replace("{scheduledAuditName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: scheduledAuditName."); + } + let body; + body = JSON.stringify({ + ...(input.dayOfMonth !== undefined && input.dayOfMonth !== null && { dayOfMonth: input.dayOfMonth }), + ...(input.dayOfWeek !== undefined && input.dayOfWeek !== null && { dayOfWeek: input.dayOfWeek }), + ...(input.frequency !== undefined && input.frequency !== null && { frequency: input.frequency }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.targetCheckNames !== undefined && + input.targetCheckNames !== null && { + targetCheckNames: serializeAws_restJson1TargetAuditCheckNames(input.targetCheckNames, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateScheduledAuditCommand = serializeAws_restJson1CreateScheduledAuditCommand; +const serializeAws_restJson1CreateSecurityProfileCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/security-profiles/{securityProfileName}"; + if (input.securityProfileName !== undefined) { + const labelValue = input.securityProfileName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: securityProfileName."); + } + resolvedPath = resolvedPath.replace("{securityProfileName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: securityProfileName."); + } + let body; + body = JSON.stringify({ + ...(input.additionalMetricsToRetain !== undefined && + input.additionalMetricsToRetain !== null && { + additionalMetricsToRetain: serializeAws_restJson1AdditionalMetricsToRetainList(input.additionalMetricsToRetain, context), + }), + ...(input.additionalMetricsToRetainV2 !== undefined && + input.additionalMetricsToRetainV2 !== null && { + additionalMetricsToRetainV2: serializeAws_restJson1AdditionalMetricsToRetainV2List(input.additionalMetricsToRetainV2, context), + }), + ...(input.alertTargets !== undefined && + input.alertTargets !== null && { alertTargets: serializeAws_restJson1AlertTargets(input.alertTargets, context) }), + ...(input.behaviors !== undefined && + input.behaviors !== null && { behaviors: serializeAws_restJson1Behaviors(input.behaviors, context) }), + ...(input.securityProfileDescription !== undefined && + input.securityProfileDescription !== null && { securityProfileDescription: input.securityProfileDescription }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateSecurityProfileCommand = serializeAws_restJson1CreateSecurityProfileCommand; +const serializeAws_restJson1CreateStreamCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/streams/{streamId}"; + if (input.streamId !== undefined) { + const labelValue = input.streamId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: streamId."); + } + resolvedPath = resolvedPath.replace("{streamId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: streamId."); + } + let body; + body = JSON.stringify({ + ...(input.description !== undefined && input.description !== null && { description: input.description }), + ...(input.files !== undefined && + input.files !== null && { files: serializeAws_restJson1StreamFiles(input.files, context) }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateStreamCommand = serializeAws_restJson1CreateStreamCommand; +const serializeAws_restJson1CreateThingCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/things/{thingName}"; + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + let body; + body = JSON.stringify({ + ...(input.attributePayload !== undefined && + input.attributePayload !== null && { + attributePayload: serializeAws_restJson1AttributePayload(input.attributePayload, context), + }), + ...(input.billingGroupName !== undefined && + input.billingGroupName !== null && { billingGroupName: input.billingGroupName }), + ...(input.thingTypeName !== undefined && input.thingTypeName !== null && { thingTypeName: input.thingTypeName }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateThingCommand = serializeAws_restJson1CreateThingCommand; +const serializeAws_restJson1CreateThingGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/thing-groups/{thingGroupName}"; + if (input.thingGroupName !== undefined) { + const labelValue = input.thingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingGroupName."); + } + resolvedPath = resolvedPath.replace("{thingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingGroupName."); + } + let body; + body = JSON.stringify({ + ...(input.parentGroupName !== undefined && + input.parentGroupName !== null && { parentGroupName: input.parentGroupName }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.thingGroupProperties !== undefined && + input.thingGroupProperties !== null && { + thingGroupProperties: serializeAws_restJson1ThingGroupProperties(input.thingGroupProperties, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateThingGroupCommand = serializeAws_restJson1CreateThingGroupCommand; +const serializeAws_restJson1CreateThingTypeCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/thing-types/{thingTypeName}"; + if (input.thingTypeName !== undefined) { + const labelValue = input.thingTypeName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingTypeName."); + } + resolvedPath = resolvedPath.replace("{thingTypeName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingTypeName."); + } + let body; + body = JSON.stringify({ + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.thingTypeProperties !== undefined && + input.thingTypeProperties !== null && { + thingTypeProperties: serializeAws_restJson1ThingTypeProperties(input.thingTypeProperties, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateThingTypeCommand = serializeAws_restJson1CreateThingTypeCommand; +const serializeAws_restJson1CreateTopicRuleCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + ...(isSerializableHeaderValue(input.tags) && { "x-amz-tagging": input.tags }), + }; + let resolvedPath = "/rules/{ruleName}"; + if (input.ruleName !== undefined) { + const labelValue = input.ruleName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: ruleName."); + } + resolvedPath = resolvedPath.replace("{ruleName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: ruleName."); + } + let body; + if (input.topicRulePayload !== undefined) { + body = serializeAws_restJson1TopicRulePayload(input.topicRulePayload, context); + } + if (body === undefined) { + body = {}; + } + body = JSON.stringify(body); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateTopicRuleCommand = serializeAws_restJson1CreateTopicRuleCommand; +const serializeAws_restJson1CreateTopicRuleDestinationCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/destinations"; + let body; + body = JSON.stringify({ + ...(input.destinationConfiguration !== undefined && + input.destinationConfiguration !== null && { + destinationConfiguration: serializeAws_restJson1TopicRuleDestinationConfiguration(input.destinationConfiguration, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1CreateTopicRuleDestinationCommand = serializeAws_restJson1CreateTopicRuleDestinationCommand; +const serializeAws_restJson1DeleteAccountAuditConfigurationCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/configuration"; + const query = { + ...(input.deleteScheduledAudits !== undefined && { deleteScheduledAudits: input.deleteScheduledAudits.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteAccountAuditConfigurationCommand = serializeAws_restJson1DeleteAccountAuditConfigurationCommand; +const serializeAws_restJson1DeleteAuditSuppressionCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/suppressions/delete"; + let body; + body = JSON.stringify({ + ...(input.checkName !== undefined && input.checkName !== null && { checkName: input.checkName }), + ...(input.resourceIdentifier !== undefined && + input.resourceIdentifier !== null && { + resourceIdentifier: serializeAws_restJson1ResourceIdentifier(input.resourceIdentifier, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteAuditSuppressionCommand = serializeAws_restJson1DeleteAuditSuppressionCommand; +const serializeAws_restJson1DeleteAuthorizerCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/authorizer/{authorizerName}"; + if (input.authorizerName !== undefined) { + const labelValue = input.authorizerName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: authorizerName."); + } + resolvedPath = resolvedPath.replace("{authorizerName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: authorizerName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteAuthorizerCommand = serializeAws_restJson1DeleteAuthorizerCommand; +const serializeAws_restJson1DeleteBillingGroupCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/billing-groups/{billingGroupName}"; + if (input.billingGroupName !== undefined) { + const labelValue = input.billingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: billingGroupName."); + } + resolvedPath = resolvedPath.replace("{billingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: billingGroupName."); + } + const query = { + ...(input.expectedVersion !== undefined && { expectedVersion: input.expectedVersion.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteBillingGroupCommand = serializeAws_restJson1DeleteBillingGroupCommand; +const serializeAws_restJson1DeleteCACertificateCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/cacertificate/{certificateId}"; + if (input.certificateId !== undefined) { + const labelValue = input.certificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: certificateId."); + } + resolvedPath = resolvedPath.replace("{certificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: certificateId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteCACertificateCommand = serializeAws_restJson1DeleteCACertificateCommand; +const serializeAws_restJson1DeleteCertificateCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/certificates/{certificateId}"; + if (input.certificateId !== undefined) { + const labelValue = input.certificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: certificateId."); + } + resolvedPath = resolvedPath.replace("{certificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: certificateId."); + } + const query = { + ...(input.forceDelete !== undefined && { forceDelete: input.forceDelete.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteCertificateCommand = serializeAws_restJson1DeleteCertificateCommand; +const serializeAws_restJson1DeleteDimensionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/dimensions/{name}"; + if (input.name !== undefined) { + const labelValue = input.name; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: name."); + } + resolvedPath = resolvedPath.replace("{name}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: name."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteDimensionCommand = serializeAws_restJson1DeleteDimensionCommand; +const serializeAws_restJson1DeleteDomainConfigurationCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/domainConfigurations/{domainConfigurationName}"; + if (input.domainConfigurationName !== undefined) { + const labelValue = input.domainConfigurationName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: domainConfigurationName."); + } + resolvedPath = resolvedPath.replace("{domainConfigurationName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: domainConfigurationName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteDomainConfigurationCommand = serializeAws_restJson1DeleteDomainConfigurationCommand; +const serializeAws_restJson1DeleteDynamicThingGroupCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/dynamic-thing-groups/{thingGroupName}"; + if (input.thingGroupName !== undefined) { + const labelValue = input.thingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingGroupName."); + } + resolvedPath = resolvedPath.replace("{thingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingGroupName."); + } + const query = { + ...(input.expectedVersion !== undefined && { expectedVersion: input.expectedVersion.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteDynamicThingGroupCommand = serializeAws_restJson1DeleteDynamicThingGroupCommand; +const serializeAws_restJson1DeleteJobCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/jobs/{jobId}"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + const query = { + ...(input.force !== undefined && { force: input.force.toString() }), + ...(input.namespaceId !== undefined && { namespaceId: input.namespaceId }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteJobCommand = serializeAws_restJson1DeleteJobCommand; +const serializeAws_restJson1DeleteJobExecutionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/things/{thingName}/jobs/{jobId}/executionNumber/{executionNumber}"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + if (input.executionNumber !== undefined) { + const labelValue = input.executionNumber.toString(); + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: executionNumber."); + } + resolvedPath = resolvedPath.replace("{executionNumber}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: executionNumber."); + } + const query = { + ...(input.force !== undefined && { force: input.force.toString() }), + ...(input.namespaceId !== undefined && { namespaceId: input.namespaceId }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteJobExecutionCommand = serializeAws_restJson1DeleteJobExecutionCommand; +const serializeAws_restJson1DeleteMitigationActionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/mitigationactions/actions/{actionName}"; + if (input.actionName !== undefined) { + const labelValue = input.actionName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: actionName."); + } + resolvedPath = resolvedPath.replace("{actionName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: actionName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteMitigationActionCommand = serializeAws_restJson1DeleteMitigationActionCommand; +const serializeAws_restJson1DeleteOTAUpdateCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/otaUpdates/{otaUpdateId}"; + if (input.otaUpdateId !== undefined) { + const labelValue = input.otaUpdateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: otaUpdateId."); + } + resolvedPath = resolvedPath.replace("{otaUpdateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: otaUpdateId."); + } + const query = { + ...(input.deleteStream !== undefined && { deleteStream: input.deleteStream.toString() }), + ...(input.forceDeleteAWSJob !== undefined && { forceDeleteAWSJob: input.forceDeleteAWSJob.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteOTAUpdateCommand = serializeAws_restJson1DeleteOTAUpdateCommand; +const serializeAws_restJson1DeletePolicyCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/policies/{policyName}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeletePolicyCommand = serializeAws_restJson1DeletePolicyCommand; +const serializeAws_restJson1DeletePolicyVersionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/policies/{policyName}/version/{policyVersionId}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + if (input.policyVersionId !== undefined) { + const labelValue = input.policyVersionId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyVersionId."); + } + resolvedPath = resolvedPath.replace("{policyVersionId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyVersionId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeletePolicyVersionCommand = serializeAws_restJson1DeletePolicyVersionCommand; +const serializeAws_restJson1DeleteProvisioningTemplateCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/provisioning-templates/{templateName}"; + if (input.templateName !== undefined) { + const labelValue = input.templateName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: templateName."); + } + resolvedPath = resolvedPath.replace("{templateName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: templateName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteProvisioningTemplateCommand = serializeAws_restJson1DeleteProvisioningTemplateCommand; +const serializeAws_restJson1DeleteProvisioningTemplateVersionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/provisioning-templates/{templateName}/versions/{versionId}"; + if (input.templateName !== undefined) { + const labelValue = input.templateName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: templateName."); + } + resolvedPath = resolvedPath.replace("{templateName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: templateName."); + } + if (input.versionId !== undefined) { + const labelValue = input.versionId.toString(); + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: versionId."); + } + resolvedPath = resolvedPath.replace("{versionId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: versionId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteProvisioningTemplateVersionCommand = serializeAws_restJson1DeleteProvisioningTemplateVersionCommand; +const serializeAws_restJson1DeleteRegistrationCodeCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/registrationcode"; + let body; + body = ""; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteRegistrationCodeCommand = serializeAws_restJson1DeleteRegistrationCodeCommand; +const serializeAws_restJson1DeleteRoleAliasCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/role-aliases/{roleAlias}"; + if (input.roleAlias !== undefined) { + const labelValue = input.roleAlias; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: roleAlias."); + } + resolvedPath = resolvedPath.replace("{roleAlias}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: roleAlias."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteRoleAliasCommand = serializeAws_restJson1DeleteRoleAliasCommand; +const serializeAws_restJson1DeleteScheduledAuditCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/scheduledaudits/{scheduledAuditName}"; + if (input.scheduledAuditName !== undefined) { + const labelValue = input.scheduledAuditName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: scheduledAuditName."); + } + resolvedPath = resolvedPath.replace("{scheduledAuditName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: scheduledAuditName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteScheduledAuditCommand = serializeAws_restJson1DeleteScheduledAuditCommand; +const serializeAws_restJson1DeleteSecurityProfileCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/security-profiles/{securityProfileName}"; + if (input.securityProfileName !== undefined) { + const labelValue = input.securityProfileName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: securityProfileName."); + } + resolvedPath = resolvedPath.replace("{securityProfileName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: securityProfileName."); + } + const query = { + ...(input.expectedVersion !== undefined && { expectedVersion: input.expectedVersion.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteSecurityProfileCommand = serializeAws_restJson1DeleteSecurityProfileCommand; +const serializeAws_restJson1DeleteStreamCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/streams/{streamId}"; + if (input.streamId !== undefined) { + const labelValue = input.streamId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: streamId."); + } + resolvedPath = resolvedPath.replace("{streamId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: streamId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteStreamCommand = serializeAws_restJson1DeleteStreamCommand; +const serializeAws_restJson1DeleteThingCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/things/{thingName}"; + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + const query = { + ...(input.expectedVersion !== undefined && { expectedVersion: input.expectedVersion.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteThingCommand = serializeAws_restJson1DeleteThingCommand; +const serializeAws_restJson1DeleteThingGroupCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-groups/{thingGroupName}"; + if (input.thingGroupName !== undefined) { + const labelValue = input.thingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingGroupName."); + } + resolvedPath = resolvedPath.replace("{thingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingGroupName."); + } + const query = { + ...(input.expectedVersion !== undefined && { expectedVersion: input.expectedVersion.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteThingGroupCommand = serializeAws_restJson1DeleteThingGroupCommand; +const serializeAws_restJson1DeleteThingTypeCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-types/{thingTypeName}"; + if (input.thingTypeName !== undefined) { + const labelValue = input.thingTypeName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingTypeName."); + } + resolvedPath = resolvedPath.replace("{thingTypeName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingTypeName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteThingTypeCommand = serializeAws_restJson1DeleteThingTypeCommand; +const serializeAws_restJson1DeleteTopicRuleCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/rules/{ruleName}"; + if (input.ruleName !== undefined) { + const labelValue = input.ruleName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: ruleName."); + } + resolvedPath = resolvedPath.replace("{ruleName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: ruleName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteTopicRuleCommand = serializeAws_restJson1DeleteTopicRuleCommand; +const serializeAws_restJson1DeleteTopicRuleDestinationCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/destinations/{arn+}"; + if (input.arn !== undefined) { + const labelValue = input.arn; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: arn."); + } + resolvedPath = resolvedPath.replace("{arn+}", labelValue + .split("/") + .map((segment) => smithy_client_1.extendedEncodeURIComponent(segment)) + .join("/")); + } + else { + throw new Error("No value provided for input HTTP label: arn."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeleteTopicRuleDestinationCommand = serializeAws_restJson1DeleteTopicRuleDestinationCommand; +const serializeAws_restJson1DeleteV2LoggingLevelCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/v2LoggingLevel"; + const query = { + ...(input.targetType !== undefined && { targetType: input.targetType }), + ...(input.targetName !== undefined && { targetName: input.targetName }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DeleteV2LoggingLevelCommand = serializeAws_restJson1DeleteV2LoggingLevelCommand; +const serializeAws_restJson1DeprecateThingTypeCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/thing-types/{thingTypeName}/deprecate"; + if (input.thingTypeName !== undefined) { + const labelValue = input.thingTypeName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingTypeName."); + } + resolvedPath = resolvedPath.replace("{thingTypeName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingTypeName."); + } + let body; + body = JSON.stringify({ + ...(input.undoDeprecate !== undefined && input.undoDeprecate !== null && { undoDeprecate: input.undoDeprecate }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DeprecateThingTypeCommand = serializeAws_restJson1DeprecateThingTypeCommand; +const serializeAws_restJson1DescribeAccountAuditConfigurationCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/configuration"; + let body; + body = ""; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeAccountAuditConfigurationCommand = serializeAws_restJson1DescribeAccountAuditConfigurationCommand; +const serializeAws_restJson1DescribeAuditFindingCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/findings/{findingId}"; + if (input.findingId !== undefined) { + const labelValue = input.findingId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: findingId."); + } + resolvedPath = resolvedPath.replace("{findingId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: findingId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeAuditFindingCommand = serializeAws_restJson1DescribeAuditFindingCommand; +const serializeAws_restJson1DescribeAuditMitigationActionsTaskCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/mitigationactions/tasks/{taskId}"; + if (input.taskId !== undefined) { + const labelValue = input.taskId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: taskId."); + } + resolvedPath = resolvedPath.replace("{taskId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: taskId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeAuditMitigationActionsTaskCommand = serializeAws_restJson1DescribeAuditMitigationActionsTaskCommand; +const serializeAws_restJson1DescribeAuditSuppressionCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/suppressions/describe"; + let body; + body = JSON.stringify({ + ...(input.checkName !== undefined && input.checkName !== null && { checkName: input.checkName }), + ...(input.resourceIdentifier !== undefined && + input.resourceIdentifier !== null && { + resourceIdentifier: serializeAws_restJson1ResourceIdentifier(input.resourceIdentifier, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeAuditSuppressionCommand = serializeAws_restJson1DescribeAuditSuppressionCommand; +const serializeAws_restJson1DescribeAuditTaskCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/tasks/{taskId}"; + if (input.taskId !== undefined) { + const labelValue = input.taskId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: taskId."); + } + resolvedPath = resolvedPath.replace("{taskId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: taskId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeAuditTaskCommand = serializeAws_restJson1DescribeAuditTaskCommand; +const serializeAws_restJson1DescribeAuthorizerCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/authorizer/{authorizerName}"; + if (input.authorizerName !== undefined) { + const labelValue = input.authorizerName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: authorizerName."); + } + resolvedPath = resolvedPath.replace("{authorizerName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: authorizerName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeAuthorizerCommand = serializeAws_restJson1DescribeAuthorizerCommand; +const serializeAws_restJson1DescribeBillingGroupCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/billing-groups/{billingGroupName}"; + if (input.billingGroupName !== undefined) { + const labelValue = input.billingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: billingGroupName."); + } + resolvedPath = resolvedPath.replace("{billingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: billingGroupName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeBillingGroupCommand = serializeAws_restJson1DescribeBillingGroupCommand; +const serializeAws_restJson1DescribeCACertificateCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/cacertificate/{certificateId}"; + if (input.certificateId !== undefined) { + const labelValue = input.certificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: certificateId."); + } + resolvedPath = resolvedPath.replace("{certificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: certificateId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeCACertificateCommand = serializeAws_restJson1DescribeCACertificateCommand; +const serializeAws_restJson1DescribeCertificateCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/certificates/{certificateId}"; + if (input.certificateId !== undefined) { + const labelValue = input.certificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: certificateId."); + } + resolvedPath = resolvedPath.replace("{certificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: certificateId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeCertificateCommand = serializeAws_restJson1DescribeCertificateCommand; +const serializeAws_restJson1DescribeDefaultAuthorizerCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/default-authorizer"; + let body; + body = ""; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeDefaultAuthorizerCommand = serializeAws_restJson1DescribeDefaultAuthorizerCommand; +const serializeAws_restJson1DescribeDimensionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/dimensions/{name}"; + if (input.name !== undefined) { + const labelValue = input.name; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: name."); + } + resolvedPath = resolvedPath.replace("{name}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: name."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeDimensionCommand = serializeAws_restJson1DescribeDimensionCommand; +const serializeAws_restJson1DescribeDomainConfigurationCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/domainConfigurations/{domainConfigurationName}"; + if (input.domainConfigurationName !== undefined) { + const labelValue = input.domainConfigurationName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: domainConfigurationName."); + } + resolvedPath = resolvedPath.replace("{domainConfigurationName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: domainConfigurationName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeDomainConfigurationCommand = serializeAws_restJson1DescribeDomainConfigurationCommand; +const serializeAws_restJson1DescribeEndpointCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/endpoint"; + const query = { + ...(input.endpointType !== undefined && { endpointType: input.endpointType }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DescribeEndpointCommand = serializeAws_restJson1DescribeEndpointCommand; +const serializeAws_restJson1DescribeEventConfigurationsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/event-configurations"; + let body; + body = ""; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeEventConfigurationsCommand = serializeAws_restJson1DescribeEventConfigurationsCommand; +const serializeAws_restJson1DescribeIndexCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/indices/{indexName}"; + if (input.indexName !== undefined) { + const labelValue = input.indexName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: indexName."); + } + resolvedPath = resolvedPath.replace("{indexName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: indexName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeIndexCommand = serializeAws_restJson1DescribeIndexCommand; +const serializeAws_restJson1DescribeJobCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/jobs/{jobId}"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeJobCommand = serializeAws_restJson1DescribeJobCommand; +const serializeAws_restJson1DescribeJobExecutionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/things/{thingName}/jobs/{jobId}"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + const query = { + ...(input.executionNumber !== undefined && { executionNumber: input.executionNumber.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DescribeJobExecutionCommand = serializeAws_restJson1DescribeJobExecutionCommand; +const serializeAws_restJson1DescribeMitigationActionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/mitigationactions/actions/{actionName}"; + if (input.actionName !== undefined) { + const labelValue = input.actionName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: actionName."); + } + resolvedPath = resolvedPath.replace("{actionName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: actionName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeMitigationActionCommand = serializeAws_restJson1DescribeMitigationActionCommand; +const serializeAws_restJson1DescribeProvisioningTemplateCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/provisioning-templates/{templateName}"; + if (input.templateName !== undefined) { + const labelValue = input.templateName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: templateName."); + } + resolvedPath = resolvedPath.replace("{templateName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: templateName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeProvisioningTemplateCommand = serializeAws_restJson1DescribeProvisioningTemplateCommand; +const serializeAws_restJson1DescribeProvisioningTemplateVersionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/provisioning-templates/{templateName}/versions/{versionId}"; + if (input.templateName !== undefined) { + const labelValue = input.templateName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: templateName."); + } + resolvedPath = resolvedPath.replace("{templateName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: templateName."); + } + if (input.versionId !== undefined) { + const labelValue = input.versionId.toString(); + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: versionId."); + } + resolvedPath = resolvedPath.replace("{versionId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: versionId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeProvisioningTemplateVersionCommand = serializeAws_restJson1DescribeProvisioningTemplateVersionCommand; +const serializeAws_restJson1DescribeRoleAliasCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/role-aliases/{roleAlias}"; + if (input.roleAlias !== undefined) { + const labelValue = input.roleAlias; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: roleAlias."); + } + resolvedPath = resolvedPath.replace("{roleAlias}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: roleAlias."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeRoleAliasCommand = serializeAws_restJson1DescribeRoleAliasCommand; +const serializeAws_restJson1DescribeScheduledAuditCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/scheduledaudits/{scheduledAuditName}"; + if (input.scheduledAuditName !== undefined) { + const labelValue = input.scheduledAuditName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: scheduledAuditName."); + } + resolvedPath = resolvedPath.replace("{scheduledAuditName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: scheduledAuditName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeScheduledAuditCommand = serializeAws_restJson1DescribeScheduledAuditCommand; +const serializeAws_restJson1DescribeSecurityProfileCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/security-profiles/{securityProfileName}"; + if (input.securityProfileName !== undefined) { + const labelValue = input.securityProfileName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: securityProfileName."); + } + resolvedPath = resolvedPath.replace("{securityProfileName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: securityProfileName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeSecurityProfileCommand = serializeAws_restJson1DescribeSecurityProfileCommand; +const serializeAws_restJson1DescribeStreamCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/streams/{streamId}"; + if (input.streamId !== undefined) { + const labelValue = input.streamId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: streamId."); + } + resolvedPath = resolvedPath.replace("{streamId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: streamId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeStreamCommand = serializeAws_restJson1DescribeStreamCommand; +const serializeAws_restJson1DescribeThingCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/things/{thingName}"; + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeThingCommand = serializeAws_restJson1DescribeThingCommand; +const serializeAws_restJson1DescribeThingGroupCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-groups/{thingGroupName}"; + if (input.thingGroupName !== undefined) { + const labelValue = input.thingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingGroupName."); + } + resolvedPath = resolvedPath.replace("{thingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingGroupName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeThingGroupCommand = serializeAws_restJson1DescribeThingGroupCommand; +const serializeAws_restJson1DescribeThingRegistrationTaskCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-registration-tasks/{taskId}"; + if (input.taskId !== undefined) { + const labelValue = input.taskId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: taskId."); + } + resolvedPath = resolvedPath.replace("{taskId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: taskId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeThingRegistrationTaskCommand = serializeAws_restJson1DescribeThingRegistrationTaskCommand; +const serializeAws_restJson1DescribeThingTypeCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-types/{thingTypeName}"; + if (input.thingTypeName !== undefined) { + const labelValue = input.thingTypeName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingTypeName."); + } + resolvedPath = resolvedPath.replace("{thingTypeName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingTypeName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DescribeThingTypeCommand = serializeAws_restJson1DescribeThingTypeCommand; +const serializeAws_restJson1DetachPolicyCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/target-policies/{policyName}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + let body; + body = JSON.stringify({ + ...(input.target !== undefined && input.target !== null && { target: input.target }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DetachPolicyCommand = serializeAws_restJson1DetachPolicyCommand; +const serializeAws_restJson1DetachPrincipalPolicyCommand = async (input, context) => { + const headers = { + ...(isSerializableHeaderValue(input.principal) && { "x-amzn-iot-principal": input.principal }), + }; + let resolvedPath = "/principal-policies/{policyName}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DetachPrincipalPolicyCommand = serializeAws_restJson1DetachPrincipalPolicyCommand; +const serializeAws_restJson1DetachSecurityProfileCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/security-profiles/{securityProfileName}/targets"; + if (input.securityProfileName !== undefined) { + const labelValue = input.securityProfileName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: securityProfileName."); + } + resolvedPath = resolvedPath.replace("{securityProfileName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: securityProfileName."); + } + const query = { + ...(input.securityProfileTargetArn !== undefined && { securityProfileTargetArn: input.securityProfileTargetArn }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1DetachSecurityProfileCommand = serializeAws_restJson1DetachSecurityProfileCommand; +const serializeAws_restJson1DetachThingPrincipalCommand = async (input, context) => { + const headers = { + ...(isSerializableHeaderValue(input.principal) && { "x-amzn-principal": input.principal }), + }; + let resolvedPath = "/things/{thingName}/principals"; + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "DELETE", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DetachThingPrincipalCommand = serializeAws_restJson1DetachThingPrincipalCommand; +const serializeAws_restJson1DisableTopicRuleCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/rules/{ruleName}/disable"; + if (input.ruleName !== undefined) { + const labelValue = input.ruleName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: ruleName."); + } + resolvedPath = resolvedPath.replace("{ruleName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: ruleName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1DisableTopicRuleCommand = serializeAws_restJson1DisableTopicRuleCommand; +const serializeAws_restJson1EnableTopicRuleCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/rules/{ruleName}/enable"; + if (input.ruleName !== undefined) { + const labelValue = input.ruleName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: ruleName."); + } + resolvedPath = resolvedPath.replace("{ruleName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: ruleName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1EnableTopicRuleCommand = serializeAws_restJson1EnableTopicRuleCommand; +const serializeAws_restJson1GetCardinalityCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/indices/cardinality"; + let body; + body = JSON.stringify({ + ...(input.aggregationField !== undefined && + input.aggregationField !== null && { aggregationField: input.aggregationField }), + ...(input.indexName !== undefined && input.indexName !== null && { indexName: input.indexName }), + ...(input.queryString !== undefined && input.queryString !== null && { queryString: input.queryString }), + ...(input.queryVersion !== undefined && input.queryVersion !== null && { queryVersion: input.queryVersion }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetCardinalityCommand = serializeAws_restJson1GetCardinalityCommand; +const serializeAws_restJson1GetEffectivePoliciesCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/effective-policies"; + const query = { + ...(input.thingName !== undefined && { thingName: input.thingName }), + }; + let body; + body = JSON.stringify({ + ...(input.cognitoIdentityPoolId !== undefined && + input.cognitoIdentityPoolId !== null && { cognitoIdentityPoolId: input.cognitoIdentityPoolId }), + ...(input.principal !== undefined && input.principal !== null && { principal: input.principal }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1GetEffectivePoliciesCommand = serializeAws_restJson1GetEffectivePoliciesCommand; +const serializeAws_restJson1GetIndexingConfigurationCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/indexing/config"; + let body; + body = ""; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetIndexingConfigurationCommand = serializeAws_restJson1GetIndexingConfigurationCommand; +const serializeAws_restJson1GetJobDocumentCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/jobs/{jobId}/job-document"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetJobDocumentCommand = serializeAws_restJson1GetJobDocumentCommand; +const serializeAws_restJson1GetLoggingOptionsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/loggingOptions"; + let body; + body = ""; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetLoggingOptionsCommand = serializeAws_restJson1GetLoggingOptionsCommand; +const serializeAws_restJson1GetOTAUpdateCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/otaUpdates/{otaUpdateId}"; + if (input.otaUpdateId !== undefined) { + const labelValue = input.otaUpdateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: otaUpdateId."); + } + resolvedPath = resolvedPath.replace("{otaUpdateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: otaUpdateId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetOTAUpdateCommand = serializeAws_restJson1GetOTAUpdateCommand; +const serializeAws_restJson1GetPercentilesCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/indices/percentiles"; + let body; + body = JSON.stringify({ + ...(input.aggregationField !== undefined && + input.aggregationField !== null && { aggregationField: input.aggregationField }), + ...(input.indexName !== undefined && input.indexName !== null && { indexName: input.indexName }), + ...(input.percents !== undefined && + input.percents !== null && { percents: serializeAws_restJson1PercentList(input.percents, context) }), + ...(input.queryString !== undefined && input.queryString !== null && { queryString: input.queryString }), + ...(input.queryVersion !== undefined && input.queryVersion !== null && { queryVersion: input.queryVersion }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetPercentilesCommand = serializeAws_restJson1GetPercentilesCommand; +const serializeAws_restJson1GetPolicyCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/policies/{policyName}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetPolicyCommand = serializeAws_restJson1GetPolicyCommand; +const serializeAws_restJson1GetPolicyVersionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/policies/{policyName}/version/{policyVersionId}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + if (input.policyVersionId !== undefined) { + const labelValue = input.policyVersionId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyVersionId."); + } + resolvedPath = resolvedPath.replace("{policyVersionId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyVersionId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetPolicyVersionCommand = serializeAws_restJson1GetPolicyVersionCommand; +const serializeAws_restJson1GetRegistrationCodeCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/registrationcode"; + let body; + body = ""; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetRegistrationCodeCommand = serializeAws_restJson1GetRegistrationCodeCommand; +const serializeAws_restJson1GetStatisticsCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/indices/statistics"; + let body; + body = JSON.stringify({ + ...(input.aggregationField !== undefined && + input.aggregationField !== null && { aggregationField: input.aggregationField }), + ...(input.indexName !== undefined && input.indexName !== null && { indexName: input.indexName }), + ...(input.queryString !== undefined && input.queryString !== null && { queryString: input.queryString }), + ...(input.queryVersion !== undefined && input.queryVersion !== null && { queryVersion: input.queryVersion }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetStatisticsCommand = serializeAws_restJson1GetStatisticsCommand; +const serializeAws_restJson1GetTopicRuleCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/rules/{ruleName}"; + if (input.ruleName !== undefined) { + const labelValue = input.ruleName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: ruleName."); + } + resolvedPath = resolvedPath.replace("{ruleName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: ruleName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetTopicRuleCommand = serializeAws_restJson1GetTopicRuleCommand; +const serializeAws_restJson1GetTopicRuleDestinationCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/destinations/{arn+}"; + if (input.arn !== undefined) { + const labelValue = input.arn; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: arn."); + } + resolvedPath = resolvedPath.replace("{arn+}", labelValue + .split("/") + .map((segment) => smithy_client_1.extendedEncodeURIComponent(segment)) + .join("/")); + } + else { + throw new Error("No value provided for input HTTP label: arn."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetTopicRuleDestinationCommand = serializeAws_restJson1GetTopicRuleDestinationCommand; +const serializeAws_restJson1GetV2LoggingOptionsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/v2LoggingOptions"; + let body; + body = ""; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1GetV2LoggingOptionsCommand = serializeAws_restJson1GetV2LoggingOptionsCommand; +const serializeAws_restJson1ListActiveViolationsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/active-violations"; + const query = { + ...(input.thingName !== undefined && { thingName: input.thingName }), + ...(input.securityProfileName !== undefined && { securityProfileName: input.securityProfileName }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListActiveViolationsCommand = serializeAws_restJson1ListActiveViolationsCommand; +const serializeAws_restJson1ListAttachedPoliciesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/attached-policies/{target}"; + if (input.target !== undefined) { + const labelValue = input.target; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: target."); + } + resolvedPath = resolvedPath.replace("{target}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: target."); + } + const query = { + ...(input.recursive !== undefined && { recursive: input.recursive.toString() }), + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListAttachedPoliciesCommand = serializeAws_restJson1ListAttachedPoliciesCommand; +const serializeAws_restJson1ListAuditFindingsCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/findings"; + let body; + body = JSON.stringify({ + ...(input.checkName !== undefined && input.checkName !== null && { checkName: input.checkName }), + ...(input.endTime !== undefined && + input.endTime !== null && { endTime: Math.round(input.endTime.getTime() / 1000) }), + ...(input.listSuppressedFindings !== undefined && + input.listSuppressedFindings !== null && { listSuppressedFindings: input.listSuppressedFindings }), + ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }), + ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }), + ...(input.resourceIdentifier !== undefined && + input.resourceIdentifier !== null && { + resourceIdentifier: serializeAws_restJson1ResourceIdentifier(input.resourceIdentifier, context), + }), + ...(input.startTime !== undefined && + input.startTime !== null && { startTime: Math.round(input.startTime.getTime() / 1000) }), + ...(input.taskId !== undefined && input.taskId !== null && { taskId: input.taskId }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1ListAuditFindingsCommand = serializeAws_restJson1ListAuditFindingsCommand; +const serializeAws_restJson1ListAuditMitigationActionsExecutionsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/mitigationactions/executions"; + const query = { + ...(input.taskId !== undefined && { taskId: input.taskId }), + ...(input.actionStatus !== undefined && { actionStatus: input.actionStatus }), + ...(input.findingId !== undefined && { findingId: input.findingId }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListAuditMitigationActionsExecutionsCommand = serializeAws_restJson1ListAuditMitigationActionsExecutionsCommand; +const serializeAws_restJson1ListAuditMitigationActionsTasksCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/mitigationactions/tasks"; + const query = { + ...(input.auditTaskId !== undefined && { auditTaskId: input.auditTaskId }), + ...(input.findingId !== undefined && { findingId: input.findingId }), + ...(input.taskStatus !== undefined && { taskStatus: input.taskStatus }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.startTime !== undefined && { startTime: (input.startTime.toISOString().split(".")[0] + "Z").toString() }), + ...(input.endTime !== undefined && { endTime: (input.endTime.toISOString().split(".")[0] + "Z").toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListAuditMitigationActionsTasksCommand = serializeAws_restJson1ListAuditMitigationActionsTasksCommand; +const serializeAws_restJson1ListAuditSuppressionsCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/suppressions/list"; + let body; + body = JSON.stringify({ + ...(input.ascendingOrder !== undefined && + input.ascendingOrder !== null && { ascendingOrder: input.ascendingOrder }), + ...(input.checkName !== undefined && input.checkName !== null && { checkName: input.checkName }), + ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }), + ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }), + ...(input.resourceIdentifier !== undefined && + input.resourceIdentifier !== null && { + resourceIdentifier: serializeAws_restJson1ResourceIdentifier(input.resourceIdentifier, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1ListAuditSuppressionsCommand = serializeAws_restJson1ListAuditSuppressionsCommand; +const serializeAws_restJson1ListAuditTasksCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/tasks"; + const query = { + ...(input.startTime !== undefined && { startTime: (input.startTime.toISOString().split(".")[0] + "Z").toString() }), + ...(input.endTime !== undefined && { endTime: (input.endTime.toISOString().split(".")[0] + "Z").toString() }), + ...(input.taskType !== undefined && { taskType: input.taskType }), + ...(input.taskStatus !== undefined && { taskStatus: input.taskStatus }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListAuditTasksCommand = serializeAws_restJson1ListAuditTasksCommand; +const serializeAws_restJson1ListAuthorizersCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/authorizers"; + const query = { + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.ascendingOrder !== undefined && { isAscendingOrder: input.ascendingOrder.toString() }), + ...(input.status !== undefined && { status: input.status }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListAuthorizersCommand = serializeAws_restJson1ListAuthorizersCommand; +const serializeAws_restJson1ListBillingGroupsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/billing-groups"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.namePrefixFilter !== undefined && { namePrefixFilter: input.namePrefixFilter }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListBillingGroupsCommand = serializeAws_restJson1ListBillingGroupsCommand; +const serializeAws_restJson1ListCACertificatesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/cacertificates"; + const query = { + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.ascendingOrder !== undefined && { isAscendingOrder: input.ascendingOrder.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListCACertificatesCommand = serializeAws_restJson1ListCACertificatesCommand; +const serializeAws_restJson1ListCertificatesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/certificates"; + const query = { + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.ascendingOrder !== undefined && { isAscendingOrder: input.ascendingOrder.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListCertificatesCommand = serializeAws_restJson1ListCertificatesCommand; +const serializeAws_restJson1ListCertificatesByCACommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/certificates-by-ca/{caCertificateId}"; + if (input.caCertificateId !== undefined) { + const labelValue = input.caCertificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: caCertificateId."); + } + resolvedPath = resolvedPath.replace("{caCertificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: caCertificateId."); + } + const query = { + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.ascendingOrder !== undefined && { isAscendingOrder: input.ascendingOrder.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListCertificatesByCACommand = serializeAws_restJson1ListCertificatesByCACommand; +const serializeAws_restJson1ListDimensionsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/dimensions"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListDimensionsCommand = serializeAws_restJson1ListDimensionsCommand; +const serializeAws_restJson1ListDomainConfigurationsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/domainConfigurations"; + const query = { + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + ...(input.serviceType !== undefined && { serviceType: input.serviceType }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListDomainConfigurationsCommand = serializeAws_restJson1ListDomainConfigurationsCommand; +const serializeAws_restJson1ListIndicesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/indices"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListIndicesCommand = serializeAws_restJson1ListIndicesCommand; +const serializeAws_restJson1ListJobExecutionsForJobCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/jobs/{jobId}/things"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + const query = { + ...(input.status !== undefined && { status: input.status }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListJobExecutionsForJobCommand = serializeAws_restJson1ListJobExecutionsForJobCommand; +const serializeAws_restJson1ListJobExecutionsForThingCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/things/{thingName}/jobs"; + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + const query = { + ...(input.status !== undefined && { status: input.status }), + ...(input.namespaceId !== undefined && { namespaceId: input.namespaceId }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListJobExecutionsForThingCommand = serializeAws_restJson1ListJobExecutionsForThingCommand; +const serializeAws_restJson1ListJobsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/jobs"; + const query = { + ...(input.status !== undefined && { status: input.status }), + ...(input.targetSelection !== undefined && { targetSelection: input.targetSelection }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.thingGroupName !== undefined && { thingGroupName: input.thingGroupName }), + ...(input.thingGroupId !== undefined && { thingGroupId: input.thingGroupId }), + ...(input.namespaceId !== undefined && { namespaceId: input.namespaceId }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListJobsCommand = serializeAws_restJson1ListJobsCommand; +const serializeAws_restJson1ListMitigationActionsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/mitigationactions/actions"; + const query = { + ...(input.actionType !== undefined && { actionType: input.actionType }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListMitigationActionsCommand = serializeAws_restJson1ListMitigationActionsCommand; +const serializeAws_restJson1ListOTAUpdatesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/otaUpdates"; + const query = { + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.otaUpdateStatus !== undefined && { otaUpdateStatus: input.otaUpdateStatus }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListOTAUpdatesCommand = serializeAws_restJson1ListOTAUpdatesCommand; +const serializeAws_restJson1ListOutgoingCertificatesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/certificates-out-going"; + const query = { + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.ascendingOrder !== undefined && { isAscendingOrder: input.ascendingOrder.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListOutgoingCertificatesCommand = serializeAws_restJson1ListOutgoingCertificatesCommand; +const serializeAws_restJson1ListPoliciesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/policies"; + const query = { + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + ...(input.ascendingOrder !== undefined && { isAscendingOrder: input.ascendingOrder.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListPoliciesCommand = serializeAws_restJson1ListPoliciesCommand; +const serializeAws_restJson1ListPolicyPrincipalsCommand = async (input, context) => { + const headers = { + ...(isSerializableHeaderValue(input.policyName) && { "x-amzn-iot-policy": input.policyName }), + }; + let resolvedPath = "/policy-principals"; + const query = { + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + ...(input.ascendingOrder !== undefined && { isAscendingOrder: input.ascendingOrder.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListPolicyPrincipalsCommand = serializeAws_restJson1ListPolicyPrincipalsCommand; +const serializeAws_restJson1ListPolicyVersionsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/policies/{policyName}/version"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1ListPolicyVersionsCommand = serializeAws_restJson1ListPolicyVersionsCommand; +const serializeAws_restJson1ListPrincipalPoliciesCommand = async (input, context) => { + const headers = { + ...(isSerializableHeaderValue(input.principal) && { "x-amzn-iot-principal": input.principal }), + }; + let resolvedPath = "/principal-policies"; + const query = { + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + ...(input.ascendingOrder !== undefined && { isAscendingOrder: input.ascendingOrder.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListPrincipalPoliciesCommand = serializeAws_restJson1ListPrincipalPoliciesCommand; +const serializeAws_restJson1ListPrincipalThingsCommand = async (input, context) => { + const headers = { + ...(isSerializableHeaderValue(input.principal) && { "x-amzn-principal": input.principal }), + }; + let resolvedPath = "/principals/things"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListPrincipalThingsCommand = serializeAws_restJson1ListPrincipalThingsCommand; +const serializeAws_restJson1ListProvisioningTemplatesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/provisioning-templates"; + const query = { + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListProvisioningTemplatesCommand = serializeAws_restJson1ListProvisioningTemplatesCommand; +const serializeAws_restJson1ListProvisioningTemplateVersionsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/provisioning-templates/{templateName}/versions"; + if (input.templateName !== undefined) { + const labelValue = input.templateName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: templateName."); + } + resolvedPath = resolvedPath.replace("{templateName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: templateName."); + } + const query = { + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListProvisioningTemplateVersionsCommand = serializeAws_restJson1ListProvisioningTemplateVersionsCommand; +const serializeAws_restJson1ListRoleAliasesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/role-aliases"; + const query = { + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.ascendingOrder !== undefined && { isAscendingOrder: input.ascendingOrder.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListRoleAliasesCommand = serializeAws_restJson1ListRoleAliasesCommand; +const serializeAws_restJson1ListScheduledAuditsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/audit/scheduledaudits"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListScheduledAuditsCommand = serializeAws_restJson1ListScheduledAuditsCommand; +const serializeAws_restJson1ListSecurityProfilesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/security-profiles"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.dimensionName !== undefined && { dimensionName: input.dimensionName }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListSecurityProfilesCommand = serializeAws_restJson1ListSecurityProfilesCommand; +const serializeAws_restJson1ListSecurityProfilesForTargetCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/security-profiles-for-target"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.recursive !== undefined && { recursive: input.recursive.toString() }), + ...(input.securityProfileTargetArn !== undefined && { securityProfileTargetArn: input.securityProfileTargetArn }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListSecurityProfilesForTargetCommand = serializeAws_restJson1ListSecurityProfilesForTargetCommand; +const serializeAws_restJson1ListStreamsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/streams"; + const query = { + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.ascendingOrder !== undefined && { isAscendingOrder: input.ascendingOrder.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListStreamsCommand = serializeAws_restJson1ListStreamsCommand; +const serializeAws_restJson1ListTagsForResourceCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/tags"; + const query = { + ...(input.resourceArn !== undefined && { resourceArn: input.resourceArn }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListTagsForResourceCommand = serializeAws_restJson1ListTagsForResourceCommand; +const serializeAws_restJson1ListTargetsForPolicyCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/policy-targets/{policyName}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + const query = { + ...(input.marker !== undefined && { marker: input.marker }), + ...(input.pageSize !== undefined && { pageSize: input.pageSize.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListTargetsForPolicyCommand = serializeAws_restJson1ListTargetsForPolicyCommand; +const serializeAws_restJson1ListTargetsForSecurityProfileCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/security-profiles/{securityProfileName}/targets"; + if (input.securityProfileName !== undefined) { + const labelValue = input.securityProfileName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: securityProfileName."); + } + resolvedPath = resolvedPath.replace("{securityProfileName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: securityProfileName."); + } + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListTargetsForSecurityProfileCommand = serializeAws_restJson1ListTargetsForSecurityProfileCommand; +const serializeAws_restJson1ListThingGroupsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-groups"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.parentGroup !== undefined && { parentGroup: input.parentGroup }), + ...(input.namePrefixFilter !== undefined && { namePrefixFilter: input.namePrefixFilter }), + ...(input.recursive !== undefined && { recursive: input.recursive.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListThingGroupsCommand = serializeAws_restJson1ListThingGroupsCommand; +const serializeAws_restJson1ListThingGroupsForThingCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/things/{thingName}/thing-groups"; + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListThingGroupsForThingCommand = serializeAws_restJson1ListThingGroupsForThingCommand; +const serializeAws_restJson1ListThingPrincipalsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/things/{thingName}/principals"; + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListThingPrincipalsCommand = serializeAws_restJson1ListThingPrincipalsCommand; +const serializeAws_restJson1ListThingRegistrationTaskReportsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-registration-tasks/{taskId}/reports"; + if (input.taskId !== undefined) { + const labelValue = input.taskId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: taskId."); + } + resolvedPath = resolvedPath.replace("{taskId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: taskId."); + } + const query = { + ...(input.reportType !== undefined && { reportType: input.reportType }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListThingRegistrationTaskReportsCommand = serializeAws_restJson1ListThingRegistrationTaskReportsCommand; +const serializeAws_restJson1ListThingRegistrationTasksCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-registration-tasks"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.status !== undefined && { status: input.status }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListThingRegistrationTasksCommand = serializeAws_restJson1ListThingRegistrationTasksCommand; +const serializeAws_restJson1ListThingsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/things"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.attributeName !== undefined && { attributeName: input.attributeName }), + ...(input.attributeValue !== undefined && { attributeValue: input.attributeValue }), + ...(input.thingTypeName !== undefined && { thingTypeName: input.thingTypeName }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListThingsCommand = serializeAws_restJson1ListThingsCommand; +const serializeAws_restJson1ListThingsInBillingGroupCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/billing-groups/{billingGroupName}/things"; + if (input.billingGroupName !== undefined) { + const labelValue = input.billingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: billingGroupName."); + } + resolvedPath = resolvedPath.replace("{billingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: billingGroupName."); + } + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListThingsInBillingGroupCommand = serializeAws_restJson1ListThingsInBillingGroupCommand; +const serializeAws_restJson1ListThingsInThingGroupCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-groups/{thingGroupName}/things"; + if (input.thingGroupName !== undefined) { + const labelValue = input.thingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingGroupName."); + } + resolvedPath = resolvedPath.replace("{thingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingGroupName."); + } + const query = { + ...(input.recursive !== undefined && { recursive: input.recursive.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListThingsInThingGroupCommand = serializeAws_restJson1ListThingsInThingGroupCommand; +const serializeAws_restJson1ListThingTypesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-types"; + const query = { + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.thingTypeName !== undefined && { thingTypeName: input.thingTypeName }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListThingTypesCommand = serializeAws_restJson1ListThingTypesCommand; +const serializeAws_restJson1ListTopicRuleDestinationsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/destinations"; + const query = { + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListTopicRuleDestinationsCommand = serializeAws_restJson1ListTopicRuleDestinationsCommand; +const serializeAws_restJson1ListTopicRulesCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/rules"; + const query = { + ...(input.topic !== undefined && { topic: input.topic }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.ruleDisabled !== undefined && { ruleDisabled: input.ruleDisabled.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListTopicRulesCommand = serializeAws_restJson1ListTopicRulesCommand; +const serializeAws_restJson1ListV2LoggingLevelsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/v2LoggingLevel"; + const query = { + ...(input.targetType !== undefined && { targetType: input.targetType }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListV2LoggingLevelsCommand = serializeAws_restJson1ListV2LoggingLevelsCommand; +const serializeAws_restJson1ListViolationEventsCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/violation-events"; + const query = { + ...(input.startTime !== undefined && { startTime: (input.startTime.toISOString().split(".")[0] + "Z").toString() }), + ...(input.endTime !== undefined && { endTime: (input.endTime.toISOString().split(".")[0] + "Z").toString() }), + ...(input.thingName !== undefined && { thingName: input.thingName }), + ...(input.securityProfileName !== undefined && { securityProfileName: input.securityProfileName }), + ...(input.nextToken !== undefined && { nextToken: input.nextToken }), + ...(input.maxResults !== undefined && { maxResults: input.maxResults.toString() }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "GET", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1ListViolationEventsCommand = serializeAws_restJson1ListViolationEventsCommand; +const serializeAws_restJson1RegisterCACertificateCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/cacertificate"; + const query = { + ...(input.setAsActive !== undefined && { setAsActive: input.setAsActive.toString() }), + ...(input.allowAutoRegistration !== undefined && { allowAutoRegistration: input.allowAutoRegistration.toString() }), + }; + let body; + body = JSON.stringify({ + ...(input.caCertificate !== undefined && input.caCertificate !== null && { caCertificate: input.caCertificate }), + ...(input.registrationConfig !== undefined && + input.registrationConfig !== null && { + registrationConfig: serializeAws_restJson1RegistrationConfig(input.registrationConfig, context), + }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + ...(input.verificationCertificate !== undefined && + input.verificationCertificate !== null && { verificationCertificate: input.verificationCertificate }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1RegisterCACertificateCommand = serializeAws_restJson1RegisterCACertificateCommand; +const serializeAws_restJson1RegisterCertificateCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/certificate/register"; + const query = { + ...(input.setAsActive !== undefined && { setAsActive: input.setAsActive.toString() }), + }; + let body; + body = JSON.stringify({ + ...(input.caCertificatePem !== undefined && + input.caCertificatePem !== null && { caCertificatePem: input.caCertificatePem }), + ...(input.certificatePem !== undefined && + input.certificatePem !== null && { certificatePem: input.certificatePem }), + ...(input.status !== undefined && input.status !== null && { status: input.status }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1RegisterCertificateCommand = serializeAws_restJson1RegisterCertificateCommand; +const serializeAws_restJson1RegisterCertificateWithoutCACommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/certificate/register-no-ca"; + let body; + body = JSON.stringify({ + ...(input.certificatePem !== undefined && + input.certificatePem !== null && { certificatePem: input.certificatePem }), + ...(input.status !== undefined && input.status !== null && { status: input.status }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1RegisterCertificateWithoutCACommand = serializeAws_restJson1RegisterCertificateWithoutCACommand; +const serializeAws_restJson1RegisterThingCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/things"; + let body; + body = JSON.stringify({ + ...(input.parameters !== undefined && + input.parameters !== null && { parameters: serializeAws_restJson1Parameters(input.parameters, context) }), + ...(input.templateBody !== undefined && input.templateBody !== null && { templateBody: input.templateBody }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1RegisterThingCommand = serializeAws_restJson1RegisterThingCommand; +const serializeAws_restJson1RejectCertificateTransferCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/reject-certificate-transfer/{certificateId}"; + if (input.certificateId !== undefined) { + const labelValue = input.certificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: certificateId."); + } + resolvedPath = resolvedPath.replace("{certificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: certificateId."); + } + let body; + body = JSON.stringify({ + ...(input.rejectReason !== undefined && input.rejectReason !== null && { rejectReason: input.rejectReason }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1RejectCertificateTransferCommand = serializeAws_restJson1RejectCertificateTransferCommand; +const serializeAws_restJson1RemoveThingFromBillingGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/billing-groups/removeThingFromBillingGroup"; + let body; + body = JSON.stringify({ + ...(input.billingGroupArn !== undefined && + input.billingGroupArn !== null && { billingGroupArn: input.billingGroupArn }), + ...(input.billingGroupName !== undefined && + input.billingGroupName !== null && { billingGroupName: input.billingGroupName }), + ...(input.thingArn !== undefined && input.thingArn !== null && { thingArn: input.thingArn }), + ...(input.thingName !== undefined && input.thingName !== null && { thingName: input.thingName }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1RemoveThingFromBillingGroupCommand = serializeAws_restJson1RemoveThingFromBillingGroupCommand; +const serializeAws_restJson1RemoveThingFromThingGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/thing-groups/removeThingFromThingGroup"; + let body; + body = JSON.stringify({ + ...(input.thingArn !== undefined && input.thingArn !== null && { thingArn: input.thingArn }), + ...(input.thingGroupArn !== undefined && input.thingGroupArn !== null && { thingGroupArn: input.thingGroupArn }), + ...(input.thingGroupName !== undefined && + input.thingGroupName !== null && { thingGroupName: input.thingGroupName }), + ...(input.thingName !== undefined && input.thingName !== null && { thingName: input.thingName }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1RemoveThingFromThingGroupCommand = serializeAws_restJson1RemoveThingFromThingGroupCommand; +const serializeAws_restJson1ReplaceTopicRuleCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/rules/{ruleName}"; + if (input.ruleName !== undefined) { + const labelValue = input.ruleName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: ruleName."); + } + resolvedPath = resolvedPath.replace("{ruleName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: ruleName."); + } + let body; + if (input.topicRulePayload !== undefined) { + body = serializeAws_restJson1TopicRulePayload(input.topicRulePayload, context); + } + if (body === undefined) { + body = {}; + } + body = JSON.stringify(body); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1ReplaceTopicRuleCommand = serializeAws_restJson1ReplaceTopicRuleCommand; +const serializeAws_restJson1SearchIndexCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/indices/search"; + let body; + body = JSON.stringify({ + ...(input.indexName !== undefined && input.indexName !== null && { indexName: input.indexName }), + ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }), + ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }), + ...(input.queryString !== undefined && input.queryString !== null && { queryString: input.queryString }), + ...(input.queryVersion !== undefined && input.queryVersion !== null && { queryVersion: input.queryVersion }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1SearchIndexCommand = serializeAws_restJson1SearchIndexCommand; +const serializeAws_restJson1SetDefaultAuthorizerCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/default-authorizer"; + let body; + body = JSON.stringify({ + ...(input.authorizerName !== undefined && + input.authorizerName !== null && { authorizerName: input.authorizerName }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1SetDefaultAuthorizerCommand = serializeAws_restJson1SetDefaultAuthorizerCommand; +const serializeAws_restJson1SetDefaultPolicyVersionCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/policies/{policyName}/version/{policyVersionId}"; + if (input.policyName !== undefined) { + const labelValue = input.policyName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyName."); + } + resolvedPath = resolvedPath.replace("{policyName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyName."); + } + if (input.policyVersionId !== undefined) { + const labelValue = input.policyVersionId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: policyVersionId."); + } + resolvedPath = resolvedPath.replace("{policyVersionId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: policyVersionId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1SetDefaultPolicyVersionCommand = serializeAws_restJson1SetDefaultPolicyVersionCommand; +const serializeAws_restJson1SetLoggingOptionsCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/loggingOptions"; + let body; + if (input.loggingOptionsPayload !== undefined) { + body = serializeAws_restJson1LoggingOptionsPayload(input.loggingOptionsPayload, context); + } + if (body === undefined) { + body = {}; + } + body = JSON.stringify(body); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1SetLoggingOptionsCommand = serializeAws_restJson1SetLoggingOptionsCommand; +const serializeAws_restJson1SetV2LoggingLevelCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/v2LoggingLevel"; + let body; + body = JSON.stringify({ + ...(input.logLevel !== undefined && input.logLevel !== null && { logLevel: input.logLevel }), + ...(input.logTarget !== undefined && + input.logTarget !== null && { logTarget: serializeAws_restJson1LogTarget(input.logTarget, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1SetV2LoggingLevelCommand = serializeAws_restJson1SetV2LoggingLevelCommand; +const serializeAws_restJson1SetV2LoggingOptionsCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/v2LoggingOptions"; + let body; + body = JSON.stringify({ + ...(input.defaultLogLevel !== undefined && + input.defaultLogLevel !== null && { defaultLogLevel: input.defaultLogLevel }), + ...(input.disableAllLogs !== undefined && + input.disableAllLogs !== null && { disableAllLogs: input.disableAllLogs }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1SetV2LoggingOptionsCommand = serializeAws_restJson1SetV2LoggingOptionsCommand; +const serializeAws_restJson1StartAuditMitigationActionsTaskCommand = async (input, context) => { + var _a; + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/mitigationactions/tasks/{taskId}"; + if (input.taskId !== undefined) { + const labelValue = input.taskId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: taskId."); + } + resolvedPath = resolvedPath.replace("{taskId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: taskId."); + } + let body; + body = JSON.stringify({ + ...(input.auditCheckToActionsMapping !== undefined && + input.auditCheckToActionsMapping !== null && { + auditCheckToActionsMapping: serializeAws_restJson1AuditCheckToActionsMapping(input.auditCheckToActionsMapping, context), + }), + clientRequestToken: (_a = input.clientRequestToken) !== null && _a !== void 0 ? _a : uuid_1.v4(), + ...(input.target !== undefined && + input.target !== null && { + target: serializeAws_restJson1AuditMitigationActionsTaskTarget(input.target, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1StartAuditMitigationActionsTaskCommand = serializeAws_restJson1StartAuditMitigationActionsTaskCommand; +const serializeAws_restJson1StartOnDemandAuditTaskCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/tasks"; + let body; + body = JSON.stringify({ + ...(input.targetCheckNames !== undefined && + input.targetCheckNames !== null && { + targetCheckNames: serializeAws_restJson1TargetAuditCheckNames(input.targetCheckNames, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1StartOnDemandAuditTaskCommand = serializeAws_restJson1StartOnDemandAuditTaskCommand; +const serializeAws_restJson1StartThingRegistrationTaskCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/thing-registration-tasks"; + let body; + body = JSON.stringify({ + ...(input.inputFileBucket !== undefined && + input.inputFileBucket !== null && { inputFileBucket: input.inputFileBucket }), + ...(input.inputFileKey !== undefined && input.inputFileKey !== null && { inputFileKey: input.inputFileKey }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.templateBody !== undefined && input.templateBody !== null && { templateBody: input.templateBody }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1StartThingRegistrationTaskCommand = serializeAws_restJson1StartThingRegistrationTaskCommand; +const serializeAws_restJson1StopThingRegistrationTaskCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/thing-registration-tasks/{taskId}/cancel"; + if (input.taskId !== undefined) { + const labelValue = input.taskId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: taskId."); + } + resolvedPath = resolvedPath.replace("{taskId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: taskId."); + } + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1StopThingRegistrationTaskCommand = serializeAws_restJson1StopThingRegistrationTaskCommand; +const serializeAws_restJson1TagResourceCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/tags"; + let body; + body = JSON.stringify({ + ...(input.resourceArn !== undefined && input.resourceArn !== null && { resourceArn: input.resourceArn }), + ...(input.tags !== undefined && + input.tags !== null && { tags: serializeAws_restJson1TagList(input.tags, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1TagResourceCommand = serializeAws_restJson1TagResourceCommand; +const serializeAws_restJson1TestAuthorizationCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/test-authorization"; + const query = { + ...(input.clientId !== undefined && { clientId: input.clientId }), + }; + let body; + body = JSON.stringify({ + ...(input.authInfos !== undefined && + input.authInfos !== null && { authInfos: serializeAws_restJson1AuthInfos(input.authInfos, context) }), + ...(input.cognitoIdentityPoolId !== undefined && + input.cognitoIdentityPoolId !== null && { cognitoIdentityPoolId: input.cognitoIdentityPoolId }), + ...(input.policyNamesToAdd !== undefined && + input.policyNamesToAdd !== null && { + policyNamesToAdd: serializeAws_restJson1PolicyNames(input.policyNamesToAdd, context), + }), + ...(input.policyNamesToSkip !== undefined && + input.policyNamesToSkip !== null && { + policyNamesToSkip: serializeAws_restJson1PolicyNames(input.policyNamesToSkip, context), + }), + ...(input.principal !== undefined && input.principal !== null && { principal: input.principal }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1TestAuthorizationCommand = serializeAws_restJson1TestAuthorizationCommand; +const serializeAws_restJson1TestInvokeAuthorizerCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/authorizer/{authorizerName}/test"; + if (input.authorizerName !== undefined) { + const labelValue = input.authorizerName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: authorizerName."); + } + resolvedPath = resolvedPath.replace("{authorizerName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: authorizerName."); + } + let body; + body = JSON.stringify({ + ...(input.httpContext !== undefined && + input.httpContext !== null && { httpContext: serializeAws_restJson1HttpContext(input.httpContext, context) }), + ...(input.mqttContext !== undefined && + input.mqttContext !== null && { mqttContext: serializeAws_restJson1MqttContext(input.mqttContext, context) }), + ...(input.tlsContext !== undefined && + input.tlsContext !== null && { tlsContext: serializeAws_restJson1TlsContext(input.tlsContext, context) }), + ...(input.token !== undefined && input.token !== null && { token: input.token }), + ...(input.tokenSignature !== undefined && + input.tokenSignature !== null && { tokenSignature: input.tokenSignature }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1TestInvokeAuthorizerCommand = serializeAws_restJson1TestInvokeAuthorizerCommand; +const serializeAws_restJson1TransferCertificateCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/transfer-certificate/{certificateId}"; + if (input.certificateId !== undefined) { + const labelValue = input.certificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: certificateId."); + } + resolvedPath = resolvedPath.replace("{certificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: certificateId."); + } + const query = { + ...(input.targetAwsAccount !== undefined && { targetAwsAccount: input.targetAwsAccount }), + }; + let body; + body = JSON.stringify({ + ...(input.transferMessage !== undefined && + input.transferMessage !== null && { transferMessage: input.transferMessage }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1TransferCertificateCommand = serializeAws_restJson1TransferCertificateCommand; +const serializeAws_restJson1UntagResourceCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/untag"; + let body; + body = JSON.stringify({ + ...(input.resourceArn !== undefined && input.resourceArn !== null && { resourceArn: input.resourceArn }), + ...(input.tagKeys !== undefined && + input.tagKeys !== null && { tagKeys: serializeAws_restJson1TagKeyList(input.tagKeys, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UntagResourceCommand = serializeAws_restJson1UntagResourceCommand; +const serializeAws_restJson1UpdateAccountAuditConfigurationCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/configuration"; + let body; + body = JSON.stringify({ + ...(input.auditCheckConfigurations !== undefined && + input.auditCheckConfigurations !== null && { + auditCheckConfigurations: serializeAws_restJson1AuditCheckConfigurations(input.auditCheckConfigurations, context), + }), + ...(input.auditNotificationTargetConfigurations !== undefined && + input.auditNotificationTargetConfigurations !== null && { + auditNotificationTargetConfigurations: serializeAws_restJson1AuditNotificationTargetConfigurations(input.auditNotificationTargetConfigurations, context), + }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateAccountAuditConfigurationCommand = serializeAws_restJson1UpdateAccountAuditConfigurationCommand; +const serializeAws_restJson1UpdateAuditSuppressionCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/suppressions/update"; + let body; + body = JSON.stringify({ + ...(input.checkName !== undefined && input.checkName !== null && { checkName: input.checkName }), + ...(input.description !== undefined && input.description !== null && { description: input.description }), + ...(input.expirationDate !== undefined && + input.expirationDate !== null && { expirationDate: Math.round(input.expirationDate.getTime() / 1000) }), + ...(input.resourceIdentifier !== undefined && + input.resourceIdentifier !== null && { + resourceIdentifier: serializeAws_restJson1ResourceIdentifier(input.resourceIdentifier, context), + }), + ...(input.suppressIndefinitely !== undefined && + input.suppressIndefinitely !== null && { suppressIndefinitely: input.suppressIndefinitely }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateAuditSuppressionCommand = serializeAws_restJson1UpdateAuditSuppressionCommand; +const serializeAws_restJson1UpdateAuthorizerCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/authorizer/{authorizerName}"; + if (input.authorizerName !== undefined) { + const labelValue = input.authorizerName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: authorizerName."); + } + resolvedPath = resolvedPath.replace("{authorizerName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: authorizerName."); + } + let body; + body = JSON.stringify({ + ...(input.authorizerFunctionArn !== undefined && + input.authorizerFunctionArn !== null && { authorizerFunctionArn: input.authorizerFunctionArn }), + ...(input.status !== undefined && input.status !== null && { status: input.status }), + ...(input.tokenKeyName !== undefined && input.tokenKeyName !== null && { tokenKeyName: input.tokenKeyName }), + ...(input.tokenSigningPublicKeys !== undefined && + input.tokenSigningPublicKeys !== null && { + tokenSigningPublicKeys: serializeAws_restJson1PublicKeyMap(input.tokenSigningPublicKeys, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateAuthorizerCommand = serializeAws_restJson1UpdateAuthorizerCommand; +const serializeAws_restJson1UpdateBillingGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/billing-groups/{billingGroupName}"; + if (input.billingGroupName !== undefined) { + const labelValue = input.billingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: billingGroupName."); + } + resolvedPath = resolvedPath.replace("{billingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: billingGroupName."); + } + let body; + body = JSON.stringify({ + ...(input.billingGroupProperties !== undefined && + input.billingGroupProperties !== null && { + billingGroupProperties: serializeAws_restJson1BillingGroupProperties(input.billingGroupProperties, context), + }), + ...(input.expectedVersion !== undefined && + input.expectedVersion !== null && { expectedVersion: input.expectedVersion }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateBillingGroupCommand = serializeAws_restJson1UpdateBillingGroupCommand; +const serializeAws_restJson1UpdateCACertificateCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/cacertificate/{certificateId}"; + if (input.certificateId !== undefined) { + const labelValue = input.certificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: certificateId."); + } + resolvedPath = resolvedPath.replace("{certificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: certificateId."); + } + const query = { + ...(input.newStatus !== undefined && { newStatus: input.newStatus }), + ...(input.newAutoRegistrationStatus !== undefined && { + newAutoRegistrationStatus: input.newAutoRegistrationStatus, + }), + }; + let body; + body = JSON.stringify({ + ...(input.registrationConfig !== undefined && + input.registrationConfig !== null && { + registrationConfig: serializeAws_restJson1RegistrationConfig(input.registrationConfig, context), + }), + ...(input.removeAutoRegistration !== undefined && + input.removeAutoRegistration !== null && { removeAutoRegistration: input.removeAutoRegistration }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1UpdateCACertificateCommand = serializeAws_restJson1UpdateCACertificateCommand; +const serializeAws_restJson1UpdateCertificateCommand = async (input, context) => { + const headers = {}; + let resolvedPath = "/certificates/{certificateId}"; + if (input.certificateId !== undefined) { + const labelValue = input.certificateId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: certificateId."); + } + resolvedPath = resolvedPath.replace("{certificateId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: certificateId."); + } + const query = { + ...(input.newStatus !== undefined && { newStatus: input.newStatus }), + }; + let body; + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1UpdateCertificateCommand = serializeAws_restJson1UpdateCertificateCommand; +const serializeAws_restJson1UpdateDimensionCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/dimensions/{name}"; + if (input.name !== undefined) { + const labelValue = input.name; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: name."); + } + resolvedPath = resolvedPath.replace("{name}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: name."); + } + let body; + body = JSON.stringify({ + ...(input.stringValues !== undefined && + input.stringValues !== null && { + stringValues: serializeAws_restJson1DimensionStringValues(input.stringValues, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateDimensionCommand = serializeAws_restJson1UpdateDimensionCommand; +const serializeAws_restJson1UpdateDomainConfigurationCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/domainConfigurations/{domainConfigurationName}"; + if (input.domainConfigurationName !== undefined) { + const labelValue = input.domainConfigurationName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: domainConfigurationName."); + } + resolvedPath = resolvedPath.replace("{domainConfigurationName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: domainConfigurationName."); + } + let body; + body = JSON.stringify({ + ...(input.authorizerConfig !== undefined && + input.authorizerConfig !== null && { + authorizerConfig: serializeAws_restJson1AuthorizerConfig(input.authorizerConfig, context), + }), + ...(input.domainConfigurationStatus !== undefined && + input.domainConfigurationStatus !== null && { domainConfigurationStatus: input.domainConfigurationStatus }), + ...(input.removeAuthorizerConfig !== undefined && + input.removeAuthorizerConfig !== null && { removeAuthorizerConfig: input.removeAuthorizerConfig }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateDomainConfigurationCommand = serializeAws_restJson1UpdateDomainConfigurationCommand; +const serializeAws_restJson1UpdateDynamicThingGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/dynamic-thing-groups/{thingGroupName}"; + if (input.thingGroupName !== undefined) { + const labelValue = input.thingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingGroupName."); + } + resolvedPath = resolvedPath.replace("{thingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingGroupName."); + } + let body; + body = JSON.stringify({ + ...(input.expectedVersion !== undefined && + input.expectedVersion !== null && { expectedVersion: input.expectedVersion }), + ...(input.indexName !== undefined && input.indexName !== null && { indexName: input.indexName }), + ...(input.queryString !== undefined && input.queryString !== null && { queryString: input.queryString }), + ...(input.queryVersion !== undefined && input.queryVersion !== null && { queryVersion: input.queryVersion }), + ...(input.thingGroupProperties !== undefined && + input.thingGroupProperties !== null && { + thingGroupProperties: serializeAws_restJson1ThingGroupProperties(input.thingGroupProperties, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateDynamicThingGroupCommand = serializeAws_restJson1UpdateDynamicThingGroupCommand; +const serializeAws_restJson1UpdateEventConfigurationsCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/event-configurations"; + let body; + body = JSON.stringify({ + ...(input.eventConfigurations !== undefined && + input.eventConfigurations !== null && { + eventConfigurations: serializeAws_restJson1EventConfigurations(input.eventConfigurations, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateEventConfigurationsCommand = serializeAws_restJson1UpdateEventConfigurationsCommand; +const serializeAws_restJson1UpdateIndexingConfigurationCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/indexing/config"; + let body; + body = JSON.stringify({ + ...(input.thingGroupIndexingConfiguration !== undefined && + input.thingGroupIndexingConfiguration !== null && { + thingGroupIndexingConfiguration: serializeAws_restJson1ThingGroupIndexingConfiguration(input.thingGroupIndexingConfiguration, context), + }), + ...(input.thingIndexingConfiguration !== undefined && + input.thingIndexingConfiguration !== null && { + thingIndexingConfiguration: serializeAws_restJson1ThingIndexingConfiguration(input.thingIndexingConfiguration, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateIndexingConfigurationCommand = serializeAws_restJson1UpdateIndexingConfigurationCommand; +const serializeAws_restJson1UpdateJobCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/jobs/{jobId}"; + if (input.jobId !== undefined) { + const labelValue = input.jobId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: jobId."); + } + resolvedPath = resolvedPath.replace("{jobId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: jobId."); + } + const query = { + ...(input.namespaceId !== undefined && { namespaceId: input.namespaceId }), + }; + let body; + body = JSON.stringify({ + ...(input.abortConfig !== undefined && + input.abortConfig !== null && { abortConfig: serializeAws_restJson1AbortConfig(input.abortConfig, context) }), + ...(input.description !== undefined && input.description !== null && { description: input.description }), + ...(input.jobExecutionsRolloutConfig !== undefined && + input.jobExecutionsRolloutConfig !== null && { + jobExecutionsRolloutConfig: serializeAws_restJson1JobExecutionsRolloutConfig(input.jobExecutionsRolloutConfig, context), + }), + ...(input.presignedUrlConfig !== undefined && + input.presignedUrlConfig !== null && { + presignedUrlConfig: serializeAws_restJson1PresignedUrlConfig(input.presignedUrlConfig, context), + }), + ...(input.timeoutConfig !== undefined && + input.timeoutConfig !== null && { + timeoutConfig: serializeAws_restJson1TimeoutConfig(input.timeoutConfig, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1UpdateJobCommand = serializeAws_restJson1UpdateJobCommand; +const serializeAws_restJson1UpdateMitigationActionCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/mitigationactions/actions/{actionName}"; + if (input.actionName !== undefined) { + const labelValue = input.actionName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: actionName."); + } + resolvedPath = resolvedPath.replace("{actionName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: actionName."); + } + let body; + body = JSON.stringify({ + ...(input.actionParams !== undefined && + input.actionParams !== null && { + actionParams: serializeAws_restJson1MitigationActionParams(input.actionParams, context), + }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateMitigationActionCommand = serializeAws_restJson1UpdateMitigationActionCommand; +const serializeAws_restJson1UpdateProvisioningTemplateCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/provisioning-templates/{templateName}"; + if (input.templateName !== undefined) { + const labelValue = input.templateName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: templateName."); + } + resolvedPath = resolvedPath.replace("{templateName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: templateName."); + } + let body; + body = JSON.stringify({ + ...(input.defaultVersionId !== undefined && + input.defaultVersionId !== null && { defaultVersionId: input.defaultVersionId }), + ...(input.description !== undefined && input.description !== null && { description: input.description }), + ...(input.enabled !== undefined && input.enabled !== null && { enabled: input.enabled }), + ...(input.preProvisioningHook !== undefined && + input.preProvisioningHook !== null && { + preProvisioningHook: serializeAws_restJson1ProvisioningHook(input.preProvisioningHook, context), + }), + ...(input.provisioningRoleArn !== undefined && + input.provisioningRoleArn !== null && { provisioningRoleArn: input.provisioningRoleArn }), + ...(input.removePreProvisioningHook !== undefined && + input.removePreProvisioningHook !== null && { removePreProvisioningHook: input.removePreProvisioningHook }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateProvisioningTemplateCommand = serializeAws_restJson1UpdateProvisioningTemplateCommand; +const serializeAws_restJson1UpdateRoleAliasCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/role-aliases/{roleAlias}"; + if (input.roleAlias !== undefined) { + const labelValue = input.roleAlias; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: roleAlias."); + } + resolvedPath = resolvedPath.replace("{roleAlias}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: roleAlias."); + } + let body; + body = JSON.stringify({ + ...(input.credentialDurationSeconds !== undefined && + input.credentialDurationSeconds !== null && { credentialDurationSeconds: input.credentialDurationSeconds }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateRoleAliasCommand = serializeAws_restJson1UpdateRoleAliasCommand; +const serializeAws_restJson1UpdateScheduledAuditCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/audit/scheduledaudits/{scheduledAuditName}"; + if (input.scheduledAuditName !== undefined) { + const labelValue = input.scheduledAuditName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: scheduledAuditName."); + } + resolvedPath = resolvedPath.replace("{scheduledAuditName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: scheduledAuditName."); + } + let body; + body = JSON.stringify({ + ...(input.dayOfMonth !== undefined && input.dayOfMonth !== null && { dayOfMonth: input.dayOfMonth }), + ...(input.dayOfWeek !== undefined && input.dayOfWeek !== null && { dayOfWeek: input.dayOfWeek }), + ...(input.frequency !== undefined && input.frequency !== null && { frequency: input.frequency }), + ...(input.targetCheckNames !== undefined && + input.targetCheckNames !== null && { + targetCheckNames: serializeAws_restJson1TargetAuditCheckNames(input.targetCheckNames, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateScheduledAuditCommand = serializeAws_restJson1UpdateScheduledAuditCommand; +const serializeAws_restJson1UpdateSecurityProfileCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/security-profiles/{securityProfileName}"; + if (input.securityProfileName !== undefined) { + const labelValue = input.securityProfileName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: securityProfileName."); + } + resolvedPath = resolvedPath.replace("{securityProfileName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: securityProfileName."); + } + const query = { + ...(input.expectedVersion !== undefined && { expectedVersion: input.expectedVersion.toString() }), + }; + let body; + body = JSON.stringify({ + ...(input.additionalMetricsToRetain !== undefined && + input.additionalMetricsToRetain !== null && { + additionalMetricsToRetain: serializeAws_restJson1AdditionalMetricsToRetainList(input.additionalMetricsToRetain, context), + }), + ...(input.additionalMetricsToRetainV2 !== undefined && + input.additionalMetricsToRetainV2 !== null && { + additionalMetricsToRetainV2: serializeAws_restJson1AdditionalMetricsToRetainV2List(input.additionalMetricsToRetainV2, context), + }), + ...(input.alertTargets !== undefined && + input.alertTargets !== null && { alertTargets: serializeAws_restJson1AlertTargets(input.alertTargets, context) }), + ...(input.behaviors !== undefined && + input.behaviors !== null && { behaviors: serializeAws_restJson1Behaviors(input.behaviors, context) }), + ...(input.deleteAdditionalMetricsToRetain !== undefined && + input.deleteAdditionalMetricsToRetain !== null && { + deleteAdditionalMetricsToRetain: input.deleteAdditionalMetricsToRetain, + }), + ...(input.deleteAlertTargets !== undefined && + input.deleteAlertTargets !== null && { deleteAlertTargets: input.deleteAlertTargets }), + ...(input.deleteBehaviors !== undefined && + input.deleteBehaviors !== null && { deleteBehaviors: input.deleteBehaviors }), + ...(input.securityProfileDescription !== undefined && + input.securityProfileDescription !== null && { securityProfileDescription: input.securityProfileDescription }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + query, + body, + }); +}; +exports.serializeAws_restJson1UpdateSecurityProfileCommand = serializeAws_restJson1UpdateSecurityProfileCommand; +const serializeAws_restJson1UpdateStreamCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/streams/{streamId}"; + if (input.streamId !== undefined) { + const labelValue = input.streamId; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: streamId."); + } + resolvedPath = resolvedPath.replace("{streamId}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: streamId."); + } + let body; + body = JSON.stringify({ + ...(input.description !== undefined && input.description !== null && { description: input.description }), + ...(input.files !== undefined && + input.files !== null && { files: serializeAws_restJson1StreamFiles(input.files, context) }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateStreamCommand = serializeAws_restJson1UpdateStreamCommand; +const serializeAws_restJson1UpdateThingCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/things/{thingName}"; + if (input.thingName !== undefined) { + const labelValue = input.thingName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingName."); + } + resolvedPath = resolvedPath.replace("{thingName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingName."); + } + let body; + body = JSON.stringify({ + ...(input.attributePayload !== undefined && + input.attributePayload !== null && { + attributePayload: serializeAws_restJson1AttributePayload(input.attributePayload, context), + }), + ...(input.expectedVersion !== undefined && + input.expectedVersion !== null && { expectedVersion: input.expectedVersion }), + ...(input.removeThingType !== undefined && + input.removeThingType !== null && { removeThingType: input.removeThingType }), + ...(input.thingTypeName !== undefined && input.thingTypeName !== null && { thingTypeName: input.thingTypeName }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateThingCommand = serializeAws_restJson1UpdateThingCommand; +const serializeAws_restJson1UpdateThingGroupCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/thing-groups/{thingGroupName}"; + if (input.thingGroupName !== undefined) { + const labelValue = input.thingGroupName; + if (labelValue.length <= 0) { + throw new Error("Empty value provided for input HTTP label: thingGroupName."); + } + resolvedPath = resolvedPath.replace("{thingGroupName}", smithy_client_1.extendedEncodeURIComponent(labelValue)); + } + else { + throw new Error("No value provided for input HTTP label: thingGroupName."); + } + let body; + body = JSON.stringify({ + ...(input.expectedVersion !== undefined && + input.expectedVersion !== null && { expectedVersion: input.expectedVersion }), + ...(input.thingGroupProperties !== undefined && + input.thingGroupProperties !== null && { + thingGroupProperties: serializeAws_restJson1ThingGroupProperties(input.thingGroupProperties, context), + }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateThingGroupCommand = serializeAws_restJson1UpdateThingGroupCommand; +const serializeAws_restJson1UpdateThingGroupsForThingCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/thing-groups/updateThingGroupsForThing"; + let body; + body = JSON.stringify({ + ...(input.overrideDynamicGroups !== undefined && + input.overrideDynamicGroups !== null && { overrideDynamicGroups: input.overrideDynamicGroups }), + ...(input.thingGroupsToAdd !== undefined && + input.thingGroupsToAdd !== null && { + thingGroupsToAdd: serializeAws_restJson1ThingGroupList(input.thingGroupsToAdd, context), + }), + ...(input.thingGroupsToRemove !== undefined && + input.thingGroupsToRemove !== null && { + thingGroupsToRemove: serializeAws_restJson1ThingGroupList(input.thingGroupsToRemove, context), + }), + ...(input.thingName !== undefined && input.thingName !== null && { thingName: input.thingName }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PUT", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateThingGroupsForThingCommand = serializeAws_restJson1UpdateThingGroupsForThingCommand; +const serializeAws_restJson1UpdateTopicRuleDestinationCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/destinations"; + let body; + body = JSON.stringify({ + ...(input.arn !== undefined && input.arn !== null && { arn: input.arn }), + ...(input.status !== undefined && input.status !== null && { status: input.status }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "PATCH", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1UpdateTopicRuleDestinationCommand = serializeAws_restJson1UpdateTopicRuleDestinationCommand; +const serializeAws_restJson1ValidateSecurityProfileBehaviorsCommand = async (input, context) => { + const headers = { + "content-type": "application/json", + }; + let resolvedPath = "/security-profile-behaviors/validate"; + let body; + body = JSON.stringify({ + ...(input.behaviors !== undefined && + input.behaviors !== null && { behaviors: serializeAws_restJson1Behaviors(input.behaviors, context) }), + }); + const { hostname, protocol = "https", port } = await context.endpoint(); + return new protocol_http_1.HttpRequest({ + protocol, + hostname, + port, + method: "POST", + headers, + path: resolvedPath, + body, + }); +}; +exports.serializeAws_restJson1ValidateSecurityProfileBehaviorsCommand = serializeAws_restJson1ValidateSecurityProfileBehaviorsCommand; +const deserializeAws_restJson1AcceptCertificateTransferCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1AcceptCertificateTransferCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1AcceptCertificateTransferCommand = deserializeAws_restJson1AcceptCertificateTransferCommand; +const deserializeAws_restJson1AcceptCertificateTransferCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TransferAlreadyCompletedException": + case "com.amazonaws.iot#TransferAlreadyCompletedException": + response = { + ...(await deserializeAws_restJson1TransferAlreadyCompletedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1AddThingToBillingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1AddThingToBillingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1AddThingToBillingGroupCommand = deserializeAws_restJson1AddThingToBillingGroupCommand; +const deserializeAws_restJson1AddThingToBillingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1AddThingToThingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1AddThingToThingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1AddThingToThingGroupCommand = deserializeAws_restJson1AddThingToThingGroupCommand; +const deserializeAws_restJson1AddThingToThingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1AssociateTargetsWithJobCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1AssociateTargetsWithJobCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + description: undefined, + jobArn: undefined, + jobId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.description !== undefined && data.description !== null) { + contents.description = data.description; + } + if (data.jobArn !== undefined && data.jobArn !== null) { + contents.jobArn = data.jobArn; + } + if (data.jobId !== undefined && data.jobId !== null) { + contents.jobId = data.jobId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1AssociateTargetsWithJobCommand = deserializeAws_restJson1AssociateTargetsWithJobCommand; +const deserializeAws_restJson1AssociateTargetsWithJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1AttachPolicyCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1AttachPolicyCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1AttachPolicyCommand = deserializeAws_restJson1AttachPolicyCommand; +const deserializeAws_restJson1AttachPolicyCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1AttachPrincipalPolicyCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1AttachPrincipalPolicyCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1AttachPrincipalPolicyCommand = deserializeAws_restJson1AttachPrincipalPolicyCommand; +const deserializeAws_restJson1AttachPrincipalPolicyCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1AttachSecurityProfileCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1AttachSecurityProfileCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1AttachSecurityProfileCommand = deserializeAws_restJson1AttachSecurityProfileCommand; +const deserializeAws_restJson1AttachSecurityProfileCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1AttachThingPrincipalCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1AttachThingPrincipalCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1AttachThingPrincipalCommand = deserializeAws_restJson1AttachThingPrincipalCommand; +const deserializeAws_restJson1AttachThingPrincipalCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CancelAuditMitigationActionsTaskCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CancelAuditMitigationActionsTaskCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CancelAuditMitigationActionsTaskCommand = deserializeAws_restJson1CancelAuditMitigationActionsTaskCommand; +const deserializeAws_restJson1CancelAuditMitigationActionsTaskCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CancelAuditTaskCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CancelAuditTaskCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CancelAuditTaskCommand = deserializeAws_restJson1CancelAuditTaskCommand; +const deserializeAws_restJson1CancelAuditTaskCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CancelCertificateTransferCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CancelCertificateTransferCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CancelCertificateTransferCommand = deserializeAws_restJson1CancelCertificateTransferCommand; +const deserializeAws_restJson1CancelCertificateTransferCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TransferAlreadyCompletedException": + case "com.amazonaws.iot#TransferAlreadyCompletedException": + response = { + ...(await deserializeAws_restJson1TransferAlreadyCompletedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CancelJobCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CancelJobCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + description: undefined, + jobArn: undefined, + jobId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.description !== undefined && data.description !== null) { + contents.description = data.description; + } + if (data.jobArn !== undefined && data.jobArn !== null) { + contents.jobArn = data.jobArn; + } + if (data.jobId !== undefined && data.jobId !== null) { + contents.jobId = data.jobId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CancelJobCommand = deserializeAws_restJson1CancelJobCommand; +const deserializeAws_restJson1CancelJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CancelJobExecutionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CancelJobExecutionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CancelJobExecutionCommand = deserializeAws_restJson1CancelJobExecutionCommand; +const deserializeAws_restJson1CancelJobExecutionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidStateTransitionException": + case "com.amazonaws.iot#InvalidStateTransitionException": + response = { + ...(await deserializeAws_restJson1InvalidStateTransitionExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ClearDefaultAuthorizerCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ClearDefaultAuthorizerCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ClearDefaultAuthorizerCommand = deserializeAws_restJson1ClearDefaultAuthorizerCommand; +const deserializeAws_restJson1ClearDefaultAuthorizerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ConfirmTopicRuleDestinationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ConfirmTopicRuleDestinationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ConfirmTopicRuleDestinationCommand = deserializeAws_restJson1ConfirmTopicRuleDestinationCommand; +const deserializeAws_restJson1ConfirmTopicRuleDestinationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateAuditSuppressionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateAuditSuppressionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateAuditSuppressionCommand = deserializeAws_restJson1CreateAuditSuppressionCommand; +const deserializeAws_restJson1CreateAuditSuppressionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateAuthorizerCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateAuthorizerCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + authorizerArn: undefined, + authorizerName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.authorizerArn !== undefined && data.authorizerArn !== null) { + contents.authorizerArn = data.authorizerArn; + } + if (data.authorizerName !== undefined && data.authorizerName !== null) { + contents.authorizerName = data.authorizerName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateAuthorizerCommand = deserializeAws_restJson1CreateAuthorizerCommand; +const deserializeAws_restJson1CreateAuthorizerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateBillingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateBillingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + billingGroupArn: undefined, + billingGroupId: undefined, + billingGroupName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.billingGroupArn !== undefined && data.billingGroupArn !== null) { + contents.billingGroupArn = data.billingGroupArn; + } + if (data.billingGroupId !== undefined && data.billingGroupId !== null) { + contents.billingGroupId = data.billingGroupId; + } + if (data.billingGroupName !== undefined && data.billingGroupName !== null) { + contents.billingGroupName = data.billingGroupName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateBillingGroupCommand = deserializeAws_restJson1CreateBillingGroupCommand; +const deserializeAws_restJson1CreateBillingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateCertificateFromCsrCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateCertificateFromCsrCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificateArn: undefined, + certificateId: undefined, + certificatePem: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificateArn !== undefined && data.certificateArn !== null) { + contents.certificateArn = data.certificateArn; + } + if (data.certificateId !== undefined && data.certificateId !== null) { + contents.certificateId = data.certificateId; + } + if (data.certificatePem !== undefined && data.certificatePem !== null) { + contents.certificatePem = data.certificatePem; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateCertificateFromCsrCommand = deserializeAws_restJson1CreateCertificateFromCsrCommand; +const deserializeAws_restJson1CreateCertificateFromCsrCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateDimensionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateDimensionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + arn: undefined, + name: undefined, + }; + const data = await parseBody(output.body, context); + if (data.arn !== undefined && data.arn !== null) { + contents.arn = data.arn; + } + if (data.name !== undefined && data.name !== null) { + contents.name = data.name; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateDimensionCommand = deserializeAws_restJson1CreateDimensionCommand; +const deserializeAws_restJson1CreateDimensionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateDomainConfigurationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateDomainConfigurationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + domainConfigurationArn: undefined, + domainConfigurationName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.domainConfigurationArn !== undefined && data.domainConfigurationArn !== null) { + contents.domainConfigurationArn = data.domainConfigurationArn; + } + if (data.domainConfigurationName !== undefined && data.domainConfigurationName !== null) { + contents.domainConfigurationName = data.domainConfigurationName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateDomainConfigurationCommand = deserializeAws_restJson1CreateDomainConfigurationCommand; +const deserializeAws_restJson1CreateDomainConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CertificateValidationException": + case "com.amazonaws.iot#CertificateValidationException": + response = { + ...(await deserializeAws_restJson1CertificateValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateDynamicThingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateDynamicThingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + indexName: undefined, + queryString: undefined, + queryVersion: undefined, + thingGroupArn: undefined, + thingGroupId: undefined, + thingGroupName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.indexName !== undefined && data.indexName !== null) { + contents.indexName = data.indexName; + } + if (data.queryString !== undefined && data.queryString !== null) { + contents.queryString = data.queryString; + } + if (data.queryVersion !== undefined && data.queryVersion !== null) { + contents.queryVersion = data.queryVersion; + } + if (data.thingGroupArn !== undefined && data.thingGroupArn !== null) { + contents.thingGroupArn = data.thingGroupArn; + } + if (data.thingGroupId !== undefined && data.thingGroupId !== null) { + contents.thingGroupId = data.thingGroupId; + } + if (data.thingGroupName !== undefined && data.thingGroupName !== null) { + contents.thingGroupName = data.thingGroupName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateDynamicThingGroupCommand = deserializeAws_restJson1CreateDynamicThingGroupCommand; +const deserializeAws_restJson1CreateDynamicThingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidQueryException": + case "com.amazonaws.iot#InvalidQueryException": + response = { + ...(await deserializeAws_restJson1InvalidQueryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateJobCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateJobCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + description: undefined, + jobArn: undefined, + jobId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.description !== undefined && data.description !== null) { + contents.description = data.description; + } + if (data.jobArn !== undefined && data.jobArn !== null) { + contents.jobArn = data.jobArn; + } + if (data.jobId !== undefined && data.jobId !== null) { + contents.jobId = data.jobId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateJobCommand = deserializeAws_restJson1CreateJobCommand; +const deserializeAws_restJson1CreateJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateKeysAndCertificateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateKeysAndCertificateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificateArn: undefined, + certificateId: undefined, + certificatePem: undefined, + keyPair: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificateArn !== undefined && data.certificateArn !== null) { + contents.certificateArn = data.certificateArn; + } + if (data.certificateId !== undefined && data.certificateId !== null) { + contents.certificateId = data.certificateId; + } + if (data.certificatePem !== undefined && data.certificatePem !== null) { + contents.certificatePem = data.certificatePem; + } + if (data.keyPair !== undefined && data.keyPair !== null) { + contents.keyPair = deserializeAws_restJson1KeyPair(data.keyPair, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateKeysAndCertificateCommand = deserializeAws_restJson1CreateKeysAndCertificateCommand; +const deserializeAws_restJson1CreateKeysAndCertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateMitigationActionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateMitigationActionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + actionArn: undefined, + actionId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.actionArn !== undefined && data.actionArn !== null) { + contents.actionArn = data.actionArn; + } + if (data.actionId !== undefined && data.actionId !== null) { + contents.actionId = data.actionId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateMitigationActionCommand = deserializeAws_restJson1CreateMitigationActionCommand; +const deserializeAws_restJson1CreateMitigationActionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateOTAUpdateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateOTAUpdateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + awsIotJobArn: undefined, + awsIotJobId: undefined, + otaUpdateArn: undefined, + otaUpdateId: undefined, + otaUpdateStatus: undefined, + }; + const data = await parseBody(output.body, context); + if (data.awsIotJobArn !== undefined && data.awsIotJobArn !== null) { + contents.awsIotJobArn = data.awsIotJobArn; + } + if (data.awsIotJobId !== undefined && data.awsIotJobId !== null) { + contents.awsIotJobId = data.awsIotJobId; + } + if (data.otaUpdateArn !== undefined && data.otaUpdateArn !== null) { + contents.otaUpdateArn = data.otaUpdateArn; + } + if (data.otaUpdateId !== undefined && data.otaUpdateId !== null) { + contents.otaUpdateId = data.otaUpdateId; + } + if (data.otaUpdateStatus !== undefined && data.otaUpdateStatus !== null) { + contents.otaUpdateStatus = data.otaUpdateStatus; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateOTAUpdateCommand = deserializeAws_restJson1CreateOTAUpdateCommand; +const deserializeAws_restJson1CreateOTAUpdateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreatePolicyCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreatePolicyCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + policyArn: undefined, + policyDocument: undefined, + policyName: undefined, + policyVersionId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.policyArn !== undefined && data.policyArn !== null) { + contents.policyArn = data.policyArn; + } + if (data.policyDocument !== undefined && data.policyDocument !== null) { + contents.policyDocument = data.policyDocument; + } + if (data.policyName !== undefined && data.policyName !== null) { + contents.policyName = data.policyName; + } + if (data.policyVersionId !== undefined && data.policyVersionId !== null) { + contents.policyVersionId = data.policyVersionId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreatePolicyCommand = deserializeAws_restJson1CreatePolicyCommand; +const deserializeAws_restJson1CreatePolicyCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "MalformedPolicyException": + case "com.amazonaws.iot#MalformedPolicyException": + response = { + ...(await deserializeAws_restJson1MalformedPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreatePolicyVersionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreatePolicyVersionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + isDefaultVersion: undefined, + policyArn: undefined, + policyDocument: undefined, + policyVersionId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.isDefaultVersion !== undefined && data.isDefaultVersion !== null) { + contents.isDefaultVersion = data.isDefaultVersion; + } + if (data.policyArn !== undefined && data.policyArn !== null) { + contents.policyArn = data.policyArn; + } + if (data.policyDocument !== undefined && data.policyDocument !== null) { + contents.policyDocument = data.policyDocument; + } + if (data.policyVersionId !== undefined && data.policyVersionId !== null) { + contents.policyVersionId = data.policyVersionId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreatePolicyVersionCommand = deserializeAws_restJson1CreatePolicyVersionCommand; +const deserializeAws_restJson1CreatePolicyVersionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "MalformedPolicyException": + case "com.amazonaws.iot#MalformedPolicyException": + response = { + ...(await deserializeAws_restJson1MalformedPolicyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionsLimitExceededException": + case "com.amazonaws.iot#VersionsLimitExceededException": + response = { + ...(await deserializeAws_restJson1VersionsLimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateProvisioningClaimCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateProvisioningClaimCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificateId: undefined, + certificatePem: undefined, + expiration: undefined, + keyPair: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificateId !== undefined && data.certificateId !== null) { + contents.certificateId = data.certificateId; + } + if (data.certificatePem !== undefined && data.certificatePem !== null) { + contents.certificatePem = data.certificatePem; + } + if (data.expiration !== undefined && data.expiration !== null) { + contents.expiration = new Date(Math.round(data.expiration * 1000)); + } + if (data.keyPair !== undefined && data.keyPair !== null) { + contents.keyPair = deserializeAws_restJson1KeyPair(data.keyPair, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateProvisioningClaimCommand = deserializeAws_restJson1CreateProvisioningClaimCommand; +const deserializeAws_restJson1CreateProvisioningClaimCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateProvisioningTemplateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateProvisioningTemplateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + defaultVersionId: undefined, + templateArn: undefined, + templateName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.defaultVersionId !== undefined && data.defaultVersionId !== null) { + contents.defaultVersionId = data.defaultVersionId; + } + if (data.templateArn !== undefined && data.templateArn !== null) { + contents.templateArn = data.templateArn; + } + if (data.templateName !== undefined && data.templateName !== null) { + contents.templateName = data.templateName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateProvisioningTemplateCommand = deserializeAws_restJson1CreateProvisioningTemplateCommand; +const deserializeAws_restJson1CreateProvisioningTemplateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateProvisioningTemplateVersionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateProvisioningTemplateVersionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + isDefaultVersion: undefined, + templateArn: undefined, + templateName: undefined, + versionId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.isDefaultVersion !== undefined && data.isDefaultVersion !== null) { + contents.isDefaultVersion = data.isDefaultVersion; + } + if (data.templateArn !== undefined && data.templateArn !== null) { + contents.templateArn = data.templateArn; + } + if (data.templateName !== undefined && data.templateName !== null) { + contents.templateName = data.templateName; + } + if (data.versionId !== undefined && data.versionId !== null) { + contents.versionId = data.versionId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateProvisioningTemplateVersionCommand = deserializeAws_restJson1CreateProvisioningTemplateVersionCommand; +const deserializeAws_restJson1CreateProvisioningTemplateVersionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionsLimitExceededException": + case "com.amazonaws.iot#VersionsLimitExceededException": + response = { + ...(await deserializeAws_restJson1VersionsLimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateRoleAliasCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateRoleAliasCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + roleAlias: undefined, + roleAliasArn: undefined, + }; + const data = await parseBody(output.body, context); + if (data.roleAlias !== undefined && data.roleAlias !== null) { + contents.roleAlias = data.roleAlias; + } + if (data.roleAliasArn !== undefined && data.roleAliasArn !== null) { + contents.roleAliasArn = data.roleAliasArn; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateRoleAliasCommand = deserializeAws_restJson1CreateRoleAliasCommand; +const deserializeAws_restJson1CreateRoleAliasCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateScheduledAuditCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateScheduledAuditCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + scheduledAuditArn: undefined, + }; + const data = await parseBody(output.body, context); + if (data.scheduledAuditArn !== undefined && data.scheduledAuditArn !== null) { + contents.scheduledAuditArn = data.scheduledAuditArn; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateScheduledAuditCommand = deserializeAws_restJson1CreateScheduledAuditCommand; +const deserializeAws_restJson1CreateScheduledAuditCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateSecurityProfileCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateSecurityProfileCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + securityProfileArn: undefined, + securityProfileName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.securityProfileArn !== undefined && data.securityProfileArn !== null) { + contents.securityProfileArn = data.securityProfileArn; + } + if (data.securityProfileName !== undefined && data.securityProfileName !== null) { + contents.securityProfileName = data.securityProfileName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateSecurityProfileCommand = deserializeAws_restJson1CreateSecurityProfileCommand; +const deserializeAws_restJson1CreateSecurityProfileCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateStreamCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateStreamCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + description: undefined, + streamArn: undefined, + streamId: undefined, + streamVersion: undefined, + }; + const data = await parseBody(output.body, context); + if (data.description !== undefined && data.description !== null) { + contents.description = data.description; + } + if (data.streamArn !== undefined && data.streamArn !== null) { + contents.streamArn = data.streamArn; + } + if (data.streamId !== undefined && data.streamId !== null) { + contents.streamId = data.streamId; + } + if (data.streamVersion !== undefined && data.streamVersion !== null) { + contents.streamVersion = data.streamVersion; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateStreamCommand = deserializeAws_restJson1CreateStreamCommand; +const deserializeAws_restJson1CreateStreamCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateThingCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateThingCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + thingArn: undefined, + thingId: undefined, + thingName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.thingArn !== undefined && data.thingArn !== null) { + contents.thingArn = data.thingArn; + } + if (data.thingId !== undefined && data.thingId !== null) { + contents.thingId = data.thingId; + } + if (data.thingName !== undefined && data.thingName !== null) { + contents.thingName = data.thingName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateThingCommand = deserializeAws_restJson1CreateThingCommand; +const deserializeAws_restJson1CreateThingCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateThingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateThingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + thingGroupArn: undefined, + thingGroupId: undefined, + thingGroupName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.thingGroupArn !== undefined && data.thingGroupArn !== null) { + contents.thingGroupArn = data.thingGroupArn; + } + if (data.thingGroupId !== undefined && data.thingGroupId !== null) { + contents.thingGroupId = data.thingGroupId; + } + if (data.thingGroupName !== undefined && data.thingGroupName !== null) { + contents.thingGroupName = data.thingGroupName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateThingGroupCommand = deserializeAws_restJson1CreateThingGroupCommand; +const deserializeAws_restJson1CreateThingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateThingTypeCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateThingTypeCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + thingTypeArn: undefined, + thingTypeId: undefined, + thingTypeName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.thingTypeArn !== undefined && data.thingTypeArn !== null) { + contents.thingTypeArn = data.thingTypeArn; + } + if (data.thingTypeId !== undefined && data.thingTypeId !== null) { + contents.thingTypeId = data.thingTypeId; + } + if (data.thingTypeName !== undefined && data.thingTypeName !== null) { + contents.thingTypeName = data.thingTypeName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateThingTypeCommand = deserializeAws_restJson1CreateThingTypeCommand; +const deserializeAws_restJson1CreateThingTypeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateTopicRuleCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateTopicRuleCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateTopicRuleCommand = deserializeAws_restJson1CreateTopicRuleCommand; +const deserializeAws_restJson1CreateTopicRuleCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "SqlParseException": + case "com.amazonaws.iot#SqlParseException": + response = { + ...(await deserializeAws_restJson1SqlParseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CreateTopicRuleDestinationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1CreateTopicRuleDestinationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + topicRuleDestination: undefined, + }; + const data = await parseBody(output.body, context); + if (data.topicRuleDestination !== undefined && data.topicRuleDestination !== null) { + contents.topicRuleDestination = deserializeAws_restJson1TopicRuleDestination(data.topicRuleDestination, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1CreateTopicRuleDestinationCommand = deserializeAws_restJson1CreateTopicRuleDestinationCommand; +const deserializeAws_restJson1CreateTopicRuleDestinationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteAccountAuditConfigurationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteAccountAuditConfigurationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteAccountAuditConfigurationCommand = deserializeAws_restJson1DeleteAccountAuditConfigurationCommand; +const deserializeAws_restJson1DeleteAccountAuditConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteAuditSuppressionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteAuditSuppressionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteAuditSuppressionCommand = deserializeAws_restJson1DeleteAuditSuppressionCommand; +const deserializeAws_restJson1DeleteAuditSuppressionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteAuthorizerCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteAuthorizerCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteAuthorizerCommand = deserializeAws_restJson1DeleteAuthorizerCommand; +const deserializeAws_restJson1DeleteAuthorizerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "DeleteConflictException": + case "com.amazonaws.iot#DeleteConflictException": + response = { + ...(await deserializeAws_restJson1DeleteConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteBillingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteBillingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteBillingGroupCommand = deserializeAws_restJson1DeleteBillingGroupCommand; +const deserializeAws_restJson1DeleteBillingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteCACertificateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteCACertificateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteCACertificateCommand = deserializeAws_restJson1DeleteCACertificateCommand; +const deserializeAws_restJson1DeleteCACertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CertificateStateException": + case "com.amazonaws.iot#CertificateStateException": + response = { + ...(await deserializeAws_restJson1CertificateStateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteCertificateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteCertificateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteCertificateCommand = deserializeAws_restJson1DeleteCertificateCommand; +const deserializeAws_restJson1DeleteCertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CertificateStateException": + case "com.amazonaws.iot#CertificateStateException": + response = { + ...(await deserializeAws_restJson1CertificateStateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "DeleteConflictException": + case "com.amazonaws.iot#DeleteConflictException": + response = { + ...(await deserializeAws_restJson1DeleteConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteDimensionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteDimensionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteDimensionCommand = deserializeAws_restJson1DeleteDimensionCommand; +const deserializeAws_restJson1DeleteDimensionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteDomainConfigurationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteDomainConfigurationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteDomainConfigurationCommand = deserializeAws_restJson1DeleteDomainConfigurationCommand; +const deserializeAws_restJson1DeleteDomainConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteDynamicThingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteDynamicThingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteDynamicThingGroupCommand = deserializeAws_restJson1DeleteDynamicThingGroupCommand; +const deserializeAws_restJson1DeleteDynamicThingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteJobCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteJobCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteJobCommand = deserializeAws_restJson1DeleteJobCommand; +const deserializeAws_restJson1DeleteJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidStateTransitionException": + case "com.amazonaws.iot#InvalidStateTransitionException": + response = { + ...(await deserializeAws_restJson1InvalidStateTransitionExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteJobExecutionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteJobExecutionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteJobExecutionCommand = deserializeAws_restJson1DeleteJobExecutionCommand; +const deserializeAws_restJson1DeleteJobExecutionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidStateTransitionException": + case "com.amazonaws.iot#InvalidStateTransitionException": + response = { + ...(await deserializeAws_restJson1InvalidStateTransitionExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteMitigationActionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteMitigationActionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteMitigationActionCommand = deserializeAws_restJson1DeleteMitigationActionCommand; +const deserializeAws_restJson1DeleteMitigationActionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteOTAUpdateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteOTAUpdateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteOTAUpdateCommand = deserializeAws_restJson1DeleteOTAUpdateCommand; +const deserializeAws_restJson1DeleteOTAUpdateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeletePolicyCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeletePolicyCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeletePolicyCommand = deserializeAws_restJson1DeletePolicyCommand; +const deserializeAws_restJson1DeletePolicyCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "DeleteConflictException": + case "com.amazonaws.iot#DeleteConflictException": + response = { + ...(await deserializeAws_restJson1DeleteConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeletePolicyVersionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeletePolicyVersionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeletePolicyVersionCommand = deserializeAws_restJson1DeletePolicyVersionCommand; +const deserializeAws_restJson1DeletePolicyVersionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "DeleteConflictException": + case "com.amazonaws.iot#DeleteConflictException": + response = { + ...(await deserializeAws_restJson1DeleteConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteProvisioningTemplateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteProvisioningTemplateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteProvisioningTemplateCommand = deserializeAws_restJson1DeleteProvisioningTemplateCommand; +const deserializeAws_restJson1DeleteProvisioningTemplateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "DeleteConflictException": + case "com.amazonaws.iot#DeleteConflictException": + response = { + ...(await deserializeAws_restJson1DeleteConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteProvisioningTemplateVersionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteProvisioningTemplateVersionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteProvisioningTemplateVersionCommand = deserializeAws_restJson1DeleteProvisioningTemplateVersionCommand; +const deserializeAws_restJson1DeleteProvisioningTemplateVersionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "DeleteConflictException": + case "com.amazonaws.iot#DeleteConflictException": + response = { + ...(await deserializeAws_restJson1DeleteConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteRegistrationCodeCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteRegistrationCodeCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteRegistrationCodeCommand = deserializeAws_restJson1DeleteRegistrationCodeCommand; +const deserializeAws_restJson1DeleteRegistrationCodeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteRoleAliasCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteRoleAliasCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteRoleAliasCommand = deserializeAws_restJson1DeleteRoleAliasCommand; +const deserializeAws_restJson1DeleteRoleAliasCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "DeleteConflictException": + case "com.amazonaws.iot#DeleteConflictException": + response = { + ...(await deserializeAws_restJson1DeleteConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteScheduledAuditCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteScheduledAuditCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteScheduledAuditCommand = deserializeAws_restJson1DeleteScheduledAuditCommand; +const deserializeAws_restJson1DeleteScheduledAuditCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteSecurityProfileCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteSecurityProfileCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteSecurityProfileCommand = deserializeAws_restJson1DeleteSecurityProfileCommand; +const deserializeAws_restJson1DeleteSecurityProfileCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteStreamCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteStreamCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteStreamCommand = deserializeAws_restJson1DeleteStreamCommand; +const deserializeAws_restJson1DeleteStreamCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "DeleteConflictException": + case "com.amazonaws.iot#DeleteConflictException": + response = { + ...(await deserializeAws_restJson1DeleteConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteThingCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteThingCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteThingCommand = deserializeAws_restJson1DeleteThingCommand; +const deserializeAws_restJson1DeleteThingCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteThingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteThingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteThingGroupCommand = deserializeAws_restJson1DeleteThingGroupCommand; +const deserializeAws_restJson1DeleteThingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteThingTypeCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteThingTypeCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteThingTypeCommand = deserializeAws_restJson1DeleteThingTypeCommand; +const deserializeAws_restJson1DeleteThingTypeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteTopicRuleCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteTopicRuleCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteTopicRuleCommand = deserializeAws_restJson1DeleteTopicRuleCommand; +const deserializeAws_restJson1DeleteTopicRuleCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteTopicRuleDestinationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteTopicRuleDestinationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteTopicRuleDestinationCommand = deserializeAws_restJson1DeleteTopicRuleDestinationCommand; +const deserializeAws_restJson1DeleteTopicRuleDestinationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeleteV2LoggingLevelCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeleteV2LoggingLevelCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeleteV2LoggingLevelCommand = deserializeAws_restJson1DeleteV2LoggingLevelCommand; +const deserializeAws_restJson1DeleteV2LoggingLevelCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DeprecateThingTypeCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DeprecateThingTypeCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DeprecateThingTypeCommand = deserializeAws_restJson1DeprecateThingTypeCommand; +const deserializeAws_restJson1DeprecateThingTypeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeAccountAuditConfigurationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeAccountAuditConfigurationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + auditCheckConfigurations: undefined, + auditNotificationTargetConfigurations: undefined, + roleArn: undefined, + }; + const data = await parseBody(output.body, context); + if (data.auditCheckConfigurations !== undefined && data.auditCheckConfigurations !== null) { + contents.auditCheckConfigurations = deserializeAws_restJson1AuditCheckConfigurations(data.auditCheckConfigurations, context); + } + if (data.auditNotificationTargetConfigurations !== undefined && data.auditNotificationTargetConfigurations !== null) { + contents.auditNotificationTargetConfigurations = deserializeAws_restJson1AuditNotificationTargetConfigurations(data.auditNotificationTargetConfigurations, context); + } + if (data.roleArn !== undefined && data.roleArn !== null) { + contents.roleArn = data.roleArn; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeAccountAuditConfigurationCommand = deserializeAws_restJson1DescribeAccountAuditConfigurationCommand; +const deserializeAws_restJson1DescribeAccountAuditConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeAuditFindingCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeAuditFindingCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + finding: undefined, + }; + const data = await parseBody(output.body, context); + if (data.finding !== undefined && data.finding !== null) { + contents.finding = deserializeAws_restJson1AuditFinding(data.finding, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeAuditFindingCommand = deserializeAws_restJson1DescribeAuditFindingCommand; +const deserializeAws_restJson1DescribeAuditFindingCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeAuditMitigationActionsTaskCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeAuditMitigationActionsTaskCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + actionsDefinition: undefined, + auditCheckToActionsMapping: undefined, + endTime: undefined, + startTime: undefined, + target: undefined, + taskStatistics: undefined, + taskStatus: undefined, + }; + const data = await parseBody(output.body, context); + if (data.actionsDefinition !== undefined && data.actionsDefinition !== null) { + contents.actionsDefinition = deserializeAws_restJson1MitigationActionList(data.actionsDefinition, context); + } + if (data.auditCheckToActionsMapping !== undefined && data.auditCheckToActionsMapping !== null) { + contents.auditCheckToActionsMapping = deserializeAws_restJson1AuditCheckToActionsMapping(data.auditCheckToActionsMapping, context); + } + if (data.endTime !== undefined && data.endTime !== null) { + contents.endTime = new Date(Math.round(data.endTime * 1000)); + } + if (data.startTime !== undefined && data.startTime !== null) { + contents.startTime = new Date(Math.round(data.startTime * 1000)); + } + if (data.target !== undefined && data.target !== null) { + contents.target = deserializeAws_restJson1AuditMitigationActionsTaskTarget(data.target, context); + } + if (data.taskStatistics !== undefined && data.taskStatistics !== null) { + contents.taskStatistics = deserializeAws_restJson1AuditMitigationActionsTaskStatistics(data.taskStatistics, context); + } + if (data.taskStatus !== undefined && data.taskStatus !== null) { + contents.taskStatus = data.taskStatus; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeAuditMitigationActionsTaskCommand = deserializeAws_restJson1DescribeAuditMitigationActionsTaskCommand; +const deserializeAws_restJson1DescribeAuditMitigationActionsTaskCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeAuditSuppressionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeAuditSuppressionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + checkName: undefined, + description: undefined, + expirationDate: undefined, + resourceIdentifier: undefined, + suppressIndefinitely: undefined, + }; + const data = await parseBody(output.body, context); + if (data.checkName !== undefined && data.checkName !== null) { + contents.checkName = data.checkName; + } + if (data.description !== undefined && data.description !== null) { + contents.description = data.description; + } + if (data.expirationDate !== undefined && data.expirationDate !== null) { + contents.expirationDate = new Date(Math.round(data.expirationDate * 1000)); + } + if (data.resourceIdentifier !== undefined && data.resourceIdentifier !== null) { + contents.resourceIdentifier = deserializeAws_restJson1ResourceIdentifier(data.resourceIdentifier, context); + } + if (data.suppressIndefinitely !== undefined && data.suppressIndefinitely !== null) { + contents.suppressIndefinitely = data.suppressIndefinitely; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeAuditSuppressionCommand = deserializeAws_restJson1DescribeAuditSuppressionCommand; +const deserializeAws_restJson1DescribeAuditSuppressionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeAuditTaskCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeAuditTaskCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + auditDetails: undefined, + scheduledAuditName: undefined, + taskStartTime: undefined, + taskStatistics: undefined, + taskStatus: undefined, + taskType: undefined, + }; + const data = await parseBody(output.body, context); + if (data.auditDetails !== undefined && data.auditDetails !== null) { + contents.auditDetails = deserializeAws_restJson1AuditDetails(data.auditDetails, context); + } + if (data.scheduledAuditName !== undefined && data.scheduledAuditName !== null) { + contents.scheduledAuditName = data.scheduledAuditName; + } + if (data.taskStartTime !== undefined && data.taskStartTime !== null) { + contents.taskStartTime = new Date(Math.round(data.taskStartTime * 1000)); + } + if (data.taskStatistics !== undefined && data.taskStatistics !== null) { + contents.taskStatistics = deserializeAws_restJson1TaskStatistics(data.taskStatistics, context); + } + if (data.taskStatus !== undefined && data.taskStatus !== null) { + contents.taskStatus = data.taskStatus; + } + if (data.taskType !== undefined && data.taskType !== null) { + contents.taskType = data.taskType; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeAuditTaskCommand = deserializeAws_restJson1DescribeAuditTaskCommand; +const deserializeAws_restJson1DescribeAuditTaskCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeAuthorizerCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeAuthorizerCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + authorizerDescription: undefined, + }; + const data = await parseBody(output.body, context); + if (data.authorizerDescription !== undefined && data.authorizerDescription !== null) { + contents.authorizerDescription = deserializeAws_restJson1AuthorizerDescription(data.authorizerDescription, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeAuthorizerCommand = deserializeAws_restJson1DescribeAuthorizerCommand; +const deserializeAws_restJson1DescribeAuthorizerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeBillingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeBillingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + billingGroupArn: undefined, + billingGroupId: undefined, + billingGroupMetadata: undefined, + billingGroupName: undefined, + billingGroupProperties: undefined, + version: undefined, + }; + const data = await parseBody(output.body, context); + if (data.billingGroupArn !== undefined && data.billingGroupArn !== null) { + contents.billingGroupArn = data.billingGroupArn; + } + if (data.billingGroupId !== undefined && data.billingGroupId !== null) { + contents.billingGroupId = data.billingGroupId; + } + if (data.billingGroupMetadata !== undefined && data.billingGroupMetadata !== null) { + contents.billingGroupMetadata = deserializeAws_restJson1BillingGroupMetadata(data.billingGroupMetadata, context); + } + if (data.billingGroupName !== undefined && data.billingGroupName !== null) { + contents.billingGroupName = data.billingGroupName; + } + if (data.billingGroupProperties !== undefined && data.billingGroupProperties !== null) { + contents.billingGroupProperties = deserializeAws_restJson1BillingGroupProperties(data.billingGroupProperties, context); + } + if (data.version !== undefined && data.version !== null) { + contents.version = data.version; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeBillingGroupCommand = deserializeAws_restJson1DescribeBillingGroupCommand; +const deserializeAws_restJson1DescribeBillingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeCACertificateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeCACertificateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificateDescription: undefined, + registrationConfig: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificateDescription !== undefined && data.certificateDescription !== null) { + contents.certificateDescription = deserializeAws_restJson1CACertificateDescription(data.certificateDescription, context); + } + if (data.registrationConfig !== undefined && data.registrationConfig !== null) { + contents.registrationConfig = deserializeAws_restJson1RegistrationConfig(data.registrationConfig, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeCACertificateCommand = deserializeAws_restJson1DescribeCACertificateCommand; +const deserializeAws_restJson1DescribeCACertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeCertificateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeCertificateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificateDescription: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificateDescription !== undefined && data.certificateDescription !== null) { + contents.certificateDescription = deserializeAws_restJson1CertificateDescription(data.certificateDescription, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeCertificateCommand = deserializeAws_restJson1DescribeCertificateCommand; +const deserializeAws_restJson1DescribeCertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeDefaultAuthorizerCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeDefaultAuthorizerCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + authorizerDescription: undefined, + }; + const data = await parseBody(output.body, context); + if (data.authorizerDescription !== undefined && data.authorizerDescription !== null) { + contents.authorizerDescription = deserializeAws_restJson1AuthorizerDescription(data.authorizerDescription, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeDefaultAuthorizerCommand = deserializeAws_restJson1DescribeDefaultAuthorizerCommand; +const deserializeAws_restJson1DescribeDefaultAuthorizerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeDimensionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeDimensionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + arn: undefined, + creationDate: undefined, + lastModifiedDate: undefined, + name: undefined, + stringValues: undefined, + type: undefined, + }; + const data = await parseBody(output.body, context); + if (data.arn !== undefined && data.arn !== null) { + contents.arn = data.arn; + } + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.lastModifiedDate !== undefined && data.lastModifiedDate !== null) { + contents.lastModifiedDate = new Date(Math.round(data.lastModifiedDate * 1000)); + } + if (data.name !== undefined && data.name !== null) { + contents.name = data.name; + } + if (data.stringValues !== undefined && data.stringValues !== null) { + contents.stringValues = deserializeAws_restJson1DimensionStringValues(data.stringValues, context); + } + if (data.type !== undefined && data.type !== null) { + contents.type = data.type; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeDimensionCommand = deserializeAws_restJson1DescribeDimensionCommand; +const deserializeAws_restJson1DescribeDimensionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeDomainConfigurationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeDomainConfigurationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + authorizerConfig: undefined, + domainConfigurationArn: undefined, + domainConfigurationName: undefined, + domainConfigurationStatus: undefined, + domainName: undefined, + domainType: undefined, + lastStatusChangeDate: undefined, + serverCertificates: undefined, + serviceType: undefined, + }; + const data = await parseBody(output.body, context); + if (data.authorizerConfig !== undefined && data.authorizerConfig !== null) { + contents.authorizerConfig = deserializeAws_restJson1AuthorizerConfig(data.authorizerConfig, context); + } + if (data.domainConfigurationArn !== undefined && data.domainConfigurationArn !== null) { + contents.domainConfigurationArn = data.domainConfigurationArn; + } + if (data.domainConfigurationName !== undefined && data.domainConfigurationName !== null) { + contents.domainConfigurationName = data.domainConfigurationName; + } + if (data.domainConfigurationStatus !== undefined && data.domainConfigurationStatus !== null) { + contents.domainConfigurationStatus = data.domainConfigurationStatus; + } + if (data.domainName !== undefined && data.domainName !== null) { + contents.domainName = data.domainName; + } + if (data.domainType !== undefined && data.domainType !== null) { + contents.domainType = data.domainType; + } + if (data.lastStatusChangeDate !== undefined && data.lastStatusChangeDate !== null) { + contents.lastStatusChangeDate = new Date(Math.round(data.lastStatusChangeDate * 1000)); + } + if (data.serverCertificates !== undefined && data.serverCertificates !== null) { + contents.serverCertificates = deserializeAws_restJson1ServerCertificates(data.serverCertificates, context); + } + if (data.serviceType !== undefined && data.serviceType !== null) { + contents.serviceType = data.serviceType; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeDomainConfigurationCommand = deserializeAws_restJson1DescribeDomainConfigurationCommand; +const deserializeAws_restJson1DescribeDomainConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeEndpointCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeEndpointCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + endpointAddress: undefined, + }; + const data = await parseBody(output.body, context); + if (data.endpointAddress !== undefined && data.endpointAddress !== null) { + contents.endpointAddress = data.endpointAddress; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeEndpointCommand = deserializeAws_restJson1DescribeEndpointCommand; +const deserializeAws_restJson1DescribeEndpointCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeEventConfigurationsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeEventConfigurationsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + creationDate: undefined, + eventConfigurations: undefined, + lastModifiedDate: undefined, + }; + const data = await parseBody(output.body, context); + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.eventConfigurations !== undefined && data.eventConfigurations !== null) { + contents.eventConfigurations = deserializeAws_restJson1EventConfigurations(data.eventConfigurations, context); + } + if (data.lastModifiedDate !== undefined && data.lastModifiedDate !== null) { + contents.lastModifiedDate = new Date(Math.round(data.lastModifiedDate * 1000)); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeEventConfigurationsCommand = deserializeAws_restJson1DescribeEventConfigurationsCommand; +const deserializeAws_restJson1DescribeEventConfigurationsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeIndexCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeIndexCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + indexName: undefined, + indexStatus: undefined, + schema: undefined, + }; + const data = await parseBody(output.body, context); + if (data.indexName !== undefined && data.indexName !== null) { + contents.indexName = data.indexName; + } + if (data.indexStatus !== undefined && data.indexStatus !== null) { + contents.indexStatus = data.indexStatus; + } + if (data.schema !== undefined && data.schema !== null) { + contents.schema = data.schema; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeIndexCommand = deserializeAws_restJson1DescribeIndexCommand; +const deserializeAws_restJson1DescribeIndexCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeJobCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeJobCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + documentSource: undefined, + job: undefined, + }; + const data = await parseBody(output.body, context); + if (data.documentSource !== undefined && data.documentSource !== null) { + contents.documentSource = data.documentSource; + } + if (data.job !== undefined && data.job !== null) { + contents.job = deserializeAws_restJson1Job(data.job, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeJobCommand = deserializeAws_restJson1DescribeJobCommand; +const deserializeAws_restJson1DescribeJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeJobExecutionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeJobExecutionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + execution: undefined, + }; + const data = await parseBody(output.body, context); + if (data.execution !== undefined && data.execution !== null) { + contents.execution = deserializeAws_restJson1JobExecution(data.execution, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeJobExecutionCommand = deserializeAws_restJson1DescribeJobExecutionCommand; +const deserializeAws_restJson1DescribeJobExecutionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeMitigationActionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeMitigationActionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + actionArn: undefined, + actionId: undefined, + actionName: undefined, + actionParams: undefined, + actionType: undefined, + creationDate: undefined, + lastModifiedDate: undefined, + roleArn: undefined, + }; + const data = await parseBody(output.body, context); + if (data.actionArn !== undefined && data.actionArn !== null) { + contents.actionArn = data.actionArn; + } + if (data.actionId !== undefined && data.actionId !== null) { + contents.actionId = data.actionId; + } + if (data.actionName !== undefined && data.actionName !== null) { + contents.actionName = data.actionName; + } + if (data.actionParams !== undefined && data.actionParams !== null) { + contents.actionParams = deserializeAws_restJson1MitigationActionParams(data.actionParams, context); + } + if (data.actionType !== undefined && data.actionType !== null) { + contents.actionType = data.actionType; + } + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.lastModifiedDate !== undefined && data.lastModifiedDate !== null) { + contents.lastModifiedDate = new Date(Math.round(data.lastModifiedDate * 1000)); + } + if (data.roleArn !== undefined && data.roleArn !== null) { + contents.roleArn = data.roleArn; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeMitigationActionCommand = deserializeAws_restJson1DescribeMitigationActionCommand; +const deserializeAws_restJson1DescribeMitigationActionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeProvisioningTemplateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeProvisioningTemplateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + creationDate: undefined, + defaultVersionId: undefined, + description: undefined, + enabled: undefined, + lastModifiedDate: undefined, + preProvisioningHook: undefined, + provisioningRoleArn: undefined, + templateArn: undefined, + templateBody: undefined, + templateName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.defaultVersionId !== undefined && data.defaultVersionId !== null) { + contents.defaultVersionId = data.defaultVersionId; + } + if (data.description !== undefined && data.description !== null) { + contents.description = data.description; + } + if (data.enabled !== undefined && data.enabled !== null) { + contents.enabled = data.enabled; + } + if (data.lastModifiedDate !== undefined && data.lastModifiedDate !== null) { + contents.lastModifiedDate = new Date(Math.round(data.lastModifiedDate * 1000)); + } + if (data.preProvisioningHook !== undefined && data.preProvisioningHook !== null) { + contents.preProvisioningHook = deserializeAws_restJson1ProvisioningHook(data.preProvisioningHook, context); + } + if (data.provisioningRoleArn !== undefined && data.provisioningRoleArn !== null) { + contents.provisioningRoleArn = data.provisioningRoleArn; + } + if (data.templateArn !== undefined && data.templateArn !== null) { + contents.templateArn = data.templateArn; + } + if (data.templateBody !== undefined && data.templateBody !== null) { + contents.templateBody = data.templateBody; + } + if (data.templateName !== undefined && data.templateName !== null) { + contents.templateName = data.templateName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeProvisioningTemplateCommand = deserializeAws_restJson1DescribeProvisioningTemplateCommand; +const deserializeAws_restJson1DescribeProvisioningTemplateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeProvisioningTemplateVersionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeProvisioningTemplateVersionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + creationDate: undefined, + isDefaultVersion: undefined, + templateBody: undefined, + versionId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.isDefaultVersion !== undefined && data.isDefaultVersion !== null) { + contents.isDefaultVersion = data.isDefaultVersion; + } + if (data.templateBody !== undefined && data.templateBody !== null) { + contents.templateBody = data.templateBody; + } + if (data.versionId !== undefined && data.versionId !== null) { + contents.versionId = data.versionId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeProvisioningTemplateVersionCommand = deserializeAws_restJson1DescribeProvisioningTemplateVersionCommand; +const deserializeAws_restJson1DescribeProvisioningTemplateVersionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeRoleAliasCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeRoleAliasCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + roleAliasDescription: undefined, + }; + const data = await parseBody(output.body, context); + if (data.roleAliasDescription !== undefined && data.roleAliasDescription !== null) { + contents.roleAliasDescription = deserializeAws_restJson1RoleAliasDescription(data.roleAliasDescription, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeRoleAliasCommand = deserializeAws_restJson1DescribeRoleAliasCommand; +const deserializeAws_restJson1DescribeRoleAliasCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeScheduledAuditCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeScheduledAuditCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + dayOfMonth: undefined, + dayOfWeek: undefined, + frequency: undefined, + scheduledAuditArn: undefined, + scheduledAuditName: undefined, + targetCheckNames: undefined, + }; + const data = await parseBody(output.body, context); + if (data.dayOfMonth !== undefined && data.dayOfMonth !== null) { + contents.dayOfMonth = data.dayOfMonth; + } + if (data.dayOfWeek !== undefined && data.dayOfWeek !== null) { + contents.dayOfWeek = data.dayOfWeek; + } + if (data.frequency !== undefined && data.frequency !== null) { + contents.frequency = data.frequency; + } + if (data.scheduledAuditArn !== undefined && data.scheduledAuditArn !== null) { + contents.scheduledAuditArn = data.scheduledAuditArn; + } + if (data.scheduledAuditName !== undefined && data.scheduledAuditName !== null) { + contents.scheduledAuditName = data.scheduledAuditName; + } + if (data.targetCheckNames !== undefined && data.targetCheckNames !== null) { + contents.targetCheckNames = deserializeAws_restJson1TargetAuditCheckNames(data.targetCheckNames, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeScheduledAuditCommand = deserializeAws_restJson1DescribeScheduledAuditCommand; +const deserializeAws_restJson1DescribeScheduledAuditCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeSecurityProfileCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeSecurityProfileCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + additionalMetricsToRetain: undefined, + additionalMetricsToRetainV2: undefined, + alertTargets: undefined, + behaviors: undefined, + creationDate: undefined, + lastModifiedDate: undefined, + securityProfileArn: undefined, + securityProfileDescription: undefined, + securityProfileName: undefined, + version: undefined, + }; + const data = await parseBody(output.body, context); + if (data.additionalMetricsToRetain !== undefined && data.additionalMetricsToRetain !== null) { + contents.additionalMetricsToRetain = deserializeAws_restJson1AdditionalMetricsToRetainList(data.additionalMetricsToRetain, context); + } + if (data.additionalMetricsToRetainV2 !== undefined && data.additionalMetricsToRetainV2 !== null) { + contents.additionalMetricsToRetainV2 = deserializeAws_restJson1AdditionalMetricsToRetainV2List(data.additionalMetricsToRetainV2, context); + } + if (data.alertTargets !== undefined && data.alertTargets !== null) { + contents.alertTargets = deserializeAws_restJson1AlertTargets(data.alertTargets, context); + } + if (data.behaviors !== undefined && data.behaviors !== null) { + contents.behaviors = deserializeAws_restJson1Behaviors(data.behaviors, context); + } + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.lastModifiedDate !== undefined && data.lastModifiedDate !== null) { + contents.lastModifiedDate = new Date(Math.round(data.lastModifiedDate * 1000)); + } + if (data.securityProfileArn !== undefined && data.securityProfileArn !== null) { + contents.securityProfileArn = data.securityProfileArn; + } + if (data.securityProfileDescription !== undefined && data.securityProfileDescription !== null) { + contents.securityProfileDescription = data.securityProfileDescription; + } + if (data.securityProfileName !== undefined && data.securityProfileName !== null) { + contents.securityProfileName = data.securityProfileName; + } + if (data.version !== undefined && data.version !== null) { + contents.version = data.version; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeSecurityProfileCommand = deserializeAws_restJson1DescribeSecurityProfileCommand; +const deserializeAws_restJson1DescribeSecurityProfileCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeStreamCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeStreamCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + streamInfo: undefined, + }; + const data = await parseBody(output.body, context); + if (data.streamInfo !== undefined && data.streamInfo !== null) { + contents.streamInfo = deserializeAws_restJson1StreamInfo(data.streamInfo, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeStreamCommand = deserializeAws_restJson1DescribeStreamCommand; +const deserializeAws_restJson1DescribeStreamCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeThingCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeThingCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + attributes: undefined, + billingGroupName: undefined, + defaultClientId: undefined, + thingArn: undefined, + thingId: undefined, + thingName: undefined, + thingTypeName: undefined, + version: undefined, + }; + const data = await parseBody(output.body, context); + if (data.attributes !== undefined && data.attributes !== null) { + contents.attributes = deserializeAws_restJson1Attributes(data.attributes, context); + } + if (data.billingGroupName !== undefined && data.billingGroupName !== null) { + contents.billingGroupName = data.billingGroupName; + } + if (data.defaultClientId !== undefined && data.defaultClientId !== null) { + contents.defaultClientId = data.defaultClientId; + } + if (data.thingArn !== undefined && data.thingArn !== null) { + contents.thingArn = data.thingArn; + } + if (data.thingId !== undefined && data.thingId !== null) { + contents.thingId = data.thingId; + } + if (data.thingName !== undefined && data.thingName !== null) { + contents.thingName = data.thingName; + } + if (data.thingTypeName !== undefined && data.thingTypeName !== null) { + contents.thingTypeName = data.thingTypeName; + } + if (data.version !== undefined && data.version !== null) { + contents.version = data.version; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeThingCommand = deserializeAws_restJson1DescribeThingCommand; +const deserializeAws_restJson1DescribeThingCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeThingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeThingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + indexName: undefined, + queryString: undefined, + queryVersion: undefined, + status: undefined, + thingGroupArn: undefined, + thingGroupId: undefined, + thingGroupMetadata: undefined, + thingGroupName: undefined, + thingGroupProperties: undefined, + version: undefined, + }; + const data = await parseBody(output.body, context); + if (data.indexName !== undefined && data.indexName !== null) { + contents.indexName = data.indexName; + } + if (data.queryString !== undefined && data.queryString !== null) { + contents.queryString = data.queryString; + } + if (data.queryVersion !== undefined && data.queryVersion !== null) { + contents.queryVersion = data.queryVersion; + } + if (data.status !== undefined && data.status !== null) { + contents.status = data.status; + } + if (data.thingGroupArn !== undefined && data.thingGroupArn !== null) { + contents.thingGroupArn = data.thingGroupArn; + } + if (data.thingGroupId !== undefined && data.thingGroupId !== null) { + contents.thingGroupId = data.thingGroupId; + } + if (data.thingGroupMetadata !== undefined && data.thingGroupMetadata !== null) { + contents.thingGroupMetadata = deserializeAws_restJson1ThingGroupMetadata(data.thingGroupMetadata, context); + } + if (data.thingGroupName !== undefined && data.thingGroupName !== null) { + contents.thingGroupName = data.thingGroupName; + } + if (data.thingGroupProperties !== undefined && data.thingGroupProperties !== null) { + contents.thingGroupProperties = deserializeAws_restJson1ThingGroupProperties(data.thingGroupProperties, context); + } + if (data.version !== undefined && data.version !== null) { + contents.version = data.version; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeThingGroupCommand = deserializeAws_restJson1DescribeThingGroupCommand; +const deserializeAws_restJson1DescribeThingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeThingRegistrationTaskCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeThingRegistrationTaskCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + creationDate: undefined, + failureCount: undefined, + inputFileBucket: undefined, + inputFileKey: undefined, + lastModifiedDate: undefined, + message: undefined, + percentageProgress: undefined, + roleArn: undefined, + status: undefined, + successCount: undefined, + taskId: undefined, + templateBody: undefined, + }; + const data = await parseBody(output.body, context); + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.failureCount !== undefined && data.failureCount !== null) { + contents.failureCount = data.failureCount; + } + if (data.inputFileBucket !== undefined && data.inputFileBucket !== null) { + contents.inputFileBucket = data.inputFileBucket; + } + if (data.inputFileKey !== undefined && data.inputFileKey !== null) { + contents.inputFileKey = data.inputFileKey; + } + if (data.lastModifiedDate !== undefined && data.lastModifiedDate !== null) { + contents.lastModifiedDate = new Date(Math.round(data.lastModifiedDate * 1000)); + } + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + if (data.percentageProgress !== undefined && data.percentageProgress !== null) { + contents.percentageProgress = data.percentageProgress; + } + if (data.roleArn !== undefined && data.roleArn !== null) { + contents.roleArn = data.roleArn; + } + if (data.status !== undefined && data.status !== null) { + contents.status = data.status; + } + if (data.successCount !== undefined && data.successCount !== null) { + contents.successCount = data.successCount; + } + if (data.taskId !== undefined && data.taskId !== null) { + contents.taskId = data.taskId; + } + if (data.templateBody !== undefined && data.templateBody !== null) { + contents.templateBody = data.templateBody; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeThingRegistrationTaskCommand = deserializeAws_restJson1DescribeThingRegistrationTaskCommand; +const deserializeAws_restJson1DescribeThingRegistrationTaskCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DescribeThingTypeCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DescribeThingTypeCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + thingTypeArn: undefined, + thingTypeId: undefined, + thingTypeMetadata: undefined, + thingTypeName: undefined, + thingTypeProperties: undefined, + }; + const data = await parseBody(output.body, context); + if (data.thingTypeArn !== undefined && data.thingTypeArn !== null) { + contents.thingTypeArn = data.thingTypeArn; + } + if (data.thingTypeId !== undefined && data.thingTypeId !== null) { + contents.thingTypeId = data.thingTypeId; + } + if (data.thingTypeMetadata !== undefined && data.thingTypeMetadata !== null) { + contents.thingTypeMetadata = deserializeAws_restJson1ThingTypeMetadata(data.thingTypeMetadata, context); + } + if (data.thingTypeName !== undefined && data.thingTypeName !== null) { + contents.thingTypeName = data.thingTypeName; + } + if (data.thingTypeProperties !== undefined && data.thingTypeProperties !== null) { + contents.thingTypeProperties = deserializeAws_restJson1ThingTypeProperties(data.thingTypeProperties, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DescribeThingTypeCommand = deserializeAws_restJson1DescribeThingTypeCommand; +const deserializeAws_restJson1DescribeThingTypeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DetachPolicyCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DetachPolicyCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DetachPolicyCommand = deserializeAws_restJson1DetachPolicyCommand; +const deserializeAws_restJson1DetachPolicyCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DetachPrincipalPolicyCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DetachPrincipalPolicyCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DetachPrincipalPolicyCommand = deserializeAws_restJson1DetachPrincipalPolicyCommand; +const deserializeAws_restJson1DetachPrincipalPolicyCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DetachSecurityProfileCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DetachSecurityProfileCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DetachSecurityProfileCommand = deserializeAws_restJson1DetachSecurityProfileCommand; +const deserializeAws_restJson1DetachSecurityProfileCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DetachThingPrincipalCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DetachThingPrincipalCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DetachThingPrincipalCommand = deserializeAws_restJson1DetachThingPrincipalCommand; +const deserializeAws_restJson1DetachThingPrincipalCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1DisableTopicRuleCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1DisableTopicRuleCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1DisableTopicRuleCommand = deserializeAws_restJson1DisableTopicRuleCommand; +const deserializeAws_restJson1DisableTopicRuleCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1EnableTopicRuleCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1EnableTopicRuleCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1EnableTopicRuleCommand = deserializeAws_restJson1EnableTopicRuleCommand; +const deserializeAws_restJson1EnableTopicRuleCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetCardinalityCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetCardinalityCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + cardinality: undefined, + }; + const data = await parseBody(output.body, context); + if (data.cardinality !== undefined && data.cardinality !== null) { + contents.cardinality = data.cardinality; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetCardinalityCommand = deserializeAws_restJson1GetCardinalityCommand; +const deserializeAws_restJson1GetCardinalityCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "IndexNotReadyException": + case "com.amazonaws.iot#IndexNotReadyException": + response = { + ...(await deserializeAws_restJson1IndexNotReadyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidAggregationException": + case "com.amazonaws.iot#InvalidAggregationException": + response = { + ...(await deserializeAws_restJson1InvalidAggregationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidQueryException": + case "com.amazonaws.iot#InvalidQueryException": + response = { + ...(await deserializeAws_restJson1InvalidQueryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetEffectivePoliciesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetEffectivePoliciesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + effectivePolicies: undefined, + }; + const data = await parseBody(output.body, context); + if (data.effectivePolicies !== undefined && data.effectivePolicies !== null) { + contents.effectivePolicies = deserializeAws_restJson1EffectivePolicies(data.effectivePolicies, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetEffectivePoliciesCommand = deserializeAws_restJson1GetEffectivePoliciesCommand; +const deserializeAws_restJson1GetEffectivePoliciesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetIndexingConfigurationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetIndexingConfigurationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + thingGroupIndexingConfiguration: undefined, + thingIndexingConfiguration: undefined, + }; + const data = await parseBody(output.body, context); + if (data.thingGroupIndexingConfiguration !== undefined && data.thingGroupIndexingConfiguration !== null) { + contents.thingGroupIndexingConfiguration = deserializeAws_restJson1ThingGroupIndexingConfiguration(data.thingGroupIndexingConfiguration, context); + } + if (data.thingIndexingConfiguration !== undefined && data.thingIndexingConfiguration !== null) { + contents.thingIndexingConfiguration = deserializeAws_restJson1ThingIndexingConfiguration(data.thingIndexingConfiguration, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetIndexingConfigurationCommand = deserializeAws_restJson1GetIndexingConfigurationCommand; +const deserializeAws_restJson1GetIndexingConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetJobDocumentCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetJobDocumentCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + document: undefined, + }; + const data = await parseBody(output.body, context); + if (data.document !== undefined && data.document !== null) { + contents.document = data.document; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetJobDocumentCommand = deserializeAws_restJson1GetJobDocumentCommand; +const deserializeAws_restJson1GetJobDocumentCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetLoggingOptionsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetLoggingOptionsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + logLevel: undefined, + roleArn: undefined, + }; + const data = await parseBody(output.body, context); + if (data.logLevel !== undefined && data.logLevel !== null) { + contents.logLevel = data.logLevel; + } + if (data.roleArn !== undefined && data.roleArn !== null) { + contents.roleArn = data.roleArn; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetLoggingOptionsCommand = deserializeAws_restJson1GetLoggingOptionsCommand; +const deserializeAws_restJson1GetLoggingOptionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetOTAUpdateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetOTAUpdateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + otaUpdateInfo: undefined, + }; + const data = await parseBody(output.body, context); + if (data.otaUpdateInfo !== undefined && data.otaUpdateInfo !== null) { + contents.otaUpdateInfo = deserializeAws_restJson1OTAUpdateInfo(data.otaUpdateInfo, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetOTAUpdateCommand = deserializeAws_restJson1GetOTAUpdateCommand; +const deserializeAws_restJson1GetOTAUpdateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetPercentilesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetPercentilesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + percentiles: undefined, + }; + const data = await parseBody(output.body, context); + if (data.percentiles !== undefined && data.percentiles !== null) { + contents.percentiles = deserializeAws_restJson1Percentiles(data.percentiles, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetPercentilesCommand = deserializeAws_restJson1GetPercentilesCommand; +const deserializeAws_restJson1GetPercentilesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "IndexNotReadyException": + case "com.amazonaws.iot#IndexNotReadyException": + response = { + ...(await deserializeAws_restJson1IndexNotReadyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidAggregationException": + case "com.amazonaws.iot#InvalidAggregationException": + response = { + ...(await deserializeAws_restJson1InvalidAggregationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidQueryException": + case "com.amazonaws.iot#InvalidQueryException": + response = { + ...(await deserializeAws_restJson1InvalidQueryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetPolicyCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetPolicyCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + creationDate: undefined, + defaultVersionId: undefined, + generationId: undefined, + lastModifiedDate: undefined, + policyArn: undefined, + policyDocument: undefined, + policyName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.defaultVersionId !== undefined && data.defaultVersionId !== null) { + contents.defaultVersionId = data.defaultVersionId; + } + if (data.generationId !== undefined && data.generationId !== null) { + contents.generationId = data.generationId; + } + if (data.lastModifiedDate !== undefined && data.lastModifiedDate !== null) { + contents.lastModifiedDate = new Date(Math.round(data.lastModifiedDate * 1000)); + } + if (data.policyArn !== undefined && data.policyArn !== null) { + contents.policyArn = data.policyArn; + } + if (data.policyDocument !== undefined && data.policyDocument !== null) { + contents.policyDocument = data.policyDocument; + } + if (data.policyName !== undefined && data.policyName !== null) { + contents.policyName = data.policyName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetPolicyCommand = deserializeAws_restJson1GetPolicyCommand; +const deserializeAws_restJson1GetPolicyCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetPolicyVersionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetPolicyVersionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + creationDate: undefined, + generationId: undefined, + isDefaultVersion: undefined, + lastModifiedDate: undefined, + policyArn: undefined, + policyDocument: undefined, + policyName: undefined, + policyVersionId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.generationId !== undefined && data.generationId !== null) { + contents.generationId = data.generationId; + } + if (data.isDefaultVersion !== undefined && data.isDefaultVersion !== null) { + contents.isDefaultVersion = data.isDefaultVersion; + } + if (data.lastModifiedDate !== undefined && data.lastModifiedDate !== null) { + contents.lastModifiedDate = new Date(Math.round(data.lastModifiedDate * 1000)); + } + if (data.policyArn !== undefined && data.policyArn !== null) { + contents.policyArn = data.policyArn; + } + if (data.policyDocument !== undefined && data.policyDocument !== null) { + contents.policyDocument = data.policyDocument; + } + if (data.policyName !== undefined && data.policyName !== null) { + contents.policyName = data.policyName; + } + if (data.policyVersionId !== undefined && data.policyVersionId !== null) { + contents.policyVersionId = data.policyVersionId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetPolicyVersionCommand = deserializeAws_restJson1GetPolicyVersionCommand; +const deserializeAws_restJson1GetPolicyVersionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetRegistrationCodeCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetRegistrationCodeCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + registrationCode: undefined, + }; + const data = await parseBody(output.body, context); + if (data.registrationCode !== undefined && data.registrationCode !== null) { + contents.registrationCode = data.registrationCode; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetRegistrationCodeCommand = deserializeAws_restJson1GetRegistrationCodeCommand; +const deserializeAws_restJson1GetRegistrationCodeCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetStatisticsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetStatisticsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + statistics: undefined, + }; + const data = await parseBody(output.body, context); + if (data.statistics !== undefined && data.statistics !== null) { + contents.statistics = deserializeAws_restJson1Statistics(data.statistics, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetStatisticsCommand = deserializeAws_restJson1GetStatisticsCommand; +const deserializeAws_restJson1GetStatisticsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "IndexNotReadyException": + case "com.amazonaws.iot#IndexNotReadyException": + response = { + ...(await deserializeAws_restJson1IndexNotReadyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidAggregationException": + case "com.amazonaws.iot#InvalidAggregationException": + response = { + ...(await deserializeAws_restJson1InvalidAggregationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidQueryException": + case "com.amazonaws.iot#InvalidQueryException": + response = { + ...(await deserializeAws_restJson1InvalidQueryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetTopicRuleCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetTopicRuleCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + rule: undefined, + ruleArn: undefined, + }; + const data = await parseBody(output.body, context); + if (data.rule !== undefined && data.rule !== null) { + contents.rule = deserializeAws_restJson1TopicRule(data.rule, context); + } + if (data.ruleArn !== undefined && data.ruleArn !== null) { + contents.ruleArn = data.ruleArn; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetTopicRuleCommand = deserializeAws_restJson1GetTopicRuleCommand; +const deserializeAws_restJson1GetTopicRuleCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetTopicRuleDestinationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetTopicRuleDestinationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + topicRuleDestination: undefined, + }; + const data = await parseBody(output.body, context); + if (data.topicRuleDestination !== undefined && data.topicRuleDestination !== null) { + contents.topicRuleDestination = deserializeAws_restJson1TopicRuleDestination(data.topicRuleDestination, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetTopicRuleDestinationCommand = deserializeAws_restJson1GetTopicRuleDestinationCommand; +const deserializeAws_restJson1GetTopicRuleDestinationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1GetV2LoggingOptionsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1GetV2LoggingOptionsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + defaultLogLevel: undefined, + disableAllLogs: undefined, + roleArn: undefined, + }; + const data = await parseBody(output.body, context); + if (data.defaultLogLevel !== undefined && data.defaultLogLevel !== null) { + contents.defaultLogLevel = data.defaultLogLevel; + } + if (data.disableAllLogs !== undefined && data.disableAllLogs !== null) { + contents.disableAllLogs = data.disableAllLogs; + } + if (data.roleArn !== undefined && data.roleArn !== null) { + contents.roleArn = data.roleArn; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1GetV2LoggingOptionsCommand = deserializeAws_restJson1GetV2LoggingOptionsCommand; +const deserializeAws_restJson1GetV2LoggingOptionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotConfiguredException": + case "com.amazonaws.iot#NotConfiguredException": + response = { + ...(await deserializeAws_restJson1NotConfiguredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListActiveViolationsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListActiveViolationsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + activeViolations: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.activeViolations !== undefined && data.activeViolations !== null) { + contents.activeViolations = deserializeAws_restJson1ActiveViolations(data.activeViolations, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListActiveViolationsCommand = deserializeAws_restJson1ListActiveViolationsCommand; +const deserializeAws_restJson1ListActiveViolationsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListAttachedPoliciesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListAttachedPoliciesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextMarker: undefined, + policies: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + if (data.policies !== undefined && data.policies !== null) { + contents.policies = deserializeAws_restJson1Policies(data.policies, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListAttachedPoliciesCommand = deserializeAws_restJson1ListAttachedPoliciesCommand; +const deserializeAws_restJson1ListAttachedPoliciesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListAuditFindingsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListAuditFindingsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + findings: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.findings !== undefined && data.findings !== null) { + contents.findings = deserializeAws_restJson1AuditFindings(data.findings, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListAuditFindingsCommand = deserializeAws_restJson1ListAuditFindingsCommand; +const deserializeAws_restJson1ListAuditFindingsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListAuditMitigationActionsExecutionsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListAuditMitigationActionsExecutionsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + actionsExecutions: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.actionsExecutions !== undefined && data.actionsExecutions !== null) { + contents.actionsExecutions = deserializeAws_restJson1AuditMitigationActionExecutionMetadataList(data.actionsExecutions, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListAuditMitigationActionsExecutionsCommand = deserializeAws_restJson1ListAuditMitigationActionsExecutionsCommand; +const deserializeAws_restJson1ListAuditMitigationActionsExecutionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListAuditMitigationActionsTasksCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListAuditMitigationActionsTasksCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + tasks: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.tasks !== undefined && data.tasks !== null) { + contents.tasks = deserializeAws_restJson1AuditMitigationActionsTaskMetadataList(data.tasks, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListAuditMitigationActionsTasksCommand = deserializeAws_restJson1ListAuditMitigationActionsTasksCommand; +const deserializeAws_restJson1ListAuditMitigationActionsTasksCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListAuditSuppressionsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListAuditSuppressionsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + suppressions: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.suppressions !== undefined && data.suppressions !== null) { + contents.suppressions = deserializeAws_restJson1AuditSuppressionList(data.suppressions, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListAuditSuppressionsCommand = deserializeAws_restJson1ListAuditSuppressionsCommand; +const deserializeAws_restJson1ListAuditSuppressionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListAuditTasksCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListAuditTasksCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + tasks: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.tasks !== undefined && data.tasks !== null) { + contents.tasks = deserializeAws_restJson1AuditTaskMetadataList(data.tasks, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListAuditTasksCommand = deserializeAws_restJson1ListAuditTasksCommand; +const deserializeAws_restJson1ListAuditTasksCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListAuthorizersCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListAuthorizersCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + authorizers: undefined, + nextMarker: undefined, + }; + const data = await parseBody(output.body, context); + if (data.authorizers !== undefined && data.authorizers !== null) { + contents.authorizers = deserializeAws_restJson1Authorizers(data.authorizers, context); + } + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListAuthorizersCommand = deserializeAws_restJson1ListAuthorizersCommand; +const deserializeAws_restJson1ListAuthorizersCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListBillingGroupsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListBillingGroupsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + billingGroups: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.billingGroups !== undefined && data.billingGroups !== null) { + contents.billingGroups = deserializeAws_restJson1BillingGroupNameAndArnList(data.billingGroups, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListBillingGroupsCommand = deserializeAws_restJson1ListBillingGroupsCommand; +const deserializeAws_restJson1ListBillingGroupsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListCACertificatesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListCACertificatesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificates: undefined, + nextMarker: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificates !== undefined && data.certificates !== null) { + contents.certificates = deserializeAws_restJson1CACertificates(data.certificates, context); + } + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListCACertificatesCommand = deserializeAws_restJson1ListCACertificatesCommand; +const deserializeAws_restJson1ListCACertificatesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListCertificatesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListCertificatesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificates: undefined, + nextMarker: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificates !== undefined && data.certificates !== null) { + contents.certificates = deserializeAws_restJson1Certificates(data.certificates, context); + } + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListCertificatesCommand = deserializeAws_restJson1ListCertificatesCommand; +const deserializeAws_restJson1ListCertificatesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListCertificatesByCACommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListCertificatesByCACommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificates: undefined, + nextMarker: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificates !== undefined && data.certificates !== null) { + contents.certificates = deserializeAws_restJson1Certificates(data.certificates, context); + } + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListCertificatesByCACommand = deserializeAws_restJson1ListCertificatesByCACommand; +const deserializeAws_restJson1ListCertificatesByCACommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListDimensionsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListDimensionsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + dimensionNames: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.dimensionNames !== undefined && data.dimensionNames !== null) { + contents.dimensionNames = deserializeAws_restJson1DimensionNames(data.dimensionNames, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListDimensionsCommand = deserializeAws_restJson1ListDimensionsCommand; +const deserializeAws_restJson1ListDimensionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListDomainConfigurationsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListDomainConfigurationsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + domainConfigurations: undefined, + nextMarker: undefined, + }; + const data = await parseBody(output.body, context); + if (data.domainConfigurations !== undefined && data.domainConfigurations !== null) { + contents.domainConfigurations = deserializeAws_restJson1DomainConfigurations(data.domainConfigurations, context); + } + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListDomainConfigurationsCommand = deserializeAws_restJson1ListDomainConfigurationsCommand; +const deserializeAws_restJson1ListDomainConfigurationsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListIndicesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListIndicesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + indexNames: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.indexNames !== undefined && data.indexNames !== null) { + contents.indexNames = deserializeAws_restJson1IndexNamesList(data.indexNames, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListIndicesCommand = deserializeAws_restJson1ListIndicesCommand; +const deserializeAws_restJson1ListIndicesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListJobExecutionsForJobCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListJobExecutionsForJobCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + executionSummaries: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.executionSummaries !== undefined && data.executionSummaries !== null) { + contents.executionSummaries = deserializeAws_restJson1JobExecutionSummaryForJobList(data.executionSummaries, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListJobExecutionsForJobCommand = deserializeAws_restJson1ListJobExecutionsForJobCommand; +const deserializeAws_restJson1ListJobExecutionsForJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListJobExecutionsForThingCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListJobExecutionsForThingCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + executionSummaries: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.executionSummaries !== undefined && data.executionSummaries !== null) { + contents.executionSummaries = deserializeAws_restJson1JobExecutionSummaryForThingList(data.executionSummaries, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListJobExecutionsForThingCommand = deserializeAws_restJson1ListJobExecutionsForThingCommand; +const deserializeAws_restJson1ListJobExecutionsForThingCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListJobsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListJobsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + jobs: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.jobs !== undefined && data.jobs !== null) { + contents.jobs = deserializeAws_restJson1JobSummaryList(data.jobs, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListJobsCommand = deserializeAws_restJson1ListJobsCommand; +const deserializeAws_restJson1ListJobsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListMitigationActionsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListMitigationActionsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + actionIdentifiers: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.actionIdentifiers !== undefined && data.actionIdentifiers !== null) { + contents.actionIdentifiers = deserializeAws_restJson1MitigationActionIdentifierList(data.actionIdentifiers, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListMitigationActionsCommand = deserializeAws_restJson1ListMitigationActionsCommand; +const deserializeAws_restJson1ListMitigationActionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListOTAUpdatesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListOTAUpdatesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + otaUpdates: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.otaUpdates !== undefined && data.otaUpdates !== null) { + contents.otaUpdates = deserializeAws_restJson1OTAUpdatesSummary(data.otaUpdates, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListOTAUpdatesCommand = deserializeAws_restJson1ListOTAUpdatesCommand; +const deserializeAws_restJson1ListOTAUpdatesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListOutgoingCertificatesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListOutgoingCertificatesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextMarker: undefined, + outgoingCertificates: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + if (data.outgoingCertificates !== undefined && data.outgoingCertificates !== null) { + contents.outgoingCertificates = deserializeAws_restJson1OutgoingCertificates(data.outgoingCertificates, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListOutgoingCertificatesCommand = deserializeAws_restJson1ListOutgoingCertificatesCommand; +const deserializeAws_restJson1ListOutgoingCertificatesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListPoliciesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListPoliciesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextMarker: undefined, + policies: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + if (data.policies !== undefined && data.policies !== null) { + contents.policies = deserializeAws_restJson1Policies(data.policies, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListPoliciesCommand = deserializeAws_restJson1ListPoliciesCommand; +const deserializeAws_restJson1ListPoliciesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListPolicyPrincipalsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListPolicyPrincipalsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextMarker: undefined, + principals: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + if (data.principals !== undefined && data.principals !== null) { + contents.principals = deserializeAws_restJson1Principals(data.principals, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListPolicyPrincipalsCommand = deserializeAws_restJson1ListPolicyPrincipalsCommand; +const deserializeAws_restJson1ListPolicyPrincipalsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListPolicyVersionsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListPolicyVersionsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + policyVersions: undefined, + }; + const data = await parseBody(output.body, context); + if (data.policyVersions !== undefined && data.policyVersions !== null) { + contents.policyVersions = deserializeAws_restJson1PolicyVersions(data.policyVersions, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListPolicyVersionsCommand = deserializeAws_restJson1ListPolicyVersionsCommand; +const deserializeAws_restJson1ListPolicyVersionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListPrincipalPoliciesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListPrincipalPoliciesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextMarker: undefined, + policies: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + if (data.policies !== undefined && data.policies !== null) { + contents.policies = deserializeAws_restJson1Policies(data.policies, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListPrincipalPoliciesCommand = deserializeAws_restJson1ListPrincipalPoliciesCommand; +const deserializeAws_restJson1ListPrincipalPoliciesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListPrincipalThingsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListPrincipalThingsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + things: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.things !== undefined && data.things !== null) { + contents.things = deserializeAws_restJson1ThingNameList(data.things, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListPrincipalThingsCommand = deserializeAws_restJson1ListPrincipalThingsCommand; +const deserializeAws_restJson1ListPrincipalThingsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListProvisioningTemplatesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListProvisioningTemplatesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + templates: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.templates !== undefined && data.templates !== null) { + contents.templates = deserializeAws_restJson1ProvisioningTemplateListing(data.templates, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListProvisioningTemplatesCommand = deserializeAws_restJson1ListProvisioningTemplatesCommand; +const deserializeAws_restJson1ListProvisioningTemplatesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListProvisioningTemplateVersionsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListProvisioningTemplateVersionsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + versions: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.versions !== undefined && data.versions !== null) { + contents.versions = deserializeAws_restJson1ProvisioningTemplateVersionListing(data.versions, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListProvisioningTemplateVersionsCommand = deserializeAws_restJson1ListProvisioningTemplateVersionsCommand; +const deserializeAws_restJson1ListProvisioningTemplateVersionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListRoleAliasesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListRoleAliasesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextMarker: undefined, + roleAliases: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + if (data.roleAliases !== undefined && data.roleAliases !== null) { + contents.roleAliases = deserializeAws_restJson1RoleAliases(data.roleAliases, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListRoleAliasesCommand = deserializeAws_restJson1ListRoleAliasesCommand; +const deserializeAws_restJson1ListRoleAliasesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListScheduledAuditsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListScheduledAuditsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + scheduledAudits: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.scheduledAudits !== undefined && data.scheduledAudits !== null) { + contents.scheduledAudits = deserializeAws_restJson1ScheduledAuditMetadataList(data.scheduledAudits, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListScheduledAuditsCommand = deserializeAws_restJson1ListScheduledAuditsCommand; +const deserializeAws_restJson1ListScheduledAuditsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListSecurityProfilesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListSecurityProfilesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + securityProfileIdentifiers: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.securityProfileIdentifiers !== undefined && data.securityProfileIdentifiers !== null) { + contents.securityProfileIdentifiers = deserializeAws_restJson1SecurityProfileIdentifiers(data.securityProfileIdentifiers, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListSecurityProfilesCommand = deserializeAws_restJson1ListSecurityProfilesCommand; +const deserializeAws_restJson1ListSecurityProfilesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListSecurityProfilesForTargetCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListSecurityProfilesForTargetCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + securityProfileTargetMappings: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.securityProfileTargetMappings !== undefined && data.securityProfileTargetMappings !== null) { + contents.securityProfileTargetMappings = deserializeAws_restJson1SecurityProfileTargetMappings(data.securityProfileTargetMappings, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListSecurityProfilesForTargetCommand = deserializeAws_restJson1ListSecurityProfilesForTargetCommand; +const deserializeAws_restJson1ListSecurityProfilesForTargetCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListStreamsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListStreamsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + streams: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.streams !== undefined && data.streams !== null) { + contents.streams = deserializeAws_restJson1StreamsSummary(data.streams, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListStreamsCommand = deserializeAws_restJson1ListStreamsCommand; +const deserializeAws_restJson1ListStreamsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListTagsForResourceCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListTagsForResourceCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + tags: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.tags !== undefined && data.tags !== null) { + contents.tags = deserializeAws_restJson1TagList(data.tags, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListTagsForResourceCommand = deserializeAws_restJson1ListTagsForResourceCommand; +const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListTargetsForPolicyCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListTargetsForPolicyCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextMarker: undefined, + targets: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextMarker !== undefined && data.nextMarker !== null) { + contents.nextMarker = data.nextMarker; + } + if (data.targets !== undefined && data.targets !== null) { + contents.targets = deserializeAws_restJson1PolicyTargets(data.targets, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListTargetsForPolicyCommand = deserializeAws_restJson1ListTargetsForPolicyCommand; +const deserializeAws_restJson1ListTargetsForPolicyCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListTargetsForSecurityProfileCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListTargetsForSecurityProfileCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + securityProfileTargets: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.securityProfileTargets !== undefined && data.securityProfileTargets !== null) { + contents.securityProfileTargets = deserializeAws_restJson1SecurityProfileTargets(data.securityProfileTargets, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListTargetsForSecurityProfileCommand = deserializeAws_restJson1ListTargetsForSecurityProfileCommand; +const deserializeAws_restJson1ListTargetsForSecurityProfileCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListThingGroupsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListThingGroupsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + thingGroups: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.thingGroups !== undefined && data.thingGroups !== null) { + contents.thingGroups = deserializeAws_restJson1ThingGroupNameAndArnList(data.thingGroups, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListThingGroupsCommand = deserializeAws_restJson1ListThingGroupsCommand; +const deserializeAws_restJson1ListThingGroupsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListThingGroupsForThingCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListThingGroupsForThingCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + thingGroups: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.thingGroups !== undefined && data.thingGroups !== null) { + contents.thingGroups = deserializeAws_restJson1ThingGroupNameAndArnList(data.thingGroups, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListThingGroupsForThingCommand = deserializeAws_restJson1ListThingGroupsForThingCommand; +const deserializeAws_restJson1ListThingGroupsForThingCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListThingPrincipalsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListThingPrincipalsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + principals: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.principals !== undefined && data.principals !== null) { + contents.principals = deserializeAws_restJson1Principals(data.principals, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListThingPrincipalsCommand = deserializeAws_restJson1ListThingPrincipalsCommand; +const deserializeAws_restJson1ListThingPrincipalsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListThingRegistrationTaskReportsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListThingRegistrationTaskReportsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + reportType: undefined, + resourceLinks: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.reportType !== undefined && data.reportType !== null) { + contents.reportType = data.reportType; + } + if (data.resourceLinks !== undefined && data.resourceLinks !== null) { + contents.resourceLinks = deserializeAws_restJson1S3FileUrlList(data.resourceLinks, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListThingRegistrationTaskReportsCommand = deserializeAws_restJson1ListThingRegistrationTaskReportsCommand; +const deserializeAws_restJson1ListThingRegistrationTaskReportsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListThingRegistrationTasksCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListThingRegistrationTasksCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + taskIds: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.taskIds !== undefined && data.taskIds !== null) { + contents.taskIds = deserializeAws_restJson1TaskIdList(data.taskIds, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListThingRegistrationTasksCommand = deserializeAws_restJson1ListThingRegistrationTasksCommand; +const deserializeAws_restJson1ListThingRegistrationTasksCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListThingsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListThingsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + things: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.things !== undefined && data.things !== null) { + contents.things = deserializeAws_restJson1ThingAttributeList(data.things, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListThingsCommand = deserializeAws_restJson1ListThingsCommand; +const deserializeAws_restJson1ListThingsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListThingsInBillingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListThingsInBillingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + things: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.things !== undefined && data.things !== null) { + contents.things = deserializeAws_restJson1ThingNameList(data.things, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListThingsInBillingGroupCommand = deserializeAws_restJson1ListThingsInBillingGroupCommand; +const deserializeAws_restJson1ListThingsInBillingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListThingsInThingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListThingsInThingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + things: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.things !== undefined && data.things !== null) { + contents.things = deserializeAws_restJson1ThingNameList(data.things, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListThingsInThingGroupCommand = deserializeAws_restJson1ListThingsInThingGroupCommand; +const deserializeAws_restJson1ListThingsInThingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListThingTypesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListThingTypesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + thingTypes: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.thingTypes !== undefined && data.thingTypes !== null) { + contents.thingTypes = deserializeAws_restJson1ThingTypeList(data.thingTypes, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListThingTypesCommand = deserializeAws_restJson1ListThingTypesCommand; +const deserializeAws_restJson1ListThingTypesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListTopicRuleDestinationsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListTopicRuleDestinationsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + destinationSummaries: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.destinationSummaries !== undefined && data.destinationSummaries !== null) { + contents.destinationSummaries = deserializeAws_restJson1TopicRuleDestinationSummaries(data.destinationSummaries, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListTopicRuleDestinationsCommand = deserializeAws_restJson1ListTopicRuleDestinationsCommand; +const deserializeAws_restJson1ListTopicRuleDestinationsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListTopicRulesCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListTopicRulesCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + rules: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.rules !== undefined && data.rules !== null) { + contents.rules = deserializeAws_restJson1TopicRuleList(data.rules, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListTopicRulesCommand = deserializeAws_restJson1ListTopicRulesCommand; +const deserializeAws_restJson1ListTopicRulesCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListV2LoggingLevelsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListV2LoggingLevelsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + logTargetConfigurations: undefined, + nextToken: undefined, + }; + const data = await parseBody(output.body, context); + if (data.logTargetConfigurations !== undefined && data.logTargetConfigurations !== null) { + contents.logTargetConfigurations = deserializeAws_restJson1LogTargetConfigurations(data.logTargetConfigurations, context); + } + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListV2LoggingLevelsCommand = deserializeAws_restJson1ListV2LoggingLevelsCommand; +const deserializeAws_restJson1ListV2LoggingLevelsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotConfiguredException": + case "com.amazonaws.iot#NotConfiguredException": + response = { + ...(await deserializeAws_restJson1NotConfiguredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ListViolationEventsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ListViolationEventsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + violationEvents: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.violationEvents !== undefined && data.violationEvents !== null) { + contents.violationEvents = deserializeAws_restJson1ViolationEvents(data.violationEvents, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ListViolationEventsCommand = deserializeAws_restJson1ListViolationEventsCommand; +const deserializeAws_restJson1ListViolationEventsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1RegisterCACertificateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1RegisterCACertificateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificateArn: undefined, + certificateId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificateArn !== undefined && data.certificateArn !== null) { + contents.certificateArn = data.certificateArn; + } + if (data.certificateId !== undefined && data.certificateId !== null) { + contents.certificateId = data.certificateId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1RegisterCACertificateCommand = deserializeAws_restJson1RegisterCACertificateCommand; +const deserializeAws_restJson1RegisterCACertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CertificateValidationException": + case "com.amazonaws.iot#CertificateValidationException": + response = { + ...(await deserializeAws_restJson1CertificateValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "RegistrationCodeValidationException": + case "com.amazonaws.iot#RegistrationCodeValidationException": + response = { + ...(await deserializeAws_restJson1RegistrationCodeValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1RegisterCertificateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1RegisterCertificateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificateArn: undefined, + certificateId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificateArn !== undefined && data.certificateArn !== null) { + contents.certificateArn = data.certificateArn; + } + if (data.certificateId !== undefined && data.certificateId !== null) { + contents.certificateId = data.certificateId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1RegisterCertificateCommand = deserializeAws_restJson1RegisterCertificateCommand; +const deserializeAws_restJson1RegisterCertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CertificateConflictException": + case "com.amazonaws.iot#CertificateConflictException": + response = { + ...(await deserializeAws_restJson1CertificateConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "CertificateStateException": + case "com.amazonaws.iot#CertificateStateException": + response = { + ...(await deserializeAws_restJson1CertificateStateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "CertificateValidationException": + case "com.amazonaws.iot#CertificateValidationException": + response = { + ...(await deserializeAws_restJson1CertificateValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1RegisterCertificateWithoutCACommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1RegisterCertificateWithoutCACommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificateArn: undefined, + certificateId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificateArn !== undefined && data.certificateArn !== null) { + contents.certificateArn = data.certificateArn; + } + if (data.certificateId !== undefined && data.certificateId !== null) { + contents.certificateId = data.certificateId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1RegisterCertificateWithoutCACommand = deserializeAws_restJson1RegisterCertificateWithoutCACommand; +const deserializeAws_restJson1RegisterCertificateWithoutCACommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CertificateStateException": + case "com.amazonaws.iot#CertificateStateException": + response = { + ...(await deserializeAws_restJson1CertificateStateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "CertificateValidationException": + case "com.amazonaws.iot#CertificateValidationException": + response = { + ...(await deserializeAws_restJson1CertificateValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1RegisterThingCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1RegisterThingCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + certificatePem: undefined, + resourceArns: undefined, + }; + const data = await parseBody(output.body, context); + if (data.certificatePem !== undefined && data.certificatePem !== null) { + contents.certificatePem = data.certificatePem; + } + if (data.resourceArns !== undefined && data.resourceArns !== null) { + contents.resourceArns = deserializeAws_restJson1ResourceArns(data.resourceArns, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1RegisterThingCommand = deserializeAws_restJson1RegisterThingCommand; +const deserializeAws_restJson1RegisterThingCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceRegistrationFailureException": + case "com.amazonaws.iot#ResourceRegistrationFailureException": + response = { + ...(await deserializeAws_restJson1ResourceRegistrationFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1RejectCertificateTransferCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1RejectCertificateTransferCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1RejectCertificateTransferCommand = deserializeAws_restJson1RejectCertificateTransferCommand; +const deserializeAws_restJson1RejectCertificateTransferCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TransferAlreadyCompletedException": + case "com.amazonaws.iot#TransferAlreadyCompletedException": + response = { + ...(await deserializeAws_restJson1TransferAlreadyCompletedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1RemoveThingFromBillingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1RemoveThingFromBillingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1RemoveThingFromBillingGroupCommand = deserializeAws_restJson1RemoveThingFromBillingGroupCommand; +const deserializeAws_restJson1RemoveThingFromBillingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1RemoveThingFromThingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1RemoveThingFromThingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1RemoveThingFromThingGroupCommand = deserializeAws_restJson1RemoveThingFromThingGroupCommand; +const deserializeAws_restJson1RemoveThingFromThingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ReplaceTopicRuleCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ReplaceTopicRuleCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ReplaceTopicRuleCommand = deserializeAws_restJson1ReplaceTopicRuleCommand; +const deserializeAws_restJson1ReplaceTopicRuleCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "SqlParseException": + case "com.amazonaws.iot#SqlParseException": + response = { + ...(await deserializeAws_restJson1SqlParseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1SearchIndexCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1SearchIndexCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + nextToken: undefined, + thingGroups: undefined, + things: undefined, + }; + const data = await parseBody(output.body, context); + if (data.nextToken !== undefined && data.nextToken !== null) { + contents.nextToken = data.nextToken; + } + if (data.thingGroups !== undefined && data.thingGroups !== null) { + contents.thingGroups = deserializeAws_restJson1ThingGroupDocumentList(data.thingGroups, context); + } + if (data.things !== undefined && data.things !== null) { + contents.things = deserializeAws_restJson1ThingDocumentList(data.things, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1SearchIndexCommand = deserializeAws_restJson1SearchIndexCommand; +const deserializeAws_restJson1SearchIndexCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "IndexNotReadyException": + case "com.amazonaws.iot#IndexNotReadyException": + response = { + ...(await deserializeAws_restJson1IndexNotReadyExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidQueryException": + case "com.amazonaws.iot#InvalidQueryException": + response = { + ...(await deserializeAws_restJson1InvalidQueryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1SetDefaultAuthorizerCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1SetDefaultAuthorizerCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + authorizerArn: undefined, + authorizerName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.authorizerArn !== undefined && data.authorizerArn !== null) { + contents.authorizerArn = data.authorizerArn; + } + if (data.authorizerName !== undefined && data.authorizerName !== null) { + contents.authorizerName = data.authorizerName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1SetDefaultAuthorizerCommand = deserializeAws_restJson1SetDefaultAuthorizerCommand; +const deserializeAws_restJson1SetDefaultAuthorizerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceAlreadyExistsException": + case "com.amazonaws.iot#ResourceAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1SetDefaultPolicyVersionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1SetDefaultPolicyVersionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1SetDefaultPolicyVersionCommand = deserializeAws_restJson1SetDefaultPolicyVersionCommand; +const deserializeAws_restJson1SetDefaultPolicyVersionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1SetLoggingOptionsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1SetLoggingOptionsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1SetLoggingOptionsCommand = deserializeAws_restJson1SetLoggingOptionsCommand; +const deserializeAws_restJson1SetLoggingOptionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1SetV2LoggingLevelCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1SetV2LoggingLevelCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1SetV2LoggingLevelCommand = deserializeAws_restJson1SetV2LoggingLevelCommand; +const deserializeAws_restJson1SetV2LoggingLevelCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "NotConfiguredException": + case "com.amazonaws.iot#NotConfiguredException": + response = { + ...(await deserializeAws_restJson1NotConfiguredExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1SetV2LoggingOptionsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1SetV2LoggingOptionsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1SetV2LoggingOptionsCommand = deserializeAws_restJson1SetV2LoggingOptionsCommand; +const deserializeAws_restJson1SetV2LoggingOptionsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1StartAuditMitigationActionsTaskCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1StartAuditMitigationActionsTaskCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + taskId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.taskId !== undefined && data.taskId !== null) { + contents.taskId = data.taskId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1StartAuditMitigationActionsTaskCommand = deserializeAws_restJson1StartAuditMitigationActionsTaskCommand; +const deserializeAws_restJson1StartAuditMitigationActionsTaskCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TaskAlreadyExistsException": + case "com.amazonaws.iot#TaskAlreadyExistsException": + response = { + ...(await deserializeAws_restJson1TaskAlreadyExistsExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1StartOnDemandAuditTaskCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1StartOnDemandAuditTaskCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + taskId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.taskId !== undefined && data.taskId !== null) { + contents.taskId = data.taskId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1StartOnDemandAuditTaskCommand = deserializeAws_restJson1StartOnDemandAuditTaskCommand; +const deserializeAws_restJson1StartOnDemandAuditTaskCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1StartThingRegistrationTaskCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1StartThingRegistrationTaskCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + taskId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.taskId !== undefined && data.taskId !== null) { + contents.taskId = data.taskId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1StartThingRegistrationTaskCommand = deserializeAws_restJson1StartThingRegistrationTaskCommand; +const deserializeAws_restJson1StartThingRegistrationTaskCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1StopThingRegistrationTaskCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1StopThingRegistrationTaskCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1StopThingRegistrationTaskCommand = deserializeAws_restJson1StopThingRegistrationTaskCommand; +const deserializeAws_restJson1StopThingRegistrationTaskCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1TagResourceCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1TagResourceCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1TagResourceCommand = deserializeAws_restJson1TagResourceCommand; +const deserializeAws_restJson1TagResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1TestAuthorizationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1TestAuthorizationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + authResults: undefined, + }; + const data = await parseBody(output.body, context); + if (data.authResults !== undefined && data.authResults !== null) { + contents.authResults = deserializeAws_restJson1AuthResults(data.authResults, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1TestAuthorizationCommand = deserializeAws_restJson1TestAuthorizationCommand; +const deserializeAws_restJson1TestAuthorizationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1TestInvokeAuthorizerCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1TestInvokeAuthorizerCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + disconnectAfterInSeconds: undefined, + isAuthenticated: undefined, + policyDocuments: undefined, + principalId: undefined, + refreshAfterInSeconds: undefined, + }; + const data = await parseBody(output.body, context); + if (data.disconnectAfterInSeconds !== undefined && data.disconnectAfterInSeconds !== null) { + contents.disconnectAfterInSeconds = data.disconnectAfterInSeconds; + } + if (data.isAuthenticated !== undefined && data.isAuthenticated !== null) { + contents.isAuthenticated = data.isAuthenticated; + } + if (data.policyDocuments !== undefined && data.policyDocuments !== null) { + contents.policyDocuments = deserializeAws_restJson1PolicyDocuments(data.policyDocuments, context); + } + if (data.principalId !== undefined && data.principalId !== null) { + contents.principalId = data.principalId; + } + if (data.refreshAfterInSeconds !== undefined && data.refreshAfterInSeconds !== null) { + contents.refreshAfterInSeconds = data.refreshAfterInSeconds; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1TestInvokeAuthorizerCommand = deserializeAws_restJson1TestInvokeAuthorizerCommand; +const deserializeAws_restJson1TestInvokeAuthorizerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidResponseException": + case "com.amazonaws.iot#InvalidResponseException": + response = { + ...(await deserializeAws_restJson1InvalidResponseExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1TransferCertificateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1TransferCertificateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + transferredCertificateArn: undefined, + }; + const data = await parseBody(output.body, context); + if (data.transferredCertificateArn !== undefined && data.transferredCertificateArn !== null) { + contents.transferredCertificateArn = data.transferredCertificateArn; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1TransferCertificateCommand = deserializeAws_restJson1TransferCertificateCommand; +const deserializeAws_restJson1TransferCertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CertificateStateException": + case "com.amazonaws.iot#CertificateStateException": + response = { + ...(await deserializeAws_restJson1CertificateStateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "TransferConflictException": + case "com.amazonaws.iot#TransferConflictException": + response = { + ...(await deserializeAws_restJson1TransferConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UntagResourceCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UntagResourceCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UntagResourceCommand = deserializeAws_restJson1UntagResourceCommand; +const deserializeAws_restJson1UntagResourceCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateAccountAuditConfigurationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateAccountAuditConfigurationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateAccountAuditConfigurationCommand = deserializeAws_restJson1UpdateAccountAuditConfigurationCommand; +const deserializeAws_restJson1UpdateAccountAuditConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateAuditSuppressionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateAuditSuppressionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateAuditSuppressionCommand = deserializeAws_restJson1UpdateAuditSuppressionCommand; +const deserializeAws_restJson1UpdateAuditSuppressionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateAuthorizerCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateAuthorizerCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + authorizerArn: undefined, + authorizerName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.authorizerArn !== undefined && data.authorizerArn !== null) { + contents.authorizerArn = data.authorizerArn; + } + if (data.authorizerName !== undefined && data.authorizerName !== null) { + contents.authorizerName = data.authorizerName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateAuthorizerCommand = deserializeAws_restJson1UpdateAuthorizerCommand; +const deserializeAws_restJson1UpdateAuthorizerCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "LimitExceededException": + case "com.amazonaws.iot#LimitExceededException": + response = { + ...(await deserializeAws_restJson1LimitExceededExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateBillingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateBillingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + version: undefined, + }; + const data = await parseBody(output.body, context); + if (data.version !== undefined && data.version !== null) { + contents.version = data.version; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateBillingGroupCommand = deserializeAws_restJson1UpdateBillingGroupCommand; +const deserializeAws_restJson1UpdateBillingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateCACertificateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateCACertificateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateCACertificateCommand = deserializeAws_restJson1UpdateCACertificateCommand; +const deserializeAws_restJson1UpdateCACertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateCertificateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateCertificateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateCertificateCommand = deserializeAws_restJson1UpdateCertificateCommand; +const deserializeAws_restJson1UpdateCertificateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CertificateStateException": + case "com.amazonaws.iot#CertificateStateException": + response = { + ...(await deserializeAws_restJson1CertificateStateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateDimensionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateDimensionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + arn: undefined, + creationDate: undefined, + lastModifiedDate: undefined, + name: undefined, + stringValues: undefined, + type: undefined, + }; + const data = await parseBody(output.body, context); + if (data.arn !== undefined && data.arn !== null) { + contents.arn = data.arn; + } + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.lastModifiedDate !== undefined && data.lastModifiedDate !== null) { + contents.lastModifiedDate = new Date(Math.round(data.lastModifiedDate * 1000)); + } + if (data.name !== undefined && data.name !== null) { + contents.name = data.name; + } + if (data.stringValues !== undefined && data.stringValues !== null) { + contents.stringValues = deserializeAws_restJson1DimensionStringValues(data.stringValues, context); + } + if (data.type !== undefined && data.type !== null) { + contents.type = data.type; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateDimensionCommand = deserializeAws_restJson1UpdateDimensionCommand; +const deserializeAws_restJson1UpdateDimensionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateDomainConfigurationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateDomainConfigurationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + domainConfigurationArn: undefined, + domainConfigurationName: undefined, + }; + const data = await parseBody(output.body, context); + if (data.domainConfigurationArn !== undefined && data.domainConfigurationArn !== null) { + contents.domainConfigurationArn = data.domainConfigurationArn; + } + if (data.domainConfigurationName !== undefined && data.domainConfigurationName !== null) { + contents.domainConfigurationName = data.domainConfigurationName; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateDomainConfigurationCommand = deserializeAws_restJson1UpdateDomainConfigurationCommand; +const deserializeAws_restJson1UpdateDomainConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "CertificateValidationException": + case "com.amazonaws.iot#CertificateValidationException": + response = { + ...(await deserializeAws_restJson1CertificateValidationExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateDynamicThingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateDynamicThingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + version: undefined, + }; + const data = await parseBody(output.body, context); + if (data.version !== undefined && data.version !== null) { + contents.version = data.version; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateDynamicThingGroupCommand = deserializeAws_restJson1UpdateDynamicThingGroupCommand; +const deserializeAws_restJson1UpdateDynamicThingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidQueryException": + case "com.amazonaws.iot#InvalidQueryException": + response = { + ...(await deserializeAws_restJson1InvalidQueryExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateEventConfigurationsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateEventConfigurationsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateEventConfigurationsCommand = deserializeAws_restJson1UpdateEventConfigurationsCommand; +const deserializeAws_restJson1UpdateEventConfigurationsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateIndexingConfigurationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateIndexingConfigurationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateIndexingConfigurationCommand = deserializeAws_restJson1UpdateIndexingConfigurationCommand; +const deserializeAws_restJson1UpdateIndexingConfigurationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateJobCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateJobCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateJobCommand = deserializeAws_restJson1UpdateJobCommand; +const deserializeAws_restJson1UpdateJobCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateMitigationActionCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateMitigationActionCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + actionArn: undefined, + actionId: undefined, + }; + const data = await parseBody(output.body, context); + if (data.actionArn !== undefined && data.actionArn !== null) { + contents.actionArn = data.actionArn; + } + if (data.actionId !== undefined && data.actionId !== null) { + contents.actionId = data.actionId; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateMitigationActionCommand = deserializeAws_restJson1UpdateMitigationActionCommand; +const deserializeAws_restJson1UpdateMitigationActionCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateProvisioningTemplateCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateProvisioningTemplateCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateProvisioningTemplateCommand = deserializeAws_restJson1UpdateProvisioningTemplateCommand; +const deserializeAws_restJson1UpdateProvisioningTemplateCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateRoleAliasCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateRoleAliasCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + roleAlias: undefined, + roleAliasArn: undefined, + }; + const data = await parseBody(output.body, context); + if (data.roleAlias !== undefined && data.roleAlias !== null) { + contents.roleAlias = data.roleAlias; + } + if (data.roleAliasArn !== undefined && data.roleAliasArn !== null) { + contents.roleAliasArn = data.roleAliasArn; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateRoleAliasCommand = deserializeAws_restJson1UpdateRoleAliasCommand; +const deserializeAws_restJson1UpdateRoleAliasCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateScheduledAuditCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateScheduledAuditCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + scheduledAuditArn: undefined, + }; + const data = await parseBody(output.body, context); + if (data.scheduledAuditArn !== undefined && data.scheduledAuditArn !== null) { + contents.scheduledAuditArn = data.scheduledAuditArn; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateScheduledAuditCommand = deserializeAws_restJson1UpdateScheduledAuditCommand; +const deserializeAws_restJson1UpdateScheduledAuditCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateSecurityProfileCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateSecurityProfileCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + additionalMetricsToRetain: undefined, + additionalMetricsToRetainV2: undefined, + alertTargets: undefined, + behaviors: undefined, + creationDate: undefined, + lastModifiedDate: undefined, + securityProfileArn: undefined, + securityProfileDescription: undefined, + securityProfileName: undefined, + version: undefined, + }; + const data = await parseBody(output.body, context); + if (data.additionalMetricsToRetain !== undefined && data.additionalMetricsToRetain !== null) { + contents.additionalMetricsToRetain = deserializeAws_restJson1AdditionalMetricsToRetainList(data.additionalMetricsToRetain, context); + } + if (data.additionalMetricsToRetainV2 !== undefined && data.additionalMetricsToRetainV2 !== null) { + contents.additionalMetricsToRetainV2 = deserializeAws_restJson1AdditionalMetricsToRetainV2List(data.additionalMetricsToRetainV2, context); + } + if (data.alertTargets !== undefined && data.alertTargets !== null) { + contents.alertTargets = deserializeAws_restJson1AlertTargets(data.alertTargets, context); + } + if (data.behaviors !== undefined && data.behaviors !== null) { + contents.behaviors = deserializeAws_restJson1Behaviors(data.behaviors, context); + } + if (data.creationDate !== undefined && data.creationDate !== null) { + contents.creationDate = new Date(Math.round(data.creationDate * 1000)); + } + if (data.lastModifiedDate !== undefined && data.lastModifiedDate !== null) { + contents.lastModifiedDate = new Date(Math.round(data.lastModifiedDate * 1000)); + } + if (data.securityProfileArn !== undefined && data.securityProfileArn !== null) { + contents.securityProfileArn = data.securityProfileArn; + } + if (data.securityProfileDescription !== undefined && data.securityProfileDescription !== null) { + contents.securityProfileDescription = data.securityProfileDescription; + } + if (data.securityProfileName !== undefined && data.securityProfileName !== null) { + contents.securityProfileName = data.securityProfileName; + } + if (data.version !== undefined && data.version !== null) { + contents.version = data.version; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateSecurityProfileCommand = deserializeAws_restJson1UpdateSecurityProfileCommand; +const deserializeAws_restJson1UpdateSecurityProfileCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateStreamCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateStreamCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + description: undefined, + streamArn: undefined, + streamId: undefined, + streamVersion: undefined, + }; + const data = await parseBody(output.body, context); + if (data.description !== undefined && data.description !== null) { + contents.description = data.description; + } + if (data.streamArn !== undefined && data.streamArn !== null) { + contents.streamArn = data.streamArn; + } + if (data.streamId !== undefined && data.streamId !== null) { + contents.streamId = data.streamId; + } + if (data.streamVersion !== undefined && data.streamVersion !== null) { + contents.streamVersion = data.streamVersion; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateStreamCommand = deserializeAws_restJson1UpdateStreamCommand; +const deserializeAws_restJson1UpdateStreamCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateThingCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateThingCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateThingCommand = deserializeAws_restJson1UpdateThingCommand; +const deserializeAws_restJson1UpdateThingCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateThingGroupCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateThingGroupCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + version: undefined, + }; + const data = await parseBody(output.body, context); + if (data.version !== undefined && data.version !== null) { + contents.version = data.version; + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateThingGroupCommand = deserializeAws_restJson1UpdateThingGroupCommand; +const deserializeAws_restJson1UpdateThingGroupCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "VersionConflictException": + case "com.amazonaws.iot#VersionConflictException": + response = { + ...(await deserializeAws_restJson1VersionConflictExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateThingGroupsForThingCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateThingGroupsForThingCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateThingGroupsForThingCommand = deserializeAws_restJson1UpdateThingGroupsForThingCommand; +const deserializeAws_restJson1UpdateThingGroupsForThingCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ResourceNotFoundException": + case "com.amazonaws.iot#ResourceNotFoundException": + response = { + ...(await deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1UpdateTopicRuleDestinationCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1UpdateTopicRuleDestinationCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + }; + await collectBody(output.body, context); + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1UpdateTopicRuleDestinationCommand = deserializeAws_restJson1UpdateTopicRuleDestinationCommand; +const deserializeAws_restJson1UpdateTopicRuleDestinationCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "ConflictingResourceUpdateException": + case "com.amazonaws.iot#ConflictingResourceUpdateException": + response = { + ...(await deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InternalException": + case "com.amazonaws.iot#InternalException": + response = { + ...(await deserializeAws_restJson1InternalExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ServiceUnavailableException": + case "com.amazonaws.iot#ServiceUnavailableException": + response = { + ...(await deserializeAws_restJson1ServiceUnavailableExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "UnauthorizedException": + case "com.amazonaws.iot#UnauthorizedException": + response = { + ...(await deserializeAws_restJson1UnauthorizedExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1ValidateSecurityProfileBehaviorsCommand = async (output, context) => { + if (output.statusCode !== 200 && output.statusCode >= 300) { + return deserializeAws_restJson1ValidateSecurityProfileBehaviorsCommandError(output, context); + } + const contents = { + $metadata: deserializeMetadata(output), + valid: undefined, + validationErrors: undefined, + }; + const data = await parseBody(output.body, context); + if (data.valid !== undefined && data.valid !== null) { + contents.valid = data.valid; + } + if (data.validationErrors !== undefined && data.validationErrors !== null) { + contents.validationErrors = deserializeAws_restJson1ValidationErrors(data.validationErrors, context); + } + return Promise.resolve(contents); +}; +exports.deserializeAws_restJson1ValidateSecurityProfileBehaviorsCommand = deserializeAws_restJson1ValidateSecurityProfileBehaviorsCommand; +const deserializeAws_restJson1ValidateSecurityProfileBehaviorsCommandError = async (output, context) => { + const parsedOutput = { + ...output, + body: await parseBody(output.body, context), + }; + let response; + let errorCode = "UnknownError"; + errorCode = loadRestJsonErrorCode(output, parsedOutput.body); + switch (errorCode) { + case "InternalFailureException": + case "com.amazonaws.iot#InternalFailureException": + response = { + ...(await deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "InvalidRequestException": + case "com.amazonaws.iot#InvalidRequestException": + response = { + ...(await deserializeAws_restJson1InvalidRequestExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + case "ThrottlingException": + case "com.amazonaws.iot#ThrottlingException": + response = { + ...(await deserializeAws_restJson1ThrottlingExceptionResponse(parsedOutput, context)), + name: errorCode, + $metadata: deserializeMetadata(output), + }; + break; + default: + const parsedBody = parsedOutput.body; + errorCode = parsedBody.code || parsedBody.Code || errorCode; + response = { + ...parsedBody, + name: `${errorCode}`, + message: parsedBody.message || parsedBody.Message || errorCode, + $fault: "client", + $metadata: deserializeMetadata(output), + }; + } + const message = response.message || response.Message || errorCode; + response.message = message; + delete response.Message; + return Promise.reject(Object.assign(new Error(message), response)); +}; +const deserializeAws_restJson1CertificateConflictExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "CertificateConflictException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1CertificateStateExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "CertificateStateException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1CertificateValidationExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "CertificateValidationException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1ConflictingResourceUpdateExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "ConflictingResourceUpdateException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1DeleteConflictExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "DeleteConflictException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1IndexNotReadyExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "IndexNotReadyException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1InternalExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "InternalException", + $fault: "server", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1InternalFailureExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "InternalFailureException", + $fault: "server", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1InvalidAggregationExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "InvalidAggregationException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1InvalidQueryExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "InvalidQueryException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1InvalidRequestExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "InvalidRequestException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1InvalidResponseExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "InvalidResponseException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1InvalidStateTransitionExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "InvalidStateTransitionException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1LimitExceededExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "LimitExceededException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1MalformedPolicyExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "MalformedPolicyException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1NotConfiguredExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "NotConfiguredException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1RegistrationCodeValidationExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "RegistrationCodeValidationException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1ResourceAlreadyExistsExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "ResourceAlreadyExistsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + resourceArn: undefined, + resourceId: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + if (data.resourceArn !== undefined && data.resourceArn !== null) { + contents.resourceArn = data.resourceArn; + } + if (data.resourceId !== undefined && data.resourceId !== null) { + contents.resourceId = data.resourceId; + } + return contents; +}; +const deserializeAws_restJson1ResourceNotFoundExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "ResourceNotFoundException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1ResourceRegistrationFailureExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "ResourceRegistrationFailureException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1ServiceUnavailableExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "ServiceUnavailableException", + $fault: "server", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1SqlParseExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "SqlParseException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1TaskAlreadyExistsExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "TaskAlreadyExistsException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1ThrottlingExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "ThrottlingException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1TransferAlreadyCompletedExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "TransferAlreadyCompletedException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1TransferConflictExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "TransferConflictException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1UnauthorizedExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "UnauthorizedException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1VersionConflictExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "VersionConflictException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const deserializeAws_restJson1VersionsLimitExceededExceptionResponse = async (parsedOutput, context) => { + const contents = { + name: "VersionsLimitExceededException", + $fault: "client", + $metadata: deserializeMetadata(parsedOutput), + message: undefined, + }; + const data = parsedOutput.body; + if (data.message !== undefined && data.message !== null) { + contents.message = data.message; + } + return contents; +}; +const serializeAws_restJson1AbortConfig = (input, context) => { + return { + ...(input.criteriaList !== undefined && + input.criteriaList !== null && { + criteriaList: serializeAws_restJson1AbortCriteriaList(input.criteriaList, context), + }), + }; +}; +const serializeAws_restJson1AbortCriteria = (input, context) => { + return { + ...(input.action !== undefined && input.action !== null && { action: input.action }), + ...(input.failureType !== undefined && input.failureType !== null && { failureType: input.failureType }), + ...(input.minNumberOfExecutedThings !== undefined && + input.minNumberOfExecutedThings !== null && { minNumberOfExecutedThings: input.minNumberOfExecutedThings }), + ...(input.thresholdPercentage !== undefined && + input.thresholdPercentage !== null && { thresholdPercentage: input.thresholdPercentage }), + }; +}; +const serializeAws_restJson1AbortCriteriaList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1AbortCriteria(entry, context); + }); +}; +const serializeAws_restJson1Action = (input, context) => { + return { + ...(input.cloudwatchAlarm !== undefined && + input.cloudwatchAlarm !== null && { + cloudwatchAlarm: serializeAws_restJson1CloudwatchAlarmAction(input.cloudwatchAlarm, context), + }), + ...(input.cloudwatchLogs !== undefined && + input.cloudwatchLogs !== null && { + cloudwatchLogs: serializeAws_restJson1CloudwatchLogsAction(input.cloudwatchLogs, context), + }), + ...(input.cloudwatchMetric !== undefined && + input.cloudwatchMetric !== null && { + cloudwatchMetric: serializeAws_restJson1CloudwatchMetricAction(input.cloudwatchMetric, context), + }), + ...(input.dynamoDB !== undefined && + input.dynamoDB !== null && { dynamoDB: serializeAws_restJson1DynamoDBAction(input.dynamoDB, context) }), + ...(input.dynamoDBv2 !== undefined && + input.dynamoDBv2 !== null && { dynamoDBv2: serializeAws_restJson1DynamoDBv2Action(input.dynamoDBv2, context) }), + ...(input.elasticsearch !== undefined && + input.elasticsearch !== null && { + elasticsearch: serializeAws_restJson1ElasticsearchAction(input.elasticsearch, context), + }), + ...(input.firehose !== undefined && + input.firehose !== null && { firehose: serializeAws_restJson1FirehoseAction(input.firehose, context) }), + ...(input.http !== undefined && + input.http !== null && { http: serializeAws_restJson1HttpAction(input.http, context) }), + ...(input.iotAnalytics !== undefined && + input.iotAnalytics !== null && { + iotAnalytics: serializeAws_restJson1IotAnalyticsAction(input.iotAnalytics, context), + }), + ...(input.iotEvents !== undefined && + input.iotEvents !== null && { iotEvents: serializeAws_restJson1IotEventsAction(input.iotEvents, context) }), + ...(input.iotSiteWise !== undefined && + input.iotSiteWise !== null && { + iotSiteWise: serializeAws_restJson1IotSiteWiseAction(input.iotSiteWise, context), + }), + ...(input.kinesis !== undefined && + input.kinesis !== null && { kinesis: serializeAws_restJson1KinesisAction(input.kinesis, context) }), + ...(input.lambda !== undefined && + input.lambda !== null && { lambda: serializeAws_restJson1LambdaAction(input.lambda, context) }), + ...(input.republish !== undefined && + input.republish !== null && { republish: serializeAws_restJson1RepublishAction(input.republish, context) }), + ...(input.s3 !== undefined && input.s3 !== null && { s3: serializeAws_restJson1S3Action(input.s3, context) }), + ...(input.salesforce !== undefined && + input.salesforce !== null && { salesforce: serializeAws_restJson1SalesforceAction(input.salesforce, context) }), + ...(input.sns !== undefined && input.sns !== null && { sns: serializeAws_restJson1SnsAction(input.sns, context) }), + ...(input.sqs !== undefined && input.sqs !== null && { sqs: serializeAws_restJson1SqsAction(input.sqs, context) }), + ...(input.stepFunctions !== undefined && + input.stepFunctions !== null && { + stepFunctions: serializeAws_restJson1StepFunctionsAction(input.stepFunctions, context), + }), + ...(input.timestream !== undefined && + input.timestream !== null && { timestream: serializeAws_restJson1TimestreamAction(input.timestream, context) }), + }; +}; +const serializeAws_restJson1ActionList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1Action(entry, context); + }); +}; +const serializeAws_restJson1AdditionalMetricsToRetainList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1AdditionalMetricsToRetainV2List = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1MetricToRetain(entry, context); + }); +}; +const serializeAws_restJson1AdditionalParameterMap = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_restJson1AddThingsToThingGroupParams = (input, context) => { + return { + ...(input.overrideDynamicGroups !== undefined && + input.overrideDynamicGroups !== null && { overrideDynamicGroups: input.overrideDynamicGroups }), + ...(input.thingGroupNames !== undefined && + input.thingGroupNames !== null && { + thingGroupNames: serializeAws_restJson1ThingGroupNames(input.thingGroupNames, context), + }), + }; +}; +const serializeAws_restJson1AlertTarget = (input, context) => { + return { + ...(input.alertTargetArn !== undefined && + input.alertTargetArn !== null && { alertTargetArn: input.alertTargetArn }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }; +}; +const serializeAws_restJson1AlertTargets = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: serializeAws_restJson1AlertTarget(value, context), + }; + }, {}); +}; +const serializeAws_restJson1AssetPropertyTimestamp = (input, context) => { + return { + ...(input.offsetInNanos !== undefined && input.offsetInNanos !== null && { offsetInNanos: input.offsetInNanos }), + ...(input.timeInSeconds !== undefined && input.timeInSeconds !== null && { timeInSeconds: input.timeInSeconds }), + }; +}; +const serializeAws_restJson1AssetPropertyValue = (input, context) => { + return { + ...(input.quality !== undefined && input.quality !== null && { quality: input.quality }), + ...(input.timestamp !== undefined && + input.timestamp !== null && { + timestamp: serializeAws_restJson1AssetPropertyTimestamp(input.timestamp, context), + }), + ...(input.value !== undefined && + input.value !== null && { value: serializeAws_restJson1AssetPropertyVariant(input.value, context) }), + }; +}; +const serializeAws_restJson1AssetPropertyValueList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1AssetPropertyValue(entry, context); + }); +}; +const serializeAws_restJson1AssetPropertyVariant = (input, context) => { + return models_0_1.AssetPropertyVariant.visit(input, { + booleanValue: (value) => ({ booleanValue: value }), + doubleValue: (value) => ({ doubleValue: value }), + integerValue: (value) => ({ integerValue: value }), + stringValue: (value) => ({ stringValue: value }), + _: (name, value) => ({ name: value }), + }); +}; +const serializeAws_restJson1AttributePayload = (input, context) => { + return { + ...(input.attributes !== undefined && + input.attributes !== null && { attributes: serializeAws_restJson1Attributes(input.attributes, context) }), + ...(input.merge !== undefined && input.merge !== null && { merge: input.merge }), + }; +}; +const serializeAws_restJson1Attributes = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_restJson1AttributesMap = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_restJson1AuditCheckConfiguration = (input, context) => { + return { + ...(input.enabled !== undefined && input.enabled !== null && { enabled: input.enabled }), + }; +}; +const serializeAws_restJson1AuditCheckConfigurations = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: serializeAws_restJson1AuditCheckConfiguration(value, context), + }; + }, {}); +}; +const serializeAws_restJson1AuditCheckToActionsMapping = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: serializeAws_restJson1MitigationActionNameList(value, context), + }; + }, {}); +}; +const serializeAws_restJson1AuditCheckToReasonCodeFilter = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: serializeAws_restJson1ReasonForNonComplianceCodes(value, context), + }; + }, {}); +}; +const serializeAws_restJson1AuditMitigationActionsTaskTarget = (input, context) => { + return { + ...(input.auditCheckToReasonCodeFilter !== undefined && + input.auditCheckToReasonCodeFilter !== null && { + auditCheckToReasonCodeFilter: serializeAws_restJson1AuditCheckToReasonCodeFilter(input.auditCheckToReasonCodeFilter, context), + }), + ...(input.auditTaskId !== undefined && input.auditTaskId !== null && { auditTaskId: input.auditTaskId }), + ...(input.findingIds !== undefined && + input.findingIds !== null && { findingIds: serializeAws_restJson1FindingIds(input.findingIds, context) }), + }; +}; +const serializeAws_restJson1AuditNotificationTarget = (input, context) => { + return { + ...(input.enabled !== undefined && input.enabled !== null && { enabled: input.enabled }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.targetArn !== undefined && input.targetArn !== null && { targetArn: input.targetArn }), + }; +}; +const serializeAws_restJson1AuditNotificationTargetConfigurations = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: serializeAws_restJson1AuditNotificationTarget(value, context), + }; + }, {}); +}; +const serializeAws_restJson1AuthInfo = (input, context) => { + return { + ...(input.actionType !== undefined && input.actionType !== null && { actionType: input.actionType }), + ...(input.resources !== undefined && + input.resources !== null && { resources: serializeAws_restJson1Resources(input.resources, context) }), + }; +}; +const serializeAws_restJson1AuthInfos = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1AuthInfo(entry, context); + }); +}; +const serializeAws_restJson1AuthorizerConfig = (input, context) => { + return { + ...(input.allowAuthorizerOverride !== undefined && + input.allowAuthorizerOverride !== null && { allowAuthorizerOverride: input.allowAuthorizerOverride }), + ...(input.defaultAuthorizerName !== undefined && + input.defaultAuthorizerName !== null && { defaultAuthorizerName: input.defaultAuthorizerName }), + }; +}; +const serializeAws_restJson1AwsJobAbortConfig = (input, context) => { + return { + ...(input.abortCriteriaList !== undefined && + input.abortCriteriaList !== null && { + abortCriteriaList: serializeAws_restJson1AwsJobAbortCriteriaList(input.abortCriteriaList, context), + }), + }; +}; +const serializeAws_restJson1AwsJobAbortCriteria = (input, context) => { + return { + ...(input.action !== undefined && input.action !== null && { action: input.action }), + ...(input.failureType !== undefined && input.failureType !== null && { failureType: input.failureType }), + ...(input.minNumberOfExecutedThings !== undefined && + input.minNumberOfExecutedThings !== null && { minNumberOfExecutedThings: input.minNumberOfExecutedThings }), + ...(input.thresholdPercentage !== undefined && + input.thresholdPercentage !== null && { thresholdPercentage: input.thresholdPercentage }), + }; +}; +const serializeAws_restJson1AwsJobAbortCriteriaList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1AwsJobAbortCriteria(entry, context); + }); +}; +const serializeAws_restJson1AwsJobExecutionsRolloutConfig = (input, context) => { + return { + ...(input.exponentialRate !== undefined && + input.exponentialRate !== null && { + exponentialRate: serializeAws_restJson1AwsJobExponentialRolloutRate(input.exponentialRate, context), + }), + ...(input.maximumPerMinute !== undefined && + input.maximumPerMinute !== null && { maximumPerMinute: input.maximumPerMinute }), + }; +}; +const serializeAws_restJson1AwsJobExponentialRolloutRate = (input, context) => { + return { + ...(input.baseRatePerMinute !== undefined && + input.baseRatePerMinute !== null && { baseRatePerMinute: input.baseRatePerMinute }), + ...(input.incrementFactor !== undefined && + input.incrementFactor !== null && { incrementFactor: input.incrementFactor }), + ...(input.rateIncreaseCriteria !== undefined && + input.rateIncreaseCriteria !== null && { + rateIncreaseCriteria: serializeAws_restJson1AwsJobRateIncreaseCriteria(input.rateIncreaseCriteria, context), + }), + }; +}; +const serializeAws_restJson1AwsJobPresignedUrlConfig = (input, context) => { + return { + ...(input.expiresInSec !== undefined && input.expiresInSec !== null && { expiresInSec: input.expiresInSec }), + }; +}; +const serializeAws_restJson1AwsJobRateIncreaseCriteria = (input, context) => { + return { + ...(input.numberOfNotifiedThings !== undefined && + input.numberOfNotifiedThings !== null && { numberOfNotifiedThings: input.numberOfNotifiedThings }), + ...(input.numberOfSucceededThings !== undefined && + input.numberOfSucceededThings !== null && { numberOfSucceededThings: input.numberOfSucceededThings }), + }; +}; +const serializeAws_restJson1AwsJobTimeoutConfig = (input, context) => { + return { + ...(input.inProgressTimeoutInMinutes !== undefined && + input.inProgressTimeoutInMinutes !== null && { inProgressTimeoutInMinutes: input.inProgressTimeoutInMinutes }), + }; +}; +const serializeAws_restJson1Behavior = (input, context) => { + return { + ...(input.criteria !== undefined && + input.criteria !== null && { criteria: serializeAws_restJson1BehaviorCriteria(input.criteria, context) }), + ...(input.metric !== undefined && input.metric !== null && { metric: input.metric }), + ...(input.metricDimension !== undefined && + input.metricDimension !== null && { + metricDimension: serializeAws_restJson1MetricDimension(input.metricDimension, context), + }), + ...(input.name !== undefined && input.name !== null && { name: input.name }), + }; +}; +const serializeAws_restJson1BehaviorCriteria = (input, context) => { + return { + ...(input.comparisonOperator !== undefined && + input.comparisonOperator !== null && { comparisonOperator: input.comparisonOperator }), + ...(input.consecutiveDatapointsToAlarm !== undefined && + input.consecutiveDatapointsToAlarm !== null && { + consecutiveDatapointsToAlarm: input.consecutiveDatapointsToAlarm, + }), + ...(input.consecutiveDatapointsToClear !== undefined && + input.consecutiveDatapointsToClear !== null && { + consecutiveDatapointsToClear: input.consecutiveDatapointsToClear, + }), + ...(input.durationSeconds !== undefined && + input.durationSeconds !== null && { durationSeconds: input.durationSeconds }), + ...(input.statisticalThreshold !== undefined && + input.statisticalThreshold !== null && { + statisticalThreshold: serializeAws_restJson1StatisticalThreshold(input.statisticalThreshold, context), + }), + ...(input.value !== undefined && + input.value !== null && { value: serializeAws_restJson1MetricValue(input.value, context) }), + }; +}; +const serializeAws_restJson1Behaviors = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1Behavior(entry, context); + }); +}; +const serializeAws_restJson1BillingGroupProperties = (input, context) => { + return { + ...(input.billingGroupDescription !== undefined && + input.billingGroupDescription !== null && { billingGroupDescription: input.billingGroupDescription }), + }; +}; +const serializeAws_restJson1Cidrs = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1CloudwatchAlarmAction = (input, context) => { + return { + ...(input.alarmName !== undefined && input.alarmName !== null && { alarmName: input.alarmName }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.stateReason !== undefined && input.stateReason !== null && { stateReason: input.stateReason }), + ...(input.stateValue !== undefined && input.stateValue !== null && { stateValue: input.stateValue }), + }; +}; +const serializeAws_restJson1CloudwatchLogsAction = (input, context) => { + return { + ...(input.logGroupName !== undefined && input.logGroupName !== null && { logGroupName: input.logGroupName }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }; +}; +const serializeAws_restJson1CloudwatchMetricAction = (input, context) => { + return { + ...(input.metricName !== undefined && input.metricName !== null && { metricName: input.metricName }), + ...(input.metricNamespace !== undefined && + input.metricNamespace !== null && { metricNamespace: input.metricNamespace }), + ...(input.metricTimestamp !== undefined && + input.metricTimestamp !== null && { metricTimestamp: input.metricTimestamp }), + ...(input.metricUnit !== undefined && input.metricUnit !== null && { metricUnit: input.metricUnit }), + ...(input.metricValue !== undefined && input.metricValue !== null && { metricValue: input.metricValue }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }; +}; +const serializeAws_restJson1CodeSigning = (input, context) => { + return { + ...(input.awsSignerJobId !== undefined && + input.awsSignerJobId !== null && { awsSignerJobId: input.awsSignerJobId }), + ...(input.customCodeSigning !== undefined && + input.customCodeSigning !== null && { + customCodeSigning: serializeAws_restJson1CustomCodeSigning(input.customCodeSigning, context), + }), + ...(input.startSigningJobParameter !== undefined && + input.startSigningJobParameter !== null && { + startSigningJobParameter: serializeAws_restJson1StartSigningJobParameter(input.startSigningJobParameter, context), + }), + }; +}; +const serializeAws_restJson1CodeSigningCertificateChain = (input, context) => { + return { + ...(input.certificateName !== undefined && + input.certificateName !== null && { certificateName: input.certificateName }), + ...(input.inlineDocument !== undefined && + input.inlineDocument !== null && { inlineDocument: input.inlineDocument }), + }; +}; +const serializeAws_restJson1CodeSigningSignature = (input, context) => { + return { + ...(input.inlineDocument !== undefined && + input.inlineDocument !== null && { inlineDocument: context.base64Encoder(input.inlineDocument) }), + }; +}; +const serializeAws_restJson1Configuration = (input, context) => { + return { + ...(input.Enabled !== undefined && input.Enabled !== null && { Enabled: input.Enabled }), + }; +}; +const serializeAws_restJson1CustomCodeSigning = (input, context) => { + return { + ...(input.certificateChain !== undefined && + input.certificateChain !== null && { + certificateChain: serializeAws_restJson1CodeSigningCertificateChain(input.certificateChain, context), + }), + ...(input.hashAlgorithm !== undefined && input.hashAlgorithm !== null && { hashAlgorithm: input.hashAlgorithm }), + ...(input.signature !== undefined && + input.signature !== null && { signature: serializeAws_restJson1CodeSigningSignature(input.signature, context) }), + ...(input.signatureAlgorithm !== undefined && + input.signatureAlgorithm !== null && { signatureAlgorithm: input.signatureAlgorithm }), + }; +}; +const serializeAws_restJson1Destination = (input, context) => { + return { + ...(input.s3Destination !== undefined && + input.s3Destination !== null && { + s3Destination: serializeAws_restJson1S3Destination(input.s3Destination, context), + }), + }; +}; +const serializeAws_restJson1DetailsMap = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_restJson1DimensionStringValues = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1DynamoDBAction = (input, context) => { + return { + ...(input.hashKeyField !== undefined && input.hashKeyField !== null && { hashKeyField: input.hashKeyField }), + ...(input.hashKeyType !== undefined && input.hashKeyType !== null && { hashKeyType: input.hashKeyType }), + ...(input.hashKeyValue !== undefined && input.hashKeyValue !== null && { hashKeyValue: input.hashKeyValue }), + ...(input.operation !== undefined && input.operation !== null && { operation: input.operation }), + ...(input.payloadField !== undefined && input.payloadField !== null && { payloadField: input.payloadField }), + ...(input.rangeKeyField !== undefined && input.rangeKeyField !== null && { rangeKeyField: input.rangeKeyField }), + ...(input.rangeKeyType !== undefined && input.rangeKeyType !== null && { rangeKeyType: input.rangeKeyType }), + ...(input.rangeKeyValue !== undefined && input.rangeKeyValue !== null && { rangeKeyValue: input.rangeKeyValue }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.tableName !== undefined && input.tableName !== null && { tableName: input.tableName }), + }; +}; +const serializeAws_restJson1DynamoDBv2Action = (input, context) => { + return { + ...(input.putItem !== undefined && + input.putItem !== null && { putItem: serializeAws_restJson1PutItemInput(input.putItem, context) }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }; +}; +const serializeAws_restJson1ElasticsearchAction = (input, context) => { + return { + ...(input.endpoint !== undefined && input.endpoint !== null && { endpoint: input.endpoint }), + ...(input.id !== undefined && input.id !== null && { id: input.id }), + ...(input.index !== undefined && input.index !== null && { index: input.index }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.type !== undefined && input.type !== null && { type: input.type }), + }; +}; +const serializeAws_restJson1EnableIoTLoggingParams = (input, context) => { + return { + ...(input.logLevel !== undefined && input.logLevel !== null && { logLevel: input.logLevel }), + ...(input.roleArnForLogging !== undefined && + input.roleArnForLogging !== null && { roleArnForLogging: input.roleArnForLogging }), + }; +}; +const serializeAws_restJson1EventConfigurations = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: serializeAws_restJson1Configuration(value, context), + }; + }, {}); +}; +const serializeAws_restJson1ExponentialRolloutRate = (input, context) => { + return { + ...(input.baseRatePerMinute !== undefined && + input.baseRatePerMinute !== null && { baseRatePerMinute: input.baseRatePerMinute }), + ...(input.incrementFactor !== undefined && + input.incrementFactor !== null && { incrementFactor: input.incrementFactor }), + ...(input.rateIncreaseCriteria !== undefined && + input.rateIncreaseCriteria !== null && { + rateIncreaseCriteria: serializeAws_restJson1RateIncreaseCriteria(input.rateIncreaseCriteria, context), + }), + }; +}; +const serializeAws_restJson1Field = (input, context) => { + return { + ...(input.name !== undefined && input.name !== null && { name: input.name }), + ...(input.type !== undefined && input.type !== null && { type: input.type }), + }; +}; +const serializeAws_restJson1Fields = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1Field(entry, context); + }); +}; +const serializeAws_restJson1FileLocation = (input, context) => { + return { + ...(input.s3Location !== undefined && + input.s3Location !== null && { s3Location: serializeAws_restJson1S3Location(input.s3Location, context) }), + ...(input.stream !== undefined && + input.stream !== null && { stream: serializeAws_restJson1_Stream(input.stream, context) }), + }; +}; +const serializeAws_restJson1FindingIds = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1FirehoseAction = (input, context) => { + return { + ...(input.batchMode !== undefined && input.batchMode !== null && { batchMode: input.batchMode }), + ...(input.deliveryStreamName !== undefined && + input.deliveryStreamName !== null && { deliveryStreamName: input.deliveryStreamName }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.separator !== undefined && input.separator !== null && { separator: input.separator }), + }; +}; +const serializeAws_restJson1HeaderList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1HttpActionHeader(entry, context); + }); +}; +const serializeAws_restJson1HttpAction = (input, context) => { + return { + ...(input.auth !== undefined && + input.auth !== null && { auth: serializeAws_restJson1HttpAuthorization(input.auth, context) }), + ...(input.confirmationUrl !== undefined && + input.confirmationUrl !== null && { confirmationUrl: input.confirmationUrl }), + ...(input.headers !== undefined && + input.headers !== null && { headers: serializeAws_restJson1HeaderList(input.headers, context) }), + ...(input.url !== undefined && input.url !== null && { url: input.url }), + }; +}; +const serializeAws_restJson1HttpActionHeader = (input, context) => { + return { + ...(input.key !== undefined && input.key !== null && { key: input.key }), + ...(input.value !== undefined && input.value !== null && { value: input.value }), + }; +}; +const serializeAws_restJson1HttpAuthorization = (input, context) => { + return { + ...(input.sigv4 !== undefined && + input.sigv4 !== null && { sigv4: serializeAws_restJson1SigV4Authorization(input.sigv4, context) }), + }; +}; +const serializeAws_restJson1HttpContext = (input, context) => { + return { + ...(input.headers !== undefined && + input.headers !== null && { headers: serializeAws_restJson1HttpHeaders(input.headers, context) }), + ...(input.queryString !== undefined && input.queryString !== null && { queryString: input.queryString }), + }; +}; +const serializeAws_restJson1HttpHeaders = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_restJson1HttpUrlDestinationConfiguration = (input, context) => { + return { + ...(input.confirmationUrl !== undefined && + input.confirmationUrl !== null && { confirmationUrl: input.confirmationUrl }), + }; +}; +const serializeAws_restJson1IotAnalyticsAction = (input, context) => { + return { + ...(input.batchMode !== undefined && input.batchMode !== null && { batchMode: input.batchMode }), + ...(input.channelArn !== undefined && input.channelArn !== null && { channelArn: input.channelArn }), + ...(input.channelName !== undefined && input.channelName !== null && { channelName: input.channelName }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }; +}; +const serializeAws_restJson1IotEventsAction = (input, context) => { + return { + ...(input.batchMode !== undefined && input.batchMode !== null && { batchMode: input.batchMode }), + ...(input.inputName !== undefined && input.inputName !== null && { inputName: input.inputName }), + ...(input.messageId !== undefined && input.messageId !== null && { messageId: input.messageId }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }; +}; +const serializeAws_restJson1IotSiteWiseAction = (input, context) => { + return { + ...(input.putAssetPropertyValueEntries !== undefined && + input.putAssetPropertyValueEntries !== null && { + putAssetPropertyValueEntries: serializeAws_restJson1PutAssetPropertyValueEntryList(input.putAssetPropertyValueEntries, context), + }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }; +}; +const serializeAws_restJson1JobExecutionsRolloutConfig = (input, context) => { + return { + ...(input.exponentialRate !== undefined && + input.exponentialRate !== null && { + exponentialRate: serializeAws_restJson1ExponentialRolloutRate(input.exponentialRate, context), + }), + ...(input.maximumPerMinute !== undefined && + input.maximumPerMinute !== null && { maximumPerMinute: input.maximumPerMinute }), + }; +}; +const serializeAws_restJson1JobTargets = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1KinesisAction = (input, context) => { + return { + ...(input.partitionKey !== undefined && input.partitionKey !== null && { partitionKey: input.partitionKey }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.streamName !== undefined && input.streamName !== null && { streamName: input.streamName }), + }; +}; +const serializeAws_restJson1LambdaAction = (input, context) => { + return { + ...(input.functionArn !== undefined && input.functionArn !== null && { functionArn: input.functionArn }), + }; +}; +const serializeAws_restJson1LoggingOptionsPayload = (input, context) => { + return { + ...(input.logLevel !== undefined && input.logLevel !== null && { logLevel: input.logLevel }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }; +}; +const serializeAws_restJson1LogTarget = (input, context) => { + return { + ...(input.targetName !== undefined && input.targetName !== null && { targetName: input.targetName }), + ...(input.targetType !== undefined && input.targetType !== null && { targetType: input.targetType }), + }; +}; +const serializeAws_restJson1MetricDimension = (input, context) => { + return { + ...(input.dimensionName !== undefined && input.dimensionName !== null && { dimensionName: input.dimensionName }), + ...(input.operator !== undefined && input.operator !== null && { operator: input.operator }), + }; +}; +const serializeAws_restJson1MetricToRetain = (input, context) => { + return { + ...(input.metric !== undefined && input.metric !== null && { metric: input.metric }), + ...(input.metricDimension !== undefined && + input.metricDimension !== null && { + metricDimension: serializeAws_restJson1MetricDimension(input.metricDimension, context), + }), + }; +}; +const serializeAws_restJson1MetricValue = (input, context) => { + return { + ...(input.cidrs !== undefined && + input.cidrs !== null && { cidrs: serializeAws_restJson1Cidrs(input.cidrs, context) }), + ...(input.count !== undefined && input.count !== null && { count: input.count }), + ...(input.ports !== undefined && + input.ports !== null && { ports: serializeAws_restJson1Ports(input.ports, context) }), + }; +}; +const serializeAws_restJson1MitigationActionNameList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1MitigationActionParams = (input, context) => { + return { + ...(input.addThingsToThingGroupParams !== undefined && + input.addThingsToThingGroupParams !== null && { + addThingsToThingGroupParams: serializeAws_restJson1AddThingsToThingGroupParams(input.addThingsToThingGroupParams, context), + }), + ...(input.enableIoTLoggingParams !== undefined && + input.enableIoTLoggingParams !== null && { + enableIoTLoggingParams: serializeAws_restJson1EnableIoTLoggingParams(input.enableIoTLoggingParams, context), + }), + ...(input.publishFindingToSnsParams !== undefined && + input.publishFindingToSnsParams !== null && { + publishFindingToSnsParams: serializeAws_restJson1PublishFindingToSnsParams(input.publishFindingToSnsParams, context), + }), + ...(input.replaceDefaultPolicyVersionParams !== undefined && + input.replaceDefaultPolicyVersionParams !== null && { + replaceDefaultPolicyVersionParams: serializeAws_restJson1ReplaceDefaultPolicyVersionParams(input.replaceDefaultPolicyVersionParams, context), + }), + ...(input.updateCACertificateParams !== undefined && + input.updateCACertificateParams !== null && { + updateCACertificateParams: serializeAws_restJson1UpdateCACertificateParams(input.updateCACertificateParams, context), + }), + ...(input.updateDeviceCertificateParams !== undefined && + input.updateDeviceCertificateParams !== null && { + updateDeviceCertificateParams: serializeAws_restJson1UpdateDeviceCertificateParams(input.updateDeviceCertificateParams, context), + }), + }; +}; +const serializeAws_restJson1MqttContext = (input, context) => { + return { + ...(input.clientId !== undefined && input.clientId !== null && { clientId: input.clientId }), + ...(input.password !== undefined && input.password !== null && { password: context.base64Encoder(input.password) }), + ...(input.username !== undefined && input.username !== null && { username: input.username }), + }; +}; +const serializeAws_restJson1OTAUpdateFile = (input, context) => { + return { + ...(input.attributes !== undefined && + input.attributes !== null && { attributes: serializeAws_restJson1AttributesMap(input.attributes, context) }), + ...(input.codeSigning !== undefined && + input.codeSigning !== null && { codeSigning: serializeAws_restJson1CodeSigning(input.codeSigning, context) }), + ...(input.fileLocation !== undefined && + input.fileLocation !== null && { fileLocation: serializeAws_restJson1FileLocation(input.fileLocation, context) }), + ...(input.fileName !== undefined && input.fileName !== null && { fileName: input.fileName }), + ...(input.fileType !== undefined && input.fileType !== null && { fileType: input.fileType }), + ...(input.fileVersion !== undefined && input.fileVersion !== null && { fileVersion: input.fileVersion }), + }; +}; +const serializeAws_restJson1OTAUpdateFiles = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1OTAUpdateFile(entry, context); + }); +}; +const serializeAws_restJson1Parameters = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_restJson1PercentList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1PolicyNames = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1PolicyVersionIdentifier = (input, context) => { + return { + ...(input.policyName !== undefined && input.policyName !== null && { policyName: input.policyName }), + ...(input.policyVersionId !== undefined && + input.policyVersionId !== null && { policyVersionId: input.policyVersionId }), + }; +}; +const serializeAws_restJson1Ports = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1PresignedUrlConfig = (input, context) => { + return { + ...(input.expiresInSec !== undefined && input.expiresInSec !== null && { expiresInSec: input.expiresInSec }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }; +}; +const serializeAws_restJson1Protocols = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1ProvisioningHook = (input, context) => { + return { + ...(input.payloadVersion !== undefined && + input.payloadVersion !== null && { payloadVersion: input.payloadVersion }), + ...(input.targetArn !== undefined && input.targetArn !== null && { targetArn: input.targetArn }), + }; +}; +const serializeAws_restJson1PublicKeyMap = (input, context) => { + return Object.entries(input).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const serializeAws_restJson1PublishFindingToSnsParams = (input, context) => { + return { + ...(input.topicArn !== undefined && input.topicArn !== null && { topicArn: input.topicArn }), + }; +}; +const serializeAws_restJson1PutAssetPropertyValueEntry = (input, context) => { + return { + ...(input.assetId !== undefined && input.assetId !== null && { assetId: input.assetId }), + ...(input.entryId !== undefined && input.entryId !== null && { entryId: input.entryId }), + ...(input.propertyAlias !== undefined && input.propertyAlias !== null && { propertyAlias: input.propertyAlias }), + ...(input.propertyId !== undefined && input.propertyId !== null && { propertyId: input.propertyId }), + ...(input.propertyValues !== undefined && + input.propertyValues !== null && { + propertyValues: serializeAws_restJson1AssetPropertyValueList(input.propertyValues, context), + }), + }; +}; +const serializeAws_restJson1PutAssetPropertyValueEntryList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1PutAssetPropertyValueEntry(entry, context); + }); +}; +const serializeAws_restJson1PutItemInput = (input, context) => { + return { + ...(input.tableName !== undefined && input.tableName !== null && { tableName: input.tableName }), + }; +}; +const serializeAws_restJson1RateIncreaseCriteria = (input, context) => { + return { + ...(input.numberOfNotifiedThings !== undefined && + input.numberOfNotifiedThings !== null && { numberOfNotifiedThings: input.numberOfNotifiedThings }), + ...(input.numberOfSucceededThings !== undefined && + input.numberOfSucceededThings !== null && { numberOfSucceededThings: input.numberOfSucceededThings }), + }; +}; +const serializeAws_restJson1ReasonForNonComplianceCodes = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1RegistrationConfig = (input, context) => { + return { + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.templateBody !== undefined && input.templateBody !== null && { templateBody: input.templateBody }), + }; +}; +const serializeAws_restJson1ReplaceDefaultPolicyVersionParams = (input, context) => { + return { + ...(input.templateName !== undefined && input.templateName !== null && { templateName: input.templateName }), + }; +}; +const serializeAws_restJson1RepublishAction = (input, context) => { + return { + ...(input.qos !== undefined && input.qos !== null && { qos: input.qos }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.topic !== undefined && input.topic !== null && { topic: input.topic }), + }; +}; +const serializeAws_restJson1ResourceIdentifier = (input, context) => { + return { + ...(input.account !== undefined && input.account !== null && { account: input.account }), + ...(input.caCertificateId !== undefined && + input.caCertificateId !== null && { caCertificateId: input.caCertificateId }), + ...(input.clientId !== undefined && input.clientId !== null && { clientId: input.clientId }), + ...(input.cognitoIdentityPoolId !== undefined && + input.cognitoIdentityPoolId !== null && { cognitoIdentityPoolId: input.cognitoIdentityPoolId }), + ...(input.deviceCertificateId !== undefined && + input.deviceCertificateId !== null && { deviceCertificateId: input.deviceCertificateId }), + ...(input.iamRoleArn !== undefined && input.iamRoleArn !== null && { iamRoleArn: input.iamRoleArn }), + ...(input.policyVersionIdentifier !== undefined && + input.policyVersionIdentifier !== null && { + policyVersionIdentifier: serializeAws_restJson1PolicyVersionIdentifier(input.policyVersionIdentifier, context), + }), + ...(input.roleAliasArn !== undefined && input.roleAliasArn !== null && { roleAliasArn: input.roleAliasArn }), + }; +}; +const serializeAws_restJson1Resources = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1S3Action = (input, context) => { + return { + ...(input.bucketName !== undefined && input.bucketName !== null && { bucketName: input.bucketName }), + ...(input.cannedAcl !== undefined && input.cannedAcl !== null && { cannedAcl: input.cannedAcl }), + ...(input.key !== undefined && input.key !== null && { key: input.key }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + }; +}; +const serializeAws_restJson1S3Destination = (input, context) => { + return { + ...(input.bucket !== undefined && input.bucket !== null && { bucket: input.bucket }), + ...(input.prefix !== undefined && input.prefix !== null && { prefix: input.prefix }), + }; +}; +const serializeAws_restJson1S3Location = (input, context) => { + return { + ...(input.bucket !== undefined && input.bucket !== null && { bucket: input.bucket }), + ...(input.key !== undefined && input.key !== null && { key: input.key }), + ...(input.version !== undefined && input.version !== null && { version: input.version }), + }; +}; +const serializeAws_restJson1SalesforceAction = (input, context) => { + return { + ...(input.token !== undefined && input.token !== null && { token: input.token }), + ...(input.url !== undefined && input.url !== null && { url: input.url }), + }; +}; +const serializeAws_restJson1SearchableAttributes = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1ServerCertificateArns = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1SigningProfileParameter = (input, context) => { + return { + ...(input.certificateArn !== undefined && + input.certificateArn !== null && { certificateArn: input.certificateArn }), + ...(input.certificatePathOnDevice !== undefined && + input.certificatePathOnDevice !== null && { certificatePathOnDevice: input.certificatePathOnDevice }), + ...(input.platform !== undefined && input.platform !== null && { platform: input.platform }), + }; +}; +const serializeAws_restJson1SigV4Authorization = (input, context) => { + return { + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.serviceName !== undefined && input.serviceName !== null && { serviceName: input.serviceName }), + ...(input.signingRegion !== undefined && input.signingRegion !== null && { signingRegion: input.signingRegion }), + }; +}; +const serializeAws_restJson1SnsAction = (input, context) => { + return { + ...(input.messageFormat !== undefined && input.messageFormat !== null && { messageFormat: input.messageFormat }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.targetArn !== undefined && input.targetArn !== null && { targetArn: input.targetArn }), + }; +}; +const serializeAws_restJson1SqsAction = (input, context) => { + return { + ...(input.queueUrl !== undefined && input.queueUrl !== null && { queueUrl: input.queueUrl }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.useBase64 !== undefined && input.useBase64 !== null && { useBase64: input.useBase64 }), + }; +}; +const serializeAws_restJson1StartSigningJobParameter = (input, context) => { + return { + ...(input.destination !== undefined && + input.destination !== null && { destination: serializeAws_restJson1Destination(input.destination, context) }), + ...(input.signingProfileName !== undefined && + input.signingProfileName !== null && { signingProfileName: input.signingProfileName }), + ...(input.signingProfileParameter !== undefined && + input.signingProfileParameter !== null && { + signingProfileParameter: serializeAws_restJson1SigningProfileParameter(input.signingProfileParameter, context), + }), + }; +}; +const serializeAws_restJson1StatisticalThreshold = (input, context) => { + return { + ...(input.statistic !== undefined && input.statistic !== null && { statistic: input.statistic }), + }; +}; +const serializeAws_restJson1StepFunctionsAction = (input, context) => { + return { + ...(input.executionNamePrefix !== undefined && + input.executionNamePrefix !== null && { executionNamePrefix: input.executionNamePrefix }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.stateMachineName !== undefined && + input.stateMachineName !== null && { stateMachineName: input.stateMachineName }), + }; +}; +const serializeAws_restJson1_Stream = (input, context) => { + return { + ...(input.fileId !== undefined && input.fileId !== null && { fileId: input.fileId }), + ...(input.streamId !== undefined && input.streamId !== null && { streamId: input.streamId }), + }; +}; +const serializeAws_restJson1StreamFile = (input, context) => { + return { + ...(input.fileId !== undefined && input.fileId !== null && { fileId: input.fileId }), + ...(input.s3Location !== undefined && + input.s3Location !== null && { s3Location: serializeAws_restJson1S3Location(input.s3Location, context) }), + }; +}; +const serializeAws_restJson1StreamFiles = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1StreamFile(entry, context); + }); +}; +const serializeAws_restJson1Tag = (input, context) => { + return { + ...(input.Key !== undefined && input.Key !== null && { Key: input.Key }), + ...(input.Value !== undefined && input.Value !== null && { Value: input.Value }), + }; +}; +const serializeAws_restJson1TagKeyList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1TagList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1Tag(entry, context); + }); +}; +const serializeAws_restJson1TargetAuditCheckNames = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1Targets = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1ThingGroupIndexingConfiguration = (input, context) => { + return { + ...(input.customFields !== undefined && + input.customFields !== null && { customFields: serializeAws_restJson1Fields(input.customFields, context) }), + ...(input.managedFields !== undefined && + input.managedFields !== null && { managedFields: serializeAws_restJson1Fields(input.managedFields, context) }), + ...(input.thingGroupIndexingMode !== undefined && + input.thingGroupIndexingMode !== null && { thingGroupIndexingMode: input.thingGroupIndexingMode }), + }; +}; +const serializeAws_restJson1ThingGroupList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1ThingGroupNames = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const serializeAws_restJson1ThingGroupProperties = (input, context) => { + return { + ...(input.attributePayload !== undefined && + input.attributePayload !== null && { + attributePayload: serializeAws_restJson1AttributePayload(input.attributePayload, context), + }), + ...(input.thingGroupDescription !== undefined && + input.thingGroupDescription !== null && { thingGroupDescription: input.thingGroupDescription }), + }; +}; +const serializeAws_restJson1ThingIndexingConfiguration = (input, context) => { + return { + ...(input.customFields !== undefined && + input.customFields !== null && { customFields: serializeAws_restJson1Fields(input.customFields, context) }), + ...(input.managedFields !== undefined && + input.managedFields !== null && { managedFields: serializeAws_restJson1Fields(input.managedFields, context) }), + ...(input.thingConnectivityIndexingMode !== undefined && + input.thingConnectivityIndexingMode !== null && { + thingConnectivityIndexingMode: input.thingConnectivityIndexingMode, + }), + ...(input.thingIndexingMode !== undefined && + input.thingIndexingMode !== null && { thingIndexingMode: input.thingIndexingMode }), + }; +}; +const serializeAws_restJson1ThingTypeProperties = (input, context) => { + return { + ...(input.searchableAttributes !== undefined && + input.searchableAttributes !== null && { + searchableAttributes: serializeAws_restJson1SearchableAttributes(input.searchableAttributes, context), + }), + ...(input.thingTypeDescription !== undefined && + input.thingTypeDescription !== null && { thingTypeDescription: input.thingTypeDescription }), + }; +}; +const serializeAws_restJson1TimeoutConfig = (input, context) => { + return { + ...(input.inProgressTimeoutInMinutes !== undefined && + input.inProgressTimeoutInMinutes !== null && { inProgressTimeoutInMinutes: input.inProgressTimeoutInMinutes }), + }; +}; +const serializeAws_restJson1TimestreamAction = (input, context) => { + return { + ...(input.databaseName !== undefined && input.databaseName !== null && { databaseName: input.databaseName }), + ...(input.dimensions !== undefined && + input.dimensions !== null && { + dimensions: serializeAws_restJson1TimestreamDimensionList(input.dimensions, context), + }), + ...(input.roleArn !== undefined && input.roleArn !== null && { roleArn: input.roleArn }), + ...(input.tableName !== undefined && input.tableName !== null && { tableName: input.tableName }), + ...(input.timestamp !== undefined && + input.timestamp !== null && { timestamp: serializeAws_restJson1TimestreamTimestamp(input.timestamp, context) }), + }; +}; +const serializeAws_restJson1TimestreamDimension = (input, context) => { + return { + ...(input.name !== undefined && input.name !== null && { name: input.name }), + ...(input.value !== undefined && input.value !== null && { value: input.value }), + }; +}; +const serializeAws_restJson1TimestreamDimensionList = (input, context) => { + return input + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return serializeAws_restJson1TimestreamDimension(entry, context); + }); +}; +const serializeAws_restJson1TimestreamTimestamp = (input, context) => { + return { + ...(input.unit !== undefined && input.unit !== null && { unit: input.unit }), + ...(input.value !== undefined && input.value !== null && { value: input.value }), + }; +}; +const serializeAws_restJson1TlsContext = (input, context) => { + return { + ...(input.serverName !== undefined && input.serverName !== null && { serverName: input.serverName }), + }; +}; +const serializeAws_restJson1TopicRuleDestinationConfiguration = (input, context) => { + return { + ...(input.httpUrlConfiguration !== undefined && + input.httpUrlConfiguration !== null && { + httpUrlConfiguration: serializeAws_restJson1HttpUrlDestinationConfiguration(input.httpUrlConfiguration, context), + }), + }; +}; +const serializeAws_restJson1TopicRulePayload = (input, context) => { + return { + ...(input.actions !== undefined && + input.actions !== null && { actions: serializeAws_restJson1ActionList(input.actions, context) }), + ...(input.awsIotSqlVersion !== undefined && + input.awsIotSqlVersion !== null && { awsIotSqlVersion: input.awsIotSqlVersion }), + ...(input.description !== undefined && input.description !== null && { description: input.description }), + ...(input.errorAction !== undefined && + input.errorAction !== null && { errorAction: serializeAws_restJson1Action(input.errorAction, context) }), + ...(input.ruleDisabled !== undefined && input.ruleDisabled !== null && { ruleDisabled: input.ruleDisabled }), + ...(input.sql !== undefined && input.sql !== null && { sql: input.sql }), + }; +}; +const serializeAws_restJson1UpdateCACertificateParams = (input, context) => { + return { + ...(input.action !== undefined && input.action !== null && { action: input.action }), + }; +}; +const serializeAws_restJson1UpdateDeviceCertificateParams = (input, context) => { + return { + ...(input.action !== undefined && input.action !== null && { action: input.action }), + }; +}; +const deserializeAws_restJson1AbortConfig = (output, context) => { + return { + criteriaList: output.criteriaList !== undefined && output.criteriaList !== null + ? deserializeAws_restJson1AbortCriteriaList(output.criteriaList, context) + : undefined, + }; +}; +const deserializeAws_restJson1AbortCriteria = (output, context) => { + return { + action: output.action !== undefined && output.action !== null ? output.action : undefined, + failureType: output.failureType !== undefined && output.failureType !== null ? output.failureType : undefined, + minNumberOfExecutedThings: output.minNumberOfExecutedThings !== undefined && output.minNumberOfExecutedThings !== null + ? output.minNumberOfExecutedThings + : undefined, + thresholdPercentage: output.thresholdPercentage !== undefined && output.thresholdPercentage !== null + ? output.thresholdPercentage + : undefined, + }; +}; +const deserializeAws_restJson1AbortCriteriaList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1AbortCriteria(entry, context); + }); +}; +const deserializeAws_restJson1Action = (output, context) => { + return { + cloudwatchAlarm: output.cloudwatchAlarm !== undefined && output.cloudwatchAlarm !== null + ? deserializeAws_restJson1CloudwatchAlarmAction(output.cloudwatchAlarm, context) + : undefined, + cloudwatchLogs: output.cloudwatchLogs !== undefined && output.cloudwatchLogs !== null + ? deserializeAws_restJson1CloudwatchLogsAction(output.cloudwatchLogs, context) + : undefined, + cloudwatchMetric: output.cloudwatchMetric !== undefined && output.cloudwatchMetric !== null + ? deserializeAws_restJson1CloudwatchMetricAction(output.cloudwatchMetric, context) + : undefined, + dynamoDB: output.dynamoDB !== undefined && output.dynamoDB !== null + ? deserializeAws_restJson1DynamoDBAction(output.dynamoDB, context) + : undefined, + dynamoDBv2: output.dynamoDBv2 !== undefined && output.dynamoDBv2 !== null + ? deserializeAws_restJson1DynamoDBv2Action(output.dynamoDBv2, context) + : undefined, + elasticsearch: output.elasticsearch !== undefined && output.elasticsearch !== null + ? deserializeAws_restJson1ElasticsearchAction(output.elasticsearch, context) + : undefined, + firehose: output.firehose !== undefined && output.firehose !== null + ? deserializeAws_restJson1FirehoseAction(output.firehose, context) + : undefined, + http: output.http !== undefined && output.http !== null + ? deserializeAws_restJson1HttpAction(output.http, context) + : undefined, + iotAnalytics: output.iotAnalytics !== undefined && output.iotAnalytics !== null + ? deserializeAws_restJson1IotAnalyticsAction(output.iotAnalytics, context) + : undefined, + iotEvents: output.iotEvents !== undefined && output.iotEvents !== null + ? deserializeAws_restJson1IotEventsAction(output.iotEvents, context) + : undefined, + iotSiteWise: output.iotSiteWise !== undefined && output.iotSiteWise !== null + ? deserializeAws_restJson1IotSiteWiseAction(output.iotSiteWise, context) + : undefined, + kinesis: output.kinesis !== undefined && output.kinesis !== null + ? deserializeAws_restJson1KinesisAction(output.kinesis, context) + : undefined, + lambda: output.lambda !== undefined && output.lambda !== null + ? deserializeAws_restJson1LambdaAction(output.lambda, context) + : undefined, + republish: output.republish !== undefined && output.republish !== null + ? deserializeAws_restJson1RepublishAction(output.republish, context) + : undefined, + s3: output.s3 !== undefined && output.s3 !== null ? deserializeAws_restJson1S3Action(output.s3, context) : undefined, + salesforce: output.salesforce !== undefined && output.salesforce !== null + ? deserializeAws_restJson1SalesforceAction(output.salesforce, context) + : undefined, + sns: output.sns !== undefined && output.sns !== null + ? deserializeAws_restJson1SnsAction(output.sns, context) + : undefined, + sqs: output.sqs !== undefined && output.sqs !== null + ? deserializeAws_restJson1SqsAction(output.sqs, context) + : undefined, + stepFunctions: output.stepFunctions !== undefined && output.stepFunctions !== null + ? deserializeAws_restJson1StepFunctionsAction(output.stepFunctions, context) + : undefined, + timestream: output.timestream !== undefined && output.timestream !== null + ? deserializeAws_restJson1TimestreamAction(output.timestream, context) + : undefined, + }; +}; +const deserializeAws_restJson1ActionList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1Action(entry, context); + }); +}; +const deserializeAws_restJson1ActiveViolation = (output, context) => { + return { + behavior: output.behavior !== undefined && output.behavior !== null + ? deserializeAws_restJson1Behavior(output.behavior, context) + : undefined, + lastViolationTime: output.lastViolationTime !== undefined && output.lastViolationTime !== null + ? new Date(Math.round(output.lastViolationTime * 1000)) + : undefined, + lastViolationValue: output.lastViolationValue !== undefined && output.lastViolationValue !== null + ? deserializeAws_restJson1MetricValue(output.lastViolationValue, context) + : undefined, + securityProfileName: output.securityProfileName !== undefined && output.securityProfileName !== null + ? output.securityProfileName + : undefined, + thingName: output.thingName !== undefined && output.thingName !== null ? output.thingName : undefined, + violationId: output.violationId !== undefined && output.violationId !== null ? output.violationId : undefined, + violationStartTime: output.violationStartTime !== undefined && output.violationStartTime !== null + ? new Date(Math.round(output.violationStartTime * 1000)) + : undefined, + }; +}; +const deserializeAws_restJson1ActiveViolations = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ActiveViolation(entry, context); + }); +}; +const deserializeAws_restJson1AdditionalMetricsToRetainList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1AdditionalMetricsToRetainV2List = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1MetricToRetain(entry, context); + }); +}; +const deserializeAws_restJson1AdditionalParameterMap = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_restJson1AddThingsToThingGroupParams = (output, context) => { + return { + overrideDynamicGroups: output.overrideDynamicGroups !== undefined && output.overrideDynamicGroups !== null + ? output.overrideDynamicGroups + : undefined, + thingGroupNames: output.thingGroupNames !== undefined && output.thingGroupNames !== null + ? deserializeAws_restJson1ThingGroupNames(output.thingGroupNames, context) + : undefined, + }; +}; +const deserializeAws_restJson1AlertTarget = (output, context) => { + return { + alertTargetArn: output.alertTargetArn !== undefined && output.alertTargetArn !== null ? output.alertTargetArn : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1AlertTargets = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: deserializeAws_restJson1AlertTarget(value, context), + }; + }, {}); +}; +const deserializeAws_restJson1Allowed = (output, context) => { + return { + policies: output.policies !== undefined && output.policies !== null + ? deserializeAws_restJson1Policies(output.policies, context) + : undefined, + }; +}; +const deserializeAws_restJson1AssetPropertyTimestamp = (output, context) => { + return { + offsetInNanos: output.offsetInNanos !== undefined && output.offsetInNanos !== null ? output.offsetInNanos : undefined, + timeInSeconds: output.timeInSeconds !== undefined && output.timeInSeconds !== null ? output.timeInSeconds : undefined, + }; +}; +const deserializeAws_restJson1AssetPropertyValue = (output, context) => { + return { + quality: output.quality !== undefined && output.quality !== null ? output.quality : undefined, + timestamp: output.timestamp !== undefined && output.timestamp !== null + ? deserializeAws_restJson1AssetPropertyTimestamp(output.timestamp, context) + : undefined, + value: output.value !== undefined && output.value !== null + ? deserializeAws_restJson1AssetPropertyVariant(output.value, context) + : undefined, + }; +}; +const deserializeAws_restJson1AssetPropertyValueList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1AssetPropertyValue(entry, context); + }); +}; +const deserializeAws_restJson1AssetPropertyVariant = (output, context) => { + if (output.booleanValue !== undefined && output.booleanValue !== null) { + return { + booleanValue: output.booleanValue, + }; + } + if (output.doubleValue !== undefined && output.doubleValue !== null) { + return { + doubleValue: output.doubleValue, + }; + } + if (output.integerValue !== undefined && output.integerValue !== null) { + return { + integerValue: output.integerValue, + }; + } + if (output.stringValue !== undefined && output.stringValue !== null) { + return { + stringValue: output.stringValue, + }; + } + return { $unknown: Object.entries(output)[0] }; +}; +const deserializeAws_restJson1AttributePayload = (output, context) => { + return { + attributes: output.attributes !== undefined && output.attributes !== null + ? deserializeAws_restJson1Attributes(output.attributes, context) + : undefined, + merge: output.merge !== undefined && output.merge !== null ? output.merge : undefined, + }; +}; +const deserializeAws_restJson1Attributes = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_restJson1AttributesMap = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_restJson1AuditCheckConfiguration = (output, context) => { + return { + enabled: output.enabled !== undefined && output.enabled !== null ? output.enabled : undefined, + }; +}; +const deserializeAws_restJson1AuditCheckConfigurations = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: deserializeAws_restJson1AuditCheckConfiguration(value, context), + }; + }, {}); +}; +const deserializeAws_restJson1AuditCheckDetails = (output, context) => { + return { + checkCompliant: output.checkCompliant !== undefined && output.checkCompliant !== null ? output.checkCompliant : undefined, + checkRunStatus: output.checkRunStatus !== undefined && output.checkRunStatus !== null ? output.checkRunStatus : undefined, + errorCode: output.errorCode !== undefined && output.errorCode !== null ? output.errorCode : undefined, + message: output.message !== undefined && output.message !== null ? output.message : undefined, + nonCompliantResourcesCount: output.nonCompliantResourcesCount !== undefined && output.nonCompliantResourcesCount !== null + ? output.nonCompliantResourcesCount + : undefined, + suppressedNonCompliantResourcesCount: output.suppressedNonCompliantResourcesCount !== undefined && output.suppressedNonCompliantResourcesCount !== null + ? output.suppressedNonCompliantResourcesCount + : undefined, + totalResourcesCount: output.totalResourcesCount !== undefined && output.totalResourcesCount !== null + ? output.totalResourcesCount + : undefined, + }; +}; +const deserializeAws_restJson1AuditCheckToActionsMapping = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: deserializeAws_restJson1MitigationActionNameList(value, context), + }; + }, {}); +}; +const deserializeAws_restJson1AuditCheckToReasonCodeFilter = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: deserializeAws_restJson1ReasonForNonComplianceCodes(value, context), + }; + }, {}); +}; +const deserializeAws_restJson1AuditDetails = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: deserializeAws_restJson1AuditCheckDetails(value, context), + }; + }, {}); +}; +const deserializeAws_restJson1AuditFinding = (output, context) => { + return { + checkName: output.checkName !== undefined && output.checkName !== null ? output.checkName : undefined, + findingId: output.findingId !== undefined && output.findingId !== null ? output.findingId : undefined, + findingTime: output.findingTime !== undefined && output.findingTime !== null + ? new Date(Math.round(output.findingTime * 1000)) + : undefined, + isSuppressed: output.isSuppressed !== undefined && output.isSuppressed !== null ? output.isSuppressed : undefined, + nonCompliantResource: output.nonCompliantResource !== undefined && output.nonCompliantResource !== null + ? deserializeAws_restJson1NonCompliantResource(output.nonCompliantResource, context) + : undefined, + reasonForNonCompliance: output.reasonForNonCompliance !== undefined && output.reasonForNonCompliance !== null + ? output.reasonForNonCompliance + : undefined, + reasonForNonComplianceCode: output.reasonForNonComplianceCode !== undefined && output.reasonForNonComplianceCode !== null + ? output.reasonForNonComplianceCode + : undefined, + relatedResources: output.relatedResources !== undefined && output.relatedResources !== null + ? deserializeAws_restJson1RelatedResources(output.relatedResources, context) + : undefined, + severity: output.severity !== undefined && output.severity !== null ? output.severity : undefined, + taskId: output.taskId !== undefined && output.taskId !== null ? output.taskId : undefined, + taskStartTime: output.taskStartTime !== undefined && output.taskStartTime !== null + ? new Date(Math.round(output.taskStartTime * 1000)) + : undefined, + }; +}; +const deserializeAws_restJson1AuditFindings = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1AuditFinding(entry, context); + }); +}; +const deserializeAws_restJson1AuditMitigationActionExecutionMetadata = (output, context) => { + return { + actionId: output.actionId !== undefined && output.actionId !== null ? output.actionId : undefined, + actionName: output.actionName !== undefined && output.actionName !== null ? output.actionName : undefined, + endTime: output.endTime !== undefined && output.endTime !== null ? new Date(Math.round(output.endTime * 1000)) : undefined, + errorCode: output.errorCode !== undefined && output.errorCode !== null ? output.errorCode : undefined, + findingId: output.findingId !== undefined && output.findingId !== null ? output.findingId : undefined, + message: output.message !== undefined && output.message !== null ? output.message : undefined, + startTime: output.startTime !== undefined && output.startTime !== null + ? new Date(Math.round(output.startTime * 1000)) + : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + taskId: output.taskId !== undefined && output.taskId !== null ? output.taskId : undefined, + }; +}; +const deserializeAws_restJson1AuditMitigationActionExecutionMetadataList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1AuditMitigationActionExecutionMetadata(entry, context); + }); +}; +const deserializeAws_restJson1AuditMitigationActionsTaskMetadata = (output, context) => { + return { + startTime: output.startTime !== undefined && output.startTime !== null + ? new Date(Math.round(output.startTime * 1000)) + : undefined, + taskId: output.taskId !== undefined && output.taskId !== null ? output.taskId : undefined, + taskStatus: output.taskStatus !== undefined && output.taskStatus !== null ? output.taskStatus : undefined, + }; +}; +const deserializeAws_restJson1AuditMitigationActionsTaskMetadataList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1AuditMitigationActionsTaskMetadata(entry, context); + }); +}; +const deserializeAws_restJson1AuditMitigationActionsTaskStatistics = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: deserializeAws_restJson1TaskStatisticsForAuditCheck(value, context), + }; + }, {}); +}; +const deserializeAws_restJson1AuditMitigationActionsTaskTarget = (output, context) => { + return { + auditCheckToReasonCodeFilter: output.auditCheckToReasonCodeFilter !== undefined && output.auditCheckToReasonCodeFilter !== null + ? deserializeAws_restJson1AuditCheckToReasonCodeFilter(output.auditCheckToReasonCodeFilter, context) + : undefined, + auditTaskId: output.auditTaskId !== undefined && output.auditTaskId !== null ? output.auditTaskId : undefined, + findingIds: output.findingIds !== undefined && output.findingIds !== null + ? deserializeAws_restJson1FindingIds(output.findingIds, context) + : undefined, + }; +}; +const deserializeAws_restJson1AuditNotificationTarget = (output, context) => { + return { + enabled: output.enabled !== undefined && output.enabled !== null ? output.enabled : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + targetArn: output.targetArn !== undefined && output.targetArn !== null ? output.targetArn : undefined, + }; +}; +const deserializeAws_restJson1AuditNotificationTargetConfigurations = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: deserializeAws_restJson1AuditNotificationTarget(value, context), + }; + }, {}); +}; +const deserializeAws_restJson1AuditSuppression = (output, context) => { + return { + checkName: output.checkName !== undefined && output.checkName !== null ? output.checkName : undefined, + description: output.description !== undefined && output.description !== null ? output.description : undefined, + expirationDate: output.expirationDate !== undefined && output.expirationDate !== null + ? new Date(Math.round(output.expirationDate * 1000)) + : undefined, + resourceIdentifier: output.resourceIdentifier !== undefined && output.resourceIdentifier !== null + ? deserializeAws_restJson1ResourceIdentifier(output.resourceIdentifier, context) + : undefined, + suppressIndefinitely: output.suppressIndefinitely !== undefined && output.suppressIndefinitely !== null + ? output.suppressIndefinitely + : undefined, + }; +}; +const deserializeAws_restJson1AuditSuppressionList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1AuditSuppression(entry, context); + }); +}; +const deserializeAws_restJson1AuditTaskMetadata = (output, context) => { + return { + taskId: output.taskId !== undefined && output.taskId !== null ? output.taskId : undefined, + taskStatus: output.taskStatus !== undefined && output.taskStatus !== null ? output.taskStatus : undefined, + taskType: output.taskType !== undefined && output.taskType !== null ? output.taskType : undefined, + }; +}; +const deserializeAws_restJson1AuditTaskMetadataList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1AuditTaskMetadata(entry, context); + }); +}; +const deserializeAws_restJson1AuthInfo = (output, context) => { + return { + actionType: output.actionType !== undefined && output.actionType !== null ? output.actionType : undefined, + resources: output.resources !== undefined && output.resources !== null + ? deserializeAws_restJson1Resources(output.resources, context) + : undefined, + }; +}; +const deserializeAws_restJson1AuthorizerConfig = (output, context) => { + return { + allowAuthorizerOverride: output.allowAuthorizerOverride !== undefined && output.allowAuthorizerOverride !== null + ? output.allowAuthorizerOverride + : undefined, + defaultAuthorizerName: output.defaultAuthorizerName !== undefined && output.defaultAuthorizerName !== null + ? output.defaultAuthorizerName + : undefined, + }; +}; +const deserializeAws_restJson1AuthorizerDescription = (output, context) => { + return { + authorizerArn: output.authorizerArn !== undefined && output.authorizerArn !== null ? output.authorizerArn : undefined, + authorizerFunctionArn: output.authorizerFunctionArn !== undefined && output.authorizerFunctionArn !== null + ? output.authorizerFunctionArn + : undefined, + authorizerName: output.authorizerName !== undefined && output.authorizerName !== null ? output.authorizerName : undefined, + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + lastModifiedDate: output.lastModifiedDate !== undefined && output.lastModifiedDate !== null + ? new Date(Math.round(output.lastModifiedDate * 1000)) + : undefined, + signingDisabled: output.signingDisabled !== undefined && output.signingDisabled !== null ? output.signingDisabled : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + tokenKeyName: output.tokenKeyName !== undefined && output.tokenKeyName !== null ? output.tokenKeyName : undefined, + tokenSigningPublicKeys: output.tokenSigningPublicKeys !== undefined && output.tokenSigningPublicKeys !== null + ? deserializeAws_restJson1PublicKeyMap(output.tokenSigningPublicKeys, context) + : undefined, + }; +}; +const deserializeAws_restJson1Authorizers = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1AuthorizerSummary(entry, context); + }); +}; +const deserializeAws_restJson1AuthorizerSummary = (output, context) => { + return { + authorizerArn: output.authorizerArn !== undefined && output.authorizerArn !== null ? output.authorizerArn : undefined, + authorizerName: output.authorizerName !== undefined && output.authorizerName !== null ? output.authorizerName : undefined, + }; +}; +const deserializeAws_restJson1AuthResult = (output, context) => { + return { + allowed: output.allowed !== undefined && output.allowed !== null + ? deserializeAws_restJson1Allowed(output.allowed, context) + : undefined, + authDecision: output.authDecision !== undefined && output.authDecision !== null ? output.authDecision : undefined, + authInfo: output.authInfo !== undefined && output.authInfo !== null + ? deserializeAws_restJson1AuthInfo(output.authInfo, context) + : undefined, + denied: output.denied !== undefined && output.denied !== null + ? deserializeAws_restJson1Denied(output.denied, context) + : undefined, + missingContextValues: output.missingContextValues !== undefined && output.missingContextValues !== null + ? deserializeAws_restJson1MissingContextValues(output.missingContextValues, context) + : undefined, + }; +}; +const deserializeAws_restJson1AuthResults = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1AuthResult(entry, context); + }); +}; +const deserializeAws_restJson1AwsJobExecutionsRolloutConfig = (output, context) => { + return { + exponentialRate: output.exponentialRate !== undefined && output.exponentialRate !== null + ? deserializeAws_restJson1AwsJobExponentialRolloutRate(output.exponentialRate, context) + : undefined, + maximumPerMinute: output.maximumPerMinute !== undefined && output.maximumPerMinute !== null ? output.maximumPerMinute : undefined, + }; +}; +const deserializeAws_restJson1AwsJobExponentialRolloutRate = (output, context) => { + return { + baseRatePerMinute: output.baseRatePerMinute !== undefined && output.baseRatePerMinute !== null + ? output.baseRatePerMinute + : undefined, + incrementFactor: output.incrementFactor !== undefined && output.incrementFactor !== null ? output.incrementFactor : undefined, + rateIncreaseCriteria: output.rateIncreaseCriteria !== undefined && output.rateIncreaseCriteria !== null + ? deserializeAws_restJson1AwsJobRateIncreaseCriteria(output.rateIncreaseCriteria, context) + : undefined, + }; +}; +const deserializeAws_restJson1AwsJobPresignedUrlConfig = (output, context) => { + return { + expiresInSec: output.expiresInSec !== undefined && output.expiresInSec !== null ? output.expiresInSec : undefined, + }; +}; +const deserializeAws_restJson1AwsJobRateIncreaseCriteria = (output, context) => { + return { + numberOfNotifiedThings: output.numberOfNotifiedThings !== undefined && output.numberOfNotifiedThings !== null + ? output.numberOfNotifiedThings + : undefined, + numberOfSucceededThings: output.numberOfSucceededThings !== undefined && output.numberOfSucceededThings !== null + ? output.numberOfSucceededThings + : undefined, + }; +}; +const deserializeAws_restJson1Behavior = (output, context) => { + return { + criteria: output.criteria !== undefined && output.criteria !== null + ? deserializeAws_restJson1BehaviorCriteria(output.criteria, context) + : undefined, + metric: output.metric !== undefined && output.metric !== null ? output.metric : undefined, + metricDimension: output.metricDimension !== undefined && output.metricDimension !== null + ? deserializeAws_restJson1MetricDimension(output.metricDimension, context) + : undefined, + name: output.name !== undefined && output.name !== null ? output.name : undefined, + }; +}; +const deserializeAws_restJson1BehaviorCriteria = (output, context) => { + return { + comparisonOperator: output.comparisonOperator !== undefined && output.comparisonOperator !== null + ? output.comparisonOperator + : undefined, + consecutiveDatapointsToAlarm: output.consecutiveDatapointsToAlarm !== undefined && output.consecutiveDatapointsToAlarm !== null + ? output.consecutiveDatapointsToAlarm + : undefined, + consecutiveDatapointsToClear: output.consecutiveDatapointsToClear !== undefined && output.consecutiveDatapointsToClear !== null + ? output.consecutiveDatapointsToClear + : undefined, + durationSeconds: output.durationSeconds !== undefined && output.durationSeconds !== null ? output.durationSeconds : undefined, + statisticalThreshold: output.statisticalThreshold !== undefined && output.statisticalThreshold !== null + ? deserializeAws_restJson1StatisticalThreshold(output.statisticalThreshold, context) + : undefined, + value: output.value !== undefined && output.value !== null + ? deserializeAws_restJson1MetricValue(output.value, context) + : undefined, + }; +}; +const deserializeAws_restJson1Behaviors = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1Behavior(entry, context); + }); +}; +const deserializeAws_restJson1BillingGroupMetadata = (output, context) => { + return { + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + }; +}; +const deserializeAws_restJson1BillingGroupNameAndArnList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1GroupNameAndArn(entry, context); + }); +}; +const deserializeAws_restJson1BillingGroupProperties = (output, context) => { + return { + billingGroupDescription: output.billingGroupDescription !== undefined && output.billingGroupDescription !== null + ? output.billingGroupDescription + : undefined, + }; +}; +const deserializeAws_restJson1CACertificate = (output, context) => { + return { + certificateArn: output.certificateArn !== undefined && output.certificateArn !== null ? output.certificateArn : undefined, + certificateId: output.certificateId !== undefined && output.certificateId !== null ? output.certificateId : undefined, + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + }; +}; +const deserializeAws_restJson1CACertificateDescription = (output, context) => { + return { + autoRegistrationStatus: output.autoRegistrationStatus !== undefined && output.autoRegistrationStatus !== null + ? output.autoRegistrationStatus + : undefined, + certificateArn: output.certificateArn !== undefined && output.certificateArn !== null ? output.certificateArn : undefined, + certificateId: output.certificateId !== undefined && output.certificateId !== null ? output.certificateId : undefined, + certificatePem: output.certificatePem !== undefined && output.certificatePem !== null ? output.certificatePem : undefined, + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + customerVersion: output.customerVersion !== undefined && output.customerVersion !== null ? output.customerVersion : undefined, + generationId: output.generationId !== undefined && output.generationId !== null ? output.generationId : undefined, + lastModifiedDate: output.lastModifiedDate !== undefined && output.lastModifiedDate !== null + ? new Date(Math.round(output.lastModifiedDate * 1000)) + : undefined, + ownedBy: output.ownedBy !== undefined && output.ownedBy !== null ? output.ownedBy : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + validity: output.validity !== undefined && output.validity !== null + ? deserializeAws_restJson1CertificateValidity(output.validity, context) + : undefined, + }; +}; +const deserializeAws_restJson1CACertificates = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1CACertificate(entry, context); + }); +}; +const deserializeAws_restJson1Certificate = (output, context) => { + return { + certificateArn: output.certificateArn !== undefined && output.certificateArn !== null ? output.certificateArn : undefined, + certificateId: output.certificateId !== undefined && output.certificateId !== null ? output.certificateId : undefined, + certificateMode: output.certificateMode !== undefined && output.certificateMode !== null ? output.certificateMode : undefined, + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + }; +}; +const deserializeAws_restJson1CertificateDescription = (output, context) => { + return { + caCertificateId: output.caCertificateId !== undefined && output.caCertificateId !== null ? output.caCertificateId : undefined, + certificateArn: output.certificateArn !== undefined && output.certificateArn !== null ? output.certificateArn : undefined, + certificateId: output.certificateId !== undefined && output.certificateId !== null ? output.certificateId : undefined, + certificateMode: output.certificateMode !== undefined && output.certificateMode !== null ? output.certificateMode : undefined, + certificatePem: output.certificatePem !== undefined && output.certificatePem !== null ? output.certificatePem : undefined, + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + customerVersion: output.customerVersion !== undefined && output.customerVersion !== null ? output.customerVersion : undefined, + generationId: output.generationId !== undefined && output.generationId !== null ? output.generationId : undefined, + lastModifiedDate: output.lastModifiedDate !== undefined && output.lastModifiedDate !== null + ? new Date(Math.round(output.lastModifiedDate * 1000)) + : undefined, + ownedBy: output.ownedBy !== undefined && output.ownedBy !== null ? output.ownedBy : undefined, + previousOwnedBy: output.previousOwnedBy !== undefined && output.previousOwnedBy !== null ? output.previousOwnedBy : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + transferData: output.transferData !== undefined && output.transferData !== null + ? deserializeAws_restJson1TransferData(output.transferData, context) + : undefined, + validity: output.validity !== undefined && output.validity !== null + ? deserializeAws_restJson1CertificateValidity(output.validity, context) + : undefined, + }; +}; +const deserializeAws_restJson1Certificates = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1Certificate(entry, context); + }); +}; +const deserializeAws_restJson1CertificateValidity = (output, context) => { + return { + notAfter: output.notAfter !== undefined && output.notAfter !== null + ? new Date(Math.round(output.notAfter * 1000)) + : undefined, + notBefore: output.notBefore !== undefined && output.notBefore !== null + ? new Date(Math.round(output.notBefore * 1000)) + : undefined, + }; +}; +const deserializeAws_restJson1Cidrs = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1CloudwatchAlarmAction = (output, context) => { + return { + alarmName: output.alarmName !== undefined && output.alarmName !== null ? output.alarmName : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + stateReason: output.stateReason !== undefined && output.stateReason !== null ? output.stateReason : undefined, + stateValue: output.stateValue !== undefined && output.stateValue !== null ? output.stateValue : undefined, + }; +}; +const deserializeAws_restJson1CloudwatchLogsAction = (output, context) => { + return { + logGroupName: output.logGroupName !== undefined && output.logGroupName !== null ? output.logGroupName : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1CloudwatchMetricAction = (output, context) => { + return { + metricName: output.metricName !== undefined && output.metricName !== null ? output.metricName : undefined, + metricNamespace: output.metricNamespace !== undefined && output.metricNamespace !== null ? output.metricNamespace : undefined, + metricTimestamp: output.metricTimestamp !== undefined && output.metricTimestamp !== null ? output.metricTimestamp : undefined, + metricUnit: output.metricUnit !== undefined && output.metricUnit !== null ? output.metricUnit : undefined, + metricValue: output.metricValue !== undefined && output.metricValue !== null ? output.metricValue : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1CodeSigning = (output, context) => { + return { + awsSignerJobId: output.awsSignerJobId !== undefined && output.awsSignerJobId !== null ? output.awsSignerJobId : undefined, + customCodeSigning: output.customCodeSigning !== undefined && output.customCodeSigning !== null + ? deserializeAws_restJson1CustomCodeSigning(output.customCodeSigning, context) + : undefined, + startSigningJobParameter: output.startSigningJobParameter !== undefined && output.startSigningJobParameter !== null + ? deserializeAws_restJson1StartSigningJobParameter(output.startSigningJobParameter, context) + : undefined, + }; +}; +const deserializeAws_restJson1CodeSigningCertificateChain = (output, context) => { + return { + certificateName: output.certificateName !== undefined && output.certificateName !== null ? output.certificateName : undefined, + inlineDocument: output.inlineDocument !== undefined && output.inlineDocument !== null ? output.inlineDocument : undefined, + }; +}; +const deserializeAws_restJson1CodeSigningSignature = (output, context) => { + return { + inlineDocument: output.inlineDocument !== undefined && output.inlineDocument !== null + ? context.base64Decoder(output.inlineDocument) + : undefined, + }; +}; +const deserializeAws_restJson1Configuration = (output, context) => { + return { + Enabled: output.Enabled !== undefined && output.Enabled !== null ? output.Enabled : undefined, + }; +}; +const deserializeAws_restJson1CustomCodeSigning = (output, context) => { + return { + certificateChain: output.certificateChain !== undefined && output.certificateChain !== null + ? deserializeAws_restJson1CodeSigningCertificateChain(output.certificateChain, context) + : undefined, + hashAlgorithm: output.hashAlgorithm !== undefined && output.hashAlgorithm !== null ? output.hashAlgorithm : undefined, + signature: output.signature !== undefined && output.signature !== null + ? deserializeAws_restJson1CodeSigningSignature(output.signature, context) + : undefined, + signatureAlgorithm: output.signatureAlgorithm !== undefined && output.signatureAlgorithm !== null + ? output.signatureAlgorithm + : undefined, + }; +}; +const deserializeAws_restJson1Denied = (output, context) => { + return { + explicitDeny: output.explicitDeny !== undefined && output.explicitDeny !== null + ? deserializeAws_restJson1ExplicitDeny(output.explicitDeny, context) + : undefined, + implicitDeny: output.implicitDeny !== undefined && output.implicitDeny !== null + ? deserializeAws_restJson1ImplicitDeny(output.implicitDeny, context) + : undefined, + }; +}; +const deserializeAws_restJson1Destination = (output, context) => { + return { + s3Destination: output.s3Destination !== undefined && output.s3Destination !== null + ? deserializeAws_restJson1S3Destination(output.s3Destination, context) + : undefined, + }; +}; +const deserializeAws_restJson1DetailsMap = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_restJson1DimensionNames = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1DimensionStringValues = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1DomainConfigurations = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1DomainConfigurationSummary(entry, context); + }); +}; +const deserializeAws_restJson1DomainConfigurationSummary = (output, context) => { + return { + domainConfigurationArn: output.domainConfigurationArn !== undefined && output.domainConfigurationArn !== null + ? output.domainConfigurationArn + : undefined, + domainConfigurationName: output.domainConfigurationName !== undefined && output.domainConfigurationName !== null + ? output.domainConfigurationName + : undefined, + serviceType: output.serviceType !== undefined && output.serviceType !== null ? output.serviceType : undefined, + }; +}; +const deserializeAws_restJson1DynamoDBAction = (output, context) => { + return { + hashKeyField: output.hashKeyField !== undefined && output.hashKeyField !== null ? output.hashKeyField : undefined, + hashKeyType: output.hashKeyType !== undefined && output.hashKeyType !== null ? output.hashKeyType : undefined, + hashKeyValue: output.hashKeyValue !== undefined && output.hashKeyValue !== null ? output.hashKeyValue : undefined, + operation: output.operation !== undefined && output.operation !== null ? output.operation : undefined, + payloadField: output.payloadField !== undefined && output.payloadField !== null ? output.payloadField : undefined, + rangeKeyField: output.rangeKeyField !== undefined && output.rangeKeyField !== null ? output.rangeKeyField : undefined, + rangeKeyType: output.rangeKeyType !== undefined && output.rangeKeyType !== null ? output.rangeKeyType : undefined, + rangeKeyValue: output.rangeKeyValue !== undefined && output.rangeKeyValue !== null ? output.rangeKeyValue : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + tableName: output.tableName !== undefined && output.tableName !== null ? output.tableName : undefined, + }; +}; +const deserializeAws_restJson1DynamoDBv2Action = (output, context) => { + return { + putItem: output.putItem !== undefined && output.putItem !== null + ? deserializeAws_restJson1PutItemInput(output.putItem, context) + : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1EffectivePolicies = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1EffectivePolicy(entry, context); + }); +}; +const deserializeAws_restJson1EffectivePolicy = (output, context) => { + return { + policyArn: output.policyArn !== undefined && output.policyArn !== null ? output.policyArn : undefined, + policyDocument: output.policyDocument !== undefined && output.policyDocument !== null ? output.policyDocument : undefined, + policyName: output.policyName !== undefined && output.policyName !== null ? output.policyName : undefined, + }; +}; +const deserializeAws_restJson1ElasticsearchAction = (output, context) => { + return { + endpoint: output.endpoint !== undefined && output.endpoint !== null ? output.endpoint : undefined, + id: output.id !== undefined && output.id !== null ? output.id : undefined, + index: output.index !== undefined && output.index !== null ? output.index : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + type: output.type !== undefined && output.type !== null ? output.type : undefined, + }; +}; +const deserializeAws_restJson1EnableIoTLoggingParams = (output, context) => { + return { + logLevel: output.logLevel !== undefined && output.logLevel !== null ? output.logLevel : undefined, + roleArnForLogging: output.roleArnForLogging !== undefined && output.roleArnForLogging !== null + ? output.roleArnForLogging + : undefined, + }; +}; +const deserializeAws_restJson1ErrorInfo = (output, context) => { + return { + code: output.code !== undefined && output.code !== null ? output.code : undefined, + message: output.message !== undefined && output.message !== null ? output.message : undefined, + }; +}; +const deserializeAws_restJson1EventConfigurations = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: deserializeAws_restJson1Configuration(value, context), + }; + }, {}); +}; +const deserializeAws_restJson1ExplicitDeny = (output, context) => { + return { + policies: output.policies !== undefined && output.policies !== null + ? deserializeAws_restJson1Policies(output.policies, context) + : undefined, + }; +}; +const deserializeAws_restJson1ExponentialRolloutRate = (output, context) => { + return { + baseRatePerMinute: output.baseRatePerMinute !== undefined && output.baseRatePerMinute !== null + ? output.baseRatePerMinute + : undefined, + incrementFactor: output.incrementFactor !== undefined && output.incrementFactor !== null ? output.incrementFactor : undefined, + rateIncreaseCriteria: output.rateIncreaseCriteria !== undefined && output.rateIncreaseCriteria !== null + ? deserializeAws_restJson1RateIncreaseCriteria(output.rateIncreaseCriteria, context) + : undefined, + }; +}; +const deserializeAws_restJson1Field = (output, context) => { + return { + name: output.name !== undefined && output.name !== null ? output.name : undefined, + type: output.type !== undefined && output.type !== null ? output.type : undefined, + }; +}; +const deserializeAws_restJson1Fields = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1Field(entry, context); + }); +}; +const deserializeAws_restJson1FileLocation = (output, context) => { + return { + s3Location: output.s3Location !== undefined && output.s3Location !== null + ? deserializeAws_restJson1S3Location(output.s3Location, context) + : undefined, + stream: output.stream !== undefined && output.stream !== null + ? deserializeAws_restJson1_Stream(output.stream, context) + : undefined, + }; +}; +const deserializeAws_restJson1FindingIds = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1FirehoseAction = (output, context) => { + return { + batchMode: output.batchMode !== undefined && output.batchMode !== null ? output.batchMode : undefined, + deliveryStreamName: output.deliveryStreamName !== undefined && output.deliveryStreamName !== null + ? output.deliveryStreamName + : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + separator: output.separator !== undefined && output.separator !== null ? output.separator : undefined, + }; +}; +const deserializeAws_restJson1GroupNameAndArn = (output, context) => { + return { + groupArn: output.groupArn !== undefined && output.groupArn !== null ? output.groupArn : undefined, + groupName: output.groupName !== undefined && output.groupName !== null ? output.groupName : undefined, + }; +}; +const deserializeAws_restJson1HeaderList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1HttpActionHeader(entry, context); + }); +}; +const deserializeAws_restJson1HttpAction = (output, context) => { + return { + auth: output.auth !== undefined && output.auth !== null + ? deserializeAws_restJson1HttpAuthorization(output.auth, context) + : undefined, + confirmationUrl: output.confirmationUrl !== undefined && output.confirmationUrl !== null ? output.confirmationUrl : undefined, + headers: output.headers !== undefined && output.headers !== null + ? deserializeAws_restJson1HeaderList(output.headers, context) + : undefined, + url: output.url !== undefined && output.url !== null ? output.url : undefined, + }; +}; +const deserializeAws_restJson1HttpActionHeader = (output, context) => { + return { + key: output.key !== undefined && output.key !== null ? output.key : undefined, + value: output.value !== undefined && output.value !== null ? output.value : undefined, + }; +}; +const deserializeAws_restJson1HttpAuthorization = (output, context) => { + return { + sigv4: output.sigv4 !== undefined && output.sigv4 !== null + ? deserializeAws_restJson1SigV4Authorization(output.sigv4, context) + : undefined, + }; +}; +const deserializeAws_restJson1HttpUrlDestinationProperties = (output, context) => { + return { + confirmationUrl: output.confirmationUrl !== undefined && output.confirmationUrl !== null ? output.confirmationUrl : undefined, + }; +}; +const deserializeAws_restJson1HttpUrlDestinationSummary = (output, context) => { + return { + confirmationUrl: output.confirmationUrl !== undefined && output.confirmationUrl !== null ? output.confirmationUrl : undefined, + }; +}; +const deserializeAws_restJson1ImplicitDeny = (output, context) => { + return { + policies: output.policies !== undefined && output.policies !== null + ? deserializeAws_restJson1Policies(output.policies, context) + : undefined, + }; +}; +const deserializeAws_restJson1IndexNamesList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1IotAnalyticsAction = (output, context) => { + return { + batchMode: output.batchMode !== undefined && output.batchMode !== null ? output.batchMode : undefined, + channelArn: output.channelArn !== undefined && output.channelArn !== null ? output.channelArn : undefined, + channelName: output.channelName !== undefined && output.channelName !== null ? output.channelName : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1IotEventsAction = (output, context) => { + return { + batchMode: output.batchMode !== undefined && output.batchMode !== null ? output.batchMode : undefined, + inputName: output.inputName !== undefined && output.inputName !== null ? output.inputName : undefined, + messageId: output.messageId !== undefined && output.messageId !== null ? output.messageId : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1IotSiteWiseAction = (output, context) => { + return { + putAssetPropertyValueEntries: output.putAssetPropertyValueEntries !== undefined && output.putAssetPropertyValueEntries !== null + ? deserializeAws_restJson1PutAssetPropertyValueEntryList(output.putAssetPropertyValueEntries, context) + : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1Job = (output, context) => { + return { + abortConfig: output.abortConfig !== undefined && output.abortConfig !== null + ? deserializeAws_restJson1AbortConfig(output.abortConfig, context) + : undefined, + comment: output.comment !== undefined && output.comment !== null ? output.comment : undefined, + completedAt: output.completedAt !== undefined && output.completedAt !== null + ? new Date(Math.round(output.completedAt * 1000)) + : undefined, + createdAt: output.createdAt !== undefined && output.createdAt !== null + ? new Date(Math.round(output.createdAt * 1000)) + : undefined, + description: output.description !== undefined && output.description !== null ? output.description : undefined, + forceCanceled: output.forceCanceled !== undefined && output.forceCanceled !== null ? output.forceCanceled : undefined, + jobArn: output.jobArn !== undefined && output.jobArn !== null ? output.jobArn : undefined, + jobExecutionsRolloutConfig: output.jobExecutionsRolloutConfig !== undefined && output.jobExecutionsRolloutConfig !== null + ? deserializeAws_restJson1JobExecutionsRolloutConfig(output.jobExecutionsRolloutConfig, context) + : undefined, + jobId: output.jobId !== undefined && output.jobId !== null ? output.jobId : undefined, + jobProcessDetails: output.jobProcessDetails !== undefined && output.jobProcessDetails !== null + ? deserializeAws_restJson1JobProcessDetails(output.jobProcessDetails, context) + : undefined, + lastUpdatedAt: output.lastUpdatedAt !== undefined && output.lastUpdatedAt !== null + ? new Date(Math.round(output.lastUpdatedAt * 1000)) + : undefined, + namespaceId: output.namespaceId !== undefined && output.namespaceId !== null ? output.namespaceId : undefined, + presignedUrlConfig: output.presignedUrlConfig !== undefined && output.presignedUrlConfig !== null + ? deserializeAws_restJson1PresignedUrlConfig(output.presignedUrlConfig, context) + : undefined, + reasonCode: output.reasonCode !== undefined && output.reasonCode !== null ? output.reasonCode : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + targetSelection: output.targetSelection !== undefined && output.targetSelection !== null ? output.targetSelection : undefined, + targets: output.targets !== undefined && output.targets !== null + ? deserializeAws_restJson1JobTargets(output.targets, context) + : undefined, + timeoutConfig: output.timeoutConfig !== undefined && output.timeoutConfig !== null + ? deserializeAws_restJson1TimeoutConfig(output.timeoutConfig, context) + : undefined, + }; +}; +const deserializeAws_restJson1JobExecution = (output, context) => { + return { + approximateSecondsBeforeTimedOut: output.approximateSecondsBeforeTimedOut !== undefined && output.approximateSecondsBeforeTimedOut !== null + ? output.approximateSecondsBeforeTimedOut + : undefined, + executionNumber: output.executionNumber !== undefined && output.executionNumber !== null ? output.executionNumber : undefined, + forceCanceled: output.forceCanceled !== undefined && output.forceCanceled !== null ? output.forceCanceled : undefined, + jobId: output.jobId !== undefined && output.jobId !== null ? output.jobId : undefined, + lastUpdatedAt: output.lastUpdatedAt !== undefined && output.lastUpdatedAt !== null + ? new Date(Math.round(output.lastUpdatedAt * 1000)) + : undefined, + queuedAt: output.queuedAt !== undefined && output.queuedAt !== null + ? new Date(Math.round(output.queuedAt * 1000)) + : undefined, + startedAt: output.startedAt !== undefined && output.startedAt !== null + ? new Date(Math.round(output.startedAt * 1000)) + : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + statusDetails: output.statusDetails !== undefined && output.statusDetails !== null + ? deserializeAws_restJson1JobExecutionStatusDetails(output.statusDetails, context) + : undefined, + thingArn: output.thingArn !== undefined && output.thingArn !== null ? output.thingArn : undefined, + versionNumber: output.versionNumber !== undefined && output.versionNumber !== null ? output.versionNumber : undefined, + }; +}; +const deserializeAws_restJson1JobExecutionsRolloutConfig = (output, context) => { + return { + exponentialRate: output.exponentialRate !== undefined && output.exponentialRate !== null + ? deserializeAws_restJson1ExponentialRolloutRate(output.exponentialRate, context) + : undefined, + maximumPerMinute: output.maximumPerMinute !== undefined && output.maximumPerMinute !== null ? output.maximumPerMinute : undefined, + }; +}; +const deserializeAws_restJson1JobExecutionStatusDetails = (output, context) => { + return { + detailsMap: output.detailsMap !== undefined && output.detailsMap !== null + ? deserializeAws_restJson1DetailsMap(output.detailsMap, context) + : undefined, + }; +}; +const deserializeAws_restJson1JobExecutionSummary = (output, context) => { + return { + executionNumber: output.executionNumber !== undefined && output.executionNumber !== null ? output.executionNumber : undefined, + lastUpdatedAt: output.lastUpdatedAt !== undefined && output.lastUpdatedAt !== null + ? new Date(Math.round(output.lastUpdatedAt * 1000)) + : undefined, + queuedAt: output.queuedAt !== undefined && output.queuedAt !== null + ? new Date(Math.round(output.queuedAt * 1000)) + : undefined, + startedAt: output.startedAt !== undefined && output.startedAt !== null + ? new Date(Math.round(output.startedAt * 1000)) + : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + }; +}; +const deserializeAws_restJson1JobExecutionSummaryForJob = (output, context) => { + return { + jobExecutionSummary: output.jobExecutionSummary !== undefined && output.jobExecutionSummary !== null + ? deserializeAws_restJson1JobExecutionSummary(output.jobExecutionSummary, context) + : undefined, + thingArn: output.thingArn !== undefined && output.thingArn !== null ? output.thingArn : undefined, + }; +}; +const deserializeAws_restJson1JobExecutionSummaryForJobList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1JobExecutionSummaryForJob(entry, context); + }); +}; +const deserializeAws_restJson1JobExecutionSummaryForThing = (output, context) => { + return { + jobExecutionSummary: output.jobExecutionSummary !== undefined && output.jobExecutionSummary !== null + ? deserializeAws_restJson1JobExecutionSummary(output.jobExecutionSummary, context) + : undefined, + jobId: output.jobId !== undefined && output.jobId !== null ? output.jobId : undefined, + }; +}; +const deserializeAws_restJson1JobExecutionSummaryForThingList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1JobExecutionSummaryForThing(entry, context); + }); +}; +const deserializeAws_restJson1JobProcessDetails = (output, context) => { + return { + numberOfCanceledThings: output.numberOfCanceledThings !== undefined && output.numberOfCanceledThings !== null + ? output.numberOfCanceledThings + : undefined, + numberOfFailedThings: output.numberOfFailedThings !== undefined && output.numberOfFailedThings !== null + ? output.numberOfFailedThings + : undefined, + numberOfInProgressThings: output.numberOfInProgressThings !== undefined && output.numberOfInProgressThings !== null + ? output.numberOfInProgressThings + : undefined, + numberOfQueuedThings: output.numberOfQueuedThings !== undefined && output.numberOfQueuedThings !== null + ? output.numberOfQueuedThings + : undefined, + numberOfRejectedThings: output.numberOfRejectedThings !== undefined && output.numberOfRejectedThings !== null + ? output.numberOfRejectedThings + : undefined, + numberOfRemovedThings: output.numberOfRemovedThings !== undefined && output.numberOfRemovedThings !== null + ? output.numberOfRemovedThings + : undefined, + numberOfSucceededThings: output.numberOfSucceededThings !== undefined && output.numberOfSucceededThings !== null + ? output.numberOfSucceededThings + : undefined, + numberOfTimedOutThings: output.numberOfTimedOutThings !== undefined && output.numberOfTimedOutThings !== null + ? output.numberOfTimedOutThings + : undefined, + processingTargets: output.processingTargets !== undefined && output.processingTargets !== null + ? deserializeAws_restJson1ProcessingTargetNameList(output.processingTargets, context) + : undefined, + }; +}; +const deserializeAws_restJson1JobSummary = (output, context) => { + return { + completedAt: output.completedAt !== undefined && output.completedAt !== null + ? new Date(Math.round(output.completedAt * 1000)) + : undefined, + createdAt: output.createdAt !== undefined && output.createdAt !== null + ? new Date(Math.round(output.createdAt * 1000)) + : undefined, + jobArn: output.jobArn !== undefined && output.jobArn !== null ? output.jobArn : undefined, + jobId: output.jobId !== undefined && output.jobId !== null ? output.jobId : undefined, + lastUpdatedAt: output.lastUpdatedAt !== undefined && output.lastUpdatedAt !== null + ? new Date(Math.round(output.lastUpdatedAt * 1000)) + : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + targetSelection: output.targetSelection !== undefined && output.targetSelection !== null ? output.targetSelection : undefined, + thingGroupId: output.thingGroupId !== undefined && output.thingGroupId !== null ? output.thingGroupId : undefined, + }; +}; +const deserializeAws_restJson1JobSummaryList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1JobSummary(entry, context); + }); +}; +const deserializeAws_restJson1JobTargets = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1KeyPair = (output, context) => { + return { + PrivateKey: output.PrivateKey !== undefined && output.PrivateKey !== null ? output.PrivateKey : undefined, + PublicKey: output.PublicKey !== undefined && output.PublicKey !== null ? output.PublicKey : undefined, + }; +}; +const deserializeAws_restJson1KinesisAction = (output, context) => { + return { + partitionKey: output.partitionKey !== undefined && output.partitionKey !== null ? output.partitionKey : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + streamName: output.streamName !== undefined && output.streamName !== null ? output.streamName : undefined, + }; +}; +const deserializeAws_restJson1LambdaAction = (output, context) => { + return { + functionArn: output.functionArn !== undefined && output.functionArn !== null ? output.functionArn : undefined, + }; +}; +const deserializeAws_restJson1LogTarget = (output, context) => { + return { + targetName: output.targetName !== undefined && output.targetName !== null ? output.targetName : undefined, + targetType: output.targetType !== undefined && output.targetType !== null ? output.targetType : undefined, + }; +}; +const deserializeAws_restJson1LogTargetConfiguration = (output, context) => { + return { + logLevel: output.logLevel !== undefined && output.logLevel !== null ? output.logLevel : undefined, + logTarget: output.logTarget !== undefined && output.logTarget !== null + ? deserializeAws_restJson1LogTarget(output.logTarget, context) + : undefined, + }; +}; +const deserializeAws_restJson1LogTargetConfigurations = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1LogTargetConfiguration(entry, context); + }); +}; +const deserializeAws_restJson1MetricDimension = (output, context) => { + return { + dimensionName: output.dimensionName !== undefined && output.dimensionName !== null ? output.dimensionName : undefined, + operator: output.operator !== undefined && output.operator !== null ? output.operator : undefined, + }; +}; +const deserializeAws_restJson1MetricToRetain = (output, context) => { + return { + metric: output.metric !== undefined && output.metric !== null ? output.metric : undefined, + metricDimension: output.metricDimension !== undefined && output.metricDimension !== null + ? deserializeAws_restJson1MetricDimension(output.metricDimension, context) + : undefined, + }; +}; +const deserializeAws_restJson1MetricValue = (output, context) => { + return { + cidrs: output.cidrs !== undefined && output.cidrs !== null + ? deserializeAws_restJson1Cidrs(output.cidrs, context) + : undefined, + count: output.count !== undefined && output.count !== null ? output.count : undefined, + ports: output.ports !== undefined && output.ports !== null + ? deserializeAws_restJson1Ports(output.ports, context) + : undefined, + }; +}; +const deserializeAws_restJson1MissingContextValues = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1MitigationAction = (output, context) => { + return { + actionParams: output.actionParams !== undefined && output.actionParams !== null + ? deserializeAws_restJson1MitigationActionParams(output.actionParams, context) + : undefined, + id: output.id !== undefined && output.id !== null ? output.id : undefined, + name: output.name !== undefined && output.name !== null ? output.name : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1MitigationActionIdentifier = (output, context) => { + return { + actionArn: output.actionArn !== undefined && output.actionArn !== null ? output.actionArn : undefined, + actionName: output.actionName !== undefined && output.actionName !== null ? output.actionName : undefined, + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + }; +}; +const deserializeAws_restJson1MitigationActionIdentifierList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1MitigationActionIdentifier(entry, context); + }); +}; +const deserializeAws_restJson1MitigationActionList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1MitigationAction(entry, context); + }); +}; +const deserializeAws_restJson1MitigationActionNameList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1MitigationActionParams = (output, context) => { + return { + addThingsToThingGroupParams: output.addThingsToThingGroupParams !== undefined && output.addThingsToThingGroupParams !== null + ? deserializeAws_restJson1AddThingsToThingGroupParams(output.addThingsToThingGroupParams, context) + : undefined, + enableIoTLoggingParams: output.enableIoTLoggingParams !== undefined && output.enableIoTLoggingParams !== null + ? deserializeAws_restJson1EnableIoTLoggingParams(output.enableIoTLoggingParams, context) + : undefined, + publishFindingToSnsParams: output.publishFindingToSnsParams !== undefined && output.publishFindingToSnsParams !== null + ? deserializeAws_restJson1PublishFindingToSnsParams(output.publishFindingToSnsParams, context) + : undefined, + replaceDefaultPolicyVersionParams: output.replaceDefaultPolicyVersionParams !== undefined && output.replaceDefaultPolicyVersionParams !== null + ? deserializeAws_restJson1ReplaceDefaultPolicyVersionParams(output.replaceDefaultPolicyVersionParams, context) + : undefined, + updateCACertificateParams: output.updateCACertificateParams !== undefined && output.updateCACertificateParams !== null + ? deserializeAws_restJson1UpdateCACertificateParams(output.updateCACertificateParams, context) + : undefined, + updateDeviceCertificateParams: output.updateDeviceCertificateParams !== undefined && output.updateDeviceCertificateParams !== null + ? deserializeAws_restJson1UpdateDeviceCertificateParams(output.updateDeviceCertificateParams, context) + : undefined, + }; +}; +const deserializeAws_restJson1NonCompliantResource = (output, context) => { + return { + additionalInfo: output.additionalInfo !== undefined && output.additionalInfo !== null + ? deserializeAws_restJson1StringMap(output.additionalInfo, context) + : undefined, + resourceIdentifier: output.resourceIdentifier !== undefined && output.resourceIdentifier !== null + ? deserializeAws_restJson1ResourceIdentifier(output.resourceIdentifier, context) + : undefined, + resourceType: output.resourceType !== undefined && output.resourceType !== null ? output.resourceType : undefined, + }; +}; +const deserializeAws_restJson1OTAUpdateFile = (output, context) => { + return { + attributes: output.attributes !== undefined && output.attributes !== null + ? deserializeAws_restJson1AttributesMap(output.attributes, context) + : undefined, + codeSigning: output.codeSigning !== undefined && output.codeSigning !== null + ? deserializeAws_restJson1CodeSigning(output.codeSigning, context) + : undefined, + fileLocation: output.fileLocation !== undefined && output.fileLocation !== null + ? deserializeAws_restJson1FileLocation(output.fileLocation, context) + : undefined, + fileName: output.fileName !== undefined && output.fileName !== null ? output.fileName : undefined, + fileType: output.fileType !== undefined && output.fileType !== null ? output.fileType : undefined, + fileVersion: output.fileVersion !== undefined && output.fileVersion !== null ? output.fileVersion : undefined, + }; +}; +const deserializeAws_restJson1OTAUpdateFiles = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1OTAUpdateFile(entry, context); + }); +}; +const deserializeAws_restJson1OTAUpdateInfo = (output, context) => { + return { + additionalParameters: output.additionalParameters !== undefined && output.additionalParameters !== null + ? deserializeAws_restJson1AdditionalParameterMap(output.additionalParameters, context) + : undefined, + awsIotJobArn: output.awsIotJobArn !== undefined && output.awsIotJobArn !== null ? output.awsIotJobArn : undefined, + awsIotJobId: output.awsIotJobId !== undefined && output.awsIotJobId !== null ? output.awsIotJobId : undefined, + awsJobExecutionsRolloutConfig: output.awsJobExecutionsRolloutConfig !== undefined && output.awsJobExecutionsRolloutConfig !== null + ? deserializeAws_restJson1AwsJobExecutionsRolloutConfig(output.awsJobExecutionsRolloutConfig, context) + : undefined, + awsJobPresignedUrlConfig: output.awsJobPresignedUrlConfig !== undefined && output.awsJobPresignedUrlConfig !== null + ? deserializeAws_restJson1AwsJobPresignedUrlConfig(output.awsJobPresignedUrlConfig, context) + : undefined, + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + description: output.description !== undefined && output.description !== null ? output.description : undefined, + errorInfo: output.errorInfo !== undefined && output.errorInfo !== null + ? deserializeAws_restJson1ErrorInfo(output.errorInfo, context) + : undefined, + lastModifiedDate: output.lastModifiedDate !== undefined && output.lastModifiedDate !== null + ? new Date(Math.round(output.lastModifiedDate * 1000)) + : undefined, + otaUpdateArn: output.otaUpdateArn !== undefined && output.otaUpdateArn !== null ? output.otaUpdateArn : undefined, + otaUpdateFiles: output.otaUpdateFiles !== undefined && output.otaUpdateFiles !== null + ? deserializeAws_restJson1OTAUpdateFiles(output.otaUpdateFiles, context) + : undefined, + otaUpdateId: output.otaUpdateId !== undefined && output.otaUpdateId !== null ? output.otaUpdateId : undefined, + otaUpdateStatus: output.otaUpdateStatus !== undefined && output.otaUpdateStatus !== null ? output.otaUpdateStatus : undefined, + protocols: output.protocols !== undefined && output.protocols !== null + ? deserializeAws_restJson1Protocols(output.protocols, context) + : undefined, + targetSelection: output.targetSelection !== undefined && output.targetSelection !== null ? output.targetSelection : undefined, + targets: output.targets !== undefined && output.targets !== null + ? deserializeAws_restJson1Targets(output.targets, context) + : undefined, + }; +}; +const deserializeAws_restJson1OTAUpdatesSummary = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1OTAUpdateSummary(entry, context); + }); +}; +const deserializeAws_restJson1OTAUpdateSummary = (output, context) => { + return { + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + otaUpdateArn: output.otaUpdateArn !== undefined && output.otaUpdateArn !== null ? output.otaUpdateArn : undefined, + otaUpdateId: output.otaUpdateId !== undefined && output.otaUpdateId !== null ? output.otaUpdateId : undefined, + }; +}; +const deserializeAws_restJson1OutgoingCertificate = (output, context) => { + return { + certificateArn: output.certificateArn !== undefined && output.certificateArn !== null ? output.certificateArn : undefined, + certificateId: output.certificateId !== undefined && output.certificateId !== null ? output.certificateId : undefined, + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + transferDate: output.transferDate !== undefined && output.transferDate !== null + ? new Date(Math.round(output.transferDate * 1000)) + : undefined, + transferMessage: output.transferMessage !== undefined && output.transferMessage !== null ? output.transferMessage : undefined, + transferredTo: output.transferredTo !== undefined && output.transferredTo !== null ? output.transferredTo : undefined, + }; +}; +const deserializeAws_restJson1OutgoingCertificates = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1OutgoingCertificate(entry, context); + }); +}; +const deserializeAws_restJson1Percentiles = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1PercentPair(entry, context); + }); +}; +const deserializeAws_restJson1PercentPair = (output, context) => { + return { + percent: output.percent !== undefined && output.percent !== null ? output.percent : undefined, + value: output.value !== undefined && output.value !== null ? output.value : undefined, + }; +}; +const deserializeAws_restJson1Policies = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1Policy(entry, context); + }); +}; +const deserializeAws_restJson1Policy = (output, context) => { + return { + policyArn: output.policyArn !== undefined && output.policyArn !== null ? output.policyArn : undefined, + policyName: output.policyName !== undefined && output.policyName !== null ? output.policyName : undefined, + }; +}; +const deserializeAws_restJson1PolicyDocuments = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1PolicyTargets = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1PolicyVersion = (output, context) => { + return { + createDate: output.createDate !== undefined && output.createDate !== null + ? new Date(Math.round(output.createDate * 1000)) + : undefined, + isDefaultVersion: output.isDefaultVersion !== undefined && output.isDefaultVersion !== null ? output.isDefaultVersion : undefined, + versionId: output.versionId !== undefined && output.versionId !== null ? output.versionId : undefined, + }; +}; +const deserializeAws_restJson1PolicyVersionIdentifier = (output, context) => { + return { + policyName: output.policyName !== undefined && output.policyName !== null ? output.policyName : undefined, + policyVersionId: output.policyVersionId !== undefined && output.policyVersionId !== null ? output.policyVersionId : undefined, + }; +}; +const deserializeAws_restJson1PolicyVersions = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1PolicyVersion(entry, context); + }); +}; +const deserializeAws_restJson1Ports = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1PresignedUrlConfig = (output, context) => { + return { + expiresInSec: output.expiresInSec !== undefined && output.expiresInSec !== null ? output.expiresInSec : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1Principals = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1ProcessingTargetNameList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1Protocols = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1ProvisioningHook = (output, context) => { + return { + payloadVersion: output.payloadVersion !== undefined && output.payloadVersion !== null ? output.payloadVersion : undefined, + targetArn: output.targetArn !== undefined && output.targetArn !== null ? output.targetArn : undefined, + }; +}; +const deserializeAws_restJson1ProvisioningTemplateListing = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ProvisioningTemplateSummary(entry, context); + }); +}; +const deserializeAws_restJson1ProvisioningTemplateSummary = (output, context) => { + return { + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + description: output.description !== undefined && output.description !== null ? output.description : undefined, + enabled: output.enabled !== undefined && output.enabled !== null ? output.enabled : undefined, + lastModifiedDate: output.lastModifiedDate !== undefined && output.lastModifiedDate !== null + ? new Date(Math.round(output.lastModifiedDate * 1000)) + : undefined, + templateArn: output.templateArn !== undefined && output.templateArn !== null ? output.templateArn : undefined, + templateName: output.templateName !== undefined && output.templateName !== null ? output.templateName : undefined, + }; +}; +const deserializeAws_restJson1ProvisioningTemplateVersionListing = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ProvisioningTemplateVersionSummary(entry, context); + }); +}; +const deserializeAws_restJson1ProvisioningTemplateVersionSummary = (output, context) => { + return { + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + isDefaultVersion: output.isDefaultVersion !== undefined && output.isDefaultVersion !== null ? output.isDefaultVersion : undefined, + versionId: output.versionId !== undefined && output.versionId !== null ? output.versionId : undefined, + }; +}; +const deserializeAws_restJson1PublicKeyMap = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_restJson1PublishFindingToSnsParams = (output, context) => { + return { + topicArn: output.topicArn !== undefined && output.topicArn !== null ? output.topicArn : undefined, + }; +}; +const deserializeAws_restJson1PutAssetPropertyValueEntry = (output, context) => { + return { + assetId: output.assetId !== undefined && output.assetId !== null ? output.assetId : undefined, + entryId: output.entryId !== undefined && output.entryId !== null ? output.entryId : undefined, + propertyAlias: output.propertyAlias !== undefined && output.propertyAlias !== null ? output.propertyAlias : undefined, + propertyId: output.propertyId !== undefined && output.propertyId !== null ? output.propertyId : undefined, + propertyValues: output.propertyValues !== undefined && output.propertyValues !== null + ? deserializeAws_restJson1AssetPropertyValueList(output.propertyValues, context) + : undefined, + }; +}; +const deserializeAws_restJson1PutAssetPropertyValueEntryList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1PutAssetPropertyValueEntry(entry, context); + }); +}; +const deserializeAws_restJson1PutItemInput = (output, context) => { + return { + tableName: output.tableName !== undefined && output.tableName !== null ? output.tableName : undefined, + }; +}; +const deserializeAws_restJson1RateIncreaseCriteria = (output, context) => { + return { + numberOfNotifiedThings: output.numberOfNotifiedThings !== undefined && output.numberOfNotifiedThings !== null + ? output.numberOfNotifiedThings + : undefined, + numberOfSucceededThings: output.numberOfSucceededThings !== undefined && output.numberOfSucceededThings !== null + ? output.numberOfSucceededThings + : undefined, + }; +}; +const deserializeAws_restJson1ReasonForNonComplianceCodes = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1RegistrationConfig = (output, context) => { + return { + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + templateBody: output.templateBody !== undefined && output.templateBody !== null ? output.templateBody : undefined, + }; +}; +const deserializeAws_restJson1RelatedResource = (output, context) => { + return { + additionalInfo: output.additionalInfo !== undefined && output.additionalInfo !== null + ? deserializeAws_restJson1StringMap(output.additionalInfo, context) + : undefined, + resourceIdentifier: output.resourceIdentifier !== undefined && output.resourceIdentifier !== null + ? deserializeAws_restJson1ResourceIdentifier(output.resourceIdentifier, context) + : undefined, + resourceType: output.resourceType !== undefined && output.resourceType !== null ? output.resourceType : undefined, + }; +}; +const deserializeAws_restJson1RelatedResources = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1RelatedResource(entry, context); + }); +}; +const deserializeAws_restJson1ReplaceDefaultPolicyVersionParams = (output, context) => { + return { + templateName: output.templateName !== undefined && output.templateName !== null ? output.templateName : undefined, + }; +}; +const deserializeAws_restJson1RepublishAction = (output, context) => { + return { + qos: output.qos !== undefined && output.qos !== null ? output.qos : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + topic: output.topic !== undefined && output.topic !== null ? output.topic : undefined, + }; +}; +const deserializeAws_restJson1ResourceArns = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_restJson1ResourceIdentifier = (output, context) => { + return { + account: output.account !== undefined && output.account !== null ? output.account : undefined, + caCertificateId: output.caCertificateId !== undefined && output.caCertificateId !== null ? output.caCertificateId : undefined, + clientId: output.clientId !== undefined && output.clientId !== null ? output.clientId : undefined, + cognitoIdentityPoolId: output.cognitoIdentityPoolId !== undefined && output.cognitoIdentityPoolId !== null + ? output.cognitoIdentityPoolId + : undefined, + deviceCertificateId: output.deviceCertificateId !== undefined && output.deviceCertificateId !== null + ? output.deviceCertificateId + : undefined, + iamRoleArn: output.iamRoleArn !== undefined && output.iamRoleArn !== null ? output.iamRoleArn : undefined, + policyVersionIdentifier: output.policyVersionIdentifier !== undefined && output.policyVersionIdentifier !== null + ? deserializeAws_restJson1PolicyVersionIdentifier(output.policyVersionIdentifier, context) + : undefined, + roleAliasArn: output.roleAliasArn !== undefined && output.roleAliasArn !== null ? output.roleAliasArn : undefined, + }; +}; +const deserializeAws_restJson1Resources = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1RoleAliasDescription = (output, context) => { + return { + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + credentialDurationSeconds: output.credentialDurationSeconds !== undefined && output.credentialDurationSeconds !== null + ? output.credentialDurationSeconds + : undefined, + lastModifiedDate: output.lastModifiedDate !== undefined && output.lastModifiedDate !== null + ? new Date(Math.round(output.lastModifiedDate * 1000)) + : undefined, + owner: output.owner !== undefined && output.owner !== null ? output.owner : undefined, + roleAlias: output.roleAlias !== undefined && output.roleAlias !== null ? output.roleAlias : undefined, + roleAliasArn: output.roleAliasArn !== undefined && output.roleAliasArn !== null ? output.roleAliasArn : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1RoleAliases = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1S3Action = (output, context) => { + return { + bucketName: output.bucketName !== undefined && output.bucketName !== null ? output.bucketName : undefined, + cannedAcl: output.cannedAcl !== undefined && output.cannedAcl !== null ? output.cannedAcl : undefined, + key: output.key !== undefined && output.key !== null ? output.key : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + }; +}; +const deserializeAws_restJson1S3Destination = (output, context) => { + return { + bucket: output.bucket !== undefined && output.bucket !== null ? output.bucket : undefined, + prefix: output.prefix !== undefined && output.prefix !== null ? output.prefix : undefined, + }; +}; +const deserializeAws_restJson1S3FileUrlList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1S3Location = (output, context) => { + return { + bucket: output.bucket !== undefined && output.bucket !== null ? output.bucket : undefined, + key: output.key !== undefined && output.key !== null ? output.key : undefined, + version: output.version !== undefined && output.version !== null ? output.version : undefined, + }; +}; +const deserializeAws_restJson1SalesforceAction = (output, context) => { + return { + token: output.token !== undefined && output.token !== null ? output.token : undefined, + url: output.url !== undefined && output.url !== null ? output.url : undefined, + }; +}; +const deserializeAws_restJson1ScheduledAuditMetadata = (output, context) => { + return { + dayOfMonth: output.dayOfMonth !== undefined && output.dayOfMonth !== null ? output.dayOfMonth : undefined, + dayOfWeek: output.dayOfWeek !== undefined && output.dayOfWeek !== null ? output.dayOfWeek : undefined, + frequency: output.frequency !== undefined && output.frequency !== null ? output.frequency : undefined, + scheduledAuditArn: output.scheduledAuditArn !== undefined && output.scheduledAuditArn !== null + ? output.scheduledAuditArn + : undefined, + scheduledAuditName: output.scheduledAuditName !== undefined && output.scheduledAuditName !== null + ? output.scheduledAuditName + : undefined, + }; +}; +const deserializeAws_restJson1ScheduledAuditMetadataList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ScheduledAuditMetadata(entry, context); + }); +}; +const deserializeAws_restJson1SearchableAttributes = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1SecurityProfileIdentifier = (output, context) => { + return { + arn: output.arn !== undefined && output.arn !== null ? output.arn : undefined, + name: output.name !== undefined && output.name !== null ? output.name : undefined, + }; +}; +const deserializeAws_restJson1SecurityProfileIdentifiers = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1SecurityProfileIdentifier(entry, context); + }); +}; +const deserializeAws_restJson1SecurityProfileTarget = (output, context) => { + return { + arn: output.arn !== undefined && output.arn !== null ? output.arn : undefined, + }; +}; +const deserializeAws_restJson1SecurityProfileTargetMapping = (output, context) => { + return { + securityProfileIdentifier: output.securityProfileIdentifier !== undefined && output.securityProfileIdentifier !== null + ? deserializeAws_restJson1SecurityProfileIdentifier(output.securityProfileIdentifier, context) + : undefined, + target: output.target !== undefined && output.target !== null + ? deserializeAws_restJson1SecurityProfileTarget(output.target, context) + : undefined, + }; +}; +const deserializeAws_restJson1SecurityProfileTargetMappings = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1SecurityProfileTargetMapping(entry, context); + }); +}; +const deserializeAws_restJson1SecurityProfileTargets = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1SecurityProfileTarget(entry, context); + }); +}; +const deserializeAws_restJson1ServerCertificates = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ServerCertificateSummary(entry, context); + }); +}; +const deserializeAws_restJson1ServerCertificateSummary = (output, context) => { + return { + serverCertificateArn: output.serverCertificateArn !== undefined && output.serverCertificateArn !== null + ? output.serverCertificateArn + : undefined, + serverCertificateStatus: output.serverCertificateStatus !== undefined && output.serverCertificateStatus !== null + ? output.serverCertificateStatus + : undefined, + serverCertificateStatusDetail: output.serverCertificateStatusDetail !== undefined && output.serverCertificateStatusDetail !== null + ? output.serverCertificateStatusDetail + : undefined, + }; +}; +const deserializeAws_restJson1SigningProfileParameter = (output, context) => { + return { + certificateArn: output.certificateArn !== undefined && output.certificateArn !== null ? output.certificateArn : undefined, + certificatePathOnDevice: output.certificatePathOnDevice !== undefined && output.certificatePathOnDevice !== null + ? output.certificatePathOnDevice + : undefined, + platform: output.platform !== undefined && output.platform !== null ? output.platform : undefined, + }; +}; +const deserializeAws_restJson1SigV4Authorization = (output, context) => { + return { + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + serviceName: output.serviceName !== undefined && output.serviceName !== null ? output.serviceName : undefined, + signingRegion: output.signingRegion !== undefined && output.signingRegion !== null ? output.signingRegion : undefined, + }; +}; +const deserializeAws_restJson1SnsAction = (output, context) => { + return { + messageFormat: output.messageFormat !== undefined && output.messageFormat !== null ? output.messageFormat : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + targetArn: output.targetArn !== undefined && output.targetArn !== null ? output.targetArn : undefined, + }; +}; +const deserializeAws_restJson1SqsAction = (output, context) => { + return { + queueUrl: output.queueUrl !== undefined && output.queueUrl !== null ? output.queueUrl : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + useBase64: output.useBase64 !== undefined && output.useBase64 !== null ? output.useBase64 : undefined, + }; +}; +const deserializeAws_restJson1StartSigningJobParameter = (output, context) => { + return { + destination: output.destination !== undefined && output.destination !== null + ? deserializeAws_restJson1Destination(output.destination, context) + : undefined, + signingProfileName: output.signingProfileName !== undefined && output.signingProfileName !== null + ? output.signingProfileName + : undefined, + signingProfileParameter: output.signingProfileParameter !== undefined && output.signingProfileParameter !== null + ? deserializeAws_restJson1SigningProfileParameter(output.signingProfileParameter, context) + : undefined, + }; +}; +const deserializeAws_restJson1StatisticalThreshold = (output, context) => { + return { + statistic: output.statistic !== undefined && output.statistic !== null ? output.statistic : undefined, + }; +}; +const deserializeAws_restJson1Statistics = (output, context) => { + return { + average: output.average !== undefined && output.average !== null ? output.average : undefined, + count: output.count !== undefined && output.count !== null ? output.count : undefined, + maximum: output.maximum !== undefined && output.maximum !== null ? output.maximum : undefined, + minimum: output.minimum !== undefined && output.minimum !== null ? output.minimum : undefined, + stdDeviation: output.stdDeviation !== undefined && output.stdDeviation !== null ? output.stdDeviation : undefined, + sum: output.sum !== undefined && output.sum !== null ? output.sum : undefined, + sumOfSquares: output.sumOfSquares !== undefined && output.sumOfSquares !== null ? output.sumOfSquares : undefined, + variance: output.variance !== undefined && output.variance !== null ? output.variance : undefined, + }; +}; +const deserializeAws_restJson1StepFunctionsAction = (output, context) => { + return { + executionNamePrefix: output.executionNamePrefix !== undefined && output.executionNamePrefix !== null + ? output.executionNamePrefix + : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + stateMachineName: output.stateMachineName !== undefined && output.stateMachineName !== null ? output.stateMachineName : undefined, + }; +}; +const deserializeAws_restJson1_Stream = (output, context) => { + return { + fileId: output.fileId !== undefined && output.fileId !== null ? output.fileId : undefined, + streamId: output.streamId !== undefined && output.streamId !== null ? output.streamId : undefined, + }; +}; +const deserializeAws_restJson1StreamFile = (output, context) => { + return { + fileId: output.fileId !== undefined && output.fileId !== null ? output.fileId : undefined, + s3Location: output.s3Location !== undefined && output.s3Location !== null + ? deserializeAws_restJson1S3Location(output.s3Location, context) + : undefined, + }; +}; +const deserializeAws_restJson1StreamFiles = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1StreamFile(entry, context); + }); +}; +const deserializeAws_restJson1StreamInfo = (output, context) => { + return { + createdAt: output.createdAt !== undefined && output.createdAt !== null + ? new Date(Math.round(output.createdAt * 1000)) + : undefined, + description: output.description !== undefined && output.description !== null ? output.description : undefined, + files: output.files !== undefined && output.files !== null + ? deserializeAws_restJson1StreamFiles(output.files, context) + : undefined, + lastUpdatedAt: output.lastUpdatedAt !== undefined && output.lastUpdatedAt !== null + ? new Date(Math.round(output.lastUpdatedAt * 1000)) + : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + streamArn: output.streamArn !== undefined && output.streamArn !== null ? output.streamArn : undefined, + streamId: output.streamId !== undefined && output.streamId !== null ? output.streamId : undefined, + streamVersion: output.streamVersion !== undefined && output.streamVersion !== null ? output.streamVersion : undefined, + }; +}; +const deserializeAws_restJson1StreamsSummary = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1StreamSummary(entry, context); + }); +}; +const deserializeAws_restJson1StreamSummary = (output, context) => { + return { + description: output.description !== undefined && output.description !== null ? output.description : undefined, + streamArn: output.streamArn !== undefined && output.streamArn !== null ? output.streamArn : undefined, + streamId: output.streamId !== undefined && output.streamId !== null ? output.streamId : undefined, + streamVersion: output.streamVersion !== undefined && output.streamVersion !== null ? output.streamVersion : undefined, + }; +}; +const deserializeAws_restJson1StringMap = (output, context) => { + return Object.entries(output).reduce((acc, [key, value]) => { + if (value === null) { + return acc; + } + return { + ...acc, + [key]: value, + }; + }, {}); +}; +const deserializeAws_restJson1Tag = (output, context) => { + return { + Key: output.Key !== undefined && output.Key !== null ? output.Key : undefined, + Value: output.Value !== undefined && output.Value !== null ? output.Value : undefined, + }; +}; +const deserializeAws_restJson1TagList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1Tag(entry, context); + }); +}; +const deserializeAws_restJson1TargetAuditCheckNames = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1Targets = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1TaskIdList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1TaskStatistics = (output, context) => { + return { + canceledChecks: output.canceledChecks !== undefined && output.canceledChecks !== null ? output.canceledChecks : undefined, + compliantChecks: output.compliantChecks !== undefined && output.compliantChecks !== null ? output.compliantChecks : undefined, + failedChecks: output.failedChecks !== undefined && output.failedChecks !== null ? output.failedChecks : undefined, + inProgressChecks: output.inProgressChecks !== undefined && output.inProgressChecks !== null ? output.inProgressChecks : undefined, + nonCompliantChecks: output.nonCompliantChecks !== undefined && output.nonCompliantChecks !== null + ? output.nonCompliantChecks + : undefined, + totalChecks: output.totalChecks !== undefined && output.totalChecks !== null ? output.totalChecks : undefined, + waitingForDataCollectionChecks: output.waitingForDataCollectionChecks !== undefined && output.waitingForDataCollectionChecks !== null + ? output.waitingForDataCollectionChecks + : undefined, + }; +}; +const deserializeAws_restJson1TaskStatisticsForAuditCheck = (output, context) => { + return { + canceledFindingsCount: output.canceledFindingsCount !== undefined && output.canceledFindingsCount !== null + ? output.canceledFindingsCount + : undefined, + failedFindingsCount: output.failedFindingsCount !== undefined && output.failedFindingsCount !== null + ? output.failedFindingsCount + : undefined, + skippedFindingsCount: output.skippedFindingsCount !== undefined && output.skippedFindingsCount !== null + ? output.skippedFindingsCount + : undefined, + succeededFindingsCount: output.succeededFindingsCount !== undefined && output.succeededFindingsCount !== null + ? output.succeededFindingsCount + : undefined, + totalFindingsCount: output.totalFindingsCount !== undefined && output.totalFindingsCount !== null + ? output.totalFindingsCount + : undefined, + }; +}; +const deserializeAws_restJson1ThingAttribute = (output, context) => { + return { + attributes: output.attributes !== undefined && output.attributes !== null + ? deserializeAws_restJson1Attributes(output.attributes, context) + : undefined, + thingArn: output.thingArn !== undefined && output.thingArn !== null ? output.thingArn : undefined, + thingName: output.thingName !== undefined && output.thingName !== null ? output.thingName : undefined, + thingTypeName: output.thingTypeName !== undefined && output.thingTypeName !== null ? output.thingTypeName : undefined, + version: output.version !== undefined && output.version !== null ? output.version : undefined, + }; +}; +const deserializeAws_restJson1ThingAttributeList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ThingAttribute(entry, context); + }); +}; +const deserializeAws_restJson1ThingConnectivity = (output, context) => { + return { + connected: output.connected !== undefined && output.connected !== null ? output.connected : undefined, + timestamp: output.timestamp !== undefined && output.timestamp !== null ? output.timestamp : undefined, + }; +}; +const deserializeAws_restJson1ThingDocument = (output, context) => { + return { + attributes: output.attributes !== undefined && output.attributes !== null + ? deserializeAws_restJson1Attributes(output.attributes, context) + : undefined, + connectivity: output.connectivity !== undefined && output.connectivity !== null + ? deserializeAws_restJson1ThingConnectivity(output.connectivity, context) + : undefined, + shadow: output.shadow !== undefined && output.shadow !== null ? output.shadow : undefined, + thingGroupNames: output.thingGroupNames !== undefined && output.thingGroupNames !== null + ? deserializeAws_restJson1ThingGroupNameList(output.thingGroupNames, context) + : undefined, + thingId: output.thingId !== undefined && output.thingId !== null ? output.thingId : undefined, + thingName: output.thingName !== undefined && output.thingName !== null ? output.thingName : undefined, + thingTypeName: output.thingTypeName !== undefined && output.thingTypeName !== null ? output.thingTypeName : undefined, + }; +}; +const deserializeAws_restJson1ThingDocumentList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ThingDocument(entry, context); + }); +}; +const deserializeAws_restJson1ThingGroupDocument = (output, context) => { + return { + attributes: output.attributes !== undefined && output.attributes !== null + ? deserializeAws_restJson1Attributes(output.attributes, context) + : undefined, + parentGroupNames: output.parentGroupNames !== undefined && output.parentGroupNames !== null + ? deserializeAws_restJson1ThingGroupNameList(output.parentGroupNames, context) + : undefined, + thingGroupDescription: output.thingGroupDescription !== undefined && output.thingGroupDescription !== null + ? output.thingGroupDescription + : undefined, + thingGroupId: output.thingGroupId !== undefined && output.thingGroupId !== null ? output.thingGroupId : undefined, + thingGroupName: output.thingGroupName !== undefined && output.thingGroupName !== null ? output.thingGroupName : undefined, + }; +}; +const deserializeAws_restJson1ThingGroupDocumentList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ThingGroupDocument(entry, context); + }); +}; +const deserializeAws_restJson1ThingGroupIndexingConfiguration = (output, context) => { + return { + customFields: output.customFields !== undefined && output.customFields !== null + ? deserializeAws_restJson1Fields(output.customFields, context) + : undefined, + managedFields: output.managedFields !== undefined && output.managedFields !== null + ? deserializeAws_restJson1Fields(output.managedFields, context) + : undefined, + thingGroupIndexingMode: output.thingGroupIndexingMode !== undefined && output.thingGroupIndexingMode !== null + ? output.thingGroupIndexingMode + : undefined, + }; +}; +const deserializeAws_restJson1ThingGroupMetadata = (output, context) => { + return { + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + parentGroupName: output.parentGroupName !== undefined && output.parentGroupName !== null ? output.parentGroupName : undefined, + rootToParentThingGroups: output.rootToParentThingGroups !== undefined && output.rootToParentThingGroups !== null + ? deserializeAws_restJson1ThingGroupNameAndArnList(output.rootToParentThingGroups, context) + : undefined, + }; +}; +const deserializeAws_restJson1ThingGroupNameAndArnList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1GroupNameAndArn(entry, context); + }); +}; +const deserializeAws_restJson1ThingGroupNameList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1ThingGroupNames = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1ThingGroupProperties = (output, context) => { + return { + attributePayload: output.attributePayload !== undefined && output.attributePayload !== null + ? deserializeAws_restJson1AttributePayload(output.attributePayload, context) + : undefined, + thingGroupDescription: output.thingGroupDescription !== undefined && output.thingGroupDescription !== null + ? output.thingGroupDescription + : undefined, + }; +}; +const deserializeAws_restJson1ThingIndexingConfiguration = (output, context) => { + return { + customFields: output.customFields !== undefined && output.customFields !== null + ? deserializeAws_restJson1Fields(output.customFields, context) + : undefined, + managedFields: output.managedFields !== undefined && output.managedFields !== null + ? deserializeAws_restJson1Fields(output.managedFields, context) + : undefined, + thingConnectivityIndexingMode: output.thingConnectivityIndexingMode !== undefined && output.thingConnectivityIndexingMode !== null + ? output.thingConnectivityIndexingMode + : undefined, + thingIndexingMode: output.thingIndexingMode !== undefined && output.thingIndexingMode !== null + ? output.thingIndexingMode + : undefined, + }; +}; +const deserializeAws_restJson1ThingNameList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return entry; + }); +}; +const deserializeAws_restJson1ThingTypeDefinition = (output, context) => { + return { + thingTypeArn: output.thingTypeArn !== undefined && output.thingTypeArn !== null ? output.thingTypeArn : undefined, + thingTypeMetadata: output.thingTypeMetadata !== undefined && output.thingTypeMetadata !== null + ? deserializeAws_restJson1ThingTypeMetadata(output.thingTypeMetadata, context) + : undefined, + thingTypeName: output.thingTypeName !== undefined && output.thingTypeName !== null ? output.thingTypeName : undefined, + thingTypeProperties: output.thingTypeProperties !== undefined && output.thingTypeProperties !== null + ? deserializeAws_restJson1ThingTypeProperties(output.thingTypeProperties, context) + : undefined, + }; +}; +const deserializeAws_restJson1ThingTypeList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ThingTypeDefinition(entry, context); + }); +}; +const deserializeAws_restJson1ThingTypeMetadata = (output, context) => { + return { + creationDate: output.creationDate !== undefined && output.creationDate !== null + ? new Date(Math.round(output.creationDate * 1000)) + : undefined, + deprecated: output.deprecated !== undefined && output.deprecated !== null ? output.deprecated : undefined, + deprecationDate: output.deprecationDate !== undefined && output.deprecationDate !== null + ? new Date(Math.round(output.deprecationDate * 1000)) + : undefined, + }; +}; +const deserializeAws_restJson1ThingTypeProperties = (output, context) => { + return { + searchableAttributes: output.searchableAttributes !== undefined && output.searchableAttributes !== null + ? deserializeAws_restJson1SearchableAttributes(output.searchableAttributes, context) + : undefined, + thingTypeDescription: output.thingTypeDescription !== undefined && output.thingTypeDescription !== null + ? output.thingTypeDescription + : undefined, + }; +}; +const deserializeAws_restJson1TimeoutConfig = (output, context) => { + return { + inProgressTimeoutInMinutes: output.inProgressTimeoutInMinutes !== undefined && output.inProgressTimeoutInMinutes !== null + ? output.inProgressTimeoutInMinutes + : undefined, + }; +}; +const deserializeAws_restJson1TimestreamAction = (output, context) => { + return { + databaseName: output.databaseName !== undefined && output.databaseName !== null ? output.databaseName : undefined, + dimensions: output.dimensions !== undefined && output.dimensions !== null + ? deserializeAws_restJson1TimestreamDimensionList(output.dimensions, context) + : undefined, + roleArn: output.roleArn !== undefined && output.roleArn !== null ? output.roleArn : undefined, + tableName: output.tableName !== undefined && output.tableName !== null ? output.tableName : undefined, + timestamp: output.timestamp !== undefined && output.timestamp !== null + ? deserializeAws_restJson1TimestreamTimestamp(output.timestamp, context) + : undefined, + }; +}; +const deserializeAws_restJson1TimestreamDimension = (output, context) => { + return { + name: output.name !== undefined && output.name !== null ? output.name : undefined, + value: output.value !== undefined && output.value !== null ? output.value : undefined, + }; +}; +const deserializeAws_restJson1TimestreamDimensionList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1TimestreamDimension(entry, context); + }); +}; +const deserializeAws_restJson1TimestreamTimestamp = (output, context) => { + return { + unit: output.unit !== undefined && output.unit !== null ? output.unit : undefined, + value: output.value !== undefined && output.value !== null ? output.value : undefined, + }; +}; +const deserializeAws_restJson1TopicRule = (output, context) => { + return { + actions: output.actions !== undefined && output.actions !== null + ? deserializeAws_restJson1ActionList(output.actions, context) + : undefined, + awsIotSqlVersion: output.awsIotSqlVersion !== undefined && output.awsIotSqlVersion !== null ? output.awsIotSqlVersion : undefined, + createdAt: output.createdAt !== undefined && output.createdAt !== null + ? new Date(Math.round(output.createdAt * 1000)) + : undefined, + description: output.description !== undefined && output.description !== null ? output.description : undefined, + errorAction: output.errorAction !== undefined && output.errorAction !== null + ? deserializeAws_restJson1Action(output.errorAction, context) + : undefined, + ruleDisabled: output.ruleDisabled !== undefined && output.ruleDisabled !== null ? output.ruleDisabled : undefined, + ruleName: output.ruleName !== undefined && output.ruleName !== null ? output.ruleName : undefined, + sql: output.sql !== undefined && output.sql !== null ? output.sql : undefined, + }; +}; +const deserializeAws_restJson1TopicRuleDestination = (output, context) => { + return { + arn: output.arn !== undefined && output.arn !== null ? output.arn : undefined, + httpUrlProperties: output.httpUrlProperties !== undefined && output.httpUrlProperties !== null + ? deserializeAws_restJson1HttpUrlDestinationProperties(output.httpUrlProperties, context) + : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + statusReason: output.statusReason !== undefined && output.statusReason !== null ? output.statusReason : undefined, + }; +}; +const deserializeAws_restJson1TopicRuleDestinationSummaries = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1TopicRuleDestinationSummary(entry, context); + }); +}; +const deserializeAws_restJson1TopicRuleDestinationSummary = (output, context) => { + return { + arn: output.arn !== undefined && output.arn !== null ? output.arn : undefined, + httpUrlSummary: output.httpUrlSummary !== undefined && output.httpUrlSummary !== null + ? deserializeAws_restJson1HttpUrlDestinationSummary(output.httpUrlSummary, context) + : undefined, + status: output.status !== undefined && output.status !== null ? output.status : undefined, + statusReason: output.statusReason !== undefined && output.statusReason !== null ? output.statusReason : undefined, + }; +}; +const deserializeAws_restJson1TopicRuleList = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1TopicRuleListItem(entry, context); + }); +}; +const deserializeAws_restJson1TopicRuleListItem = (output, context) => { + return { + createdAt: output.createdAt !== undefined && output.createdAt !== null + ? new Date(Math.round(output.createdAt * 1000)) + : undefined, + ruleArn: output.ruleArn !== undefined && output.ruleArn !== null ? output.ruleArn : undefined, + ruleDisabled: output.ruleDisabled !== undefined && output.ruleDisabled !== null ? output.ruleDisabled : undefined, + ruleName: output.ruleName !== undefined && output.ruleName !== null ? output.ruleName : undefined, + topicPattern: output.topicPattern !== undefined && output.topicPattern !== null ? output.topicPattern : undefined, + }; +}; +const deserializeAws_restJson1TransferData = (output, context) => { + return { + acceptDate: output.acceptDate !== undefined && output.acceptDate !== null + ? new Date(Math.round(output.acceptDate * 1000)) + : undefined, + rejectDate: output.rejectDate !== undefined && output.rejectDate !== null + ? new Date(Math.round(output.rejectDate * 1000)) + : undefined, + rejectReason: output.rejectReason !== undefined && output.rejectReason !== null ? output.rejectReason : undefined, + transferDate: output.transferDate !== undefined && output.transferDate !== null + ? new Date(Math.round(output.transferDate * 1000)) + : undefined, + transferMessage: output.transferMessage !== undefined && output.transferMessage !== null ? output.transferMessage : undefined, + }; +}; +const deserializeAws_restJson1UpdateCACertificateParams = (output, context) => { + return { + action: output.action !== undefined && output.action !== null ? output.action : undefined, + }; +}; +const deserializeAws_restJson1UpdateDeviceCertificateParams = (output, context) => { + return { + action: output.action !== undefined && output.action !== null ? output.action : undefined, + }; +}; +const deserializeAws_restJson1ValidationError = (output, context) => { + return { + errorMessage: output.errorMessage !== undefined && output.errorMessage !== null ? output.errorMessage : undefined, + }; +}; +const deserializeAws_restJson1ValidationErrors = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ValidationError(entry, context); + }); +}; +const deserializeAws_restJson1ViolationEvent = (output, context) => { + return { + behavior: output.behavior !== undefined && output.behavior !== null + ? deserializeAws_restJson1Behavior(output.behavior, context) + : undefined, + metricValue: output.metricValue !== undefined && output.metricValue !== null + ? deserializeAws_restJson1MetricValue(output.metricValue, context) + : undefined, + securityProfileName: output.securityProfileName !== undefined && output.securityProfileName !== null + ? output.securityProfileName + : undefined, + thingName: output.thingName !== undefined && output.thingName !== null ? output.thingName : undefined, + violationEventTime: output.violationEventTime !== undefined && output.violationEventTime !== null + ? new Date(Math.round(output.violationEventTime * 1000)) + : undefined, + violationEventType: output.violationEventType !== undefined && output.violationEventType !== null + ? output.violationEventType + : undefined, + violationId: output.violationId !== undefined && output.violationId !== null ? output.violationId : undefined, + }; +}; +const deserializeAws_restJson1ViolationEvents = (output, context) => { + return (output || []) + .filter((e) => e != null) + .map((entry) => { + if (entry === null) { + return null; + } + return deserializeAws_restJson1ViolationEvent(entry, context); + }); +}; +const deserializeMetadata = (output) => { + var _a; + return ({ + httpStatusCode: output.statusCode, + requestId: (_a = output.headers["x-amzn-requestid"]) !== null && _a !== void 0 ? _a : output.headers["x-amzn-request-id"], + extendedRequestId: output.headers["x-amz-id-2"], + cfId: output.headers["x-amz-cf-id"], + }); +}; +// Collect low-level response body stream to Uint8Array. +const collectBody = (streamBody = new Uint8Array(), context) => { + if (streamBody instanceof Uint8Array) { + return Promise.resolve(streamBody); + } + return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array()); +}; +// Encode Uint8Array data into string with utf-8. +const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body)); +const isSerializableHeaderValue = (value) => value !== undefined && + value !== null && + value !== "" && + (!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) && + (!Object.getOwnPropertyNames(value).includes("size") || value.size != 0); +const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => { + if (encoded.length) { + return JSON.parse(encoded); + } + return {}; +}); +/** + * Load an error code for the aws.rest-json-1.1 protocol. + */ +const loadRestJsonErrorCode = (output, data) => { + const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase()); + const sanitizeErrorCode = (rawValue) => { + let cleanValue = rawValue; + if (cleanValue.indexOf(":") >= 0) { + cleanValue = cleanValue.split(":")[0]; + } + if (cleanValue.indexOf("#") >= 0) { + cleanValue = cleanValue.split("#")[1]; + } + return cleanValue; + }; + const headerKey = findKey(output.headers, "x-amzn-errortype"); + if (headerKey !== undefined) { + return sanitizeErrorCode(output.headers[headerKey]); + } + if (data.code !== undefined) { + return sanitizeErrorCode(data.code); + } + if (data["__type"] !== undefined) { + return sanitizeErrorCode(data["__type"]); + } + return ""; +}; +//# sourceMappingURL=Aws_restJson1.js.map + +/***/ }), + +/***/ 67490: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ClientDefaultValues = void 0; +const tslib_1 = __nccwpck_require__(3153); +const package_json_1 = tslib_1.__importDefault(__nccwpck_require__(57111)); +const config_resolver_1 = __nccwpck_require__(87229); +const credential_provider_node_1 = __nccwpck_require__(98030); +const hash_node_1 = __nccwpck_require__(90791); +const middleware_retry_1 = __nccwpck_require__(7000); +const node_config_provider_1 = __nccwpck_require__(71124); +const node_http_handler_1 = __nccwpck_require__(15168); +const util_base64_node_1 = __nccwpck_require__(2091); +const util_body_length_node_1 = __nccwpck_require__(40286); +const util_user_agent_node_1 = __nccwpck_require__(64717); +const util_utf8_node_1 = __nccwpck_require__(85227); +const runtimeConfig_shared_1 = __nccwpck_require__(96571); +/** + * @internal + */ +exports.ClientDefaultValues = { + ...runtimeConfig_shared_1.ClientSharedValues, + runtime: "node", + base64Decoder: util_base64_node_1.fromBase64, + base64Encoder: util_base64_node_1.toBase64, + bodyLengthChecker: util_body_length_node_1.calculateBodyLength, + credentialDefaultProvider: credential_provider_node_1.defaultProvider, + defaultUserAgentProvider: util_user_agent_node_1.defaultUserAgent({ + serviceId: runtimeConfig_shared_1.ClientSharedValues.serviceId, + clientVersion: package_json_1.default.version, + }), + maxAttempts: node_config_provider_1.loadConfig(middleware_retry_1.NODE_MAX_ATTEMPT_CONFIG_OPTIONS), + region: node_config_provider_1.loadConfig(config_resolver_1.NODE_REGION_CONFIG_OPTIONS, config_resolver_1.NODE_REGION_CONFIG_FILE_OPTIONS), + requestHandler: new node_http_handler_1.NodeHttpHandler(), + sha256: hash_node_1.Hash.bind(null, "sha256"), + streamCollector: node_http_handler_1.streamCollector, + utf8Decoder: util_utf8_node_1.fromUtf8, + utf8Encoder: util_utf8_node_1.toUtf8, +}; +//# sourceMappingURL=runtimeConfig.js.map + +/***/ }), + +/***/ 96571: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ClientSharedValues = void 0; +const endpoints_1 = __nccwpck_require__(37987); +const url_parser_1 = __nccwpck_require__(99427); +/** + * @internal + */ +exports.ClientSharedValues = { + apiVersion: "2015-05-28", + disableHostPrefix: false, + logger: {}, + regionInfoProvider: endpoints_1.defaultRegionInfoProvider, + serviceId: "IoT", + urlParser: url_parser_1.parseUrl, +}; +//# sourceMappingURL=runtimeConfig.shared.js.map + +/***/ }), + +/***/ 3153: +/***/ ((__unused_webpack_module, __webpack_exports__, __nccwpck_require__) => { + +"use strict"; +__nccwpck_require__.r(__webpack_exports__); +/* harmony export */ __nccwpck_require__.d(__webpack_exports__, { +/* harmony export */ "__extends": () => /* binding */ __extends, +/* harmony export */ "__assign": () => /* binding */ __assign, +/* harmony export */ "__rest": () => /* binding */ __rest, +/* harmony export */ "__decorate": () => /* binding */ __decorate, +/* harmony export */ "__param": () => /* binding */ __param, +/* harmony export */ "__metadata": () => /* binding */ __metadata, +/* harmony export */ "__awaiter": () => /* binding */ __awaiter, +/* harmony export */ "__generator": () => /* binding */ __generator, +/* harmony export */ "__createBinding": () => /* binding */ __createBinding, +/* harmony export */ "__exportStar": () => /* binding */ __exportStar, +/* harmony export */ "__values": () => /* binding */ __values, +/* harmony export */ "__read": () => /* binding */ __read, +/* harmony export */ "__spread": () => /* binding */ __spread, +/* harmony export */ "__spreadArrays": () => /* binding */ __spreadArrays, +/* harmony export */ "__spreadArray": () => /* binding */ __spreadArray, +/* harmony export */ "__await": () => /* binding */ __await, +/* harmony export */ "__asyncGenerator": () => /* binding */ __asyncGenerator, +/* harmony export */ "__asyncDelegator": () => /* binding */ __asyncDelegator, +/* harmony export */ "__asyncValues": () => /* binding */ __asyncValues, +/* harmony export */ "__makeTemplateObject": () => /* binding */ __makeTemplateObject, +/* harmony export */ "__importStar": () => /* binding */ __importStar, +/* harmony export */ "__importDefault": () => /* binding */ __importDefault, +/* harmony export */ "__classPrivateFieldGet": () => /* binding */ __classPrivateFieldGet, +/* harmony export */ "__classPrivateFieldSet": () => /* binding */ __classPrivateFieldSet +/* harmony export */ }); +/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. +***************************************************************************** */ +/* global Reflect, Promise */ + +var extendStatics = function(d, b) { + extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; + return extendStatics(d, b); +}; + +function __extends(d, b) { + if (typeof b !== "function" && b !== null) + throw new TypeError("Class extends value " + String(b) + " is not a constructor or null"); + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); +} + +var __assign = function() { + __assign = Object.assign || function __assign(t) { + for (var s, i = 1, n = arguments.length; i < n; i++) { + s = arguments[i]; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p]; + } + return t; + } + return __assign.apply(this, arguments); +} + +function __rest(s, e) { + var t = {}; + for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) + t[p] = s[p]; + if (s != null && typeof Object.getOwnPropertySymbols === "function") + for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) { + if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) + t[p[i]] = s[p[i]]; + } + return t; +} + +function __decorate(decorators, target, key, desc) { + var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; + if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); + else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; + return c > 3 && r && Object.defineProperty(target, key, r), r; +} + +function __param(paramIndex, decorator) { + return function (target, key) { decorator(target, key, paramIndex); } +} + +function __metadata(metadataKey, metadataValue) { + if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue); +} + +function __awaiter(thisArg, _arguments, P, generator) { + function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } + return new (P || (P = Promise))(function (resolve, reject) { + function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } + function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } + function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } + step((generator = generator.apply(thisArg, _arguments || [])).next()); + }); +} + +function __generator(thisArg, body) { + var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g; + return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g; + function verb(n) { return function (v) { return step([n, v]); }; } + function step(op) { + if (f) throw new TypeError("Generator is already executing."); + while (_) try { + if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t; + if (y = 0, t) op = [op[0] & 2, t.value]; + switch (op[0]) { + case 0: case 1: t = op; break; + case 4: _.label++; return { value: op[1], done: false }; + case 5: _.label++; y = op[1]; op = [0]; continue; + case 7: op = _.ops.pop(); _.trys.pop(); continue; + default: + if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; } + if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; } + if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; } + if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; } + if (t[2]) _.ops.pop(); + _.trys.pop(); continue; + } + op = body.call(thisArg, _); + } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; } + if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true }; + } +} + +var __createBinding = Object.create ? (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } }); +}) : (function(o, m, k, k2) { + if (k2 === undefined) k2 = k; + o[k2] = m[k]; +}); + +function __exportStar(m, o) { + for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p); +} + +function __values(o) { + var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0; + if (m) return m.call(o); + if (o && typeof o.length === "number") return { + next: function () { + if (o && i >= o.length) o = void 0; + return { value: o && o[i++], done: !o }; + } + }; + throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined."); +} + +function __read(o, n) { + var m = typeof Symbol === "function" && o[Symbol.iterator]; + if (!m) return o; + var i = m.call(o), r, ar = [], e; + try { + while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value); + } + catch (error) { e = { error: error }; } + finally { + try { + if (r && !r.done && (m = i["return"])) m.call(i); + } + finally { if (e) throw e.error; } + } + return ar; +} + +/** @deprecated */ +function __spread() { + for (var ar = [], i = 0; i < arguments.length; i++) + ar = ar.concat(__read(arguments[i])); + return ar; +} + +/** @deprecated */ +function __spreadArrays() { + for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length; + for (var r = Array(s), k = 0, i = 0; i < il; i++) + for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++) + r[k] = a[j]; + return r; +} + +function __spreadArray(to, from) { + for (var i = 0, il = from.length, j = to.length; i < il; i++, j++) + to[j] = from[i]; + return to; +} + +function __await(v) { + return this instanceof __await ? (this.v = v, this) : new __await(v); +} + +function __asyncGenerator(thisArg, _arguments, generator) { + if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined."); + var g = generator.apply(thisArg, _arguments || []), i, q = []; + return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i; + function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; } + function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } } + function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); } + function fulfill(value) { resume("next", value); } + function reject(value) { resume("throw", value); } + function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); } +} + +function __asyncDelegator(o) { + var i, p; + return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i; + function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; } +} + +function __asyncValues(o) { + if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined."); + var m = o[Symbol.asyncIterator], i; + return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i); + function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; } + function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); } +} + +function __makeTemplateObject(cooked, raw) { + if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; } + return cooked; +}; + +var __setModuleDefault = Object.create ? (function(o, v) { + Object.defineProperty(o, "default", { enumerable: true, value: v }); +}) : function(o, v) { + o["default"] = v; +}; + +function __importStar(mod) { + if (mod && mod.__esModule) return mod; + var result = {}; + if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k); + __setModuleDefault(result, mod); + return result; +} + +function __importDefault(mod) { + return (mod && mod.__esModule) ? mod : { default: mod }; +} + +function __classPrivateFieldGet(receiver, privateMap) { + if (!privateMap.has(receiver)) { + throw new TypeError("attempted to get private field on non-instance"); + } + return privateMap.get(receiver); +} + +function __classPrivateFieldSet(receiver, privateMap, value) { + if (!privateMap.has(receiver)) { + throw new TypeError("attempted to set private field on non-instance"); + } + privateMap.set(receiver, value); + return value; +} + + +/***/ }), + +/***/ 44221: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.SQS = void 0; +const SQSClient_1 = __nccwpck_require__(81509); +const AddPermissionCommand_1 = __nccwpck_require__(26913); +const ChangeMessageVisibilityBatchCommand_1 = __nccwpck_require__(22597); +const ChangeMessageVisibilityCommand_1 = __nccwpck_require__(87760); +const CreateQueueCommand_1 = __nccwpck_require__(11412); +const DeleteMessageBatchCommand_1 = __nccwpck_require__(66794); +const DeleteMessageCommand_1 = __nccwpck_require__(5675); +const DeleteQueueCommand_1 = __nccwpck_require__(29855); +const GetQueueAttributesCommand_1 = __nccwpck_require__(42025); +const GetQueueUrlCommand_1 = __nccwpck_require__(56125); +const ListDeadLetterSourceQueuesCommand_1 = __nccwpck_require__(66167); +const ListQueueTagsCommand_1 = __nccwpck_require__(79354); +const ListQueuesCommand_1 = __nccwpck_require__(41816); +const PurgeQueueCommand_1 = __nccwpck_require__(39702); +const ReceiveMessageCommand_1 = __nccwpck_require__(93954); +const RemovePermissionCommand_1 = __nccwpck_require__(60281); +const SendMessageBatchCommand_1 = __nccwpck_require__(49149); +const SendMessageCommand_1 = __nccwpck_require__(34021); +const SetQueueAttributesCommand_1 = __nccwpck_require__(65618); +const TagQueueCommand_1 = __nccwpck_require__(68409); +const UntagQueueCommand_1 = __nccwpck_require__(79769); +/** + *Welcome to the Amazon Simple Queue Service API Reference.
+ *Amazon Simple Queue Service (Amazon SQS) is a reliable, highly-scalable hosted queue for storing messages as they travel between applications or microservices. Amazon SQS moves data between distributed application components and helps you decouple these components.
+ *For information on the permissions you need to use this API, see + * Identity and + * access management in the Amazon Simple Queue Service Developer Guide. + *
+ *You can use AWS SDKs to access Amazon SQS using your favorite programming language. The SDKs perform tasks such as the following automatically:
+ *Cryptographically sign your service requests
+ *Retry requests
+ *Handle error responses
+ *+ * Additional Information + *
+ *+ * Amazon SQS Product Page + *
+ *+ * Amazon Simple Queue Service Developer Guide + *
+ *+ * Making API Requests + *
+ *+ * Amazon SQS Message Attributes + *
+ *+ * Amazon SQS Dead-Letter Queues + *
+ *+ * Amazon Web Services General Reference + *
+ *+ * Regions and Endpoints + *
+ *Welcome to the Amazon Simple Queue Service API Reference.
+ *Amazon Simple Queue Service (Amazon SQS) is a reliable, highly-scalable hosted queue for storing messages as they travel between applications or microservices. Amazon SQS moves data between distributed application components and helps you decouple these components.
+ *For information on the permissions you need to use this API, see + * Identity and + * access management in the Amazon Simple Queue Service Developer Guide. + *
+ *You can use AWS SDKs to access Amazon SQS using your favorite programming language. The SDKs perform tasks such as the following automatically:
+ *Cryptographically sign your service requests
+ *Retry requests
+ *Handle error responses
+ *+ * Additional Information + *
+ *+ * Amazon SQS Product Page + *
+ *+ * Amazon Simple Queue Service Developer Guide + *
+ *+ * Making API Requests + *
+ *+ * Amazon SQS Message Attributes + *
+ *+ * Amazon SQS Dead-Letter Queues + *
+ *+ * Amazon Web Services General Reference + *
+ *+ * Regions and Endpoints + *
+ *Adds a permission to a queue for a specific + * principal. + * This allows sharing access to the queue.
+ *When you create a queue, you have full control access rights for the queue. + * Only you, the owner of the queue, can grant or deny permissions to the queue. + * For more information about these permissions, see + * Allow + * Developers to Write Messages to a Shared Queue in the Amazon Simple Queue Service Developer Guide.
+ *
+ * AddPermission
generates a policy for you. You can use
+ *
+ * SetQueueAttributes
+ *
to
+ * upload your policy. For more information, see
+ * Using Custom Policies with the Amazon SQS Access Policy Language in
+ * the Amazon Simple Queue Service Developer Guide.
An Amazon SQS policy can have a maximum of 7 actions.
+ *To remove the ability to change queue permissions, you must deny permission to the AddPermission
, RemovePermission
, and SetQueueAttributes
actions in your IAM policy.
Some actions take lists of parameters. These lists are specified using the param.n
notation. Values of n
are integers starting from 1. For example, a parameter list with two elements looks like this:
+ * &AttributeName.1=first
+ *
+ * &AttributeName.2=second
+ *
Cross-account permissions don't apply to this action. For more information, see Grant Cross-Account Permissions to a Role and a User Name in the Amazon Simple Queue Service Developer Guide.
+ *Changes the visibility timeout of multiple messages. This is a batch version of
+ * ChangeMessageVisibility.
The result of the action on each message is reported individually in the response.
+ * You can send up to 10
+ * ChangeMessageVisibility
+ *
requests with each ChangeMessageVisibilityBatch
action.
Because the batch request can result in a combination of successful and unsuccessful actions, you should check for batch errors even when the call returns an HTTP status code of 200
.
Some actions take lists of parameters. These lists are specified using the param.n
notation. Values of n
are integers starting from 1. For example, a parameter list with two elements looks like this:
+ * &AttributeName.1=first
+ *
+ * &AttributeName.2=second
+ *
Changes the visibility timeout of a specified message in a queue to a new value. The + * default visibility timeout for a message is 30 seconds. The minimum is 0 seconds. The + * maximum is 12 hours. For more information, see Visibility Timeout in the Amazon Simple Queue Service Developer Guide.
+ *For example, you have a message with a visibility timeout of 5 minutes. After 3
+ * minutes, you call ChangeMessageVisibility
with a timeout of 10 minutes. You
+ * can continue to call ChangeMessageVisibility
to extend the visibility
+ * timeout to the maximum allowed time. If you try to extend the visibility timeout beyond
+ * the maximum, your request is rejected.
An Amazon SQS message has three basic states:
+ *Sent to a queue by a producer.
+ *Received from the queue by a consumer.
+ *Deleted from the queue.
+ *A message is considered to be stored after it is sent to a queue by a producer, but not yet received from the queue by a consumer (that is, between states 1 and 2). There is no limit to the number of stored messages. + * A message is considered to be in flight after it is received from a queue by a consumer, but not yet deleted from the queue (that is, between states 2 and 3). There is a limit to the number of inflight messages.
+ *Limits that apply to inflight messages are unrelated to the unlimited number of stored messages.
+ *For most standard queues (depending on queue traffic and message backlog), there can be a maximum of approximately 120,000 inflight messages (received from a queue by a consumer, but not yet deleted from the queue).
+ * If you reach this limit, Amazon SQS returns the OverLimit
error message.
+ * To avoid reaching the limit, you should delete messages from the queue after they're processed. You can also increase the number of queues you use to process your messages.
+ * To request a limit increase, file a support request.
For FIFO queues, there can be a maximum of 20,000 inflight messages (received from a queue by a consumer, but not yet deleted from the queue). If you reach this limit, Amazon SQS returns no error messages.
+ * + *If you attempt to set the VisibilityTimeout
to a value greater than the maximum time left, Amazon SQS returns an error. Amazon SQS doesn't automatically recalculate and increase the timeout to the maximum remaining time.
Unlike with a queue, when you change the visibility timeout for a specific message the timeout value is applied immediately but isn't saved in memory for that message. If you don't delete a message after it is received, the visibility timeout
+ * for the message reverts to the original timeout value (not to the value you set using the ChangeMessageVisibility
action) the next time the message is received.
Creates a new standard or FIFO queue. You can pass one or more attributes in + * the request. Keep the following in mind:
+ *If you don't specify the FifoQueue
attribute, Amazon SQS creates a standard queue.
You can't change the queue type after you create it and you can't convert + * an existing standard queue into a FIFO queue. You must either create a new + * FIFO queue for your application or delete your existing standard queue and + * recreate it as a FIFO queue. For more information, see Moving From a Standard Queue to a FIFO Queue in the + * Amazon Simple Queue Service Developer Guide.
+ *If you don't provide a value for an attribute, the queue is created with the default value for the attribute.
+ *If you delete a queue, you must wait at least 60 seconds before creating a queue with the same name.
+ *To successfully create a new queue, you must provide a queue name that adheres to the limits related to queues and is unique within the scope of your queues.
+ *After you create a queue, you must wait at least one second after the queue is + * created to be able to use the queue.
+ *To get the queue URL, use the
+ * GetQueueUrl
+ *
action.
+ * GetQueueUrl
+ *
requires only the QueueName
parameter.
+ * be aware of existing queue names:
If you provide the name of an existing queue along with the exact names and values of all the queue's attributes, CreateQueue
returns the queue URL for the existing queue.
If the queue name, attribute names, or attribute values don't match an existing queue, CreateQueue
returns an error.
Some actions take lists of parameters. These lists are specified using the param.n
notation. Values of n
are integers starting from 1. For example, a parameter list with two elements looks like this:
+ * &AttributeName.1=first
+ *
+ * &AttributeName.2=second
+ *
Cross-account permissions don't apply to this action. For more information, see Grant Cross-Account Permissions to a Role and a User Name in the Amazon Simple Queue Service Developer Guide.
+ *Deletes up to ten messages from the specified queue. This is a batch version of
+ * DeleteMessage.
The result of the action on each message is reported individually in the response.
Because the batch request can result in a combination of successful and unsuccessful actions, you should check for batch errors even when the call returns an HTTP status code of 200
.
Some actions take lists of parameters. These lists are specified using the param.n
notation. Values of n
are integers starting from 1. For example, a parameter list with two elements looks like this:
+ * &AttributeName.1=first
+ *
+ * &AttributeName.2=second
+ *
Deletes the specified message from the specified queue. To select the message to
+ * delete, use the ReceiptHandle
of the message (not the
+ * MessageId
which you receive when you send the message). Amazon SQS can
+ * delete a message from a queue even if a visibility timeout setting causes the message to
+ * be locked by another consumer. Amazon SQS automatically deletes messages left in a queue
+ * longer than the retention period configured for the queue.
The ReceiptHandle
is associated with a specific
+ * instance of receiving a message. If you receive a message more than
+ * once, the ReceiptHandle
is different each time you receive a message.
+ * When you use the DeleteMessage
action, you must provide the most
+ * recently received ReceiptHandle
for the message (otherwise, the request
+ * succeeds, but the message might not be deleted).
For standard queues, it is possible to receive a message even after you + * delete it. This might happen on rare occasions if one of the servers which stores a + * copy of the message is unavailable when you send the request to delete the message. + * The copy remains on the server and might be returned to you during a subsequent + * receive request. You should ensure that your application is idempotent, so that + * receiving a message more than once does not cause issues.
+ *Deletes the queue specified by the QueueUrl
, regardless of the queue's contents.
Be careful with the DeleteQueue
action: When you delete a queue, any messages in the queue are no longer available.
+ *
When you delete a queue, the deletion process takes up to 60 seconds. Requests you send involving that queue during the 60 seconds might succeed. For example, a
+ *
+ * SendMessage
+ *
request might succeed, but after 60 seconds the queue and the message you sent no longer exist.
When you delete a queue, you must wait at least 60 seconds before creating a queue with the same name.
+ *Cross-account permissions don't apply to this action. For more information, see Grant Cross-Account Permissions to a Role and a User Name in the Amazon Simple Queue Service Developer Guide.
+ *Gets attributes for the specified queue.
+ *To determine whether a queue is FIFO, you can check whether QueueName
ends with the .fifo
suffix.
Returns the URL of an existing Amazon SQS queue.
+ *To access a queue that belongs to another AWS account, use the QueueOwnerAWSAccountId
parameter to specify the account ID of the queue's owner. The queue's owner must grant you permission to access the queue.
+ * For more information about shared queue access, see
+ * AddPermission
+ *
or see Allow Developers to Write Messages to a Shared Queue in the Amazon Simple Queue Service Developer Guide.
+ *
Returns a list of your queues that have the RedrivePolicy
queue attribute configured with a dead-letter queue.
The ListDeadLetterSourceQueues
methods supports
+ * pagination. Set parameter MaxResults
in the request to specify the maximum number of
+ * results to be returned in the response. If you do not set MaxResults
,
+ * the response includes a maximum of 1,000 results. If you set MaxResults
and there are additional results to
+ * display, the response includes a value for NextToken
. Use
+ * NextToken
as a parameter in your next request to
+ * ListDeadLetterSourceQueues
to receive the next page of results.
For more information about using dead-letter queues, see Using Amazon SQS Dead-Letter Queues + * in the Amazon Simple Queue Service Developer Guide.
+ */ +class ListDeadLetterSourceQueuesCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "SQSClient"; + const commandName = "ListDeadLetterSourceQueuesCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.ListDeadLetterSourceQueuesRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.ListDeadLetterSourceQueuesResult.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryListDeadLetterSourceQueuesCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryListDeadLetterSourceQueuesCommand(output, context); + } +} +exports.ListDeadLetterSourceQueuesCommand = ListDeadLetterSourceQueuesCommand; +//# sourceMappingURL=ListDeadLetterSourceQueuesCommand.js.map + +/***/ }), + +/***/ 79354: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.ListQueueTagsCommand = void 0; +const models_0_1 = __nccwpck_require__(12183); +const Aws_query_1 = __nccwpck_require__(47377); +const middleware_serde_1 = __nccwpck_require__(86142); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *List all cost allocation tags added to the specified Amazon SQS queue. For an overview, see Tagging Your Amazon SQS Queues in the Amazon Simple Queue Service Developer Guide.
+ *Cross-account permissions don't apply to this action. For more information, see Grant Cross-Account Permissions to a Role and a User Name in the Amazon Simple Queue Service Developer Guide.
+ *Returns a list of your queues in the current region. The response includes a maximum of 1,000 results. If you specify a value for the optional
+ * QueueNamePrefix
parameter, only queues with a name that begins with the specified value are returned.
The listQueues
methods supports
+ * pagination. Set parameter MaxResults
in the request to specify the maximum number of
+ * results to be returned in the response. If you do not set MaxResults
,
+ * the response includes a maximum of 1,000 results. If you set MaxResults
and there are additional results to
+ * display, the response includes a value for NextToken
. Use
+ * NextToken
as a parameter in your next request to
+ * listQueues
to receive the next page of results.
Cross-account permissions don't apply to this action. For more information, see Grant Cross-Account Permissions to a Role and a User Name in the Amazon Simple Queue Service Developer Guide.
+ *Deletes the messages in a queue specified by the QueueURL
+ * parameter.
When you use the PurgeQueue
action, you can't retrieve any messages
+ * deleted from a queue.
The message deletion process takes up to 60 seconds. We recommend waiting for + * 60 seconds regardless of your queue's size.
+ *Messages sent to the queue before you call
+ * PurgeQueue
might be received but are deleted within the next
+ * minute.
Messages sent to the queue after you call
+ * PurgeQueue
might be deleted while the queue is being purged.
Retrieves one or more messages (up to 10), from the specified queue. Using the WaitTimeSeconds
parameter enables long-poll support.
+ * For more information, see Amazon SQS Long Polling in the Amazon Simple Queue Service Developer Guide.
+ *
Short poll is the default behavior where a weighted random set of machines is sampled on a ReceiveMessage
call. Thus, only the messages on the sampled machines are returned.
+ * If the number of messages in the queue is small (fewer than 1,000), you most likely get fewer messages than you requested per ReceiveMessage
call. If the number of messages in the queue is extremely small,
+ * you might not receive any messages in a particular ReceiveMessage
response. If this happens, repeat the request.
+ *
For each message returned, the response includes the following:
+ *The message body.
+ *An MD5 digest of the message body. For information about MD5, see RFC1321.
+ *The MessageId
you received when you sent the message to the queue.
The receipt handle.
+ *The message attributes.
+ *An MD5 digest of the message attributes.
+ *The receipt handle is the identifier you must provide when deleting the message. For more information, see Queue + * and Message Identifiers in the Amazon Simple Queue Service Developer Guide.
+ *You can provide the VisibilityTimeout
parameter in your request. The parameter is applied to the messages that Amazon SQS returns in the response. If you don't include the parameter, the overall visibility timeout for the queue
+ * is used for the returned messages. For more information, see Visibility Timeout in the Amazon Simple Queue Service Developer Guide.
A message that isn't deleted or a message whose visibility isn't extended before the visibility timeout expires counts as a failed receive. Depending on the configuration of the queue, the message might be sent to the dead-letter queue.
+ *In the future, new attributes might be added. If you write code that calls this action, we recommend that you structure your code so that it can handle new attributes gracefully.
+ *Revokes any permissions in the queue policy that matches the specified Label
parameter.
Only the owner of a queue can remove permissions from it.
+ *Cross-account permissions don't apply to this action. For more information, see Grant Cross-Account Permissions to a Role and a User Name in the Amazon Simple Queue Service Developer Guide.
+ *To remove the ability to change queue permissions, you must deny permission to the AddPermission
, RemovePermission
, and SetQueueAttributes
actions in your IAM policy.
Delivers up to ten messages to the specified queue. This is a batch version of
+ * SendMessage.
For a FIFO queue, multiple messages within a single batch are enqueued in the order they are sent.
The result of sending each message is reported individually in the response. Because the batch request can result in a combination of successful and unsuccessful actions, you should check for batch errors even when the call returns an HTTP status code of 200
.
The maximum allowed individual message size and the maximum total payload size (the sum of the individual lengths of all of the batched messages) are both 256 KB (262,144 bytes).
+ *A message can include only XML, JSON, and unformatted text. The following Unicode characters are allowed:
+ *
+ * #x9
| #xA
| #xD
| #x20
to #xD7FF
| #xE000
to #xFFFD
| #x10000
to #x10FFFF
+ *
Any characters not included in this list will be rejected. For more information, see the W3C specification for characters.
+ *If you don't specify the DelaySeconds
parameter for an entry, Amazon SQS uses the default value for the queue.
Some actions take lists of parameters. These lists are specified using the param.n
notation. Values of n
are integers starting from 1. For example, a parameter list with two elements looks like this:
+ * &AttributeName.1=first
+ *
+ * &AttributeName.2=second
+ *
Delivers a message to the specified queue.
+ *A message can include only XML, JSON, and unformatted text. The following Unicode characters are allowed:
+ *
+ * #x9
| #xA
| #xD
| #x20
to #xD7FF
| #xE000
to #xFFFD
| #x10000
to #x10FFFF
+ *
Any characters not included in this list will be rejected. For more information, see the W3C specification for characters.
+ *Sets the value of one or more queue attributes. When you change a queue's attributes, the change can take up to 60 seconds for most of the attributes to propagate throughout the Amazon SQS system.
+ * Changes made to the MessageRetentionPeriod
attribute can take up to 15 minutes.
In the future, new attributes might be added. If you write code that calls this action, we recommend that you structure your code so that it can handle new attributes gracefully.
+ *Cross-account permissions don't apply to this action. For more information, see Grant Cross-Account Permissions to a Role and a User Name in the Amazon Simple Queue Service Developer Guide.
+ *To remove the ability to change queue permissions, you must deny permission to the AddPermission
, RemovePermission
, and SetQueueAttributes
actions in your IAM policy.
Add cost allocation tags to the specified Amazon SQS queue. For an overview, see Tagging Your Amazon SQS Queues in the Amazon Simple Queue Service Developer Guide.
+ * + *When you use queue tags, keep the following guidelines in mind:
+ *Adding more than 50 tags to a queue isn't recommended.
+ *Tags don't have any semantic meaning. Amazon SQS interprets tags as character strings.
+ *Tags are case-sensitive.
+ *A new tag with a key identical to that of an existing tag overwrites the existing tag.
+ *For a full list of tag restrictions, see Limits Related to Queues in the Amazon Simple Queue Service Developer Guide.
+ *Cross-account permissions don't apply to this action. For more information, see Grant Cross-Account Permissions to a Role and a User Name in the Amazon Simple Queue Service Developer Guide.
+ *Remove cost allocation tags from the specified Amazon SQS queue. For an overview, see Tagging Your Amazon SQS Queues in the Amazon Simple Queue Service Developer Guide.
+ *Cross-account permissions don't apply to this action. For more information, see Grant Cross-Account Permissions to a Role and a User Name in the Amazon Simple Queue Service Developer Guide.
+ *AWS Security Token Service (STS) enables you to request temporary, limited-privilege + * credentials for AWS Identity and Access Management (IAM) users or for users that you + * authenticate (federated users). This guide provides descriptions of the STS API. For + * more information about using this service, see Temporary Security Credentials.
+ */ +class STS extends STSClient_1.STSClient { + assumeRole(args, optionsOrCb, cb) { + const command = new AssumeRoleCommand_1.AssumeRoleCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + assumeRoleWithSAML(args, optionsOrCb, cb) { + const command = new AssumeRoleWithSAMLCommand_1.AssumeRoleWithSAMLCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + assumeRoleWithWebIdentity(args, optionsOrCb, cb) { + const command = new AssumeRoleWithWebIdentityCommand_1.AssumeRoleWithWebIdentityCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + decodeAuthorizationMessage(args, optionsOrCb, cb) { + const command = new DecodeAuthorizationMessageCommand_1.DecodeAuthorizationMessageCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getAccessKeyInfo(args, optionsOrCb, cb) { + const command = new GetAccessKeyInfoCommand_1.GetAccessKeyInfoCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getCallerIdentity(args, optionsOrCb, cb) { + const command = new GetCallerIdentityCommand_1.GetCallerIdentityCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getFederationToken(args, optionsOrCb, cb) { + const command = new GetFederationTokenCommand_1.GetFederationTokenCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } + getSessionToken(args, optionsOrCb, cb) { + const command = new GetSessionTokenCommand_1.GetSessionTokenCommand(args); + if (typeof optionsOrCb === "function") { + this.send(command, optionsOrCb); + } + else if (typeof cb === "function") { + if (typeof optionsOrCb !== "object") + throw new Error(`Expect http options but get ${typeof optionsOrCb}`); + this.send(command, optionsOrCb || {}, cb); + } + else { + return this.send(command, optionsOrCb); + } + } +} +exports.STS = STS; +//# sourceMappingURL=STS.js.map + +/***/ }), + +/***/ 22316: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.STSClient = void 0; +const runtimeConfig_1 = __nccwpck_require__(4675); +const config_resolver_1 = __nccwpck_require__(87229); +const middleware_content_length_1 = __nccwpck_require__(69323); +const middleware_host_header_1 = __nccwpck_require__(58645); +const middleware_logger_1 = __nccwpck_require__(98685); +const middleware_retry_1 = __nccwpck_require__(7000); +const middleware_signing_1 = __nccwpck_require__(82487); +const middleware_user_agent_1 = __nccwpck_require__(55976); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *AWS Security Token Service (STS) enables you to request temporary, limited-privilege + * credentials for AWS Identity and Access Management (IAM) users or for users that you + * authenticate (federated users). This guide provides descriptions of the STS API. For + * more information about using this service, see Temporary Security Credentials.
+ */ +class STSClient extends smithy_client_1.Client { + constructor(configuration) { + let _config_0 = { + ...runtimeConfig_1.ClientDefaultValues, + ...configuration, + }; + let _config_1 = config_resolver_1.resolveRegionConfig(_config_0); + let _config_2 = config_resolver_1.resolveEndpointsConfig(_config_1); + let _config_3 = middleware_signing_1.resolveAwsAuthConfig(_config_2); + let _config_4 = middleware_retry_1.resolveRetryConfig(_config_3); + let _config_5 = middleware_host_header_1.resolveHostHeaderConfig(_config_4); + let _config_6 = middleware_user_agent_1.resolveUserAgentConfig(_config_5); + super(_config_6); + this.config = _config_6; + this.middlewareStack.use(middleware_retry_1.getRetryPlugin(this.config)); + this.middlewareStack.use(middleware_content_length_1.getContentLengthPlugin(this.config)); + this.middlewareStack.use(middleware_host_header_1.getHostHeaderPlugin(this.config)); + this.middlewareStack.use(middleware_logger_1.getLoggerPlugin(this.config)); + this.middlewareStack.use(middleware_user_agent_1.getUserAgentPlugin(this.config)); + } + destroy() { + super.destroy(); + } +} +exports.STSClient = STSClient; +//# sourceMappingURL=STSClient.js.map + +/***/ }), + +/***/ 83638: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.AssumeRoleCommand = void 0; +const models_0_1 = __nccwpck_require__(536); +const Aws_query_1 = __nccwpck_require__(6528); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns a set of temporary security credentials that you can use to access AWS
+ * resources that you might not normally have access to. These temporary credentials consist
+ * of an access key ID, a secret access key, and a security token. Typically, you use
+ * AssumeRole
within your account or for cross-account access. For a
+ * comparison of AssumeRole
with other API operations that produce temporary
+ * credentials, see Requesting Temporary Security
+ * Credentials and Comparing the
+ * AWS STS API operations in the IAM User Guide.
You cannot use AWS account root user credentials to call AssumeRole
.
+ * You must use credentials for an IAM user or an IAM role to call
+ * AssumeRole
.
For cross-account access, imagine that you own multiple accounts and need to access + * resources in each account. You could create long-term credentials in each account to access + * those resources. However, managing all those credentials and remembering which one can + * access which account can be time consuming. Instead, you can create one set of long-term + * credentials in one account. Then use temporary security credentials to access all the other + * accounts by assuming roles in those accounts. For more information about roles, see IAM Roles in the + * IAM User Guide.
+ *+ * Session Duration + *
+ *By default, the temporary security credentials created by AssumeRole
last
+ * for one hour. However, you can use the optional DurationSeconds
parameter to
+ * specify the duration of your session. You can provide a value from 900 seconds (15 minutes)
+ * up to the maximum session duration setting for the role. This setting can have a value from
+ * 1 hour to 12 hours. To learn how to view the maximum value for your role, see View the
+ * Maximum Session Duration Setting for a Role in the
+ * IAM User Guide. The maximum session duration limit applies when
+ * you use the AssumeRole*
API operations or the assume-role*
CLI
+ * commands. However the limit does not apply when you use those operations to create a
+ * console URL. For more information, see Using IAM Roles in the
+ * IAM User Guide.
+ * Permissions + *
+ *The temporary security credentials created by AssumeRole
can be used to
+ * make API calls to any AWS service with the following exception: You cannot call the
+ * AWS STS GetFederationToken
or GetSessionToken
API
+ * operations.
(Optional) You can pass inline or managed session policies to + * this operation. You can pass a single JSON policy document to use as an inline session + * policy. You can also specify up to 10 managed policies to use as managed session policies. + * The plain text that you use for both inline and managed session policies can't exceed 2,048 + * characters. Passing policies to this operation returns new + * temporary credentials. The resulting session's permissions are the intersection of the + * role's identity-based policy and the session policies. You can use the role's temporary + * credentials in subsequent AWS API calls to access resources in the account that owns + * the role. You cannot use session policies to grant more permissions than those allowed + * by the identity-based policy of the role that is being assumed. For more information, see + * Session + * Policies in the IAM User Guide.
+ *To assume a role from a different account, your AWS account must be trusted by the + * role. The trust relationship is defined in the role's trust policy when the role is + * created. That trust policy states which accounts are allowed to delegate that access to + * users in the account.
+ *A user who wants to access a role in a different account must also have permissions that
+ * are delegated from the user account administrator. The administrator must attach a policy
+ * that allows the user to call AssumeRole
for the ARN of the role in the other
+ * account. If the user is in the same account as the role, then you can do either of the
+ * following:
Attach a policy to the user (identical to the previous user in a different + * account).
+ *Add the user as a principal directly in the role's trust policy.
+ *In this case, the trust policy acts as an IAM resource-based policy. Users in the same + * account as the role do not need explicit permission to assume the role. For more + * information about trust policies and resource-based policies, see IAM Policies in + * the IAM User Guide.
+ *+ * Tags + *
+ *(Optional) You can pass tag key-value pairs to your session. These tags are called + * session tags. For more information about session tags, see Passing Session Tags in STS in the + * IAM User Guide.
+ *An administrator must grant you the permissions necessary to pass session tags. The + * administrator can also create granular permissions to allow you to pass only specific + * session tags. For more information, see Tutorial: Using Tags + * for Attribute-Based Access Control in the + * IAM User Guide.
+ *You can set the session tags as transitive. Transitive tags persist during role + * chaining. For more information, see Chaining Roles + * with Session Tags in the IAM User Guide.
+ *+ * Using MFA with AssumeRole + *
+ *(Optional) You can include multi-factor authentication (MFA) information when you call
+ * AssumeRole
. This is useful for cross-account scenarios to ensure that the
+ * user that assumes the role has been authenticated with an AWS MFA device. In that
+ * scenario, the trust policy of the role being assumed includes a condition that tests for
+ * MFA authentication. If the caller does not include valid MFA information, the request to
+ * assume the role is denied. The condition in a trust policy that tests for MFA
+ * authentication might look like the following example.
+ * "Condition": {"Bool": {"aws:MultiFactorAuthPresent": true}}
+ *
For more information, see Configuring MFA-Protected API Access + * in the IAM User Guide guide.
+ *To use MFA with AssumeRole
, you pass values for the
+ * SerialNumber
and TokenCode
parameters. The
+ * SerialNumber
value identifies the user's hardware or virtual MFA device.
+ * The TokenCode
is the time-based one-time password (TOTP) that the MFA device
+ * produces.
Returns a set of temporary security credentials for users who have been authenticated
+ * via a SAML authentication response. This operation provides a mechanism for tying an
+ * enterprise identity store or directory to role-based AWS access without user-specific
+ * credentials or configuration. For a comparison of AssumeRoleWithSAML
with the
+ * other API operations that produce temporary credentials, see Requesting Temporary Security
+ * Credentials and Comparing the
+ * AWS STS API operations in the IAM User Guide.
The temporary security credentials returned by this operation consist of an access key + * ID, a secret access key, and a security token. Applications can use these temporary + * security credentials to sign calls to AWS services.
+ *+ * Session Duration + *
+ *By default, the temporary security credentials created by
+ * AssumeRoleWithSAML
last for one hour. However, you can use the optional
+ * DurationSeconds
parameter to specify the duration of your session. Your
+ * role session lasts for the duration that you specify, or until the time specified in the
+ * SAML authentication response's SessionNotOnOrAfter
value, whichever is
+ * shorter. You can provide a DurationSeconds
value from 900 seconds (15 minutes)
+ * up to the maximum session duration setting for the role. This setting can have a value from
+ * 1 hour to 12 hours. To learn how to view the maximum value for your role, see View the
+ * Maximum Session Duration Setting for a Role in the
+ * IAM User Guide. The maximum session duration limit applies when
+ * you use the AssumeRole*
API operations or the assume-role*
CLI
+ * commands. However the limit does not apply when you use those operations to create a
+ * console URL. For more information, see Using IAM Roles in the
+ * IAM User Guide.
+ * Permissions + *
+ *The temporary security credentials created by AssumeRoleWithSAML
can be
+ * used to make API calls to any AWS service with the following exception: you cannot call
+ * the STS GetFederationToken
or GetSessionToken
API
+ * operations.
(Optional) You can pass inline or managed session policies to + * this operation. You can pass a single JSON policy document to use as an inline session + * policy. You can also specify up to 10 managed policies to use as managed session policies. + * The plain text that you use for both inline and managed session policies can't exceed 2,048 + * characters. Passing policies to this operation returns new + * temporary credentials. The resulting session's permissions are the intersection of the + * role's identity-based policy and the session policies. You can use the role's temporary + * credentials in subsequent AWS API calls to access resources in the account that owns + * the role. You cannot use session policies to grant more permissions than those allowed + * by the identity-based policy of the role that is being assumed. For more information, see + * Session + * Policies in the IAM User Guide.
+ *Calling AssumeRoleWithSAML
does not require the use of AWS security
+ * credentials. The identity of the caller is validated by using keys in the metadata document
+ * that is uploaded for the SAML provider entity for your identity provider.
Calling AssumeRoleWithSAML
can result in an entry in your AWS CloudTrail logs.
+ * The entry includes the value in the NameID
element of the SAML assertion.
+ * We recommend that you use a NameIDType
that is not associated with any
+ * personally identifiable information (PII). For example, you could instead use the
+ * persistent identifier
+ * (urn:oasis:names:tc:SAML:2.0:nameid-format:persistent
).
+ * Tags + *
+ *(Optional) You can configure your IdP to pass attributes into your SAML assertion as + * session tags. Each session tag consists of a key name and an associated value. For more + * information about session tags, see Passing Session Tags in STS in the + * IAM User Guide.
+ *You can pass up to 50 session tags. The plain text session tag keys can’t exceed 128 + * characters and the values can’t exceed 256 characters. For these and additional limits, see + * IAM + * and STS Character Limits in the IAM User Guide.
+ * + *An AWS conversion compresses the passed session policies and session tags into a
+ * packed binary format that has a separate limit. Your request can fail for this limit
+ * even if your plain text meets the other requirements. The PackedPolicySize
+ * response element indicates by percentage how close the policies and tags for your
+ * request are to the upper size limit.
+ *
You can pass a session tag with the same key as a tag that is attached to the role. When + * you do, session tags override the role's tags with the same key.
+ *An administrator must grant you the permissions necessary to pass session tags. The + * administrator can also create granular permissions to allow you to pass only specific + * session tags. For more information, see Tutorial: Using Tags + * for Attribute-Based Access Control in the + * IAM User Guide.
+ *You can set the session tags as transitive. Transitive tags persist during role + * chaining. For more information, see Chaining Roles + * with Session Tags in the IAM User Guide.
+ *+ * SAML Configuration + *
+ *Before your application can call AssumeRoleWithSAML
, you must configure
+ * your SAML identity provider (IdP) to issue the claims required by AWS. Additionally, you
+ * must use AWS Identity and Access Management (IAM) to create a SAML provider entity in your AWS account that
+ * represents your identity provider. You must also create an IAM role that specifies this
+ * SAML provider in its trust policy.
For more information, see the following resources:
+ *+ * About + * SAML 2.0-based Federation in the IAM User Guide. + *
+ *+ * Creating SAML Identity Providers in the + * IAM User Guide.
+ *+ * Configuring + * a Relying Party and Claims in the IAM User Guide. + *
+ *+ * Creating a Role for SAML 2.0 Federation in the + * IAM User Guide.
+ *Returns a set of temporary security credentials for users who have been authenticated in + * a mobile or web application with a web identity provider. Example providers include Amazon Cognito, + * Login with Amazon, Facebook, Google, or any OpenID Connect-compatible identity + * provider.
+ *For mobile applications, we recommend that you use Amazon Cognito. You can use Amazon Cognito with the + * AWS SDK for iOS Developer Guide and the AWS SDK for Android Developer Guide to uniquely + * identify a user. You can also supply the user with a consistent identity throughout the + * lifetime of an application.
+ *To learn more about Amazon Cognito, see Amazon Cognito Overview in + * AWS SDK for Android Developer Guide and Amazon Cognito Overview in the + * AWS SDK for iOS Developer Guide.
+ *Calling AssumeRoleWithWebIdentity
does not require the use of AWS
+ * security credentials. Therefore, you can distribute an application (for example, on mobile
+ * devices) that requests temporary security credentials without including long-term AWS
+ * credentials in the application. You also don't need to deploy server-based proxy services
+ * that use long-term AWS credentials. Instead, the identity of the caller is validated by
+ * using a token from the web identity provider. For a comparison of
+ * AssumeRoleWithWebIdentity
with the other API operations that produce
+ * temporary credentials, see Requesting Temporary Security
+ * Credentials and Comparing the
+ * AWS STS API operations in the IAM User Guide.
The temporary security credentials returned by this API consist of an access key ID, a + * secret access key, and a security token. Applications can use these temporary security + * credentials to sign calls to AWS service API operations.
+ *+ * Session Duration + *
+ *By default, the temporary security credentials created by
+ * AssumeRoleWithWebIdentity
last for one hour. However, you can use the
+ * optional DurationSeconds
parameter to specify the duration of your session.
+ * You can provide a value from 900 seconds (15 minutes) up to the maximum session duration
+ * setting for the role. This setting can have a value from 1 hour to 12 hours. To learn how
+ * to view the maximum value for your role, see View the
+ * Maximum Session Duration Setting for a Role in the
+ * IAM User Guide. The maximum session duration limit applies when
+ * you use the AssumeRole*
API operations or the assume-role*
CLI
+ * commands. However the limit does not apply when you use those operations to create a
+ * console URL. For more information, see Using IAM Roles in the
+ * IAM User Guide.
+ * Permissions + *
+ *The temporary security credentials created by AssumeRoleWithWebIdentity
can
+ * be used to make API calls to any AWS service with the following exception: you cannot
+ * call the STS GetFederationToken
or GetSessionToken
API
+ * operations.
(Optional) You can pass inline or managed session policies to + * this operation. You can pass a single JSON policy document to use as an inline session + * policy. You can also specify up to 10 managed policies to use as managed session policies. + * The plain text that you use for both inline and managed session policies can't exceed 2,048 + * characters. Passing policies to this operation returns new + * temporary credentials. The resulting session's permissions are the intersection of the + * role's identity-based policy and the session policies. You can use the role's temporary + * credentials in subsequent AWS API calls to access resources in the account that owns + * the role. You cannot use session policies to grant more permissions than those allowed + * by the identity-based policy of the role that is being assumed. For more information, see + * Session + * Policies in the IAM User Guide.
+ *+ * Tags + *
+ *(Optional) You can configure your IdP to pass attributes into your web identity token as + * session tags. Each session tag consists of a key name and an associated value. For more + * information about session tags, see Passing Session Tags in STS in the + * IAM User Guide.
+ *You can pass up to 50 session tags. The plain text session tag keys can’t exceed 128 + * characters and the values can’t exceed 256 characters. For these and additional limits, see + * IAM + * and STS Character Limits in the IAM User Guide.
+ * + *An AWS conversion compresses the passed session policies and session tags into a
+ * packed binary format that has a separate limit. Your request can fail for this limit
+ * even if your plain text meets the other requirements. The PackedPolicySize
+ * response element indicates by percentage how close the policies and tags for your
+ * request are to the upper size limit.
+ *
You can pass a session tag with the same key as a tag that is attached to the role. When + * you do, the session tag overrides the role tag with the same key.
+ *An administrator must grant you the permissions necessary to pass session tags. The + * administrator can also create granular permissions to allow you to pass only specific + * session tags. For more information, see Tutorial: Using Tags + * for Attribute-Based Access Control in the + * IAM User Guide.
+ *You can set the session tags as transitive. Transitive tags persist during role + * chaining. For more information, see Chaining Roles + * with Session Tags in the IAM User Guide.
+ *+ * Identities + *
+ *Before your application can call AssumeRoleWithWebIdentity
, you must have
+ * an identity token from a supported identity provider and create a role that the application
+ * can assume. The role that your application assumes must trust the identity provider that is
+ * associated with the identity token. In other words, the identity provider must be specified
+ * in the role's trust policy.
Calling AssumeRoleWithWebIdentity
can result in an entry in your
+ * AWS CloudTrail logs. The entry includes the Subject of
+ * the provided Web Identity Token. We recommend that you avoid using any personally
+ * identifiable information (PII) in this field. For example, you could instead use a GUID
+ * or a pairwise identifier, as suggested
+ * in the OIDC specification.
For more information about how to use web identity federation and the
+ * AssumeRoleWithWebIdentity
API, see the following resources:
+ * Using Web Identity Federation API Operations for Mobile Apps and Federation Through a Web-based Identity Provider.
+ *+ * + * Web Identity Federation Playground. Walk through the process of + * authenticating through Login with Amazon, Facebook, or Google, getting temporary + * security credentials, and then using those credentials to make a request to AWS. + *
+ *+ * AWS SDK for iOS Developer Guide and AWS SDK for Android Developer Guide. These toolkits + * contain sample apps that show how to invoke the identity providers. The toolkits then + * show how to use the information from these providers to get and use temporary + * security credentials.
+ *+ * Web Identity + * Federation with Mobile Applications. This article discusses web identity + * federation and shows an example of how to use web identity federation to get access + * to content in Amazon S3.
+ *Decodes additional information about the authorization status of a request from an + * encoded message returned in response to an AWS request.
+ *For example, if a user is not authorized to perform an operation that he or she has
+ * requested, the request returns a Client.UnauthorizedOperation
response (an
+ * HTTP 403 response). Some AWS operations additionally return an encoded message that can
+ * provide details about this authorization failure.
Only certain AWS operations return an encoded authorization message. The + * documentation for an individual operation indicates whether that operation returns an + * encoded message in addition to returning an HTTP code.
+ *The message is encoded because the details of the authorization status can constitute
+ * privileged information that the user who requested the operation should not see. To decode
+ * an authorization status message, a user must be granted permissions via an IAM policy to
+ * request the DecodeAuthorizationMessage
+ * (sts:DecodeAuthorizationMessage
) action.
The decoded message includes the following type of information:
+ *Whether the request was denied due to an explicit deny or due to the absence of an + * explicit allow. For more information, see Determining Whether a Request is Allowed or Denied in the + * IAM User Guide.
+ *The principal who made the request.
+ *The requested action.
+ *The requested resource.
+ *The values of condition keys in the context of the user's request.
+ *Returns the account identifier for the specified access key ID.
+ *Access keys consist of two parts: an access key ID (for example,
+ * AKIAIOSFODNN7EXAMPLE
) and a secret access key (for example,
+ * wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
). For more information about
+ * access keys, see Managing Access Keys for IAM
+ * Users in the IAM User Guide.
When you pass an access key ID to this operation, it returns the ID of the AWS account
+ * to which the keys belong. Access key IDs beginning with AKIA
are long-term
+ * credentials for an IAM user or the AWS account root user. Access key IDs beginning with
+ * ASIA
are temporary credentials that are created using STS operations. If
+ * the account in the response belongs to you, you can sign in as the root user and review
+ * your root user access keys. Then, you can pull a credentials report to
+ * learn which IAM user owns the keys. To learn who requested the temporary credentials for
+ * an ASIA
access key, view the STS events in your CloudTrail logs in the
+ * IAM User Guide.
This operation does not indicate the state of the access key. The key might be active, + * inactive, or deleted. Active keys might not have permissions to perform an operation. + * Providing a deleted access key might return an error that the key doesn't exist.
+ */ +class GetAccessKeyInfoCommand extends smithy_client_1.Command { + // Start section: command_properties + // End section: command_properties + constructor(input) { + // Start section: command_constructor + super(); + this.input = input; + this.resolved = false; + // End section: command_constructor + } + /** + * @internal + */ + resolveMiddleware(clientStack, configuration, options) { + if (!this.resolved) { + this.middlewareStack.use(middleware_serde_1.getSerdePlugin(configuration, this.serialize, this.deserialize)); + this.middlewareStack.use(middleware_signing_1.getAwsAuthPlugin(configuration)); + this.resolved = true; + } + const stack = clientStack.concat(this.middlewareStack); + const { logger } = configuration; + const clientName = "STSClient"; + const commandName = "GetAccessKeyInfoCommand"; + const handlerExecutionContext = { + logger, + clientName, + commandName, + inputFilterSensitiveLog: models_0_1.GetAccessKeyInfoRequest.filterSensitiveLog, + outputFilterSensitiveLog: models_0_1.GetAccessKeyInfoResponse.filterSensitiveLog, + }; + const { requestHandler } = configuration; + return stack.resolve((request) => requestHandler.handle(request.request, options || {}), handlerExecutionContext); + } + serialize(input, context) { + return Aws_query_1.serializeAws_queryGetAccessKeyInfoCommand(input, context); + } + deserialize(output, context) { + return Aws_query_1.deserializeAws_queryGetAccessKeyInfoCommand(output, context); + } +} +exports.GetAccessKeyInfoCommand = GetAccessKeyInfoCommand; +//# sourceMappingURL=GetAccessKeyInfoCommand.js.map + +/***/ }), + +/***/ 47515: +/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => { + +"use strict"; + +Object.defineProperty(exports, "__esModule", ({ value: true })); +exports.GetCallerIdentityCommand = void 0; +const models_0_1 = __nccwpck_require__(536); +const Aws_query_1 = __nccwpck_require__(6528); +const middleware_serde_1 = __nccwpck_require__(86142); +const middleware_signing_1 = __nccwpck_require__(82487); +const smithy_client_1 = __nccwpck_require__(84060); +/** + *Returns details about the IAM user or role whose credentials are used to call the + * operation.
+ *No permissions are required to perform this operation. If an administrator adds a
+ * policy to your IAM user or role that explicitly denies access to the
+ * sts:GetCallerIdentity
action, you can still perform this operation.
+ * Permissions are not required because the same information is returned when an IAM user
+ * or role is denied access. To view an example response, see I Am Not Authorized to Perform: iam:DeleteVirtualMFADevice in the
+ * IAM User Guide.
Returns a set of temporary security credentials (consisting of an access key ID, a
+ * secret access key, and a security token) for a federated user. A typical use is in a proxy
+ * application that gets temporary security credentials on behalf of distributed applications
+ * inside a corporate network. You must call the GetFederationToken
operation
+ * using the long-term security credentials of an IAM user. As a result, this call is
+ * appropriate in contexts where those credentials can be safely stored, usually in a
+ * server-based application. For a comparison of GetFederationToken
with the
+ * other API operations that produce temporary credentials, see Requesting Temporary Security
+ * Credentials and Comparing the
+ * AWS STS API operations in the IAM User Guide.
You can create a mobile-based or browser-based app that can authenticate users using
+ * a web identity provider like Login with Amazon, Facebook, Google, or an OpenID
+ * Connect-compatible identity provider. In this case, we recommend that you use Amazon Cognito or
+ * AssumeRoleWithWebIdentity
. For more information, see Federation Through a Web-based Identity Provider in the
+ * IAM User Guide.
You can also call GetFederationToken
using the security credentials of an
+ * AWS account root user, but we do not recommend it. Instead, we recommend that you create
+ * an IAM user for the purpose of the proxy application. Then attach a policy to the IAM
+ * user that limits federated users to only the actions and resources that they need to
+ * access. For more information, see IAM Best Practices in the
+ * IAM User Guide.
+ * Session duration + *
+ *The temporary credentials are valid for the specified duration, from 900 seconds (15 + * minutes) up to a maximum of 129,600 seconds (36 hours). The default session duration is + * 43,200 seconds (12 hours). Temporary credentials that are obtained by using AWS account + * root user credentials have a maximum duration of 3,600 seconds (1 hour).
+ *+ * Permissions + *
+ *You can use the temporary credentials created by GetFederationToken
in any
+ * AWS service except the following:
You cannot call any IAM operations using the AWS CLI or the AWS API.
+ *You cannot call any STS operations except GetCallerIdentity
.
You must pass an inline or managed session policy to + * this operation. You can pass a single JSON policy document to use as an inline session + * policy. You can also specify up to 10 managed policies to use as managed session policies. + * The plain text that you use for both inline and managed session policies can't exceed 2,048 + * characters.
+ *Though the session policy parameters are optional, if you do not pass a policy, then the
+ * resulting federated user session has no permissions. When you pass session policies, the
+ * session permissions are the intersection of the IAM user policies and the session
+ * policies that you pass. This gives you a way to further restrict the permissions for a
+ * federated user. You cannot use session policies to grant more permissions than those that
+ * are defined in the permissions policy of the IAM user. For more information, see Session
+ * Policies in the IAM User Guide. For information about
+ * using GetFederationToken
to create temporary security credentials, see GetFederationToken—Federation Through a Custom Identity Broker.
You can use the credentials to access a resource that has a resource-based policy. If
+ * that policy specifically references the federated user session in the
+ * Principal
element of the policy, the session has the permissions allowed by
+ * the policy. These permissions are granted in addition to the permissions granted by the
+ * session policies.
+ * Tags + *
+ *(Optional) You can pass tag key-value pairs to your session. These are called session + * tags. For more information about session tags, see Passing Session Tags in STS in the + * IAM User Guide.
+ *An administrator must grant you the permissions necessary to pass session tags. The + * administrator can also create granular permissions to allow you to pass only specific + * session tags. For more information, see Tutorial: Using Tags + * for Attribute-Based Access Control in the + * IAM User Guide.
+ *Tag key–value pairs are not case sensitive, but case is preserved. This means that you
+ * cannot have separate Department
and department
tag keys. Assume
+ * that the user that you are federating has the
+ * Department
=Marketing
tag and you pass the
+ * department
=engineering
session tag. Department
+ * and department
are not saved as separate tags, and the session tag passed in
+ * the request takes precedence over the user tag.
Returns a set of temporary credentials for an AWS account or IAM user. The
+ * credentials consist of an access key ID, a secret access key, and a security token.
+ * Typically, you use GetSessionToken
if you want to use MFA to protect
+ * programmatic calls to specific AWS API operations like Amazon EC2 StopInstances
.
+ * MFA-enabled IAM users would need to call GetSessionToken
and submit an MFA
+ * code that is associated with their MFA device. Using the temporary security credentials
+ * that are returned from the call, IAM users can then make programmatic calls to API
+ * operations that require MFA authentication. If you do not supply a correct MFA code, then
+ * the API returns an access denied error. For a comparison of GetSessionToken
+ * with the other API operations that produce temporary credentials, see Requesting
+ * Temporary Security Credentials and Comparing the
+ * AWS STS API operations in the IAM User Guide.
+ * Session Duration + *
+ *The GetSessionToken
operation must be called by using the long-term AWS
+ * security credentials of the AWS account root user or an IAM user. Credentials that are
+ * created by IAM users are valid for the duration that you specify. This duration can range
+ * from 900 seconds (15 minutes) up to a maximum of 129,600 seconds (36 hours), with a default
+ * of 43,200 seconds (12 hours). Credentials based on account credentials can range from 900
+ * seconds (15 minutes) up to 3,600 seconds (1 hour), with a default of 1 hour.
+ * Permissions + *
+ *The temporary security credentials created by GetSessionToken
can be used
+ * to make API calls to any AWS service with the following exceptions:
You cannot call any IAM API operations unless MFA authentication information is + * included in the request.
+ *You cannot call any STS API except
+ * AssumeRole
or GetCallerIdentity
.
We recommend that you do not call GetSessionToken
with AWS account
+ * root user credentials. Instead, follow our best practices by
+ * creating one or more IAM users, giving them the necessary permissions, and using IAM
+ * users for everyday interaction with AWS.
The credentials that are returned by GetSessionToken
are based on
+ * permissions associated with the user whose credentials were used to call the operation. If
+ * GetSessionToken
is called using AWS account root user credentials, the
+ * temporary credentials have root user permissions. Similarly, if
+ * GetSessionToken
is called using the credentials of an IAM user, the
+ * temporary credentials have the same permissions as the IAM user.
For more information about using GetSessionToken
to create temporary
+ * credentials, go to Temporary
+ * Credentials for Users in Untrusted Environments in the
+ * IAM User Guide.