diff --git a/.changelog/04148efd92e7492ab9408dee22dedad7.json b/.changelog/04148efd92e7492ab9408dee22dedad7.json new file mode 100644 index 00000000000..ede084bb5d6 --- /dev/null +++ b/.changelog/04148efd92e7492ab9408dee22dedad7.json @@ -0,0 +1,44 @@ +{ + "id": "04148efd-92e7-492a-b940-8dee22dedad7", + "type": "feature", + "description": "Fixed a bug in the API client generation which caused some operation parameters to be incorrectly generated as value types instead of pointer types. The service API always required these affected parameters to be nilable. This fixes the SDK client to match the expectations of the the service API.", + "modules": [ + "service/acmpca", + "service/appconfig", + "service/appflow", + "service/appmesh", + "service/codestar", + "service/codestarnotifications", + "service/cognitoidentity", + "service/cognitoidentityprovider", + "service/configservice", + "service/connect", + "service/connectparticipant", + "service/costexplorer", + "service/customerprofiles", + "service/emrserverless", + "service/evidently", + "service/finspacedata", + "service/fis", + "service/glue", + "service/greengrassv2", + "service/imagebuilder", + "service/iot", + "service/iotanalytics", + "service/iotsecuretunneling", + "service/lookoutmetrics", + "service/m2", + "service/networkfirewall", + "service/pricing", + "service/quicksight", + "service/route53recoverycluster", + "service/s3control", + "service/sagemaker", + "service/sagemakera2iruntime", + "service/secretsmanager", + "service/servicecatalogappregistry", + "service/sfn", + "service/ssm", + "service/timestreamwrite" + ] +} \ No newline at end of file diff --git a/.changelog/0d9437c74cdc43ffae4286a06abdb9a2.json b/.changelog/0d9437c74cdc43ffae4286a06abdb9a2.json new file mode 100644 index 00000000000..6045dd02fdf --- /dev/null +++ b/.changelog/0d9437c74cdc43ffae4286a06abdb9a2.json @@ -0,0 +1,8 @@ +{ + "id": "0d9437c7-4cdc-43ff-ae42-86a06abdb9a2", + "type": "feature", + "description": "SageMaker Hosting now allows customization on ML instance storage volume size, model data download timeout and inference container startup ping health check timeout for each ProductionVariant in CreateEndpointConfig API.", + "modules": [ + "service/sagemaker" + ] +} \ No newline at end of file diff --git a/.changelog/139ac133dc9a4cd999f6f1a5728351e6.json b/.changelog/139ac133dc9a4cd999f6f1a5728351e6.json new file mode 100644 index 00000000000..a5d8e339347 --- /dev/null +++ b/.changelog/139ac133dc9a4cd999f6f1a5728351e6.json @@ -0,0 +1,8 @@ +{ + "id": "139ac133-dc9a-4cd9-99f6-f1a5728351e6", + "type": "feature", + "description": "Two new features for local gateway route tables: support for static routes targeting Elastic Network Interfaces and direct VPC routing.", + "modules": [ + "service/ec2" + ] +} \ No newline at end of file diff --git a/.changelog/168813f4fc2c40c086080f6ca037c2f2.json b/.changelog/168813f4fc2c40c086080f6ca037c2f2.json new file mode 100644 index 00000000000..7c39202176e --- /dev/null +++ b/.changelog/168813f4fc2c40c086080f6ca037c2f2.json @@ -0,0 +1,8 @@ +{ + "id": "168813f4-fc2c-40c0-8608-0f6ca037c2f2", + "type": "feature", + "description": "This release is for supporting Composite Slot Type feature in AWS Lex V2. Composite Slot Type will help developer to logically group coherent slots and maintain their inter-relationships in runtime conversation.", + "modules": [ + "service/lexmodelsv2" + ] +} \ No newline at end of file diff --git a/.changelog/1a1d88951c5744dc92c7b01800ee15b1.json b/.changelog/1a1d88951c5744dc92c7b01800ee15b1.json new file mode 100644 index 00000000000..1aeadda45df --- /dev/null +++ b/.changelog/1a1d88951c5744dc92c7b01800ee15b1.json @@ -0,0 +1,8 @@ +{ + "id": "1a1d8895-1c57-44dc-92c7-b01800ee15b1", + "type": "feature", + "description": "Adding support for local Amazon EKS clusters on Outposts", + "modules": [ + "service/eks" + ] +} \ No newline at end of file diff --git a/.changelog/1a290adcbd9740febb89d6a4c0f3ddef.json b/.changelog/1a290adcbd9740febb89d6a4c0f3ddef.json new file mode 100644 index 00000000000..162612f1cf4 --- /dev/null +++ b/.changelog/1a290adcbd9740febb89d6a4c0f3ddef.json @@ -0,0 +1,8 @@ +{ + "id": "1a290adc-bd97-40fe-bb89-d6a4c0f3ddef", + "type": "feature", + "description": "Amazon Route 53 now supports the Middle East (UAE) Region (me-central-1) for latency records, geoproximity records, and private DNS for Amazon VPCs in that region.", + "modules": [ + "service/route53" + ] +} \ No newline at end of file diff --git a/.changelog/31745245924d4f1a9e617fda3d4554e1.json b/.changelog/31745245924d4f1a9e617fda3d4554e1.json new file mode 100644 index 00000000000..eadaf3d31ff --- /dev/null +++ b/.changelog/31745245924d4f1a9e617fda3d4554e1.json @@ -0,0 +1,8 @@ +{ + "id": "31745245-924d-4f1a-9e61-7fda3d4554e1", + "type": "documentation", + "description": "Documentation update for Amazon FSx.", + "modules": [ + "service/fsx" + ] +} \ No newline at end of file diff --git a/.changelog/5f3e5c705eba45f7992c12162bcb7398.json b/.changelog/5f3e5c705eba45f7992c12162bcb7398.json new file mode 100644 index 00000000000..c2572785217 --- /dev/null +++ b/.changelog/5f3e5c705eba45f7992c12162bcb7398.json @@ -0,0 +1,8 @@ +{ + "id": "5f3e5c70-5eba-45f7-992c-12162bcb7398", + "type": "feature", + "description": "This release adds HyperParameterTuningJob type in Search API.", + "modules": [ + "service/sagemaker" + ] +} \ No newline at end of file diff --git a/.changelog/684378e98e4d4813815fcb3bca441487.json b/.changelog/684378e98e4d4813815fcb3bca441487.json new file mode 100644 index 00000000000..c198bd83c48 --- /dev/null +++ b/.changelog/684378e98e4d4813815fcb3bca441487.json @@ -0,0 +1,8 @@ +{ + "id": "684378e9-8e4d-4813-815f-cb3bca441487", + "type": "documentation", + "description": "Documentation updates for the Identity Store CLI Reference.", + "modules": [ + "service/identitystore" + ] +} \ No newline at end of file diff --git a/.changelog/723b50ca0d434294a520ded75c868f78.json b/.changelog/723b50ca0d434294a520ded75c868f78.json new file mode 100644 index 00000000000..70d8c53c148 --- /dev/null +++ b/.changelog/723b50ca0d434294a520ded75c868f78.json @@ -0,0 +1,8 @@ +{ + "id": "723b50ca-0d43-4294-a520-ded75c868f78", + "type": "feature", + "description": "Adds support for EKS Addons ResolveConflicts \"preserve\" flag. Also adds new update failed status for EKS Addons.", + "modules": [ + "service/eks" + ] +} \ No newline at end of file diff --git a/.changelog/7b24c1767dc14ce6b1e379112f89b42b.json b/.changelog/7b24c1767dc14ce6b1e379112f89b42b.json new file mode 100644 index 00000000000..b8c29ca0169 --- /dev/null +++ b/.changelog/7b24c1767dc14ce6b1e379112f89b42b.json @@ -0,0 +1,8 @@ +{ + "id": "7b24c176-7dc1-4ce6-b1e3-79112f89b42b", + "type": "feature", + "description": "This release adds Mode to AutoMLJobConfig.", + "modules": [ + "service/sagemaker" + ] +} \ No newline at end of file diff --git a/.changelog/7e20ccc8023f43869884f0423faf96b1.json b/.changelog/7e20ccc8023f43869884f0423faf96b1.json new file mode 100644 index 00000000000..464e5a2789a --- /dev/null +++ b/.changelog/7e20ccc8023f43869884f0423faf96b1.json @@ -0,0 +1,8 @@ +{ + "id": "7e20ccc8-023f-4386-9884-f0423faf96b1", + "type": "feature", + "description": "Allow specifying units in Asset Properties", + "modules": [ + "service/iotsitewise" + ] +} \ No newline at end of file diff --git a/.changelog/7f43a8eb67e74f07a20df11c7c849b05.json b/.changelog/7f43a8eb67e74f07a20df11c7c849b05.json new file mode 100644 index 00000000000..46ebc40a0a7 --- /dev/null +++ b/.changelog/7f43a8eb67e74f07a20df11c7c849b05.json @@ -0,0 +1,8 @@ +{ + "id": "7f43a8eb-67e7-4f07-a20d-f11c7c849b05", + "type": "feature", + "description": "This release is for supporting Composite Slot Type feature in AWS Lex V2. Composite Slot Type will help developer to logically group coherent slots and maintain their inter-relationships in runtime conversation.", + "modules": [ + "service/lexruntimev2" + ] +} \ No newline at end of file diff --git a/.changelog/7f53bac34fa54ac596a7809b3bf1e23a.json b/.changelog/7f53bac34fa54ac596a7809b3bf1e23a.json new file mode 100644 index 00000000000..f269b728c25 --- /dev/null +++ b/.changelog/7f53bac34fa54ac596a7809b3bf1e23a.json @@ -0,0 +1,8 @@ +{ + "id": "7f53bac3-4fa5-4ac5-96a7-809b3bf1e23a", + "type": "feature", + "description": "EMR on EKS now allows running Spark SQL using the newly introduced Spark SQL Job Driver in the Start Job Run API", + "modules": [ + "service/emrcontainers" + ] +} \ No newline at end of file diff --git a/.changelog/88086a9fc60d49ccb435c2240d8badaa.json b/.changelog/88086a9fc60d49ccb435c2240d8badaa.json new file mode 100644 index 00000000000..b29e43f5edf --- /dev/null +++ b/.changelog/88086a9fc60d49ccb435c2240d8badaa.json @@ -0,0 +1,8 @@ +{ + "id": "88086a9f-c60d-49cc-b435-c2240d8badaa", + "type": "feature", + "description": "This release adds support to send VPC Flow Logs to kinesis-data-firehose as new destination type", + "modules": [ + "service/ec2" + ] +} \ No newline at end of file diff --git a/.changelog/9454b9064521472c8fb124df145c0204.json b/.changelog/9454b9064521472c8fb124df145c0204.json new file mode 100644 index 00000000000..d17070d8d8b --- /dev/null +++ b/.changelog/9454b9064521472c8fb124df145c0204.json @@ -0,0 +1,8 @@ +{ + "id": "9454b906-4521-472c-8fb1-24df145c0204", + "type": "feature", + "description": "Added isUnstructured in response for Customer Profiles Integration APIs", + "modules": [ + "service/customerprofiles" + ] +} \ No newline at end of file diff --git a/.changelog/95a2c4ac39924f7ba0313f6872aabbce.json b/.changelog/95a2c4ac39924f7ba0313f6872aabbce.json new file mode 100644 index 00000000000..2a741352058 --- /dev/null +++ b/.changelog/95a2c4ac39924f7ba0313f6872aabbce.json @@ -0,0 +1,8 @@ +{ + "id": "95a2c4ac-3992-4f7b-a031-3f6872aabbce", + "type": "feature", + "description": "Increases the maximum values of two RDS Performance Insights APIs. The maximum value of the Limit parameter of DimensionGroup is 25. The MaxResult maximum is now 25 for the following APIs: DescribeDimensionKeys, GetResourceMetrics, ListAvailableResourceDimensions, and ListAvailableResourceMetrics.", + "modules": [ + "service/pi" + ] +} \ No newline at end of file diff --git a/.changelog/9eb9410c5e30402d8d240ad5d4a2a671.json b/.changelog/9eb9410c5e30402d8d240ad5d4a2a671.json new file mode 100644 index 00000000000..89fef233539 --- /dev/null +++ b/.changelog/9eb9410c5e30402d8d240ad5d4a2a671.json @@ -0,0 +1,8 @@ +{ + "id": "9eb9410c-5e30-402d-8d24-0ad5d4a2a671", + "type": "feature", + "description": "Documentation updates for AWS Data Exchange.", + "modules": [ + "service/dataexchange" + ] +} \ No newline at end of file diff --git a/.changelog/aceb4d705b674b77aa54d258e81206de.json b/.changelog/aceb4d705b674b77aa54d258e81206de.json new file mode 100644 index 00000000000..1573cdaf1ab --- /dev/null +++ b/.changelog/aceb4d705b674b77aa54d258e81206de.json @@ -0,0 +1,8 @@ +{ + "id": "aceb4d70-5b67-4b77-aa54-d258e81206de", + "type": "feature", + "description": "This release adds new fields like fixAvailable, fixedInVersion and remediation to the finding model. The requirement to have vulnerablePackages in the finding model has also been removed. The documentation has been updated to reflect these changes.", + "modules": [ + "service/inspector2" + ] +} \ No newline at end of file diff --git a/.changelog/b031389c3c964553a084be4f4ed6c41e.json b/.changelog/b031389c3c964553a084be4f4ed6c41e.json new file mode 100644 index 00000000000..76416295a3d --- /dev/null +++ b/.changelog/b031389c3c964553a084be4f4ed6c41e.json @@ -0,0 +1,8 @@ +{ + "id": "b031389c-3c96-4553-a084-be4f4ed6c41e", + "type": "feature", + "description": "Amplify Studio UIBuilder is introducing forms functionality. Forms can be configured from Data Store models, JSON, or from scratch. These forms can then be generated in your project and used like any other React components.", + "modules": [ + "service/amplifyuibuilder" + ] +} \ No newline at end of file diff --git a/.changelog/b1f031c6e950470ba8f0d8422bd61449.json b/.changelog/b1f031c6e950470ba8f0d8422bd61449.json new file mode 100644 index 00000000000..e58325dac85 --- /dev/null +++ b/.changelog/b1f031c6e950470ba8f0d8422bd61449.json @@ -0,0 +1,8 @@ +{ + "id": "b1f031c6-e950-470b-a8f0-d8422bd61449", + "type": "feature", + "description": "This release adds CloudTrail getChannel and listChannels APIs to allow customer to view the ServiceLinkedChannel configurations.", + "modules": [ + "service/cloudtrail" + ] +} \ No newline at end of file diff --git a/.changelog/bb4b6dff969c49858bdfb8fe7bf56f7b.json b/.changelog/bb4b6dff969c49858bdfb8fe7bf56f7b.json new file mode 100644 index 00000000000..2285060db59 --- /dev/null +++ b/.changelog/bb4b6dff969c49858bdfb8fe7bf56f7b.json @@ -0,0 +1,8 @@ +{ + "id": "bb4b6dff-969c-4985-8bdf-b8fe7bf56f7b", + "type": "feature", + "description": "Documentation updates for Amazon EC2.", + "modules": [ + "service/ec2" + ] +} \ No newline at end of file diff --git a/.changelog/ccaa37081e8a44bdb8694d7e7e8c4fd1.json b/.changelog/ccaa37081e8a44bdb8694d7e7e8c4fd1.json new file mode 100644 index 00000000000..51ac6dd14ed --- /dev/null +++ b/.changelog/ccaa37081e8a44bdb8694d7e7e8c4fd1.json @@ -0,0 +1,8 @@ +{ + "id": "ccaa3708-1e8a-44bd-b869-4d7e7e8c4fd1", + "type": "feature", + "description": "Fixed the data type of lagDuration that is returned in Describe Source Server API", + "modules": [ + "service/drs" + ] +} \ No newline at end of file diff --git a/.changelog/cdb528e9dc4d4c8d9a8b1e038c164395.json b/.changelog/cdb528e9dc4d4c8d9a8b1e038c164395.json new file mode 100644 index 00000000000..9fbba99be81 --- /dev/null +++ b/.changelog/cdb528e9dc4d4c8d9a8b1e038c164395.json @@ -0,0 +1,8 @@ +{ + "id": "cdb528e9-dc4d-4c8d-9a8b-1e038c164395", + "type": "feature", + "description": "Release dimension value filtering feature to allow customers to define dimension filters for including only a subset of their dataset to be used by LookoutMetrics.", + "modules": [ + "service/lookoutmetrics" + ] +} \ No newline at end of file diff --git a/.changelog/da018c062a494893a706b9e9760caea1.json b/.changelog/da018c062a494893a706b9e9760caea1.json new file mode 100644 index 00000000000..af74c93b96b --- /dev/null +++ b/.changelog/da018c062a494893a706b9e9760caea1.json @@ -0,0 +1,8 @@ +{ + "id": "da018c06-2a49-4893-a706-b9e9760caea1", + "type": "feature", + "description": "Amazon SNS introduces the Data Protection Policy APIs, which enable customers to attach a data protection policy to an SNS topic. This allows topic owners to enable the new message data protection feature to audit and block sensitive data that is exchanged through their topics.", + "modules": [ + "service/sns" + ] +} \ No newline at end of file diff --git a/.changelog/e4386a5b479e419f9e057d14a1541fde.json b/.changelog/e4386a5b479e419f9e057d14a1541fde.json new file mode 100644 index 00000000000..6bf097af80f --- /dev/null +++ b/.changelog/e4386a5b479e419f9e057d14a1541fde.json @@ -0,0 +1,8 @@ +{ + "id": "e4386a5b-479e-419f-9e05-7d14a1541fde", + "type": "feature", + "description": "This change exposes API settings which allow Dolby Atmos and Dolby Vision to be used when running a channel using Elemental Media Live", + "modules": [ + "service/medialive" + ] +} \ No newline at end of file diff --git a/.changelog/e4ca4763b7404ad2bcf834a5c04e684e.json b/.changelog/e4ca4763b7404ad2bcf834a5c04e684e.json new file mode 100644 index 00000000000..f765bc13655 --- /dev/null +++ b/.changelog/e4ca4763b7404ad2bcf834a5c04e684e.json @@ -0,0 +1,8 @@ +{ + "id": "e4ca4763-b740-4ad2-bcf8-34a5c04e684e", + "type": "feature", + "description": "This release adds support for Systems Manager State Manager Association tagging.", + "modules": [ + "service/ssm" + ] +} \ No newline at end of file diff --git a/.changelog/e7501d1d9b2e4314abf5c0363d777181.json b/.changelog/e7501d1d9b2e4314abf5c0363d777181.json new file mode 100644 index 00000000000..e882e99773f --- /dev/null +++ b/.changelog/e7501d1d9b2e4314abf5c0363d777181.json @@ -0,0 +1,8 @@ +{ + "id": "e7501d1d-9b2e-4314-abf5-c0363d777181", + "type": "feature", + "description": "This release adds support for the client-side evaluation - powered by AWS AppConfig feature.", + "modules": [ + "service/evidently" + ] +} \ No newline at end of file diff --git a/.changelog/f4e93fee2af040feba5672dc52a61723.json b/.changelog/f4e93fee2af040feba5672dc52a61723.json new file mode 100644 index 00000000000..0a03766e779 --- /dev/null +++ b/.changelog/f4e93fee2af040feba5672dc52a61723.json @@ -0,0 +1,8 @@ +{ + "id": "f4e93fee-2af0-40fe-ba56-72dc52a61723", + "type": "feature", + "description": "This release enables our customer to choose the option of Sharepoint 2019 for the on-premise Sharepoint connector.", + "modules": [ + "service/kendra" + ] +} \ No newline at end of file diff --git a/.changelog/f59e4bc845cb431499c2237b3d2a07aa.json b/.changelog/f59e4bc845cb431499c2237b3d2a07aa.json new file mode 100644 index 00000000000..451e6d5c79c --- /dev/null +++ b/.changelog/f59e4bc845cb431499c2237b3d2a07aa.json @@ -0,0 +1,8 @@ +{ + "id": "f59e4bc8-45cb-4314-99c2-237b3d2a07aa", + "type": "feature", + "description": "This update introduces API operations to manage and create local gateway route tables, CoIP pools, and VIF group associations.", + "modules": [ + "service/ec2" + ] +} \ No newline at end of file diff --git a/.changelog/f5e6fdc6ff5f433a884fc9ce5b7beb85.json b/.changelog/f5e6fdc6ff5f433a884fc9ce5b7beb85.json new file mode 100644 index 00000000000..1e389adaee4 --- /dev/null +++ b/.changelog/f5e6fdc6ff5f433a884fc9ce5b7beb85.json @@ -0,0 +1,8 @@ +{ + "id": "f5e6fdc6-ff5f-433a-884f-c9ce5b7beb85", + "type": "documentation", + "description": "This release updates documentation for AQUA features and other description updates.", + "modules": [ + "service/redshift" + ] +} \ No newline at end of file diff --git a/.changelog/fb9348901c9c4c18bedb22c7e0ffd399.json b/.changelog/fb9348901c9c4c18bedb22c7e0ffd399.json new file mode 100644 index 00000000000..0b11c8c9d38 --- /dev/null +++ b/.changelog/fb9348901c9c4c18bedb22c7e0ffd399.json @@ -0,0 +1,8 @@ +{ + "id": "fb934890-1c9c-4c18-bedb-22c7e0ffd399", + "type": "feature", + "description": "This release introduces the ability to have multiple server host keys for any of your Transfer Family servers that use the SFTP protocol.", + "modules": [ + "service/transfer" + ] +} \ No newline at end of file diff --git a/codegen/sdk-codegen/aws-models/amplifyuibuilder.json b/codegen/sdk-codegen/aws-models/amplifyuibuilder.json index 0599a717815..726c091e7c8 100644 --- a/codegen/sdk-codegen/aws-models/amplifyuibuilder.json +++ b/codegen/sdk-codegen/aws-models/amplifyuibuilder.json @@ -1,5 +1,5 @@ { - "smithy": "1.0", + "smithy": "2.0", "shapes": { "com.amazonaws.amplifyuibuilder#ActionParameters": { "type": "structure", @@ -7,7 +7,7 @@ "type": { "target": "com.amazonaws.amplifyuibuilder#ComponentProperty", "traits": { - "smithy.api#documentation": "

The type of navigation action. Valid values are url and anchor.\n This value is required for a navigation action.

" + "smithy.api#documentation": "

The type of navigation action. Valid values are url and anchor. This value is required for a navigation action.

" } }, "url": { @@ -19,7 +19,7 @@ "anchor": { "target": "com.amazonaws.amplifyuibuilder#ComponentProperty", "traits": { - "smithy.api#documentation": "

The HTML anchor link to the location to open. Specify this value for a navigation\n action.

" + "smithy.api#documentation": "

The HTML anchor link to the location to open. Specify this value for a navigation action.

" } }, "target": { @@ -31,13 +31,13 @@ "global": { "target": "com.amazonaws.amplifyuibuilder#ComponentProperty", "traits": { - "smithy.api#documentation": "

Specifies whether the user should be signed out globally. Specify this value for an auth\n sign out action.

" + "smithy.api#documentation": "

Specifies whether the user should be signed out globally. Specify this value for an auth sign out action.

" } }, "model": { "target": "smithy.api#String", "traits": { - "smithy.api#documentation": "

The name of the data model. Use when the action performs an operation on an Amplify DataStore model.

" + "smithy.api#documentation": "

The name of the data model. Use when the action performs an operation on an Amplify DataStore\n model.

" } }, "id": { @@ -49,7 +49,7 @@ "fields": { "target": "com.amazonaws.amplifyuibuilder#ComponentProperties", "traits": { - "smithy.api#documentation": "

A dictionary of key-value pairs mapping Amplify Studio properties to fields\n in a data model. Use when the action performs an operation on an Amplify\n DataStore model.

" + "smithy.api#documentation": "

A dictionary of key-value pairs mapping Amplify Studio properties to fields in a data model. Use when the action\n performs an operation on an Amplify DataStore model.

" } }, "state": { @@ -60,11 +60,37 @@ } }, "traits": { - "smithy.api#documentation": "

Represents the event action configuration for an element of a Component or\n ComponentChild. Use for the workflow feature in Amplify Studio\n that allows you to bind events and actions to components. ActionParameters\n defines the action that is performed when an event occurs on the component.

" + "smithy.api#documentation": "

Represents the event action configuration for an element of a Component\n or ComponentChild. Use for the workflow feature in Amplify Studio\n that allows you to bind events and actions to components. ActionParameters\n defines the action that is performed when an event occurs on the component.

" } }, "com.amazonaws.amplifyuibuilder#AmplifyUIBuilder": { "type": "service", + "version": "2021-08-11", + "operations": [ + { + "target": "com.amazonaws.amplifyuibuilder#ExchangeCodeForToken" + }, + { + "target": "com.amazonaws.amplifyuibuilder#GetMetadata" + }, + { + "target": "com.amazonaws.amplifyuibuilder#PutMetadataFlag" + }, + { + "target": "com.amazonaws.amplifyuibuilder#RefreshToken" + } + ], + "resources": [ + { + "target": "com.amazonaws.amplifyuibuilder#ComponentResource" + }, + { + "target": "com.amazonaws.amplifyuibuilder#FormResource" + }, + { + "target": "com.amazonaws.amplifyuibuilder#ThemeResource" + } + ], "traits": { "aws.api#service": { "sdkId": "AmplifyUIBuilder", @@ -102,24 +128,7 @@ "smithy.api#cors": {}, "smithy.api#documentation": "

The Amplify UI Builder API provides a programmatic interface for creating\n and configuring user interface (UI) component libraries and themes for use in your Amplify applications. You can then connect these UI components to an application's\n backend Amazon Web Services resources.

\n

You can also use the Amplify Studio visual designer to create UI components\n and model data for an app. For more information, see Introduction in the\n Amplify Docs.

\n

The Amplify Framework is a comprehensive set of SDKs, libraries, tools, and\n documentation for client app development. For more information, see the Amplify Framework. For more information about\n deploying an Amplify application to Amazon Web Services, see the Amplify User Guide.

", "smithy.api#title": "AWS Amplify UI Builder" - }, - "version": "2021-08-11", - "operations": [ - { - "target": "com.amazonaws.amplifyuibuilder#ExchangeCodeForToken" - }, - { - "target": "com.amazonaws.amplifyuibuilder#RefreshToken" - } - ], - "resources": [ - { - "target": "com.amazonaws.amplifyuibuilder#ComponentResource" - }, - { - "target": "com.amazonaws.amplifyuibuilder#ThemeResource" - } - ] + } }, "com.amazonaws.amplifyuibuilder#Component": { "type": "structure", @@ -232,7 +241,7 @@ "events": { "target": "com.amazonaws.amplifyuibuilder#ComponentEvents", "traits": { - "smithy.api#documentation": "

Describes the events that can be raised on the component. Use for the workflow feature in\n Amplify Studio that allows you to bind events and actions to\n components.

" + "smithy.api#documentation": "

Describes the events that can be raised on the component. Use for the workflow feature in Amplify Studio that allows you to\n bind events and actions to components.

" } }, "schemaVersion": { @@ -330,6 +339,12 @@ "traits": { "smithy.api#documentation": "

The default value to assign to the property.

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

The name of a component slot.

" + } } }, "traits": { @@ -369,7 +384,7 @@ "events": { "target": "com.amazonaws.amplifyuibuilder#ComponentEvents", "traits": { - "smithy.api#documentation": "

Describes the events that can be raised on the child component. Use for the workflow\n feature in Amplify Studio that allows you to bind events and actions to\n components.

" + "smithy.api#documentation": "

Describes the events that can be raised on the child component. Use for the workflow feature in Amplify Studio that allows you to\n bind events and actions to components.

" } }, "sourceId": { @@ -499,12 +514,12 @@ "bindingEvent": { "target": "smithy.api#String", "traits": { - "smithy.api#documentation": "

Binds an event to an action on a component. When you specify a bindingEvent, the event is called when the action is performed.

" + "smithy.api#documentation": "

Binds an event to an action on a component. When you specify a bindingEvent,\n the event is called when the action is performed.

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

Describes the configuration of an event. You can bind an event and a corresponding action\n to a Component or a ComponentChild. A button click is an example of\n an event.

" + "smithy.api#documentation": "

Describes the configuration of an event. You can bind an event and a corresponding\n action to a Component or a ComponentChild. A button click\n is an example of an event.

" } }, "com.amazonaws.amplifyuibuilder#ComponentEvents": { @@ -999,6 +1014,164 @@ } } }, + "com.amazonaws.amplifyuibuilder#CreateForm": { + "type": "operation", + "input": { + "target": "com.amazonaws.amplifyuibuilder#CreateFormRequest" + }, + "output": { + "target": "com.amazonaws.amplifyuibuilder#CreateFormResponse" + }, + "errors": [ + { + "target": "com.amazonaws.amplifyuibuilder#InternalServerException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#InvalidParameterException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#ResourceConflictException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#ServiceQuotaExceededException" + } + ], + "traits": { + "aws.iam#conditionKeys": [ + "aws:TagKeys", + "aws:RequestTag/${TagKey}" + ], + "aws.iam#requiredActions": [ + "amplify:GetApp" + ], + "smithy.api#documentation": "

Creates a new form for an Amplify app.

", + "smithy.api#http": { + "uri": "/app/{appId}/environment/{environmentName}/forms", + "method": "POST" + }, + "smithy.api#idempotent": {} + } + }, + "com.amazonaws.amplifyuibuilder#CreateFormData": { + "type": "structure", + "members": { + "name": { + "target": "com.amazonaws.amplifyuibuilder#FormName", + "traits": { + "smithy.api#documentation": "

The name of the form.

", + "smithy.api#required": {} + } + }, + "dataType": { + "target": "com.amazonaws.amplifyuibuilder#FormDataTypeConfig", + "traits": { + "smithy.api#documentation": "

The type of data source to use to create the form.

", + "smithy.api#required": {} + } + }, + "formActionType": { + "target": "com.amazonaws.amplifyuibuilder#FormActionType", + "traits": { + "smithy.api#documentation": "

Specifies whether to perform a create or update action on the form.

", + "smithy.api#required": {} + } + }, + "fields": { + "target": "com.amazonaws.amplifyuibuilder#FieldsMap", + "traits": { + "smithy.api#documentation": "

The configuration information for the form's fields.

", + "smithy.api#required": {} + } + }, + "style": { + "target": "com.amazonaws.amplifyuibuilder#FormStyle", + "traits": { + "smithy.api#documentation": "

The configuration for the form's style.

", + "smithy.api#required": {} + } + }, + "sectionalElements": { + "target": "com.amazonaws.amplifyuibuilder#SectionalElementMap", + "traits": { + "smithy.api#documentation": "

The configuration information for the visual helper elements for the form. These elements\n are not associated with any data.

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

The schema version of the form.

", + "smithy.api#required": {} + } + }, + "cta": { + "target": "com.amazonaws.amplifyuibuilder#FormCTA", + "traits": { + "smithy.api#documentation": "

The FormCTA object that stores the call to action configuration for the\n form.

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

One or more key-value pairs to use when tagging the form data.

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

Represents all of the information that is required to create a form.

" + } + }, + "com.amazonaws.amplifyuibuilder#CreateFormRequest": { + "type": "structure", + "members": { + "appId": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The unique ID of the Amplify app to associate with the form.

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

The name of the backend environment that is a part of the Amplify app.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + }, + "clientToken": { + "target": "smithy.api#String", + "traits": { + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The unique client token.

", + "smithy.api#httpQuery": "clientToken", + "smithy.api#idempotencyToken": {} + } + }, + "formToCreate": { + "target": "com.amazonaws.amplifyuibuilder#CreateFormData", + "traits": { + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

Represents the configuration of the form to create.

", + "smithy.api#httpPayload": {}, + "smithy.api#required": {} + } + } + } + }, + "com.amazonaws.amplifyuibuilder#CreateFormResponse": { + "type": "structure", + "members": { + "entity": { + "target": "com.amazonaws.amplifyuibuilder#Form", + "traits": { + "smithy.api#documentation": "

Describes the configuration of the new form.

", + "smithy.api#httpPayload": {} + } + } + } + }, "com.amazonaws.amplifyuibuilder#CreateTheme": { "type": "operation", "input": { @@ -1182,6 +1355,66 @@ } } }, + "com.amazonaws.amplifyuibuilder#DeleteForm": { + "type": "operation", + "input": { + "target": "com.amazonaws.amplifyuibuilder#DeleteFormRequest" + }, + "output": { + "target": "smithy.api#Unit" + }, + "errors": [ + { + "target": "com.amazonaws.amplifyuibuilder#InternalServerException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#InvalidParameterException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#ResourceNotFoundException" + } + ], + "traits": { + "aws.iam#requiredActions": [ + "amplify:GetApp" + ], + "smithy.api#documentation": "

Deletes a form from an Amplify app.

", + "smithy.api#http": { + "uri": "/app/{appId}/environment/{environmentName}/forms/{id}", + "method": "DELETE" + }, + "smithy.api#idempotent": {} + } + }, + "com.amazonaws.amplifyuibuilder#DeleteFormRequest": { + "type": "structure", + "members": { + "appId": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The unique ID of the Amplify app associated with the form to delete.

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

The name of the backend environment that is a part of the Amplify app.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + }, + "id": { + "target": "com.amazonaws.amplifyuibuilder#Uuid", + "traits": { + "smithy.api#documentation": "

The unique ID of the form to delete.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + } + } + }, "com.amazonaws.amplifyuibuilder#DeleteTheme": { "type": "operation", "input": { @@ -1408,13 +1641,13 @@ } } }, - "com.amazonaws.amplifyuibuilder#ExportThemes": { + "com.amazonaws.amplifyuibuilder#ExportForms": { "type": "operation", "input": { - "target": "com.amazonaws.amplifyuibuilder#ExportThemesRequest" + "target": "com.amazonaws.amplifyuibuilder#ExportFormsRequest" }, "output": { - "target": "com.amazonaws.amplifyuibuilder#ExportThemesResponse" + "target": "com.amazonaws.amplifyuibuilder#ExportFormsResponse" }, "errors": [ { @@ -1425,9 +1658,9 @@ } ], "traits": { - "smithy.api#documentation": "

Exports theme configurations to code that is ready to integrate into an Amplify app.

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

Exports form configurations to code that is ready to integrate into an Amplify app.

", "smithy.api#http": { - "uri": "/export/app/{appId}/environment/{environmentName}/themes", + "uri": "/export/app/{appId}/environment/{environmentName}/forms", "method": "GET" }, "smithy.api#paginated": { @@ -1438,13 +1671,13 @@ "smithy.api#readonly": {} } }, - "com.amazonaws.amplifyuibuilder#ExportThemesRequest": { + "com.amazonaws.amplifyuibuilder#ExportFormsRequest": { "type": "structure", "members": { "appId": { "target": "smithy.api#String", "traits": { - "smithy.api#documentation": "

The unique ID of the Amplify app to export the themes to.

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

The unique ID of the Amplify app to export forms to.

", "smithy.api#httpLabel": {}, "smithy.api#required": {} } @@ -1452,7 +1685,7 @@ "environmentName": { "target": "smithy.api#String", "traits": { - "smithy.api#documentation": "

The name of the backend environment that is part of the Amplify app.

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

The name of the backend environment that is a part of the Amplify app.

", "smithy.api#httpLabel": {}, "smithy.api#required": {} } @@ -1466,13 +1699,13 @@ } } }, - "com.amazonaws.amplifyuibuilder#ExportThemesResponse": { + "com.amazonaws.amplifyuibuilder#ExportFormsResponse": { "type": "structure", "members": { "entities": { - "target": "com.amazonaws.amplifyuibuilder#ThemeList", + "target": "com.amazonaws.amplifyuibuilder#FormList", "traits": { - "smithy.api#documentation": "

Represents the configuration of the exported themes.

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

Represents the configuration of the exported forms.

", "smithy.api#required": {} } }, @@ -1484,35 +1717,736 @@ } } }, - "com.amazonaws.amplifyuibuilder#FormBindingElement": { - "type": "structure", - "members": { - "element": { - "target": "smithy.api#String", - "traits": { - "smithy.api#documentation": "

The name of the component to retrieve a value from.

", - "smithy.api#required": {} - } - }, - "property": { - "target": "smithy.api#String", - "traits": { - "smithy.api#documentation": "

The property to retrieve a value from.

", - "smithy.api#required": {} - } - } + "com.amazonaws.amplifyuibuilder#ExportThemes": { + "type": "operation", + "input": { + "target": "com.amazonaws.amplifyuibuilder#ExportThemesRequest" }, - "traits": { - "smithy.api#documentation": "

Describes how to bind a component property to form data.

" - } - }, - "com.amazonaws.amplifyuibuilder#FormBindings": { - "type": "map", + "output": { + "target": "com.amazonaws.amplifyuibuilder#ExportThemesResponse" + }, + "errors": [ + { + "target": "com.amazonaws.amplifyuibuilder#InternalServerException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#InvalidParameterException" + } + ], + "traits": { + "smithy.api#documentation": "

Exports theme configurations to code that is ready to integrate into an Amplify app.

", + "smithy.api#http": { + "uri": "/export/app/{appId}/environment/{environmentName}/themes", + "method": "GET" + }, + "smithy.api#paginated": { + "inputToken": "nextToken", + "outputToken": "nextToken", + "items": "entities" + }, + "smithy.api#readonly": {} + } + }, + "com.amazonaws.amplifyuibuilder#ExportThemesRequest": { + "type": "structure", + "members": { + "appId": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The unique ID of the Amplify app to export the themes to.

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

The name of the backend environment that is part of the Amplify app.

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

The token to request the next page of results.

", + "smithy.api#httpQuery": "nextToken" + } + } + } + }, + "com.amazonaws.amplifyuibuilder#ExportThemesResponse": { + "type": "structure", + "members": { + "entities": { + "target": "com.amazonaws.amplifyuibuilder#ThemeList", + "traits": { + "smithy.api#documentation": "

Represents the configuration of the exported themes.

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

The pagination token that's included if more results are available.

" + } + } + } + }, + "com.amazonaws.amplifyuibuilder#FeaturesMap": { + "type": "map", + "key": { + "target": "smithy.api#String" + }, + "value": { + "target": "smithy.api#String" + } + }, + "com.amazonaws.amplifyuibuilder#FieldConfig": { + "type": "structure", + "members": { + "label": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The label for the field.

" + } + }, + "position": { + "target": "com.amazonaws.amplifyuibuilder#FieldPosition", + "traits": { + "smithy.api#documentation": "

Specifies the field position.

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

Specifies whether to hide a field.

" + } + }, + "inputType": { + "target": "com.amazonaws.amplifyuibuilder#FieldInputConfig", + "traits": { + "smithy.api#documentation": "

Describes the configuration for the default input value to display for a field.

" + } + }, + "validations": { + "target": "com.amazonaws.amplifyuibuilder#ValidationsList", + "traits": { + "smithy.api#documentation": "

The validations to perform on the value in the field.

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

Describes the configuration information for a field in a table.

" + } + }, + "com.amazonaws.amplifyuibuilder#FieldInputConfig": { + "type": "structure", + "members": { + "type": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The input type for the field.

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

Specifies a field that requires input.

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

Specifies a read only field.

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

The text to display as a placeholder for the field.

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

The default value for the field.

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

The text to display to describe the field.

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

Specifies whether a field has a default value.

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

The default country code for a phone number.

" + } + }, + "valueMappings": { + "target": "com.amazonaws.amplifyuibuilder#ValueMappings", + "traits": { + "smithy.api#documentation": "

The information to use to customize the input fields with data at runtime.

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

The name of the field.

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

The minimum value to display for the field.

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

The maximum value to display for the field.

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

The stepping increment for a numeric value in a field.

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

The value for the field.

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

Describes the configuration for the default input values to display for a field.

" + } + }, + "com.amazonaws.amplifyuibuilder#FieldPosition": { + "type": "union", + "members": { + "fixed": { + "target": "com.amazonaws.amplifyuibuilder#FixedPosition", + "traits": { + "smithy.api#documentation": "

The field position is fixed and doesn't change in relation to other fields.

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

The field position is to the right of the field specified by the string.

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

The field position is below the field specified by the string.

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

Describes the field position.

" + } + }, + "com.amazonaws.amplifyuibuilder#FieldValidationConfiguration": { + "type": "structure", + "members": { + "type": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The validation to perform on an object type.\n

", + "smithy.api#required": {} + } + }, + "strValues": { + "target": "com.amazonaws.amplifyuibuilder#StrValues", + "traits": { + "smithy.api#documentation": "

The validation to perform on a string value.

" + } + }, + "numValues": { + "target": "com.amazonaws.amplifyuibuilder#NumValues", + "traits": { + "smithy.api#documentation": "

The validation to perform on a number value.

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

The validation message to display.

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

Describes the validation configuration for a field.

" + } + }, + "com.amazonaws.amplifyuibuilder#FieldsMap": { + "type": "map", "key": { "target": "smithy.api#String" }, - "value": { - "target": "com.amazonaws.amplifyuibuilder#FormBindingElement" + "value": { + "target": "com.amazonaws.amplifyuibuilder#FieldConfig" + } + }, + "com.amazonaws.amplifyuibuilder#FixedPosition": { + "type": "string", + "traits": { + "smithy.api#enum": [ + { + "value": "first", + "name": "FIRST" + } + ] + } + }, + "com.amazonaws.amplifyuibuilder#Form": { + "type": "structure", + "members": { + "appId": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The unique ID of the Amplify app associated with the form.

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

The name of the backend environment that is a part of the Amplify app.

", + "smithy.api#required": {} + } + }, + "id": { + "target": "com.amazonaws.amplifyuibuilder#Uuid", + "traits": { + "smithy.api#documentation": "

The unique ID of the form.

", + "smithy.api#required": {} + } + }, + "name": { + "target": "com.amazonaws.amplifyuibuilder#FormName", + "traits": { + "smithy.api#documentation": "

The name of the form.

", + "smithy.api#required": {} + } + }, + "formActionType": { + "target": "com.amazonaws.amplifyuibuilder#FormActionType", + "traits": { + "smithy.api#documentation": "

The operation to perform on the specified form.

", + "smithy.api#required": {} + } + }, + "style": { + "target": "com.amazonaws.amplifyuibuilder#FormStyle", + "traits": { + "smithy.api#documentation": "

Stores the configuration for the form's style.

", + "smithy.api#required": {} + } + }, + "dataType": { + "target": "com.amazonaws.amplifyuibuilder#FormDataTypeConfig", + "traits": { + "smithy.api#documentation": "

The type of data source to use to create the form.

", + "smithy.api#required": {} + } + }, + "fields": { + "target": "com.amazonaws.amplifyuibuilder#FieldsMap", + "traits": { + "smithy.api#documentation": "

Stores the information about the form's fields.

", + "smithy.api#required": {} + } + }, + "sectionalElements": { + "target": "com.amazonaws.amplifyuibuilder#SectionalElementMap", + "traits": { + "smithy.api#documentation": "

Stores the visual helper elements for the form that are not associated with any\n data.

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

The schema version of the form when it was imported.

", + "smithy.api#required": {} + } + }, + "tags": { + "target": "com.amazonaws.amplifyuibuilder#Tags", + "traits": { + "aws.cloudformation#cfnMutability": "create-and-read", + "smithy.api#documentation": "

One or more key-value pairs to use when tagging the form.

" + } + }, + "cta": { + "target": "com.amazonaws.amplifyuibuilder#FormCTA", + "traits": { + "smithy.api#documentation": "

Stores the call to action configuration for the form.

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

Contains the configuration settings for a Form user interface (UI) element\n for an Amplify app. A form is a component you can add to your project by specifying a data\n source as the default configuration for the form.

", + "smithy.api#references": [ + { + "resource": "com.amazonaws.amplifyuibuilder#FormResource" + } + ] + } + }, + "com.amazonaws.amplifyuibuilder#FormActionType": { + "type": "string", + "traits": { + "smithy.api#enum": [ + { + "value": "create", + "name": "CREATE" + }, + { + "value": "update", + "name": "UPDATE" + } + ] + } + }, + "com.amazonaws.amplifyuibuilder#FormBindingElement": { + "type": "structure", + "members": { + "element": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The name of the component to retrieve a value from.

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

The property to retrieve a value from.

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

Describes how to bind a component property to form data.

" + } + }, + "com.amazonaws.amplifyuibuilder#FormBindings": { + "type": "map", + "key": { + "target": "smithy.api#String" + }, + "value": { + "target": "com.amazonaws.amplifyuibuilder#FormBindingElement" + } + }, + "com.amazonaws.amplifyuibuilder#FormButton": { + "type": "structure", + "members": { + "excluded": { + "target": "smithy.api#Boolean", + "traits": { + "smithy.api#documentation": "

Specifies whether the button is visible on the form.

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

Describes the button's properties.

" + } + }, + "position": { + "target": "com.amazonaws.amplifyuibuilder#FieldPosition", + "traits": { + "smithy.api#documentation": "

The position of the button.

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

Describes the configuration for a button UI element that is a part of a form.

" + } + }, + "com.amazonaws.amplifyuibuilder#FormButtonsPosition": { + "type": "string", + "traits": { + "smithy.api#enum": [ + { + "value": "top", + "name": "TOP" + }, + { + "value": "bottom", + "name": "BOTTOM" + }, + { + "value": "top_and_bottom", + "name": "TOP_AND_BOTTOM" + } + ] + } + }, + "com.amazonaws.amplifyuibuilder#FormCTA": { + "type": "structure", + "members": { + "position": { + "target": "com.amazonaws.amplifyuibuilder#FormButtonsPosition", + "traits": { + "smithy.api#documentation": "

The position of the button.

" + } + }, + "clear": { + "target": "com.amazonaws.amplifyuibuilder#FormButton", + "traits": { + "smithy.api#documentation": "

Displays a clear button.

" + } + }, + "cancel": { + "target": "com.amazonaws.amplifyuibuilder#FormButton", + "traits": { + "smithy.api#documentation": "

Displays a cancel button.

" + } + }, + "submit": { + "target": "com.amazonaws.amplifyuibuilder#FormButton", + "traits": { + "smithy.api#documentation": "

Displays a submit button.

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

Describes the call to action button configuration for the form..

" + } + }, + "com.amazonaws.amplifyuibuilder#FormDataSourceType": { + "type": "string", + "traits": { + "smithy.api#enum": [ + { + "value": "DataStore", + "name": "DATASTORE", + "documentation": "Will use a provided Amplify DataStore enabled API" + }, + { + "value": "Custom", + "name": "CUSTOM", + "documentation": "Will use passed in hooks to use when creating a form from scratch" + } + ] + } + }, + "com.amazonaws.amplifyuibuilder#FormDataTypeConfig": { + "type": "structure", + "members": { + "dataSourceType": { + "target": "com.amazonaws.amplifyuibuilder#FormDataSourceType", + "traits": { + "smithy.api#documentation": "

The data source type, either an Amplify DataStore model or a custom data type.

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

The unique name of the data type you are using as the data source for the form.

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

Describes the data type configuration for the data source associated with a form.

" + } + }, + "com.amazonaws.amplifyuibuilder#FormInputValueProperty": { + "type": "structure", + "members": { + "value": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The value to assign to the input field.

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

Describes the configuration for an input field on a form. Use\n FormInputValueProperty to specify the values to render or bind by\n default.

" + } + }, + "com.amazonaws.amplifyuibuilder#FormList": { + "type": "list", + "member": { + "target": "com.amazonaws.amplifyuibuilder#Form" + } + }, + "com.amazonaws.amplifyuibuilder#FormName": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 1, + "max": 255 + } + } + }, + "com.amazonaws.amplifyuibuilder#FormResource": { + "type": "resource", + "identifiers": { + "id": { + "target": "com.amazonaws.amplifyuibuilder#Uuid" + }, + "appId": { + "target": "smithy.api#String" + }, + "environmentName": { + "target": "smithy.api#String" + } + }, + "create": { + "target": "com.amazonaws.amplifyuibuilder#CreateForm" + }, + "read": { + "target": "com.amazonaws.amplifyuibuilder#GetForm" + }, + "update": { + "target": "com.amazonaws.amplifyuibuilder#UpdateForm" + }, + "delete": { + "target": "com.amazonaws.amplifyuibuilder#DeleteForm" + }, + "list": { + "target": "com.amazonaws.amplifyuibuilder#ListForms" + }, + "collectionOperations": [ + { + "target": "com.amazonaws.amplifyuibuilder#ExportForms" + } + ], + "traits": { + "aws.api#arn": { + "template": "app/{appId}/environment/{environmentName}/forms/{id}" + }, + "aws.cloudformation#cfnResource": { + "name": "Form", + "additionalSchemas": [ + "com.amazonaws.amplifyuibuilder#Form" + ] + }, + "aws.iam#conditionKeys": [ + "aws:ResourceTag/${TagKey}" + ] + } + }, + "com.amazonaws.amplifyuibuilder#FormStyle": { + "type": "structure", + "members": { + "horizontalGap": { + "target": "com.amazonaws.amplifyuibuilder#FormStyleConfig", + "traits": { + "smithy.api#documentation": "

The spacing for the horizontal gap.

" + } + }, + "verticalGap": { + "target": "com.amazonaws.amplifyuibuilder#FormStyleConfig", + "traits": { + "smithy.api#documentation": "

The spacing for the vertical gap.

" + } + }, + "outerPadding": { + "target": "com.amazonaws.amplifyuibuilder#FormStyleConfig", + "traits": { + "smithy.api#documentation": "

The size of the outer padding for the form.

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

Describes the configuration for the form's style.

" + } + }, + "com.amazonaws.amplifyuibuilder#FormStyleConfig": { + "type": "union", + "members": { + "tokenReference": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

A reference to a design token to use to bind the form's style properties to an existing\n theme.

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

The value of the style setting.

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

Describes the configuration settings for the form's style properties.

" + } + }, + "com.amazonaws.amplifyuibuilder#FormSummary": { + "type": "structure", + "members": { + "appId": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The unique ID for the app associated with the form summary.

", + "smithy.api#required": {} + } + }, + "dataType": { + "target": "com.amazonaws.amplifyuibuilder#FormDataTypeConfig", + "traits": { + "smithy.api#documentation": "

The form's data source type.

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

The name of the backend environment that is part of the Amplify app.

", + "smithy.api#required": {} + } + }, + "formActionType": { + "target": "com.amazonaws.amplifyuibuilder#FormActionType", + "traits": { + "smithy.api#documentation": "

The type of operation to perform on the form.

", + "smithy.api#required": {} + } + }, + "id": { + "target": "com.amazonaws.amplifyuibuilder#Uuid", + "traits": { + "smithy.api#documentation": "

The ID of the form.

", + "smithy.api#required": {} + } + }, + "name": { + "target": "com.amazonaws.amplifyuibuilder#FormName", + "traits": { + "smithy.api#documentation": "

The name of the form.

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

Describes the basic information about a form.

" + } + }, + "com.amazonaws.amplifyuibuilder#FormSummaryList": { + "type": "list", + "member": { + "target": "com.amazonaws.amplifyuibuilder#FormSummary" } }, "com.amazonaws.amplifyuibuilder#GetComponent": { @@ -1588,6 +2522,137 @@ } } }, + "com.amazonaws.amplifyuibuilder#GetForm": { + "type": "operation", + "input": { + "target": "com.amazonaws.amplifyuibuilder#GetFormRequest" + }, + "output": { + "target": "com.amazonaws.amplifyuibuilder#GetFormResponse" + }, + "errors": [ + { + "target": "com.amazonaws.amplifyuibuilder#InternalServerException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#InvalidParameterException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#ResourceNotFoundException" + } + ], + "traits": { + "aws.iam#requiredActions": [ + "amplify:GetApp" + ], + "smithy.api#documentation": "

Returns an existing form for an Amplify app.

", + "smithy.api#http": { + "uri": "/app/{appId}/environment/{environmentName}/forms/{id}", + "method": "GET" + }, + "smithy.api#readonly": {} + } + }, + "com.amazonaws.amplifyuibuilder#GetFormRequest": { + "type": "structure", + "members": { + "appId": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The unique ID of the Amplify app.

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

The name of the backend environment that is part of the Amplify app.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + }, + "id": { + "target": "com.amazonaws.amplifyuibuilder#Uuid", + "traits": { + "smithy.api#documentation": "

The unique ID of the form.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + } + } + }, + "com.amazonaws.amplifyuibuilder#GetFormResponse": { + "type": "structure", + "members": { + "form": { + "target": "com.amazonaws.amplifyuibuilder#Form", + "traits": { + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

Represents the configuration settings for the form.

", + "smithy.api#httpPayload": {} + } + } + } + }, + "com.amazonaws.amplifyuibuilder#GetMetadata": { + "type": "operation", + "input": { + "target": "com.amazonaws.amplifyuibuilder#GetMetadataRequest" + }, + "output": { + "target": "com.amazonaws.amplifyuibuilder#GetMetadataResponse" + }, + "errors": [ + { + "target": "com.amazonaws.amplifyuibuilder#InvalidParameterException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#UnauthorizedException" + } + ], + "traits": { + "smithy.api#documentation": "

Returns existing metadata for an Amplify app.

", + "smithy.api#http": { + "uri": "/app/{appId}/environment/{environmentName}/metadata", + "method": "GET" + }, + "smithy.api#readonly": {} + } + }, + "com.amazonaws.amplifyuibuilder#GetMetadataRequest": { + "type": "structure", + "members": { + "appId": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The unique ID of the Amplify app.

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

The name of the backend environment that is part of the Amplify app.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + } + } + }, + "com.amazonaws.amplifyuibuilder#GetMetadataResponse": { + "type": "structure", + "members": { + "features": { + "target": "com.amazonaws.amplifyuibuilder#FeaturesMap", + "traits": { + "smithy.api#documentation": "

Represents the configuration settings for the features metadata.

", + "smithy.api#required": {} + } + } + } + }, "com.amazonaws.amplifyuibuilder#GetTheme": { "type": "operation", "input": { @@ -1730,6 +2795,7 @@ "com.amazonaws.amplifyuibuilder#ListComponentsLimit": { "type": "integer", "traits": { + "smithy.api#default": 0, "smithy.api#range": { "min": 1, "max": 100 @@ -1765,6 +2831,7 @@ "maxResults": { "target": "com.amazonaws.amplifyuibuilder#ListComponentsLimit", "traits": { + "smithy.api#default": 0, "smithy.api#documentation": "

The maximum number of components to retrieve.

", "smithy.api#httpQuery": "maxResults" } @@ -1789,6 +2856,104 @@ } } }, + "com.amazonaws.amplifyuibuilder#ListForms": { + "type": "operation", + "input": { + "target": "com.amazonaws.amplifyuibuilder#ListFormsRequest" + }, + "output": { + "target": "com.amazonaws.amplifyuibuilder#ListFormsResponse" + }, + "errors": [ + { + "target": "com.amazonaws.amplifyuibuilder#InternalServerException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#InvalidParameterException" + } + ], + "traits": { + "aws.iam#requiredActions": [ + "amplify:GetApp" + ], + "smithy.api#documentation": "

Retrieves a list of forms for a specified Amplify app and backend environment.

", + "smithy.api#http": { + "uri": "/app/{appId}/environment/{environmentName}/forms", + "method": "GET" + }, + "smithy.api#paginated": { + "inputToken": "nextToken", + "outputToken": "nextToken", + "pageSize": "maxResults", + "items": "entities" + }, + "smithy.api#readonly": {} + } + }, + "com.amazonaws.amplifyuibuilder#ListFormsLimit": { + "type": "integer", + "traits": { + "smithy.api#default": 0, + "smithy.api#range": { + "min": 1, + "max": 100 + } + } + }, + "com.amazonaws.amplifyuibuilder#ListFormsRequest": { + "type": "structure", + "members": { + "appId": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The unique ID for the Amplify app.

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

The name of the backend environment that is a part of the Amplify app.

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

The token to request the next page of results.

", + "smithy.api#httpQuery": "nextToken" + } + }, + "maxResults": { + "target": "com.amazonaws.amplifyuibuilder#ListFormsLimit", + "traits": { + "smithy.api#default": 0, + "smithy.api#documentation": "

The maximum number of forms to retrieve.

", + "smithy.api#httpQuery": "maxResults" + } + } + } + }, + "com.amazonaws.amplifyuibuilder#ListFormsResponse": { + "type": "structure", + "members": { + "entities": { + "target": "com.amazonaws.amplifyuibuilder#FormSummaryList", + "traits": { + "smithy.api#documentation": "

The list of forms for the Amplify app.

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

The pagination token that's included if more results are available.

" + } + } + } + }, "com.amazonaws.amplifyuibuilder#ListThemes": { "type": "operation", "input": { @@ -1826,6 +2991,7 @@ "com.amazonaws.amplifyuibuilder#ListThemesLimit": { "type": "integer", "traits": { + "smithy.api#default": 0, "smithy.api#range": { "min": 1, "max": 100 @@ -1861,6 +3027,7 @@ "maxResults": { "target": "com.amazonaws.amplifyuibuilder#ListThemesLimit", "traits": { + "smithy.api#default": 0, "smithy.api#documentation": "

The maximum number of theme results to return in the response.

", "smithy.api#httpQuery": "maxResults" } @@ -1911,7 +3078,13 @@ } }, "traits": { - "smithy.api#documentation": "

Represents the state configuration when an action modifies a property of another element\n within the same component.

" + "smithy.api#documentation": "

Represents the state configuration when an action modifies a property of another\n element within the same component.

" + } + }, + "com.amazonaws.amplifyuibuilder#NumValues": { + "type": "list", + "member": { + "target": "smithy.api#Integer" } }, "com.amazonaws.amplifyuibuilder#Predicate": { @@ -1958,6 +3131,82 @@ "target": "com.amazonaws.amplifyuibuilder#Predicate" } }, + "com.amazonaws.amplifyuibuilder#PutMetadataFlag": { + "type": "operation", + "input": { + "target": "com.amazonaws.amplifyuibuilder#PutMetadataFlagRequest" + }, + "output": { + "target": "smithy.api#Unit" + }, + "errors": [ + { + "target": "com.amazonaws.amplifyuibuilder#InvalidParameterException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#UnauthorizedException" + } + ], + "traits": { + "smithy.api#documentation": "

Stores the metadata information about a feature on a form or view.

", + "smithy.api#http": { + "uri": "/app/{appId}/environment/{environmentName}/metadata/features/{featureName}", + "method": "PUT" + } + } + }, + "com.amazonaws.amplifyuibuilder#PutMetadataFlagBody": { + "type": "structure", + "members": { + "newValue": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The new information to store.

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

Stores the metadata information about a feature on a form or view.

" + } + }, + "com.amazonaws.amplifyuibuilder#PutMetadataFlagRequest": { + "type": "structure", + "members": { + "appId": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The unique ID for the Amplify app.

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

The name of the backend environment that is part of the Amplify app.

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

The name of the feature associated with the metadata.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + }, + "body": { + "target": "com.amazonaws.amplifyuibuilder#PutMetadataFlagBody", + "traits": { + "smithy.api#documentation": "

The metadata information to store.

", + "smithy.api#httpPayload": {}, + "smithy.api#required": {} + } + } + } + }, "com.amazonaws.amplifyuibuilder#RefreshToken": { "type": "operation", "input": { @@ -2060,6 +3309,54 @@ "smithy.api#httpError": 404 } }, + "com.amazonaws.amplifyuibuilder#SectionalElement": { + "type": "structure", + "members": { + "type": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The type of sectional element. Valid values are Heading, Text,\n and Divider.

", + "smithy.api#required": {} + } + }, + "position": { + "target": "com.amazonaws.amplifyuibuilder#FieldPosition", + "traits": { + "smithy.api#documentation": "

Specifies the position of the text in a field for a Text sectional\n element.

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

The text for a Text sectional element.

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

Specifies the size of the font for a Heading sectional element. Valid values\n are 1 | 2 | 3 | 4 | 5 | 6.

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

Specifies the orientation for a Divider sectional element. Valid values are\n horizontal or vertical.

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

Stores the configuration information for a visual helper element for a form. A sectional\n element can be a header, a text block, or a divider. These elements are static and not\n associated with any data.

" + } + }, + "com.amazonaws.amplifyuibuilder#SectionalElementMap": { + "type": "map", + "key": { + "target": "smithy.api#String" + }, + "value": { + "target": "com.amazonaws.amplifyuibuilder#SectionalElement" + } + }, "com.amazonaws.amplifyuibuilder#SensitiveString": { "type": "string", "traits": { @@ -2120,6 +3417,12 @@ "target": "com.amazonaws.amplifyuibuilder#SortProperty" } }, + "com.amazonaws.amplifyuibuilder#StrValues": { + "type": "list", + "member": { + "target": "smithy.api#String" + } + }, "com.amazonaws.amplifyuibuilder#TagKey": { "type": "string", "traits": { @@ -2389,6 +3692,19 @@ ] } }, + "com.amazonaws.amplifyuibuilder#UnauthorizedException": { + "type": "structure", + "members": { + "message": { + "target": "smithy.api#String" + } + }, + "traits": { + "smithy.api#documentation": "

You don't have permission to perform this operation.

", + "smithy.api#error": "client", + "smithy.api#httpError": 401 + } + }, "com.amazonaws.amplifyuibuilder#UpdateComponent": { "type": "operation", "input": { @@ -2559,6 +3875,152 @@ } } }, + "com.amazonaws.amplifyuibuilder#UpdateForm": { + "type": "operation", + "input": { + "target": "com.amazonaws.amplifyuibuilder#UpdateFormRequest" + }, + "output": { + "target": "com.amazonaws.amplifyuibuilder#UpdateFormResponse" + }, + "errors": [ + { + "target": "com.amazonaws.amplifyuibuilder#InternalServerException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#InvalidParameterException" + }, + { + "target": "com.amazonaws.amplifyuibuilder#ResourceConflictException" + } + ], + "traits": { + "aws.iam#requiredActions": [ + "amplify:GetApp" + ], + "smithy.api#documentation": "

Updates an existing form.

", + "smithy.api#http": { + "uri": "/app/{appId}/environment/{environmentName}/forms/{id}", + "method": "PATCH" + }, + "smithy.api#idempotent": {} + } + }, + "com.amazonaws.amplifyuibuilder#UpdateFormData": { + "type": "structure", + "members": { + "name": { + "target": "com.amazonaws.amplifyuibuilder#FormName", + "traits": { + "smithy.api#documentation": "

The name of the form.

" + } + }, + "dataType": { + "target": "com.amazonaws.amplifyuibuilder#FormDataTypeConfig", + "traits": { + "smithy.api#documentation": "

The type of data source to use to create the form.

" + } + }, + "formActionType": { + "target": "com.amazonaws.amplifyuibuilder#FormActionType", + "traits": { + "smithy.api#documentation": "

Specifies whether to perform a create or update action on the form.

" + } + }, + "fields": { + "target": "com.amazonaws.amplifyuibuilder#FieldsMap", + "traits": { + "smithy.api#documentation": "

The configuration information for the form's fields.

" + } + }, + "style": { + "target": "com.amazonaws.amplifyuibuilder#FormStyle", + "traits": { + "smithy.api#documentation": "

The configuration for the form's style.

" + } + }, + "sectionalElements": { + "target": "com.amazonaws.amplifyuibuilder#SectionalElementMap", + "traits": { + "smithy.api#documentation": "

The configuration information for the visual helper elements for the form. These elements\n are not associated with any data.

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

The schema version of the form.

" + } + }, + "cta": { + "target": "com.amazonaws.amplifyuibuilder#FormCTA", + "traits": { + "smithy.api#documentation": "

The FormCTA object that stores the call to action configuration for the\n form.

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

Updates and saves all of the information about a form, based on form ID.

" + } + }, + "com.amazonaws.amplifyuibuilder#UpdateFormRequest": { + "type": "structure", + "members": { + "appId": { + "target": "smithy.api#String", + "traits": { + "smithy.api#documentation": "

The unique ID for the Amplify app.

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

The name of the backend environment that is part of the Amplify app.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + }, + "id": { + "target": "com.amazonaws.amplifyuibuilder#Uuid", + "traits": { + "smithy.api#documentation": "

The unique ID for the form.

", + "smithy.api#httpLabel": {}, + "smithy.api#required": {} + } + }, + "clientToken": { + "target": "smithy.api#String", + "traits": { + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The unique client token.

", + "smithy.api#httpQuery": "clientToken", + "smithy.api#idempotencyToken": {} + } + }, + "updatedForm": { + "target": "com.amazonaws.amplifyuibuilder#UpdateFormData", + "traits": { + "aws.cloudformation#cfnExcludeProperty": {}, + "smithy.api#documentation": "

The request accepts the following data in JSON format.

", + "smithy.api#httpPayload": {}, + "smithy.api#required": {} + } + } + } + }, + "com.amazonaws.amplifyuibuilder#UpdateFormResponse": { + "type": "structure", + "members": { + "entity": { + "target": "com.amazonaws.amplifyuibuilder#Form", + "traits": { + "smithy.api#documentation": "

Describes the configuration of the updated form.

", + "smithy.api#httpPayload": {} + } + } + } + }, "com.amazonaws.amplifyuibuilder#UpdateTheme": { "type": "operation", "input": { @@ -2684,6 +4146,54 @@ }, "com.amazonaws.amplifyuibuilder#Uuid": { "type": "string" + }, + "com.amazonaws.amplifyuibuilder#ValidationsList": { + "type": "list", + "member": { + "target": "com.amazonaws.amplifyuibuilder#FieldValidationConfiguration" + } + }, + "com.amazonaws.amplifyuibuilder#ValueMapping": { + "type": "structure", + "members": { + "displayValue": { + "target": "com.amazonaws.amplifyuibuilder#FormInputValueProperty", + "traits": { + "smithy.api#documentation": "

The value to display for the complex object.

" + } + }, + "value": { + "target": "com.amazonaws.amplifyuibuilder#FormInputValueProperty", + "traits": { + "smithy.api#documentation": "

The complex object.

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

Associates a complex object with a display value. Use ValueMapping to store\n how to represent complex objects when they are displayed.

" + } + }, + "com.amazonaws.amplifyuibuilder#ValueMappingList": { + "type": "list", + "member": { + "target": "com.amazonaws.amplifyuibuilder#ValueMapping" + } + }, + "com.amazonaws.amplifyuibuilder#ValueMappings": { + "type": "structure", + "members": { + "values": { + "target": "com.amazonaws.amplifyuibuilder#ValueMappingList", + "traits": { + "smithy.api#documentation": "

The value and display value pairs.

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

Represents the data binding configuration for a value map.

" + } } } } \ No newline at end of file diff --git a/codegen/sdk-codegen/aws-models/cloudtrail.json b/codegen/sdk-codegen/aws-models/cloudtrail.json index 40f5fd13e22..f2367dc5e59 100644 --- a/codegen/sdk-codegen/aws-models/cloudtrail.json +++ b/codegen/sdk-codegen/aws-models/cloudtrail.json @@ -142,7 +142,7 @@ "Field": { "target": "com.amazonaws.cloudtrail#SelectorField", "traits": { - "smithy.api#documentation": "

\n A field in an event record on which to filter events to be logged. Supported fields include readOnly, eventCategory, \n eventSource (for management events), eventName, resources.type, and resources.ARN.\n

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

\n A field in an event record on which to filter events to be logged. Supported fields include readOnly, eventCategory, \n eventSource (for management events), eventName, resources.type, and resources.ARN.\n

\n ", "smithy.api#required": {} } }, @@ -287,6 +287,92 @@ } } }, + "com.amazonaws.cloudtrail#Channel": { + "type": "structure", + "members": { + "ChannelArn": { + "target": "com.amazonaws.cloudtrail#ChannelArn", + "traits": { + "smithy.api#documentation": "

\n The Amazon Resource Name (ARN) of the channel.\n

" + } + }, + "Name": { + "target": "com.amazonaws.cloudtrail#ChannelName", + "traits": { + "smithy.api#documentation": "

\n The name of the CloudTrail channel. For service-linked channels, the name is aws-service-channel/service-name/custom-suffix where service-name represents the name of the \n Amazon Web Services service that created the channel and custom-suffix represents the suffix created by the Amazon Web Services service.\n

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

\n Contains information about a returned CloudTrail channel.\n

" + } + }, + "com.amazonaws.cloudtrail#ChannelARNInvalidException": { + "type": "structure", + "members": { + "Message": { + "target": "com.amazonaws.cloudtrail#ErrorMessage", + "traits": { + "smithy.api#documentation": "

Brief description of the exception returned by the request.

" + } + } + }, + "traits": { + "aws.protocols#awsQueryError": { + "code": "ChannelARNInvalid", + "httpResponseCode": 400 + }, + "smithy.api#documentation": "

\n The specified channel ARN is not valid or does not map to a channel in your account.\n

", + "smithy.api#error": "client", + "smithy.api#httpError": 400 + } + }, + "com.amazonaws.cloudtrail#ChannelArn": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 3, + "max": 256 + }, + "smithy.api#pattern": "^[a-zA-Z0-9._/\\-:]+$" + } + }, + "com.amazonaws.cloudtrail#ChannelName": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 3, + "max": 128 + }, + "smithy.api#pattern": "^[a-zA-Z0-9._\\-]+$" + } + }, + "com.amazonaws.cloudtrail#ChannelNotFoundException": { + "type": "structure", + "members": { + "Message": { + "target": "com.amazonaws.cloudtrail#ErrorMessage", + "traits": { + "smithy.api#documentation": "

Brief description of the exception returned by the request.

" + } + } + }, + "traits": { + "aws.protocols#awsQueryError": { + "code": "ChannelNotFound", + "httpResponseCode": 404 + }, + "smithy.api#documentation": "

\n The specified channel was not found.\n

", + "smithy.api#error": "client", + "smithy.api#httpError": 404 + } + }, + "com.amazonaws.cloudtrail#Channels": { + "type": "list", + "member": { + "target": "com.amazonaws.cloudtrail#Channel" + } + }, "com.amazonaws.cloudtrail#CloudTrailARNInvalidException": { "type": "structure", "members": { @@ -393,6 +479,9 @@ { "target": "com.amazonaws.cloudtrail#DescribeTrails" }, + { + "target": "com.amazonaws.cloudtrail#GetChannel" + }, { "target": "com.amazonaws.cloudtrail#GetEventDataStore" }, @@ -411,6 +500,9 @@ { "target": "com.amazonaws.cloudtrail#GetTrailStatus" }, + { + "target": "com.amazonaws.cloudtrail#ListChannels" + }, { "target": "com.amazonaws.cloudtrail#ListEventDataStores" }, @@ -579,7 +671,7 @@ "RetentionPeriod": { "target": "com.amazonaws.cloudtrail#RetentionPeriod", "traits": { - "smithy.api#documentation": "

The retention period of the event data store, in days. You can set a retention period of up to 2555 days, \n the equivalent of seven years.

" + "smithy.api#documentation": "

The retention period of the event data store, in days. You can set a retention period of up to 2557 days, \n the equivalent of seven years.

" } }, "TerminationProtectionEnabled": { @@ -1227,6 +1319,55 @@ "smithy.api#documentation": "

Returns the objects or data listed below if successful. Otherwise, returns an error.

" } }, + "com.amazonaws.cloudtrail#Destination": { + "type": "structure", + "members": { + "Type": { + "target": "com.amazonaws.cloudtrail#DestinationType", + "traits": { + "smithy.api#documentation": "

\n The type of service. For service-linked channels, the value is AWS_SERVICE.\n

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

\n The location of the service. For service-linked channels, this is the name of the Amazon Web Services service.\n

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

\n Contains information about the service where CloudTrail delivers events.\n

" + } + }, + "com.amazonaws.cloudtrail#DestinationType": { + "type": "string", + "traits": { + "smithy.api#enum": [ + { + "value": "EVENT_DATA_STORE", + "name": "EVENT_DATA_STORE" + }, + { + "value": "AWS_SERVICE", + "name": "AWS_SERVICE" + } + ] + } + }, + "com.amazonaws.cloudtrail#Destinations": { + "type": "list", + "member": { + "target": "com.amazonaws.cloudtrail#Destination" + }, + "traits": { + "smithy.api#length": { + "min": 1, + "max": 200 + } + } + }, "com.amazonaws.cloudtrail#ErrorMessage": { "type": "string", "traits": { @@ -1399,7 +1540,7 @@ } }, "traits": { - "smithy.api#documentation": "

A storage lake of event data against which you can run complex SQL-based queries. An event data store can include events \n that you have logged on your account from the last 90 to 2555 days \n (about three months to up to seven years). To select events for an event data store, \n use advanced event selectors.

" + "smithy.api#documentation": "

A storage lake of event data against which you can run complex SQL-based queries. An event data store can include events \n that you have logged on your account from the last 90 to 2557 days \n (about three months to up to seven years). To select events for an event data store, \n use advanced event selectors.

" } }, "com.amazonaws.cloudtrail#EventDataStoreARNInvalidException": { @@ -1597,6 +1738,80 @@ "target": "com.amazonaws.cloudtrail#String" } }, + "com.amazonaws.cloudtrail#GetChannel": { + "type": "operation", + "input": { + "target": "com.amazonaws.cloudtrail#GetChannelRequest" + }, + "output": { + "target": "com.amazonaws.cloudtrail#GetChannelResponse" + }, + "errors": [ + { + "target": "com.amazonaws.cloudtrail#ChannelARNInvalidException" + }, + { + "target": "com.amazonaws.cloudtrail#ChannelNotFoundException" + }, + { + "target": "com.amazonaws.cloudtrail#OperationNotPermittedException" + }, + { + "target": "com.amazonaws.cloudtrail#UnsupportedOperationException" + } + ], + "traits": { + "smithy.api#documentation": "

\n Returns the specified CloudTrail service-linked channel. Amazon Web Services services create service-linked channels to view CloudTrail events.\n

", + "smithy.api#idempotent": {} + } + }, + "com.amazonaws.cloudtrail#GetChannelRequest": { + "type": "structure", + "members": { + "Channel": { + "target": "com.amazonaws.cloudtrail#ChannelArn", + "traits": { + "smithy.api#documentation": "

\n The Amazon Resource Name (ARN) of the CloudTrail service-linked channel.\n

", + "smithy.api#required": {} + } + } + } + }, + "com.amazonaws.cloudtrail#GetChannelResponse": { + "type": "structure", + "members": { + "ChannelArn": { + "target": "com.amazonaws.cloudtrail#ChannelArn", + "traits": { + "smithy.api#documentation": "

\n The ARN of the CloudTrail service-linked channel.\n

" + } + }, + "Name": { + "target": "com.amazonaws.cloudtrail#ChannelName", + "traits": { + "smithy.api#documentation": "

\n The name of the CloudTrail service-linked channel. For service-linked channels, the value is aws-service-channel/service-name/custom-suffix \n where service-name represents the name of the \n Amazon Web Services service that created the channel and custom-suffix represents the suffix generated by the Amazon Web Services service.\n

" + } + }, + "Source": { + "target": "com.amazonaws.cloudtrail#Source", + "traits": { + "smithy.api#documentation": "

\n The trail or event data store for the CloudTrail service-linked channel.\n

" + } + }, + "SourceConfig": { + "target": "com.amazonaws.cloudtrail#SourceConfig", + "traits": { + "smithy.api#documentation": "

\n Provides information about the advanced event selectors configured for the service-linked channel, and whether the service-linked channel applies to all regions or one region.\n

" + } + }, + "Destinations": { + "target": "com.amazonaws.cloudtrail#Destinations", + "traits": { + "smithy.api#documentation": "

\n The Amazon Web Services service that created the CloudTrail service-linked channel.\n

" + } + } + } + }, "com.amazonaws.cloudtrail#GetEventDataStore": { "type": "operation", "input": { @@ -2837,6 +3052,79 @@ "smithy.api#httpError": 400 } }, + "com.amazonaws.cloudtrail#ListChannels": { + "type": "operation", + "input": { + "target": "com.amazonaws.cloudtrail#ListChannelsRequest" + }, + "output": { + "target": "com.amazonaws.cloudtrail#ListChannelsResponse" + }, + "errors": [ + { + "target": "com.amazonaws.cloudtrail#InvalidNextTokenException" + }, + { + "target": "com.amazonaws.cloudtrail#OperationNotPermittedException" + }, + { + "target": "com.amazonaws.cloudtrail#UnsupportedOperationException" + } + ], + "traits": { + "smithy.api#documentation": "

\n Returns all CloudTrail channels.\n

", + "smithy.api#idempotent": {}, + "smithy.api#paginated": { + "inputToken": "NextToken", + "outputToken": "NextToken", + "pageSize": "MaxResults" + } + } + }, + "com.amazonaws.cloudtrail#ListChannelsMaxResultsCount": { + "type": "integer", + "traits": { + "smithy.api#box": {}, + "smithy.api#range": { + "min": 1, + "max": 1000 + } + } + }, + "com.amazonaws.cloudtrail#ListChannelsRequest": { + "type": "structure", + "members": { + "MaxResults": { + "target": "com.amazonaws.cloudtrail#ListChannelsMaxResultsCount", + "traits": { + "smithy.api#documentation": "

\n The maximum number of CloudTrail channels to display on a single page.\n

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

\n A token you can use to get the next page of results.\n

" + } + } + } + }, + "com.amazonaws.cloudtrail#ListChannelsResponse": { + "type": "structure", + "members": { + "Channels": { + "target": "com.amazonaws.cloudtrail#Channels", + "traits": { + "smithy.api#documentation": "

\n The list of CloudTrail channels.\n

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

\n A token used to get the next page of results.\n

" + } + } + } + }, "com.amazonaws.cloudtrail#ListEventDataStores": { "type": "operation", "input": { @@ -3230,7 +3518,7 @@ "NextToken": { "target": "com.amazonaws.cloudtrail#String", "traits": { - "smithy.api#documentation": "

The token to use to get the next page of results after a previous API call. This token must be passed \n in with the same parameters that were specified in the the original call. For example, if the original \n call specified an AttributeKey of 'Username' with a value of 'root', the call with NextToken should \n include those same parameters.

" + "smithy.api#documentation": "

The token to use to get the next page of results after a previous API call. This token must be passed \n in with the same parameters that were specified in the original call. For example, if the original \n call specified an AttributeKey of 'Username' with a value of 'root', the call with NextToken should \n include those same parameters.

" } } } @@ -3252,6 +3540,16 @@ } } }, + "com.amazonaws.cloudtrail#Location": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 3, + "max": 1024 + }, + "smithy.api#pattern": "^[a-zA-Z0-9._/\\-:]+$" + } + }, "com.amazonaws.cloudtrail#Long": { "type": "long", "traits": { @@ -3403,7 +3701,7 @@ "NextToken": { "target": "com.amazonaws.cloudtrail#NextToken", "traits": { - "smithy.api#documentation": "

The token to use to get the next page of results after a previous API call. This token must be passed in with the same parameters that were specified in the the original call. \n For example, if the original call specified an AttributeKey of 'Username' with a value of 'root', the call with NextToken should include those same parameters.

" + "smithy.api#documentation": "

The token to use to get the next page of results after a previous API call. This token must be passed in with the same parameters that were specified in the original call. \n For example, if the original call specified an AttributeKey of 'Username' with a value of 'root', the call with NextToken should include those same parameters.

" } } }, @@ -4368,6 +4666,36 @@ "smithy.api#pattern": ".*" } }, + "com.amazonaws.cloudtrail#Source": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 1, + "max": 256 + }, + "smithy.api#pattern": ".*" + } + }, + "com.amazonaws.cloudtrail#SourceConfig": { + "type": "structure", + "members": { + "ApplyToAllRegions": { + "target": "com.amazonaws.cloudtrail#Boolean", + "traits": { + "smithy.api#documentation": "

\n Specifies whether the service-linked channel applies to one region or all regions. \n

" + } + }, + "AdvancedEventSelectors": { + "target": "com.amazonaws.cloudtrail#AdvancedEventSelectors", + "traits": { + "smithy.api#documentation": "

\n The advanced event selectors configured for the service-linked channel.\n

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

\n Contains configuration information about the service-linked channel.\n

" + } + }, "com.amazonaws.cloudtrail#StartLogging": { "type": "operation", "input": { @@ -4910,7 +5238,7 @@ } ], "traits": { - "smithy.api#documentation": "

Updates an event data store. The required EventDataStore value is an ARN or the ID portion of the ARN. \n Other parameters are optional, but at least one optional parameter must be specified, or CloudTrail throws an error. \n RetentionPeriod is in days, and valid values are integers between 90 and 2555. \n By default, TerminationProtection is enabled. AdvancedEventSelectors includes or excludes management \n and data events in your event data store; for more information about AdvancedEventSelectors, see \n PutEventSelectorsRequest$AdvancedEventSelectors.

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

Updates an event data store. The required EventDataStore value is an ARN or the ID portion of the ARN. \n Other parameters are optional, but at least one optional parameter must be specified, or CloudTrail throws an error. \n RetentionPeriod is in days, and valid values are integers between 90 and 2557. \n By default, TerminationProtection is enabled. AdvancedEventSelectors includes or excludes management \n and data events in your event data store; for more information about AdvancedEventSelectors, see \n PutEventSelectorsRequest$AdvancedEventSelectors.

", "smithy.api#idempotent": {} } }, diff --git a/codegen/sdk-codegen/aws-models/customer-profiles.json b/codegen/sdk-codegen/aws-models/customer-profiles.json index 6b2885664eb..e9318fd1082 100644 --- a/codegen/sdk-codegen/aws-models/customer-profiles.json +++ b/codegen/sdk-codegen/aws-models/customer-profiles.json @@ -68,7 +68,7 @@ } ], "traits": { - "smithy.api#documentation": "

Associates a new key value with a specific profile, such as a Contact Trace Record (CTR)\n ContactId.

\n

A profile object can have a single unique key and any number of additional keys that can\n be used to identify the profile that it belongs to.

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

Associates a new key value with a specific profile, such as a Contact Record\n ContactId.

\n

A profile object can have a single unique key and any number of additional keys that can\n be used to identify the profile that it belongs to.

", "smithy.api#http": { "method": "POST", "uri": "/domains/{DomainName}/profiles/keys", @@ -2400,6 +2400,12 @@ "traits": { "smithy.api#documentation": "

Unique identifier for the workflow.

" } + }, + "IsUnstructured": { + "target": "com.amazonaws.customerprofiles#optionalBoolean", + "traits": { + "smithy.api#documentation": "

Boolean to indicate if the Flow associated with the Integration is created via Appflow \n console or with ObjectTypeName equals _unstructured via API/CLI in flowDefinition

" + } } } }, @@ -3504,6 +3510,12 @@ "traits": { "smithy.api#documentation": "

Unique identifier for the workflow.

" } + }, + "IsUnstructured": { + "target": "com.amazonaws.customerprofiles#optionalBoolean", + "traits": { + "smithy.api#documentation": "

Boolean to indicate if the Flow associated with the Integration is created via Appflow\n console or with ObjectTypeName equals _unstructured via API/CLI in flowDefinition

" + } } }, "traits": { @@ -4812,7 +4824,7 @@ } ], "traits": { - "smithy.api#documentation": "

Adds an integration between the service and a third-party service, which includes\n Amazon AppFlow and Amazon Connect.

\n

An integration can belong to only one domain.

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

Adds an integration between the service and a third-party service, which includes\n Amazon AppFlow and Amazon Connect.

\n

An integration can belong to only one domain.

\n

To add or remove tags on an existing Integration, see TagResource\n /\n UntagResource.

", "smithy.api#http": { "method": "PUT", "uri": "/domains/{DomainName}/integrations", @@ -4917,6 +4929,12 @@ "traits": { "smithy.api#documentation": "

Unique identifier for the workflow.

" } + }, + "IsUnstructured": { + "target": "com.amazonaws.customerprofiles#optionalBoolean", + "traits": { + "smithy.api#documentation": "

Boolean to indicate if the Flow associated with the Integration is created via Appflow \n console or with ObjectTypeName equals _unstructured via API/CLI in flowDefinition

" + } } } }, @@ -4946,7 +4964,7 @@ } ], "traits": { - "smithy.api#documentation": "

Adds additional objects to customer profiles of a given ObjectType.

\n

When adding a specific profile object, like a Contact Trace Record (CTR), an inferred\n profile can get created if it is not mapped to an existing profile. The resulting profile\n will only have a phone number populated in the standard ProfileObject. Any additional CTRs\n with the same phone number will be mapped to the same inferred profile.

\n

When a ProfileObject is created and if a ProfileObjectType already exists for the\n ProfileObject, it will provide data to a standard profile depending on the\n ProfileObjectType definition.

\n

PutProfileObject needs an ObjectType, which can be created using\n PutProfileObjectType.

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

Adds additional objects to customer profiles of a given ObjectType.

\n

When adding a specific profile object, like a Contact Record, an inferred profile can\n get created if it is not mapped to an existing profile. The resulting profile will only\n have a phone number populated in the standard ProfileObject. Any additional Contact Records\n with the same phone number will be mapped to the same inferred profile.

\n

When a ProfileObject is created and if a ProfileObjectType already exists for the\n ProfileObject, it will provide data to a standard profile depending on the\n ProfileObjectType definition.

\n

PutProfileObject needs an ObjectType, which can be created using\n PutProfileObjectType.

", "smithy.api#http": { "method": "PUT", "uri": "/domains/{DomainName}/profiles/objects", @@ -5018,7 +5036,7 @@ } ], "traits": { - "smithy.api#documentation": "

Defines a ProfileObjectType.

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

Defines a ProfileObjectType.

\n

To add or remove tags on an existing ObjectType, see \n TagResource/UntagResource.

", "smithy.api#http": { "method": "PUT", "uri": "/domains/{DomainName}/object-types/{ObjectTypeName}", @@ -6356,7 +6374,7 @@ } ], "traits": { - "smithy.api#documentation": "

Updates the properties of a domain, including creating or selecting a dead letter queue\n or an encryption key.

\n

After a domain is created, the name can’t be changed.

\n

Use this API or CreateDomain to\n enable identity\n resolution: set Matching to true.

\n

To prevent cross-service impersonation when you call this API, see Cross-service confused deputy prevention for sample policies that you should\n apply.

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

Updates the properties of a domain, including creating or selecting a dead letter queue\n or an encryption key.

\n

After a domain is created, the name can’t be changed.

\n

Use this API or CreateDomain to\n enable identity\n resolution: set Matching to true.

\n

To prevent cross-service impersonation when you call this API, see Cross-service confused deputy prevention for sample policies that you should\n apply.

\n

To add or remove tags on an existing Domain, see TagResource/UntagResource.

", "smithy.api#http": { "method": "PUT", "uri": "/domains/{DomainName}", diff --git a/codegen/sdk-codegen/aws-models/dataexchange.json b/codegen/sdk-codegen/aws-models/dataexchange.json index 084be901e85..8d318129af2 100644 --- a/codegen/sdk-codegen/aws-models/dataexchange.json +++ b/codegen/sdk-codegen/aws-models/dataexchange.json @@ -1,33 +1,5 @@ { "smithy": "1.0", - "metadata": { - "suppressions": [ - { - "id": "HttpMethodSemantics", - "namespace": "*" - }, - { - "id": "HttpResponseCodeSemantics", - "namespace": "*" - }, - { - "id": "PaginatedTrait", - "namespace": "*" - }, - { - "id": "HttpHeaderTrait", - "namespace": "*" - }, - { - "id": "HttpUriConflict", - "namespace": "*" - }, - { - "id": "Service", - "namespace": "*" - } - ] - }, "shapes": { "com.amazonaws.dataexchange#AccessDeniedException": { "type": "structure", @@ -61,10 +33,7 @@ } }, "com.amazonaws.dataexchange#ApiDescription": { - "type": "string", - "traits": { - "smithy.api#documentation": "

The description of the API.

" - } + "type": "string" }, "com.amazonaws.dataexchange#ApiGatewayApiAsset": { "type": "structure", @@ -129,10 +98,7 @@ } }, "com.amazonaws.dataexchange#Arn": { - "type": "string", - "traits": { - "smithy.api#documentation": "

An Amazon Resource Name (ARN) that uniquely identifies an AWS resource.

" - } + "type": "string" }, "com.amazonaws.dataexchange#AssetDestinationEntry": { "type": "structure", @@ -266,10 +232,7 @@ } }, "com.amazonaws.dataexchange#AssetName": { - "type": "string", - "traits": { - "smithy.api#documentation": "

The name of the asset. When importing from Amazon S3, the S3 object key is used as the asset name. When exporting to Amazon S3, the asset name is used as default target S3 object key. When importing from Amazon API Gateway API, the API name is used as the asset name. When importing from Amazon Redshift, the datashare name is used as the asset name.

" - } + "type": "string" }, "com.amazonaws.dataexchange#AssetSourceEntry": { "type": "structure", @@ -296,7 +259,6 @@ "com.amazonaws.dataexchange#AssetType": { "type": "string", "traits": { - "smithy.api#documentation": "

The type of asset that is added to a data set.

", "smithy.api#enum": [ { "value": "S3_SNAPSHOT", @@ -360,6 +322,9 @@ "input": { "target": "com.amazonaws.dataexchange#CancelJobRequest" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.dataexchange#ConflictException" @@ -527,9 +492,6 @@ "smithy.api#documentation": "

A data set tag is an optional label that you can assign to a data set when you create it. Each tag consists of a key and an optional value, both of which you define. When you use tagging, you can also use tag-based access control in IAM policies to control access to these data sets and revisions.

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

The request body for CreateDataSet.

" } }, "com.amazonaws.dataexchange#CreateDataSetResponse": { @@ -654,9 +616,6 @@ "smithy.api#required": {} } } - }, - "traits": { - "smithy.api#documentation": "

The request body for CreateEventAction.

" } }, "com.amazonaws.dataexchange#CreateEventActionResponse": { @@ -754,9 +713,6 @@ "smithy.api#required": {} } } - }, - "traits": { - "smithy.api#documentation": "

The request body for CreateJob.

" } }, "com.amazonaws.dataexchange#CreateJobResponse": { @@ -869,9 +825,6 @@ "smithy.api#documentation": "

A revision tag is an optional label that you can assign to a revision when you create it. Each tag consists of a key and an optional value, both of which you define. When you use tagging, you can also use tag-based access control in IAM policies to control access to these data sets and revisions.

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

The request body for CreateRevision.

" } }, "com.amazonaws.dataexchange#CreateRevisionResponse": { @@ -904,7 +857,7 @@ "Finalized": { "target": "com.amazonaws.dataexchange#__boolean", "traits": { - "smithy.api#documentation": "

To publish a revision to a data set in a product, the revision must first be finalized. Finalizing a revision tells AWS Data Exchange that your changes to the assets in the revision are complete. After it's in this read-only state, you can publish the revision to your products.

Finalized revisions can be published through the AWS Data Exchange console or the AWS Marketplace Catalog API, using the StartChangeSet AWS Marketplace Catalog API action. When using the API, revisions are uniquely identified by their ARN.

" + "smithy.api#documentation": "

To publish a revision to a data set in a product, the revision must first be finalized. Finalizing a revision tells AWS Data Exchange that your changes to the assets in the revision are complete. After it's in this read-only state, you can publish the revision to your products. Finalized revisions can be published through the AWS Data Exchange console or the AWS Marketplace Catalog API, using the StartChangeSet AWS Marketplace Catalog API action. When using the API, revisions are uniquely identified by their ARN.

" } }, "Id": { @@ -957,7 +910,6 @@ "aws.api#service": { "sdkId": "DataExchange", "arnNamespace": "dataexchange", - "cloudFormationName": "DataExchange", "cloudTrailEventSource": "dataexchange.amazonaws.com", "endpointPrefix": "dataexchange" }, @@ -965,7 +917,7 @@ "name": "dataexchange" }, "aws.protocols#restJson1": {}, - "smithy.api#documentation": "

AWS Data Exchange is a service that makes it easy for AWS customers to exchange data in the cloud. You can use the AWS Data Exchange APIs to create, update, manage, and access file-based data set in the AWS Cloud.

As a subscriber, you can view and access the data sets that you have an entitlement to through a subscription. You can use the APIS to download or copy your entitled data sets to Amazon S3 for use across a variety of AWS analytics and machine learning services.

As a provider, you can create and manage your data sets that you would like to publish to a product. Being able to package and provide your data sets into products requires a few steps to determine eligibility. For more information, visit the AWS Data Exchange User Guide.

A data set is a collection of data that can be changed or updated over time. Data sets can be updated using revisions, which represent a new version or incremental change to a data set. A revision contains one or more assets. An asset in AWS Data Exchange is a piece of data that can be stored as an Amazon S3 object. The asset can be a structured data file, an image file, or some other data file. Jobs are asynchronous import or export operations used to create or copy assets.

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

AWS Data Exchange is a service that makes it easy for AWS customers to exchange data in the cloud. You can use the AWS Data Exchange APIs to create, update, manage, and access file-based data set in the AWS Cloud.

\n

As a subscriber, you can view and access the data sets that you have an entitlement to through a subscription. You can use the APIS to download or copy your entitled data sets to Amazon S3 for use across a variety of AWS analytics and machine learning services.

\n

As a provider, you can create and manage your data sets that you would like to publish to a product. Being able to package and provide your data sets into products requires a few steps to determine eligibility. For more information, visit the AWS Data Exchange User Guide.

\n

A data set is a collection of data that can be changed or updated over time. Data sets can be updated using revisions, which represent a new version or incremental change to a data set. A revision contains one or more assets. An asset in AWS Data Exchange is a piece of data that can be stored as an Amazon S3 object. The asset can be a structured data file, an image file, or some other data file. Jobs are asynchronous import or export operations used to create or copy assets.

", "smithy.api#title": "AWS Data Exchange" }, "version": "2017-07-25", @@ -1140,6 +1092,9 @@ "input": { "target": "com.amazonaws.dataexchange#DeleteAssetRequest" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.dataexchange#AccessDeniedException" @@ -1203,6 +1158,9 @@ "input": { "target": "com.amazonaws.dataexchange#DeleteDataSetRequest" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.dataexchange#AccessDeniedException" @@ -1250,6 +1208,9 @@ "input": { "target": "com.amazonaws.dataexchange#DeleteEventActionRequest" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.dataexchange#InternalServerException" @@ -1291,6 +1252,9 @@ "input": { "target": "com.amazonaws.dataexchange#DeleteRevisionRequest" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.dataexchange#AccessDeniedException" @@ -1342,10 +1306,7 @@ } }, "com.amazonaws.dataexchange#Description": { - "type": "string", - "traits": { - "smithy.api#documentation": "

A description of a resource.

" - } + "type": "string" }, "com.amazonaws.dataexchange#Details": { "type": "structure", @@ -1666,7 +1627,7 @@ } }, "traits": { - "smithy.api#documentation": "

Encryption configuration of the export job. Includes the encryption type in addition to the AWS KMS key. The KMS key is only necessary if you chose the KMS encryption. type.

" + "smithy.api#documentation": "

Encryption configuration of the export job. Includes the encryption type in addition to the AWS KMS key. The KMS key is only necessary if you chose the KMS encryption type.

" } }, "com.amazonaws.dataexchange#GetAsset": { @@ -1697,7 +1658,8 @@ "method": "GET", "uri": "/v1/data-sets/{DataSetId}/revisions/{RevisionId}/assets/{AssetId}", "code": 200 - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#GetAssetRequest": { @@ -1822,7 +1784,8 @@ "method": "GET", "uri": "/v1/data-sets/{DataSetId}", "code": 200 - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#GetDataSetRequest": { @@ -1937,7 +1900,8 @@ "method": "GET", "uri": "/v1/event-actions/{EventActionId}", "code": 200 - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#GetEventActionRequest": { @@ -2022,7 +1986,8 @@ "method": "GET", "uri": "/v1/jobs/{JobId}", "code": 200 - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#GetJobRequest": { @@ -2119,7 +2084,8 @@ "method": "GET", "uri": "/v1/data-sets/{DataSetId}/revisions/{RevisionId}", "code": 200 - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#GetRevisionRequest": { @@ -2173,7 +2139,7 @@ "Finalized": { "target": "com.amazonaws.dataexchange#__boolean", "traits": { - "smithy.api#documentation": "

To publish a revision to a data set in a product, the revision must first be finalized. Finalizing a revision tells AWS Data Exchange that your changes to the assets in the revision are complete. After it's in this read-only state, you can publish the revision to your products.

Finalized revisions can be published through the AWS Data Exchange console or the AWS Marketplace Catalog API, using the StartChangeSet AWS Marketplace Catalog API action. When using the API, revisions are uniquely identified by their ARN.

" + "smithy.api#documentation": "

To publish a revision to a data set in a product, the revision must first be finalized. Finalizing a revision tells AWS Data Exchange that your changes to the assets in the revision are complete. After it's in this read-only state, you can publish the revision to your products. Finalized revisions can be published through the AWS Data Exchange console or the AWS Marketplace Catalog API, using the StartChangeSet AWS Marketplace Catalog API action. When using the API, revisions are uniquely identified by their ARN.

" } }, "Id": { @@ -2221,10 +2187,7 @@ } }, "com.amazonaws.dataexchange#Id": { - "type": "string", - "traits": { - "smithy.api#documentation": "

A unique identifier.

" - } + "type": "string" }, "com.amazonaws.dataexchange#ImportAssetFromApiGatewayApiRequestDetails": { "type": "structure", @@ -2482,27 +2445,27 @@ "AssetSources": { "target": "com.amazonaws.dataexchange#ListOfRedshiftDataShareAssetSourceEntry", "traits": { - "smithy.api#documentation": "A list of Amazon Redshift datashare assets.", + "smithy.api#documentation": "

A list of Amazon Redshift datashare assets.

", "smithy.api#required": {} } }, "DataSetId": { "target": "com.amazonaws.dataexchange#Id", "traits": { - "smithy.api#documentation": "The unique identifier for the data set associated with this import job.", + "smithy.api#documentation": "

The unique identifier for the data set associated with this import job.

", "smithy.api#required": {} } }, "RevisionId": { "target": "com.amazonaws.dataexchange#Id", "traits": { - "smithy.api#documentation": "The unique identifier for the revision associated with this import job.", + "smithy.api#documentation": "

The unique identifier for the revision associated with this import job.

", "smithy.api#required": {} } } }, "traits": { - "smithy.api#documentation": "Details from an import from Amazon Redshift datashare request." + "smithy.api#documentation": "

Details from an import from Amazon Redshift datashare request.

" } }, "com.amazonaws.dataexchange#ImportAssetsFromRedshiftDataSharesResponseDetails": { @@ -2511,27 +2474,27 @@ "AssetSources": { "target": "com.amazonaws.dataexchange#ListOfRedshiftDataShareAssetSourceEntry", "traits": { - "smithy.api#documentation": "A list of Amazon Redshift datashare asset sources.", + "smithy.api#documentation": "

A list of Amazon Redshift datashare asset sources.

", "smithy.api#required": {} } }, "DataSetId": { "target": "com.amazonaws.dataexchange#Id", "traits": { - "smithy.api#documentation": "The unique identifier for the data set associated with this import job.", + "smithy.api#documentation": "

The unique identifier for the data set associated with this import job.

", "smithy.api#required": {} } }, "RevisionId": { "target": "com.amazonaws.dataexchange#Id", "traits": { - "smithy.api#documentation": "The unique identifier for the revision associated with this import job.", + "smithy.api#documentation": "

The unique identifier for the revision associated with this import job.

", "smithy.api#required": {} } } }, "traits": { - "smithy.api#documentation": "Details from an import from Amazon Redshift datashare response." + "smithy.api#documentation": "

Details from an import from Amazon Redshift datashare response.

" } }, "com.amazonaws.dataexchange#ImportAssetsFromS3RequestDetails": { @@ -2598,13 +2561,13 @@ "Message": { "target": "com.amazonaws.dataexchange#__string", "traits": { - "smithy.api#documentation": "The message identifying the service exception that occurred.", + "smithy.api#documentation": "

The message identifying the service exception that occurred.

", "smithy.api#required": {} } } }, "traits": { - "smithy.api#documentation": "An exception occurred with the service.", + "smithy.api#documentation": "

An exception occurred with the service.

", "smithy.api#error": "server", "smithy.api#httpError": 500 } @@ -2669,7 +2632,7 @@ } }, "traits": { - "smithy.api#documentation": "AWS Data Exchange Jobs are asynchronous import or export operations used to create or copy assets. A data set owner can both import and export as they see fit. Someone with an entitlement to a data set can only export. Jobs are deleted 90 days after they are created." + "smithy.api#documentation": "

AWS Data Exchange Jobs are asynchronous import or export operations used to create or copy assets. A data set owner can both import and export as they see fit. Someone with an entitlement to a data set can only export. Jobs are deleted 90 days after they are created.

" } }, "com.amazonaws.dataexchange#JobError": { @@ -2678,7 +2641,7 @@ "Code": { "target": "com.amazonaws.dataexchange#Code", "traits": { - "smithy.api#documentation": "The code for the job error.", + "smithy.api#documentation": "

The code for the job error.

", "smithy.api#required": {} } }, @@ -2697,37 +2660,36 @@ "LimitValue": { "target": "com.amazonaws.dataexchange#__double", "traits": { - "smithy.api#documentation": "The value of the exceeded limit." + "smithy.api#documentation": "

The value of the exceeded limit.

" } }, "Message": { "target": "com.amazonaws.dataexchange#__string", "traits": { - "smithy.api#documentation": "The message related to the job error.", + "smithy.api#documentation": "

The message related to the job error.

", "smithy.api#required": {} } }, "ResourceId": { "target": "com.amazonaws.dataexchange#__string", "traits": { - "smithy.api#documentation": "The unique identifier for the resource related to the error." + "smithy.api#documentation": "

The unique identifier for the resource related to the error.

" } }, "ResourceType": { "target": "com.amazonaws.dataexchange#JobErrorResourceTypes", "traits": { - "smithy.api#documentation": "The type of resource related to the error." + "smithy.api#documentation": "

The type of resource related to the error.

" } } }, "traits": { - "smithy.api#documentation": "An error that occurred with the job request." + "smithy.api#documentation": "

An error that occurred with the job request.

" } }, "com.amazonaws.dataexchange#JobErrorLimitName": { "type": "string", "traits": { - "smithy.api#documentation": "The name of the limit that was reached.", "smithy.api#enum": [ { "value": "Assets per revision", @@ -2747,7 +2709,6 @@ "com.amazonaws.dataexchange#JobErrorResourceTypes": { "type": "string", "traits": { - "smithy.api#documentation": "The types of resource which the job error can apply to.", "smithy.api#enum": [ { "value": "REVISION", @@ -2893,7 +2854,8 @@ "outputToken": "NextToken", "items": "Revisions", "pageSize": "MaxResults" - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#ListDataSetRevisionsRequest": { @@ -2974,7 +2936,8 @@ "outputToken": "NextToken", "items": "DataSets", "pageSize": "MaxResults" - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#ListDataSetsRequest": { @@ -3054,7 +3017,8 @@ "outputToken": "NextToken", "items": "EventActions", "pageSize": "MaxResults" - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#ListEventActionsRequest": { @@ -3134,7 +3098,8 @@ "outputToken": "NextToken", "items": "Jobs", "pageSize": "MaxResults" - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#ListJobsRequest": { @@ -3191,9 +3156,6 @@ "type": "list", "member": { "target": "com.amazonaws.dataexchange#AssetDestinationEntry" - }, - "traits": { - "smithy.api#documentation": "

The destination where the assets will be exported.

" } }, "com.amazonaws.dataexchange#ListOfAssetEntry": { @@ -3206,9 +3168,6 @@ "type": "list", "member": { "target": "com.amazonaws.dataexchange#AssetSourceEntry" - }, - "traits": { - "smithy.api#documentation": "

The list of sources for the assets.

" } }, "com.amazonaws.dataexchange#ListOfDataSetEntry": { @@ -3239,18 +3198,12 @@ "type": "list", "member": { "target": "com.amazonaws.dataexchange#RedshiftDataShareAssetSourceEntry" - }, - "traits": { - "smithy.api#documentation": "A list of Amazon Redshift datashare asset sources." } }, "com.amazonaws.dataexchange#ListOfRevisionDestinationEntry": { "type": "list", "member": { "target": "com.amazonaws.dataexchange#RevisionDestinationEntry" - }, - "traits": { - "smithy.api#documentation": "

The destination where the assets in the revision will be exported.

" } }, "com.amazonaws.dataexchange#ListOfRevisionEntry": { @@ -3299,7 +3252,8 @@ "outputToken": "NextToken", "items": "Assets", "pageSize": "MaxResults" - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#ListRevisionAssetsRequest": { @@ -3368,7 +3322,8 @@ "method": "GET", "uri": "/tags/{ResourceArn}", "code": 200 - } + }, + "smithy.api#readonly": {} } }, "com.amazonaws.dataexchange#ListTagsForResourceRequest": { @@ -3390,7 +3345,7 @@ "Tags": { "target": "com.amazonaws.dataexchange#MapOf__string", "traits": { - "smithy.api#documentation": "A label that consists of a customer-defined key and an optional value.", + "smithy.api#documentation": "

A label that consists of a customer-defined key and an optional value.

", "smithy.api#jsonName": "tags" } } @@ -3415,21 +3370,14 @@ } }, "com.amazonaws.dataexchange#Name": { - "type": "string", - "traits": { - "smithy.api#documentation": "The name of the model." - } + "type": "string" }, "com.amazonaws.dataexchange#NextToken": { - "type": "string", - "traits": { - "smithy.api#documentation": "

The token value retrieved from a previous call to access the next page of results.

" - } + "type": "string" }, "com.amazonaws.dataexchange#Origin": { "type": "string", "traits": { - "smithy.api#documentation": "

A property that defines the data set as OWNED by the account (for providers) or ENTITLED to the account (for subscribers). When an owned data set is published in a product, AWS Data Exchange creates a copy of the data set. Subscribers can access that copy of the data set as an entitled data set.

", "smithy.api#enum": [ { "value": "OWNED", @@ -3474,13 +3422,13 @@ "Arn": { "target": "com.amazonaws.dataexchange#__string", "traits": { - "smithy.api#documentation": "The Amazon Resource Name (ARN) of the datashare asset.", + "smithy.api#documentation": "

The Amazon Resource Name (ARN) of the datashare asset.

", "smithy.api#required": {} } } }, "traits": { - "smithy.api#documentation": "The Amazon Redshift datashare asset." + "smithy.api#documentation": "

The Amazon Redshift datashare asset.

" } }, "com.amazonaws.dataexchange#RedshiftDataShareAssetSourceEntry": { @@ -3489,7 +3437,7 @@ "DataShareArn": { "target": "com.amazonaws.dataexchange#__string", "traits": { - "smithy.api#documentation": "The Amazon Resource Name (ARN) of the datashare asset.", + "smithy.api#documentation": "

The Amazon Resource Name (ARN) of the datashare asset.

", "smithy.api#required": {} } } @@ -3522,13 +3470,13 @@ "ImportAssetFromSignedUrl": { "target": "com.amazonaws.dataexchange#ImportAssetFromSignedUrlRequestDetails", "traits": { - "smithy.api#documentation": "

Details about the import from signed URL request.

" + "smithy.api#documentation": "

Details about the import from Amazon S3 request.

" } }, "ImportAssetsFromS3": { "target": "com.amazonaws.dataexchange#ImportAssetsFromS3RequestDetails", "traits": { - "smithy.api#documentation": "

Details about the import from Amazon S3 request.

" + "smithy.api#documentation": "

Information about the import asset from API Gateway API request.

" } }, "ImportAssetsFromRedshiftDataShares": { @@ -3540,7 +3488,7 @@ "ImportAssetFromApiGatewayApi": { "target": "com.amazonaws.dataexchange#ImportAssetFromApiGatewayApiRequestDetails", "traits": { - "smithy.api#documentation": "

Information about the import asset from API Gateway API request.

" + "smithy.api#documentation": "

Details about the import from signed URL request.

" } } }, @@ -3715,7 +3663,7 @@ "Finalized": { "target": "com.amazonaws.dataexchange#__boolean", "traits": { - "smithy.api#documentation": "

To publish a revision to a data set in a product, the revision must first be finalized. Finalizing a revision tells AWS Data Exchange that your changes to the assets in the revision are complete. After it's in this read-only state, you can publish the revision to your products.

Finalized revisions can be published through the AWS Data Exchange console or the AWS Marketplace Catalog API, using the StartChangeSet AWS Marketplace Catalog API action. When using the API, revisions are uniquely identified by their ARN.

" + "smithy.api#documentation": "

To publish a revision to a data set in a product, the revision must first be finalized. Finalizing a revision tells AWS Data Exchange that your changes to the assets in the revision are complete. After it's in this read-only state, you can publish the revision to your products. Finalized revisions can be published through the AWS Data Exchange console or the AWS Marketplace Catalog API, using the StartChangeSet AWS Marketplace Catalog API action. When using the API, revisions are uniquely identified by their ARN.

" } }, "Id": { @@ -3839,9 +3787,6 @@ "smithy.api#required": {} } } - }, - "traits": { - "smithy.api#documentation": "

The request body for RevokeRevision.

" } }, "com.amazonaws.dataexchange#RevokeRevisionResponse": { @@ -3874,7 +3819,7 @@ "Finalized": { "target": "com.amazonaws.dataexchange#__boolean", "traits": { - "smithy.api#documentation": "

To publish a revision to a data set in a product, the revision must first be finalized. Finalizing a revision tells AWS Data Exchange that changes to the assets in the revision are complete. After it's in this read-only state, you can publish the revision to your products.

Finalized revisions can be published through the AWS Data Exchange console or the AWS Marketplace Catalog API, using the StartChangeSet AWS Marketplace Catalog API action. When using the API, revisions are uniquely identified by their ARN.

" + "smithy.api#documentation": "

To publish a revision to a data set in a product, the revision must first be finalized. Finalizing a revision tells AWS Data Exchange that changes to the assets in the revision are complete. After it's in this read-only state, you can publish the revision to your products. Finalized revisions can be published through the AWS Data Exchange console or the AWS Marketplace Catalog API, using the StartChangeSet AWS Marketplace Catalog API action. When using the API, revisions are uniquely identified by their ARN.

" } }, "Id": { @@ -4017,7 +3962,7 @@ "Path": { "target": "com.amazonaws.dataexchange#__string", "traits": { - "smithy.api#documentation": "

URI path value for the API request. Alternatively, you can set the URI path directly by invoking /v1/{pathValue}

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

URI path value for the API request. Alternatively, you can set the URI path directly by invoking /v1/{pathValue}.

", "smithy.api#httpHeader": "x-amzn-dataexchange-path" } }, @@ -4029,9 +3974,6 @@ "smithy.api#required": {} } } - }, - "traits": { - "smithy.api#documentation": "

The request body for SendApiAsset.

" } }, "com.amazonaws.dataexchange#SendApiAssetResponse": { @@ -4056,7 +3998,6 @@ "com.amazonaws.dataexchange#ServerSideEncryptionTypes": { "type": "string", "traits": { - "smithy.api#documentation": "

The types of encryption supported in export jobs to Amazon S3.

", "smithy.api#enum": [ { "value": "aws:kms", @@ -4075,13 +4016,13 @@ "LimitName": { "target": "com.amazonaws.dataexchange#LimitName", "traits": { - "smithy.api#documentation": "

The name of the quota that was exceeded.

" + "smithy.api#documentation": "

The name of the limit that was reached.

" } }, "LimitValue": { "target": "com.amazonaws.dataexchange#__double", "traits": { - "smithy.api#documentation": "

The maximum value for the service-specific limit.

" + "smithy.api#documentation": "

The value of the exceeded limit.

" } }, "Message": { @@ -4188,6 +4129,9 @@ "input": { "target": "com.amazonaws.dataexchange#TagResourceRequest" }, + "output": { + "target": "smithy.api#Unit" + }, "traits": { "smithy.api#documentation": "

This operation tags a resource.

", "smithy.api#http": { @@ -4211,14 +4155,11 @@ "Tags": { "target": "com.amazonaws.dataexchange#MapOf__string", "traits": { - "smithy.api#documentation": "A label that consists of a customer-defined key and an optional value.", + "smithy.api#documentation": "

A label that consists of a customer-defined key and an optional value.

", "smithy.api#jsonName": "tags", "smithy.api#required": {} } } - }, - "traits": { - "smithy.api#documentation": "

The request body for TagResource.

" } }, "com.amazonaws.dataexchange#ThrottlingException": { @@ -4241,7 +4182,6 @@ "com.amazonaws.dataexchange#Timestamp": { "type": "timestamp", "traits": { - "smithy.api#documentation": "

Dates and times in AWS Data Exchange are recorded in ISO 8601 format.

", "smithy.api#timestampFormat": "date-time" } }, @@ -4285,13 +4225,17 @@ "input": { "target": "com.amazonaws.dataexchange#UntagResourceRequest" }, + "output": { + "target": "smithy.api#Unit" + }, "traits": { "smithy.api#documentation": "

This operation removes one or more tags from a resource.

", "smithy.api#http": { "method": "DELETE", "uri": "/tags/{ResourceArn}", "code": 204 - } + }, + "smithy.api#idempotent": {} } }, "com.amazonaws.dataexchange#UntagResourceRequest": { @@ -4308,7 +4252,7 @@ "TagKeys": { "target": "com.amazonaws.dataexchange#ListOf__string", "traits": { - "smithy.api#documentation": "The key tags.", + "smithy.api#documentation": "

The key tags.

", "smithy.api#httpQuery": "tagKeys", "smithy.api#required": {} } @@ -4386,9 +4330,6 @@ "smithy.api#required": {} } } - }, - "traits": { - "smithy.api#documentation": "

The request body for UpdateAsset.

" } }, "com.amazonaws.dataexchange#UpdateAssetResponse": { @@ -4513,9 +4454,6 @@ "smithy.api#documentation": "

The name of the data set.

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

The request body for UpdateDataSet.

" } }, "com.amazonaws.dataexchange#UpdateDataSetResponse": { @@ -4634,9 +4572,6 @@ "smithy.api#required": {} } } - }, - "traits": { - "smithy.api#documentation": "

The request body for UpdateEventAction.

" } }, "com.amazonaws.dataexchange#UpdateEventActionResponse": { @@ -4748,9 +4683,6 @@ "smithy.api#required": {} } } - }, - "traits": { - "smithy.api#documentation": "

The request body for UpdateRevision.

" } }, "com.amazonaws.dataexchange#UpdateRevisionResponse": { @@ -4783,7 +4715,7 @@ "Finalized": { "target": "com.amazonaws.dataexchange#__boolean", "traits": { - "smithy.api#documentation": "

To publish a revision to a data set in a product, the revision must first be finalized. Finalizing a revision tells AWS Data Exchange that changes to the assets in the revision are complete. After it's in this read-only state, you can publish the revision to your products.

Finalized revisions can be published through the AWS Data Exchange console or the AWS Marketplace Catalog API, using the StartChangeSet AWS Marketplace Catalog API action. When using the API, revisions are uniquely identified by their ARN.

" + "smithy.api#documentation": "

To publish a revision to a data set in a product, the revision must first be finalized. Finalizing a revision tells AWS Data Exchange that changes to the assets in the revision are complete. After it's in this read-only state, you can publish the revision to your products. Finalized revisions can be published through the AWS Data Exchange console or the AWS Marketplace Catalog API, using the StartChangeSet AWS Marketplace Catalog API action. When using the API, revisions are uniquely identified by their ARN.

" } }, "Id": { @@ -4837,7 +4769,7 @@ "ExceptionCause": { "target": "com.amazonaws.dataexchange#ExceptionCause", "traits": { - "smithy.api#documentation": "

The message that informs you about what the exception was.

" + "smithy.api#documentation": "

The unique identifier for the resource that couldn't be found.

" } } }, @@ -4888,4 +4820,4 @@ } } } -} +} \ No newline at end of file diff --git a/codegen/sdk-codegen/aws-models/drs.json b/codegen/sdk-codegen/aws-models/drs.json index 672fea30351..a3fc8447846 100644 --- a/codegen/sdk-codegen/aws-models/drs.json +++ b/codegen/sdk-codegen/aws-models/drs.json @@ -496,7 +496,7 @@ "type": "structure", "members": { "lagDuration": { - "target": "com.amazonaws.drs#ISO8601DatetimeString", + "target": "com.amazonaws.drs#ISO8601DurationString", "traits": { "smithy.api#documentation": "

Data replication lag duration.

" } @@ -2120,6 +2120,15 @@ "smithy.api#pattern": "^[1-9][0-9]*-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])T([0-1][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9](\\.[0-9]+)?Z$" } }, + "com.amazonaws.drs#ISO8601DurationString": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 1, + "max": 64 + } + } + }, "com.amazonaws.drs#IdentificationHints": { "type": "structure", "members": { @@ -2713,7 +2722,7 @@ } }, "elapsedReplicationDuration": { - "target": "com.amazonaws.drs#ISO8601DatetimeString", + "target": "com.amazonaws.drs#ISO8601DurationString", "traits": { "smithy.api#documentation": "

The amount of time that the Source Server has been replicating for.

" } diff --git a/codegen/sdk-codegen/aws-models/ec2.json b/codegen/sdk-codegen/aws-models/ec2.json index 00c034a932c..4a65b80587b 100644 --- a/codegen/sdk-codegen/aws-models/ec2.json +++ b/codegen/sdk-codegen/aws-models/ec2.json @@ -136,6 +136,14 @@ { "value": "vu9p", "name": "VU9P" + }, + { + "value": "inferentia", + "name": "INFERENTIA" + }, + { + "value": "k520", + "name": "K520" } ] } @@ -1806,6 +1814,12 @@ { "target": "com.amazonaws.ec2#CreateClientVpnRoute" }, + { + "target": "com.amazonaws.ec2#CreateCoipCidr" + }, + { + "target": "com.amazonaws.ec2#CreateCoipPool" + }, { "target": "com.amazonaws.ec2#CreateCustomerGateway" }, @@ -1863,6 +1877,12 @@ { "target": "com.amazonaws.ec2#CreateLocalGatewayRoute" }, + { + "target": "com.amazonaws.ec2#CreateLocalGatewayRouteTable" + }, + { + "target": "com.amazonaws.ec2#CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation" + }, { "target": "com.amazonaws.ec2#CreateLocalGatewayRouteTableVpcAssociation" }, @@ -2016,6 +2036,12 @@ { "target": "com.amazonaws.ec2#DeleteClientVpnRoute" }, + { + "target": "com.amazonaws.ec2#DeleteCoipCidr" + }, + { + "target": "com.amazonaws.ec2#DeleteCoipPool" + }, { "target": "com.amazonaws.ec2#DeleteCustomerGateway" }, @@ -2061,6 +2087,12 @@ { "target": "com.amazonaws.ec2#DeleteLocalGatewayRoute" }, + { + "target": "com.amazonaws.ec2#DeleteLocalGatewayRouteTable" + }, + { + "target": "com.amazonaws.ec2#DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation" + }, { "target": "com.amazonaws.ec2#DeleteLocalGatewayRouteTableVpcAssociation" }, @@ -2964,6 +2996,9 @@ { "target": "com.amazonaws.ec2#ModifyLaunchTemplate" }, + { + "target": "com.amazonaws.ec2#ModifyLocalGatewayRoute" + }, { "target": "com.amazonaws.ec2#ModifyManagedPrefixList" }, @@ -4996,7 +5031,7 @@ "target": "com.amazonaws.ec2#AttachClassicLinkVpcResult" }, "traits": { - "smithy.api#documentation": "\n\t

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
\n\t

Links an EC2-Classic instance to a ClassicLink-enabled VPC through one or more of the VPC's\n\t\t\tsecurity groups. You cannot link an EC2-Classic instance to more than one VPC at a time. You\n\t\t\tcan only link an instance that's in the running state. An instance is\n\t\t\tautomatically unlinked from a VPC when it's stopped - you can link it to the VPC again when\n\t\t\tyou restart it.

\n\t\t

After you've linked an instance, you cannot change the VPC security groups that are associated with it. To change the security groups, you must first unlink the instance, and then link it again.

\n\t\t

Linking your instance to a VPC is sometimes referred to as attaching your instance.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
\n\t

Links an EC2-Classic instance to a ClassicLink-enabled VPC through one or more of the VPC's\n\t\t\tsecurity groups. You cannot link an EC2-Classic instance to more than one VPC at a time. You\n\t\t\tcan only link an instance that's in the running state. An instance is\n\t\t\tautomatically unlinked from a VPC when it's stopped - you can link it to the VPC again when\n\t\t\tyou restart it.

\n\t\t

After you've linked an instance, you cannot change the VPC security groups that are associated with it. To change the security groups, you must first unlink the instance, and then link it again.

\n\t\t

Linking your instance to a VPC is sometimes referred to as attaching your instance.

" } }, "com.amazonaws.ec2#AttachClassicLinkVpcRequest": { @@ -8156,7 +8191,7 @@ } }, "traits": { - "smithy.api#documentation": "\n\t

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
\n\t\t

Describes a linked EC2-Classic instance.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
\n\t\t

Describes a linked EC2-Classic instance.

" } }, "com.amazonaws.ec2#ClassicLinkInstanceList": { @@ -9246,6 +9281,38 @@ } } }, + "com.amazonaws.ec2#CoipCidr": { + "type": "structure", + "members": { + "Cidr": { + "target": "com.amazonaws.ec2#String", + "traits": { + "aws.protocols#ec2QueryName": "Cidr", + "smithy.api#documentation": "

\n An address range in a customer-owned IP address space.\n

", + "smithy.api#xmlName": "cidr" + } + }, + "CoipPoolId": { + "target": "com.amazonaws.ec2#Ipv4PoolCoipId", + "traits": { + "aws.protocols#ec2QueryName": "CoipPoolId", + "smithy.api#documentation": "

\n The ID of the address pool.\n

", + "smithy.api#xmlName": "coipPoolId" + } + }, + "LocalGatewayRouteTableId": { + "target": "com.amazonaws.ec2#String", + "traits": { + "aws.protocols#ec2QueryName": "LocalGatewayRouteTableId", + "smithy.api#documentation": "

\n The ID of the local gateway route table.\n

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

\n Information about a customer-owned IP address range.\n

" + } + }, "com.amazonaws.ec2#CoipPool": { "type": "structure", "members": { @@ -10638,6 +10705,105 @@ } } }, + "com.amazonaws.ec2#CreateCoipCidr": { + "type": "operation", + "input": { + "target": "com.amazonaws.ec2#CreateCoipCidrRequest" + }, + "output": { + "target": "com.amazonaws.ec2#CreateCoipCidrResult" + }, + "traits": { + "smithy.api#documentation": "

\n Creates a range of customer-owned IP addresses.\n

" + } + }, + "com.amazonaws.ec2#CreateCoipCidrRequest": { + "type": "structure", + "members": { + "Cidr": { + "target": "com.amazonaws.ec2#String", + "traits": { + "smithy.api#documentation": "

\n A customer-owned IP address range to create.\n

", + "smithy.api#required": {} + } + }, + "CoipPoolId": { + "target": "com.amazonaws.ec2#Ipv4PoolCoipId", + "traits": { + "smithy.api#documentation": "

\n The ID of the address pool.\n

", + "smithy.api#required": {} + } + }, + "DryRun": { + "target": "com.amazonaws.ec2#Boolean", + "traits": { + "smithy.api#documentation": "

Checks whether you have the required permissions for the action, without actually making the request, \n and provides an error response. If you have the required permissions, the error response is DryRunOperation. \n Otherwise, it is UnauthorizedOperation.

" + } + } + } + }, + "com.amazonaws.ec2#CreateCoipCidrResult": { + "type": "structure", + "members": { + "CoipCidr": { + "target": "com.amazonaws.ec2#CoipCidr", + "traits": { + "aws.protocols#ec2QueryName": "CoipCidr", + "smithy.api#documentation": "

\n Information about a range of customer-owned IP addresses.\n

", + "smithy.api#xmlName": "coipCidr" + } + } + } + }, + "com.amazonaws.ec2#CreateCoipPool": { + "type": "operation", + "input": { + "target": "com.amazonaws.ec2#CreateCoipPoolRequest" + }, + "output": { + "target": "com.amazonaws.ec2#CreateCoipPoolResult" + }, + "traits": { + "smithy.api#documentation": "

Creates a pool of customer-owned IP (CoIP) addresses.

" + } + }, + "com.amazonaws.ec2#CreateCoipPoolRequest": { + "type": "structure", + "members": { + "LocalGatewayRouteTableId": { + "target": "com.amazonaws.ec2#LocalGatewayRoutetableId", + "traits": { + "smithy.api#documentation": "

\n The ID of the local gateway route table.\n

", + "smithy.api#required": {} + } + }, + "TagSpecifications": { + "target": "com.amazonaws.ec2#TagSpecificationList", + "traits": { + "smithy.api#documentation": "

\n The tags to assign to the CoIP address pool.\n

", + "smithy.api#xmlName": "TagSpecification" + } + }, + "DryRun": { + "target": "com.amazonaws.ec2#Boolean", + "traits": { + "smithy.api#documentation": "

Checks whether you have the required permissions for the action, without actually making the request, \n and provides an error response. If you have the required permissions, the error response is DryRunOperation. \n Otherwise, it is UnauthorizedOperation.

" + } + } + } + }, + "com.amazonaws.ec2#CreateCoipPoolResult": { + "type": "structure", + "members": { + "CoipPool": { + "target": "com.amazonaws.ec2#CoipPool", + "traits": { + "aws.protocols#ec2QueryName": "CoipPool", + "smithy.api#xmlName": "coipPool" + } + } + } + }, "com.amazonaws.ec2#CreateCustomerGateway": { "type": "operation", "input": { @@ -10785,7 +10951,7 @@ "target": "com.amazonaws.ec2#CreateDefaultVpcResult" }, "traits": { - "smithy.api#documentation": "

Creates a default VPC with a size /16 IPv4 CIDR block and a default subnet\n\t\t\tin each Availability Zone. For more information about the components of a default VPC,\n\t\t\tsee Default VPC and\n\t\t\tdefault subnets in the Amazon Virtual Private Cloud User Guide. You cannot\n\t\t\tspecify the components of the default VPC yourself.

\n\t\t

If you deleted your previous default VPC, you can create a default VPC. You cannot have\n\t\t\tmore than one default VPC per Region.

\n\t\t

If your account supports EC2-Classic, you cannot use this action to create a default VPC\n\t\t\tin a Region that supports EC2-Classic. If you want a default VPC in a Region that\n\t\t\tsupports EC2-Classic, see \"I really want a default VPC for my existing EC2 account. Is\n\t\t\tthat possible?\" in the Default VPCs\n\t\t\tFAQ.

\n\t \n\t

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

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

Creates a default VPC with a size /16 IPv4 CIDR block and a default subnet\n\t\t\tin each Availability Zone. For more information about the components of a default VPC,\n\t\t\tsee Default VPC and\n\t\t\tdefault subnets in the Amazon Virtual Private Cloud User Guide. You cannot\n\t\t\tspecify the components of the default VPC yourself.

\n\t\t

If you deleted your previous default VPC, you can create a default VPC. You cannot have\n\t\t\tmore than one default VPC per Region.

\n\t\t

If your account supports EC2-Classic, you cannot use this action to create a default VPC\n\t\t\tin a Region that supports EC2-Classic. If you want a default VPC in a Region that\n\t\t\tsupports EC2-Classic, see \"I really want a default VPC for my existing EC2 account. Is\n\t\t\tthat possible?\" in the Default VPCs\n\t\t\tFAQ.

\n\t \n\t

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
" } }, "com.amazonaws.ec2#CreateDefaultVpcRequest": { @@ -11199,19 +11365,25 @@ "DeliverLogsPermissionArn": { "target": "com.amazonaws.ec2#String", "traits": { - "smithy.api#documentation": "

The ARN for the IAM role that permits Amazon EC2 to publish flow logs to a CloudWatch Logs log group \n in your account.

\n

If you specify LogDestinationType as s3, do not specify \n DeliverLogsPermissionArn or LogGroupName.

" + "smithy.api#documentation": "

The ARN of the IAM role that allows Amazon EC2 to publish flow logs to a CloudWatch Logs log group in\n your account.

\n

This parameter is required if the destination type is cloud-watch-logs\n and unsupported otherwise.

" + } + }, + "DeliverCrossAccountRole": { + "target": "com.amazonaws.ec2#String", + "traits": { + "smithy.api#documentation": "

The ARN of the IAM role that allows Amazon EC2 to publish flow logs across accounts.

" } }, "LogGroupName": { "target": "com.amazonaws.ec2#String", "traits": { - "smithy.api#documentation": "

The name of a new or existing CloudWatch Logs log group where Amazon EC2 publishes your flow logs.

\n

If you specify LogDestinationType as s3, do not specify \n DeliverLogsPermissionArn or LogGroupName.

" + "smithy.api#documentation": "

The name of a new or existing CloudWatch Logs log group where Amazon EC2 publishes your flow logs.

\n

This parameter is valid only if the destination type is cloud-watch-logs.

" } }, "ResourceIds": { "target": "com.amazonaws.ec2#FlowLogResourceIds", "traits": { - "smithy.api#documentation": "

The ID of the subnet, network interface, or VPC for which you want to create a flow log.

\n

Constraints: Maximum of 1000 resources

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

The IDs of the resources to monitor. For example, if the resource type is\n VPC, specify the IDs of the VPCs.

\n

Constraints: Maximum of 1000 resources

", "smithy.api#required": {}, "smithy.api#xmlName": "ResourceId" } @@ -11219,32 +11391,32 @@ "ResourceType": { "target": "com.amazonaws.ec2#FlowLogsResourceType", "traits": { - "smithy.api#documentation": "

The type of resource for which to create the flow log. For example, if you specified a VPC ID for \n the ResourceId property, specify VPC for this property.

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

The type of resource to monitor.

", "smithy.api#required": {} } }, "TrafficType": { "target": "com.amazonaws.ec2#TrafficType", "traits": { - "smithy.api#documentation": "

The type of traffic to log. You can log traffic that the resource accepts or rejects, or all traffic.

" + "smithy.api#documentation": "

The type of traffic to monitor (accepted traffic, rejected traffic, or all\n traffic).

" } }, "LogDestinationType": { "target": "com.amazonaws.ec2#LogDestinationType", "traits": { - "smithy.api#documentation": "

The type of destination to which the flow log data is to be published. Flow log data can be \n published to CloudWatch Logs or Amazon S3. To publish flow log data to CloudWatch Logs, specify cloud-watch-logs. To \n publish flow log data to Amazon S3, specify s3.

\n

If you specify LogDestinationType as s3, do not specify \n DeliverLogsPermissionArn or LogGroupName.

\n

Default: cloud-watch-logs\n

" + "smithy.api#documentation": "

The type of destination for the flow log data.

\n

Default: cloud-watch-logs\n

" } }, "LogDestination": { "target": "com.amazonaws.ec2#String", "traits": { - "smithy.api#documentation": "

The destination to which the flow log data is to be published. Flow log data can be published \n to a CloudWatch Logs log group or an Amazon S3 bucket. The value specified for this parameter depends on the value specified\n for LogDestinationType.

\n

If LogDestinationType is not specified or cloud-watch-logs,\n specify the Amazon Resource Name (ARN) of the CloudWatch Logs log group. For example, to publish\n to a log group called my-logs, specify\n arn:aws:logs:us-east-1:123456789012:log-group:my-logs. Alternatively,\n use LogGroupName instead.

\n

If LogDestinationType is s3, specify the ARN of the Amazon S3 bucket. You can also specify a \n subfolder in the bucket. To specify a subfolder in the bucket, use the following ARN format: \n bucket_ARN/subfolder_name/. For example, to specify a subfolder named my-logs in a \n bucket named my-bucket, use the following ARN: arn:aws:s3:::my-bucket/my-logs/. You \n cannot use AWSLogs as a subfolder name. This is a reserved term.

" + "smithy.api#documentation": "

The destination for the flow log data. The meaning of this parameter depends on the destination type.

\n " } }, "LogFormat": { "target": "com.amazonaws.ec2#String", "traits": { - "smithy.api#documentation": "

The fields to include in the flow log record, in the order in which they should\n appear. For a list of available fields, see Flow log records. If you\n omit this parameter, the flow log is created using the default format. If you specify this parameter, \n you must specify at least one field.

\n

Specify the fields using the ${field-id} format, separated by spaces. For\n the CLI, surround this parameter value with single quotes on Linux or\n double quotes on Windows.

" + "smithy.api#documentation": "

The fields to include in the flow log record. List the fields in the order in which\n they should appear. For more information about the available fields, see Flow log\n records. If you omit this parameter, the flow log is created using the\n default format. If you specify this parameter, you must include at least one\n field.

\n

Specify the fields using the ${field-id} format, separated by spaces. For\n the CLI, surround this parameter value with single quotes on Linux or\n double quotes on Windows.

" } }, "TagSpecifications": { @@ -12114,7 +12286,7 @@ "target": "com.amazonaws.ec2#CreateLocalGatewayRouteResult" }, "traits": { - "smithy.api#documentation": "

Creates a static route for the specified local gateway route table.

" + "smithy.api#documentation": "

Creates a static route for the specified local gateway route table. You must specify one of the \n following targets:

\n " } }, "com.amazonaws.ec2#CreateLocalGatewayRouteRequest": { @@ -12137,8 +12309,7 @@ "LocalGatewayVirtualInterfaceGroupId": { "target": "com.amazonaws.ec2#LocalGatewayVirtualInterfaceGroupId", "traits": { - "smithy.api#documentation": "

The ID of the virtual interface group.

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

The ID of the virtual interface group.

" } }, "DryRun": { @@ -12146,6 +12317,12 @@ "traits": { "smithy.api#documentation": "

Checks whether you have the required permissions for the action, without actually making the request, \n and provides an error response. If you have the required permissions, the error response is DryRunOperation. \n Otherwise, it is UnauthorizedOperation.

" } + }, + "NetworkInterfaceId": { + "target": "com.amazonaws.ec2#NetworkInterfaceId", + "traits": { + "smithy.api#documentation": "

The ID of the network interface.

" + } } } }, @@ -12162,6 +12339,117 @@ } } }, + "com.amazonaws.ec2#CreateLocalGatewayRouteTable": { + "type": "operation", + "input": { + "target": "com.amazonaws.ec2#CreateLocalGatewayRouteTableRequest" + }, + "output": { + "target": "com.amazonaws.ec2#CreateLocalGatewayRouteTableResult" + }, + "traits": { + "smithy.api#documentation": "

\n Creates a local gateway route table. \n

" + } + }, + "com.amazonaws.ec2#CreateLocalGatewayRouteTableRequest": { + "type": "structure", + "members": { + "LocalGatewayId": { + "target": "com.amazonaws.ec2#LocalGatewayId", + "traits": { + "smithy.api#documentation": "

\n The ID of the local gateway. \n

", + "smithy.api#required": {} + } + }, + "Mode": { + "target": "com.amazonaws.ec2#LocalGatewayRouteTableMode", + "traits": { + "smithy.api#documentation": "

\n The mode of the local gateway route table.\n

" + } + }, + "TagSpecifications": { + "target": "com.amazonaws.ec2#TagSpecificationList", + "traits": { + "smithy.api#documentation": "

\n The tags assigned to the local gateway route table.\n

", + "smithy.api#xmlName": "TagSpecification" + } + }, + "DryRun": { + "target": "com.amazonaws.ec2#Boolean", + "traits": { + "smithy.api#documentation": "

Checks whether you have the required permissions for the action, without actually making the request, \n and provides an error response. If you have the required permissions, the error response is DryRunOperation. \n Otherwise, it is UnauthorizedOperation.

" + } + } + } + }, + "com.amazonaws.ec2#CreateLocalGatewayRouteTableResult": { + "type": "structure", + "members": { + "LocalGatewayRouteTable": { + "target": "com.amazonaws.ec2#LocalGatewayRouteTable", + "traits": { + "aws.protocols#ec2QueryName": "LocalGatewayRouteTable", + "smithy.api#xmlName": "localGatewayRouteTable" + } + } + } + }, + "com.amazonaws.ec2#CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation": { + "type": "operation", + "input": { + "target": "com.amazonaws.ec2#CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationRequest" + }, + "output": { + "target": "com.amazonaws.ec2#CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationResult" + }, + "traits": { + "smithy.api#documentation": "

\n Creates a local gateway route table virtual interface group association. \n

" + } + }, + "com.amazonaws.ec2#CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationRequest": { + "type": "structure", + "members": { + "LocalGatewayRouteTableId": { + "target": "com.amazonaws.ec2#LocalGatewayRoutetableId", + "traits": { + "smithy.api#documentation": "

\n The ID of the local gateway route table.\n

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

\n The ID of the local gateway route table virtual interface group association.\n

", + "smithy.api#required": {} + } + }, + "TagSpecifications": { + "target": "com.amazonaws.ec2#TagSpecificationList", + "traits": { + "smithy.api#documentation": "

\n The tags assigned to the local gateway route table virtual interface group association.\n

", + "smithy.api#xmlName": "TagSpecification" + } + }, + "DryRun": { + "target": "com.amazonaws.ec2#Boolean", + "traits": { + "smithy.api#documentation": "

Checks whether you have the required permissions for the action, without actually making the request, \n and provides an error response. If you have the required permissions, the error response is DryRunOperation. \n Otherwise, it is UnauthorizedOperation.

" + } + } + } + }, + "com.amazonaws.ec2#CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationResult": { + "type": "structure", + "members": { + "LocalGatewayRouteTableVirtualInterfaceGroupAssociation": { + "target": "com.amazonaws.ec2#LocalGatewayRouteTableVirtualInterfaceGroupAssociation", + "traits": { + "aws.protocols#ec2QueryName": "LocalGatewayRouteTableVirtualInterfaceGroupAssociation", + "smithy.api#xmlName": "localGatewayRouteTableVirtualInterfaceGroupAssociation" + } + } + } + }, "com.amazonaws.ec2#CreateLocalGatewayRouteTableVpcAssociation": { "type": "operation", "input": { @@ -16278,6 +16566,98 @@ } } }, + "com.amazonaws.ec2#DeleteCoipCidr": { + "type": "operation", + "input": { + "target": "com.amazonaws.ec2#DeleteCoipCidrRequest" + }, + "output": { + "target": "com.amazonaws.ec2#DeleteCoipCidrResult" + }, + "traits": { + "smithy.api#documentation": "

\n Deletes a range of customer-owned IP addresses.\n

" + } + }, + "com.amazonaws.ec2#DeleteCoipCidrRequest": { + "type": "structure", + "members": { + "Cidr": { + "target": "com.amazonaws.ec2#String", + "traits": { + "smithy.api#documentation": "

A customer-owned IP address range that you want to delete.

", + "smithy.api#required": {} + } + }, + "CoipPoolId": { + "target": "com.amazonaws.ec2#Ipv4PoolCoipId", + "traits": { + "smithy.api#documentation": "

\n The ID of the customer-owned address pool. \n

", + "smithy.api#required": {} + } + }, + "DryRun": { + "target": "com.amazonaws.ec2#Boolean", + "traits": { + "smithy.api#documentation": "

Checks whether you have the required permissions for the action, without actually making the request, \n and provides an error response. If you have the required permissions, the error response is DryRunOperation. \n Otherwise, it is UnauthorizedOperation.

" + } + } + } + }, + "com.amazonaws.ec2#DeleteCoipCidrResult": { + "type": "structure", + "members": { + "CoipCidr": { + "target": "com.amazonaws.ec2#CoipCidr", + "traits": { + "aws.protocols#ec2QueryName": "CoipCidr", + "smithy.api#documentation": "

\n Information about a range of customer-owned IP addresses.\n

", + "smithy.api#xmlName": "coipCidr" + } + } + } + }, + "com.amazonaws.ec2#DeleteCoipPool": { + "type": "operation", + "input": { + "target": "com.amazonaws.ec2#DeleteCoipPoolRequest" + }, + "output": { + "target": "com.amazonaws.ec2#DeleteCoipPoolResult" + }, + "traits": { + "smithy.api#documentation": "

Deletes a pool of customer-owned IP (CoIP) addresses.

" + } + }, + "com.amazonaws.ec2#DeleteCoipPoolRequest": { + "type": "structure", + "members": { + "CoipPoolId": { + "target": "com.amazonaws.ec2#Ipv4PoolCoipId", + "traits": { + "smithy.api#documentation": "

The ID of the CoIP pool that you want to delete.

", + "smithy.api#required": {} + } + }, + "DryRun": { + "target": "com.amazonaws.ec2#Boolean", + "traits": { + "smithy.api#documentation": "

Checks whether you have the required permissions for the action, without actually making the request, \n and provides an error response. If you have the required permissions, the error response is DryRunOperation. \n Otherwise, it is UnauthorizedOperation.

" + } + } + } + }, + "com.amazonaws.ec2#DeleteCoipPoolResult": { + "type": "structure", + "members": { + "CoipPool": { + "target": "com.amazonaws.ec2#CoipPool", + "traits": { + "aws.protocols#ec2QueryName": "CoipPool", + "smithy.api#xmlName": "coipPool" + } + } + } + }, "com.amazonaws.ec2#DeleteCustomerGateway": { "type": "operation", "input": { @@ -17163,6 +17543,90 @@ } } }, + "com.amazonaws.ec2#DeleteLocalGatewayRouteTable": { + "type": "operation", + "input": { + "target": "com.amazonaws.ec2#DeleteLocalGatewayRouteTableRequest" + }, + "output": { + "target": "com.amazonaws.ec2#DeleteLocalGatewayRouteTableResult" + }, + "traits": { + "smithy.api#documentation": "

\n Deletes a local gateway route table.\n

" + } + }, + "com.amazonaws.ec2#DeleteLocalGatewayRouteTableRequest": { + "type": "structure", + "members": { + "LocalGatewayRouteTableId": { + "target": "com.amazonaws.ec2#LocalGatewayRoutetableId", + "traits": { + "smithy.api#documentation": "

\n The ID of the local gateway route table.\n

", + "smithy.api#required": {} + } + }, + "DryRun": { + "target": "com.amazonaws.ec2#Boolean", + "traits": { + "smithy.api#documentation": "

Checks whether you have the required permissions for the action, without actually making the request, \n and provides an error response. If you have the required permissions, the error response is DryRunOperation. \n Otherwise, it is UnauthorizedOperation.

" + } + } + } + }, + "com.amazonaws.ec2#DeleteLocalGatewayRouteTableResult": { + "type": "structure", + "members": { + "LocalGatewayRouteTable": { + "target": "com.amazonaws.ec2#LocalGatewayRouteTable", + "traits": { + "aws.protocols#ec2QueryName": "LocalGatewayRouteTable", + "smithy.api#xmlName": "localGatewayRouteTable" + } + } + } + }, + "com.amazonaws.ec2#DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation": { + "type": "operation", + "input": { + "target": "com.amazonaws.ec2#DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationRequest" + }, + "output": { + "target": "com.amazonaws.ec2#DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationResult" + }, + "traits": { + "smithy.api#documentation": "

\n Deletes a local gateway route table virtual interface group association.\n

" + } + }, + "com.amazonaws.ec2#DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationRequest": { + "type": "structure", + "members": { + "LocalGatewayRouteTableVirtualInterfaceGroupAssociationId": { + "target": "com.amazonaws.ec2#LocalGatewayRouteTableVirtualInterfaceGroupAssociationId", + "traits": { + "smithy.api#documentation": "

\n The ID of the local gateway route table virtual interface group association.\n

", + "smithy.api#required": {} + } + }, + "DryRun": { + "target": "com.amazonaws.ec2#Boolean", + "traits": { + "smithy.api#documentation": "

Checks whether you have the required permissions for the action, without actually making the request, \n and provides an error response. If you have the required permissions, the error response is DryRunOperation. \n Otherwise, it is UnauthorizedOperation.

" + } + } + } + }, + "com.amazonaws.ec2#DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationResult": { + "type": "structure", + "members": { + "LocalGatewayRouteTableVirtualInterfaceGroupAssociation": { + "target": "com.amazonaws.ec2#LocalGatewayRouteTableVirtualInterfaceGroupAssociation", + "traits": { + "aws.protocols#ec2QueryName": "LocalGatewayRouteTableVirtualInterfaceGroupAssociation", + "smithy.api#xmlName": "localGatewayRouteTableVirtualInterfaceGroupAssociation" + } + } + } + }, "com.amazonaws.ec2#DeleteLocalGatewayRouteTableVpcAssociation": { "type": "operation", "input": { @@ -20206,7 +20670,7 @@ "target": "com.amazonaws.ec2#DescribeClassicLinkInstancesResult" }, "traits": { - "smithy.api#documentation": "

Describes one or more of your linked EC2-Classic instances. This request only returns\n\t\t\tinformation about EC2-Classic instances linked to a VPC through ClassicLink. You cannot\n\t\t\tuse this request to return information about other instances.

\n\t \n\t

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

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

Describes one or more of your linked EC2-Classic instances. This request only returns\n\t\t\tinformation about EC2-Classic instances linked to a VPC through ClassicLink. You cannot\n\t\t\tuse this request to return information about other instances.

\n\t \n\t

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
", "smithy.api#paginated": { "inputToken": "NextToken", "outputToken": "NextToken", @@ -22161,7 +22625,7 @@ "target": "com.amazonaws.ec2#DescribeFlowLogsResult" }, "traits": { - "smithy.api#documentation": "

Describes one or more flow logs. To view the information in your flow logs (the log\n streams for the network interfaces), you must use the CloudWatch Logs console or the CloudWatch Logs\n API.

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

Describes one or more flow logs.

\n

To view the published flow log records, you must view the log destination. For example, \n the CloudWatch Logs log group, the Amazon S3 bucket, or the Kinesis Data Firehose delivery stream.

", "smithy.api#paginated": { "inputToken": "NextToken", "outputToken": "NextToken", @@ -22182,7 +22646,7 @@ "Filter": { "target": "com.amazonaws.ec2#FilterList", "traits": { - "smithy.api#documentation": "

One or more filters.

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

One or more filters.

\n " } }, "FlowLogIds": { @@ -30119,7 +30583,7 @@ "target": "com.amazonaws.ec2#DescribeVpcClassicLinkResult" }, "traits": { - "smithy.api#documentation": "

Describes the ClassicLink status of one or more VPCs.

\n\t \n\t

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

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

Describes the ClassicLink status of one or more VPCs.

\n\t \n\t

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
" } }, "com.amazonaws.ec2#DescribeVpcClassicLinkDnsSupport": { @@ -30131,7 +30595,7 @@ "target": "com.amazonaws.ec2#DescribeVpcClassicLinkDnsSupportResult" }, "traits": { - "smithy.api#documentation": "\n

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Describes the ClassicLink DNS support status of one or more VPCs. If enabled, the DNS\n hostname of a linked EC2-Classic instance resolves to its private IP address when\n addressed from an instance in the VPC to which it's linked. Similarly, the DNS hostname\n of an instance in a VPC resolves to its private IP address when addressed from a linked\n EC2-Classic instance. For more information, see ClassicLink in the Amazon Elastic Compute Cloud User Guide.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Describes the ClassicLink DNS support status of one or more VPCs. If enabled, the DNS\n hostname of a linked EC2-Classic instance resolves to its private IP address when\n addressed from an instance in the VPC to which it's linked. Similarly, the DNS hostname\n of an instance in a VPC resolves to its private IP address when addressed from a linked\n EC2-Classic instance. For more information, see ClassicLink in the Amazon Elastic Compute Cloud User Guide.

", "smithy.api#paginated": { "inputToken": "NextToken", "outputToken": "NextToken", @@ -31223,7 +31687,7 @@ "target": "com.amazonaws.ec2#DetachClassicLinkVpcResult" }, "traits": { - "smithy.api#documentation": "\n\t

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
\n\t\t

Unlinks (detaches) a linked EC2-Classic instance from a VPC. After the instance has been unlinked, the VPC security groups are no longer associated with it. An instance is automatically unlinked from a VPC when it's stopped.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
\n\t\t

Unlinks (detaches) a linked EC2-Classic instance from a VPC. After the instance has been unlinked, the VPC security groups are no longer associated with it. An instance is automatically unlinked from a VPC when it's stopped.

" } }, "com.amazonaws.ec2#DetachClassicLinkVpcRequest": { @@ -32228,7 +32692,7 @@ "target": "com.amazonaws.ec2#DisableVpcClassicLinkResult" }, "traits": { - "smithy.api#documentation": "

Disables ClassicLink for a VPC. You cannot disable ClassicLink for a VPC that has EC2-Classic instances linked to it.

\n \n

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

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

Disables ClassicLink for a VPC. You cannot disable ClassicLink for a VPC that has EC2-Classic instances linked to it.

\n \n

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
" } }, "com.amazonaws.ec2#DisableVpcClassicLinkDnsSupport": { @@ -32240,7 +32704,7 @@ "target": "com.amazonaws.ec2#DisableVpcClassicLinkDnsSupportResult" }, "traits": { - "smithy.api#documentation": "

Disables ClassicLink DNS support for a VPC. If disabled, DNS hostnames resolve to\n\t\t\tpublic IP addresses when addressed between a linked EC2-Classic instance and instances\n\t\t\tin the VPC to which it's linked. For more information, see ClassicLink in the\n\t\t\t\tAmazon Elastic Compute Cloud User Guide.

\n

You must specify a VPC ID in the request.

\n \n \n

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

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

Disables ClassicLink DNS support for a VPC. If disabled, DNS hostnames resolve to\n\t\t\tpublic IP addresses when addressed between a linked EC2-Classic instance and instances\n\t\t\tin the VPC to which it's linked. For more information, see ClassicLink in the\n\t\t\t\tAmazon Elastic Compute Cloud User Guide.

\n

You must specify a VPC ID in the request.

\n \n \n

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
" } }, "com.amazonaws.ec2#DisableVpcClassicLinkDnsSupportRequest": { @@ -34681,7 +35145,7 @@ "target": "com.amazonaws.ec2#EnableVpcClassicLinkResult" }, "traits": { - "smithy.api#documentation": "\n

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Enables a VPC for ClassicLink. You can then link EC2-Classic instances to your\n\t\t\tClassicLink-enabled VPC to allow communication over private IP addresses. You cannot\n\t\t\tenable your VPC for ClassicLink if any of your VPC route tables have existing routes for\n\t\t\taddress ranges within the 10.0.0.0/8 IP address range, excluding local\n\t\t\troutes for VPCs in the 10.0.0.0/16 and 10.1.0.0/16 IP address\n\t\t\tranges. For more information, see ClassicLink in the\n\t\t\t\tAmazon Elastic Compute Cloud User Guide.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Enables a VPC for ClassicLink. You can then link EC2-Classic instances to your\n\t\t\tClassicLink-enabled VPC to allow communication over private IP addresses. You cannot\n\t\t\tenable your VPC for ClassicLink if any of your VPC route tables have existing routes for\n\t\t\taddress ranges within the 10.0.0.0/8 IP address range, excluding local\n\t\t\troutes for VPCs in the 10.0.0.0/16 and 10.1.0.0/16 IP address\n\t\t\tranges. For more information, see ClassicLink in the\n\t\t\t\tAmazon Elastic Compute Cloud User Guide.

" } }, "com.amazonaws.ec2#EnableVpcClassicLinkDnsSupport": { @@ -34693,7 +35157,7 @@ "target": "com.amazonaws.ec2#EnableVpcClassicLinkDnsSupportResult" }, "traits": { - "smithy.api#documentation": "\n

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Enables a VPC to support DNS hostname resolution for ClassicLink. If enabled, the DNS\n\t\t\thostname of a linked EC2-Classic instance resolves to its private IP address when\n\t\t\taddressed from an instance in the VPC to which it's linked. Similarly, the DNS hostname\n\t\t\tof an instance in a VPC resolves to its private IP address when addressed from a linked\n\t\t\tEC2-Classic instance. For more information, see ClassicLink in the\n\t\t\t\tAmazon Elastic Compute Cloud User Guide.

\n

You must specify a VPC ID in the request.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Enables a VPC to support DNS hostname resolution for ClassicLink. If enabled, the DNS\n\t\t\thostname of a linked EC2-Classic instance resolves to its private IP address when\n\t\t\taddressed from an instance in the VPC to which it's linked. Similarly, the DNS hostname\n\t\t\tof an instance in a VPC resolves to its private IP address when addressed from a linked\n\t\t\tEC2-Classic instance. For more information, see ClassicLink in the\n\t\t\t\tAmazon Elastic Compute Cloud User Guide.

\n

You must specify a VPC ID in the request.

" } }, "com.amazonaws.ec2#EnableVpcClassicLinkDnsSupportRequest": { @@ -37209,10 +37673,18 @@ "target": "com.amazonaws.ec2#String", "traits": { "aws.protocols#ec2QueryName": "DeliverLogsPermissionArn", - "smithy.api#documentation": "

The ARN of the IAM role that posts logs to CloudWatch Logs.

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

The ARN of the IAM role allows the service to publish logs to CloudWatch Logs.

", "smithy.api#xmlName": "deliverLogsPermissionArn" } }, + "DeliverCrossAccountRole": { + "target": "com.amazonaws.ec2#String", + "traits": { + "aws.protocols#ec2QueryName": "DeliverCrossAccountRole", + "smithy.api#documentation": "

The ARN of the IAM role that allows the service to publish flow logs across accounts.

", + "smithy.api#xmlName": "deliverCrossAccountRole" + } + }, "DeliverLogsStatus": { "target": "com.amazonaws.ec2#String", "traits": { @@ -37225,7 +37697,7 @@ "target": "com.amazonaws.ec2#String", "traits": { "aws.protocols#ec2QueryName": "FlowLogId", - "smithy.api#documentation": "

The flow log ID.

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

The ID of the flow log.

", "smithy.api#xmlName": "flowLogId" } }, @@ -37249,7 +37721,7 @@ "target": "com.amazonaws.ec2#String", "traits": { "aws.protocols#ec2QueryName": "ResourceId", - "smithy.api#documentation": "

The ID of the resource on which the flow log was created.

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

The ID of the resource being monitored.

", "smithy.api#xmlName": "resourceId" } }, @@ -37265,7 +37737,7 @@ "target": "com.amazonaws.ec2#LogDestinationType", "traits": { "aws.protocols#ec2QueryName": "LogDestinationType", - "smithy.api#documentation": "

The type of destination to which the flow log data is published. Flow log data can be \n published to CloudWatch Logs or Amazon S3.

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

The type of destination for the flow log data.

", "smithy.api#xmlName": "logDestinationType" } }, @@ -37273,7 +37745,7 @@ "target": "com.amazonaws.ec2#String", "traits": { "aws.protocols#ec2QueryName": "LogDestination", - "smithy.api#documentation": "

The destination to which the flow log data is published. Flow log data can be\n published to an CloudWatch Logs log group or an Amazon S3 bucket. If the flow log publishes to CloudWatch Logs,\n this element indicates the Amazon Resource Name (ARN) of the CloudWatch Logs log group to which\n the data is published. If the flow log publishes to Amazon S3, this element indicates the ARN\n of the Amazon S3 bucket to which the data is published.

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

The Amazon Resource Name (ARN) of the destination for the flow log data.

", "smithy.api#xmlName": "logDestination" } }, @@ -53620,6 +54092,30 @@ "smithy.api#documentation": "

The ID of the Amazon Web Services account that owns the local gateway route.

", "smithy.api#xmlName": "ownerId" } + }, + "SubnetId": { + "target": "com.amazonaws.ec2#SubnetId", + "traits": { + "aws.protocols#ec2QueryName": "SubnetId", + "smithy.api#documentation": "

The ID of the subnet.

", + "smithy.api#xmlName": "subnetId" + } + }, + "CoipPoolId": { + "target": "com.amazonaws.ec2#CoipPoolId", + "traits": { + "aws.protocols#ec2QueryName": "CoipPoolId", + "smithy.api#documentation": "

The ID of the customer-owned address pool.

", + "smithy.api#xmlName": "coipPoolId" + } + }, + "NetworkInterfaceId": { + "target": "com.amazonaws.ec2#NetworkInterfaceId", + "traits": { + "aws.protocols#ec2QueryName": "NetworkInterfaceId", + "smithy.api#documentation": "

The ID of the network interface.

", + "smithy.api#xmlName": "networkInterfaceId" + } } }, "traits": { @@ -53720,6 +54216,21 @@ "smithy.api#documentation": "

The tags assigned to the local gateway route table.

", "smithy.api#xmlName": "tagSet" } + }, + "Mode": { + "target": "com.amazonaws.ec2#LocalGatewayRouteTableMode", + "traits": { + "aws.protocols#ec2QueryName": "Mode", + "smithy.api#documentation": "

The mode of the local gateway route table.

", + "smithy.api#xmlName": "mode" + } + }, + "StateReason": { + "target": "com.amazonaws.ec2#StateReason", + "traits": { + "aws.protocols#ec2QueryName": "StateReason", + "smithy.api#xmlName": "stateReason" + } } }, "traits": { @@ -53735,6 +54246,21 @@ } } }, + "com.amazonaws.ec2#LocalGatewayRouteTableMode": { + "type": "string", + "traits": { + "smithy.api#enum": [ + { + "value": "direct-vpc-routing", + "name": "direct_vpc_routing" + }, + { + "value": "coip", + "name": "coip" + } + ] + } + }, "com.amazonaws.ec2#LocalGatewayRouteTableSet": { "type": "list", "member": { @@ -54203,6 +54729,10 @@ { "value": "s3", "name": "s3" + }, + { + "value": "kinesis-data-firehose", + "name": "kinesis_data_firehose" } ] } @@ -56304,6 +56834,67 @@ } } }, + "com.amazonaws.ec2#ModifyLocalGatewayRoute": { + "type": "operation", + "input": { + "target": "com.amazonaws.ec2#ModifyLocalGatewayRouteRequest" + }, + "output": { + "target": "com.amazonaws.ec2#ModifyLocalGatewayRouteResult" + }, + "traits": { + "smithy.api#documentation": "

Modifies the specified local gateway route.

" + } + }, + "com.amazonaws.ec2#ModifyLocalGatewayRouteRequest": { + "type": "structure", + "members": { + "DestinationCidrBlock": { + "target": "com.amazonaws.ec2#String", + "traits": { + "smithy.api#documentation": "

The CIDR block used for destination matches. The value that you provide must match the CIDR of an existing route in the table.

", + "smithy.api#required": {} + } + }, + "LocalGatewayRouteTableId": { + "target": "com.amazonaws.ec2#LocalGatewayRoutetableId", + "traits": { + "smithy.api#documentation": "

The ID of the local gateway route table.

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

\n The ID of the virtual interface group.\n

" + } + }, + "NetworkInterfaceId": { + "target": "com.amazonaws.ec2#NetworkInterfaceId", + "traits": { + "smithy.api#documentation": "

The ID of the network interface.

" + } + }, + "DryRun": { + "target": "com.amazonaws.ec2#Boolean", + "traits": { + "smithy.api#documentation": "

Checks whether you have the required permissions for the action, without actually making the request, \n and provides an error response. If you have the required permissions, the error response is DryRunOperation. \n Otherwise, it is UnauthorizedOperation.

" + } + } + } + }, + "com.amazonaws.ec2#ModifyLocalGatewayRouteResult": { + "type": "structure", + "members": { + "Route": { + "target": "com.amazonaws.ec2#LocalGatewayRoute", + "traits": { + "aws.protocols#ec2QueryName": "Route", + "smithy.api#xmlName": "route" + } + } + } + }, "com.amazonaws.ec2#ModifyManagedPrefixList": { "type": "operation", "input": { @@ -57962,7 +58553,7 @@ "target": "com.amazonaws.ec2#ModifyVpcPeeringConnectionOptionsResult" }, "traits": { - "smithy.api#documentation": "\n

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Modifies the VPC peering connection options on one side of a VPC peering connection. You can do the following:

\n \n

If the peered VPCs are in the same Amazon Web Services account, you can enable DNS resolution \n for queries from the local VPC. This ensures that queries from the local VPC resolve to private IP\n addresses in the peer VPC. This option is not available if the peered VPCs are in different\n different Amazon Web Services accounts or different Regions. For peered VPCs in different \n Amazon Web Services accounts, each Amazon Web Services account owner must initiate a separate request \n to modify the peering connection options. For inter-region peering connections, you must use the \n Region for the requester VPC to modify the requester VPC peering options and the Region for the \n accepter VPC to modify the accepter VPC peering options. To verify which VPCs are the accepter and \n the requester for a VPC peering connection, use the DescribeVpcPeeringConnections command.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Modifies the VPC peering connection options on one side of a VPC peering connection. You can do the following:

\n \n

If the peered VPCs are in the same Amazon Web Services account, you can enable DNS resolution \n for queries from the local VPC. This ensures that queries from the local VPC resolve to private IP\n addresses in the peer VPC. This option is not available if the peered VPCs are in different\n different Amazon Web Services accounts or different Regions. For peered VPCs in different \n Amazon Web Services accounts, each Amazon Web Services account owner must initiate a separate request \n to modify the peering connection options. For inter-region peering connections, you must use the \n Region for the requester VPC to modify the requester VPC peering options and the Region for the \n accepter VPC to modify the accepter VPC peering options. To verify which VPCs are the accepter and \n the requester for a VPC peering connection, use the DescribeVpcPeeringConnections command.

" } }, "com.amazonaws.ec2#ModifyVpcPeeringConnectionOptionsRequest": { @@ -61224,7 +61815,7 @@ } }, "traits": { - "smithy.api#documentation": "\n

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Describes the VPC peering connection options.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Describes the VPC peering connection options.

" } }, "com.amazonaws.ec2#PeeringConnectionOptionsRequest": { @@ -61250,7 +61841,7 @@ } }, "traits": { - "smithy.api#documentation": "\n

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

The VPC peering connection options.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

The VPC peering connection options.

" } }, "com.amazonaws.ec2#PeeringTgwInfo": { @@ -67126,6 +67717,10 @@ "value": "carrier-gateway", "name": "carrier_gateway" }, + { + "value": "coip-pool", + "name": "coip_pool" + }, { "value": "dedicated-host", "name": "dedicated_host" @@ -67401,6 +67996,10 @@ { "value": "vpc-endpoint-connection-device-type", "name": "vpc_endpoint_connection_device_type" + }, + { + "value": "vpn-connection-device-type", + "name": "vpn_connection_device_type" } ] } @@ -80629,7 +81228,7 @@ } }, "traits": { - "smithy.api#documentation": "\n\t

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
\n\t\t

Describes whether a VPC is enabled for ClassicLink.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n\t
\n\t\t

Describes whether a VPC is enabled for ClassicLink.

" } }, "com.amazonaws.ec2#VpcClassicLinkIdList": { @@ -81165,7 +81764,7 @@ } }, "traits": { - "smithy.api#documentation": "\n

We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Describes the VPC peering connection options.

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

We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a VPC in the Amazon Elastic Compute Cloud User Guide.

\n
\n

Describes the VPC peering connection options.

" } }, "com.amazonaws.ec2#VpcPeeringConnectionStateReason": { diff --git a/codegen/sdk-codegen/aws-models/eks.json b/codegen/sdk-codegen/aws-models/eks.json index 4c3a3d4e7de..639458cdacc 100644 --- a/codegen/sdk-codegen/aws-models/eks.json +++ b/codegen/sdk-codegen/aws-models/eks.json @@ -234,7 +234,7 @@ "health": { "target": "com.amazonaws.eks#AddonHealth", "traits": { - "smithy.api#documentation": "

An object that represents the health of the add-on.

" + "smithy.api#documentation": "

An object representing the health of the add-on.

" } }, "addonArn": { @@ -264,7 +264,7 @@ "tags": { "target": "com.amazonaws.eks#TagMap", "traits": { - "smithy.api#documentation": "

The metadata that you apply to the add-on to assist with categorization and\n organization. Each tag consists of a key and an optional value. You define both.\n Add-on tags do not propagate to any other resources associated with the cluster.\n

" + "smithy.api#documentation": "

The metadata that you apply to the add-on to assist with categorization and\n organization. Each tag consists of a key and an optional value. You define both. Add-on\n tags do not propagate to any other resources associated with the cluster.

" } } }, @@ -278,7 +278,7 @@ "issues": { "target": "com.amazonaws.eks#AddonIssueList", "traits": { - "smithy.api#documentation": "

An object that represents the add-on's health issues.

" + "smithy.api#documentation": "

An object representing the health issues for an add-on.

" } } }, @@ -304,7 +304,7 @@ "addonVersions": { "target": "com.amazonaws.eks#AddonVersionInfoList", "traits": { - "smithy.api#documentation": "

An object that represents information about available add-on versions and compatible\n Kubernetes versions.

" + "smithy.api#documentation": "

An object representing information about available add-on versions and compatible\n Kubernetes versions.

" } } }, @@ -414,6 +414,10 @@ { "value": "DEGRADED", "name": "DEGRADED" + }, + { + "value": "UPDATE_FAILED", + "name": "UPDATE_FAILED" } ] } @@ -436,7 +440,7 @@ "compatibilities": { "target": "com.amazonaws.eks#Compatibilities", "traits": { - "smithy.api#documentation": "

An object that represents the compatibilities of a version.

" + "smithy.api#documentation": "

An object representing the compatibilities of a version.

" } } }, @@ -579,7 +583,7 @@ "oidc": { "target": "com.amazonaws.eks#OidcIdentityProviderConfigRequest", "traits": { - "smithy.api#documentation": "

An object that represents an OpenID Connect (OIDC) identity provider\n configuration.

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

An object representing an OpenID Connect (OIDC) identity provider\n configuration.

", "smithy.api#required": {} } }, @@ -816,7 +820,7 @@ "tags": { "target": "com.amazonaws.eks#TagMap", "traits": { - "smithy.api#documentation": "

The metadata that you apply to the cluster to assist with categorization and\n organization. Each tag consists of a key and an optional value. You define both.\n Cluster tags do not propagate to any other resources associated with the\n cluster.

" + "smithy.api#documentation": "

The metadata that you apply to the cluster to assist with categorization and\n organization. Each tag consists of a key and an optional value. You define both. Cluster\n tags do not propagate to any other resources associated with the cluster.

" } }, "encryptionConfig": { @@ -830,12 +834,107 @@ "traits": { "smithy.api#documentation": "

The configuration used to connect to a cluster for registration.

" } + }, + "id": { + "target": "com.amazonaws.eks#String", + "traits": { + "smithy.api#documentation": "

The ID of your local Amazon EKS cluster on an Amazon Web Services Outpost. This\n property isn't available for an Amazon EKS cluster on the Amazon Web Services\n cloud.

" + } + }, + "health": { + "target": "com.amazonaws.eks#ClusterHealth", + "traits": { + "smithy.api#documentation": "

An object representing the health of your local Amazon EKS cluster on an\n Amazon Web Services Outpost. This object isn't available for clusters on the Amazon Web Services cloud.

" + } + }, + "outpostConfig": { + "target": "com.amazonaws.eks#OutpostConfigResponse", + "traits": { + "smithy.api#documentation": "

An object representing the configuration of your local Amazon EKS cluster on\n an Amazon Web Services Outpost. This object isn't available for clusters on the Amazon Web Services cloud.

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

An object representing an Amazon EKS cluster.

" } }, + "com.amazonaws.eks#ClusterHealth": { + "type": "structure", + "members": { + "issues": { + "target": "com.amazonaws.eks#ClusterIssueList", + "traits": { + "smithy.api#documentation": "

An object representing the health issues of your local Amazon EKS cluster on\n an Amazon Web Services Outpost.

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

An object representing the health of your local Amazon EKS cluster on an\n Amazon Web Services Outpost. You can't use this API with an Amazon EKS\n cluster on the Amazon Web Services cloud.\n

" + } + }, + "com.amazonaws.eks#ClusterIssue": { + "type": "structure", + "members": { + "code": { + "target": "com.amazonaws.eks#ClusterIssueCode", + "traits": { + "smithy.api#documentation": "

The error code of the issue.

" + } + }, + "message": { + "target": "com.amazonaws.eks#String", + "traits": { + "smithy.api#documentation": "

A description of the issue.

" + } + }, + "resourceIds": { + "target": "com.amazonaws.eks#StringList", + "traits": { + "smithy.api#documentation": "

The resource IDs that the issue relates\n to.

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

An issue with your local Amazon EKS cluster on an Amazon Web Services Outpost.\n You can't use this API with an Amazon EKS cluster on the Amazon Web Services\n cloud.

" + } + }, + "com.amazonaws.eks#ClusterIssueCode": { + "type": "string", + "traits": { + "smithy.api#enum": [ + { + "value": "AccessDenied", + "name": "ACCESS_DENIED" + }, + { + "value": "ClusterUnreachable", + "name": "CLUSTER_UNREACHABLE" + }, + { + "value": "ConfigurationConflict", + "name": "CONFIGURATION_CONFLICT" + }, + { + "value": "InternalFailure", + "name": "INTERNAL_FAILURE" + }, + { + "value": "ResourceLimitExceeded", + "name": "RESOURCE_LIMIT_EXCEEDED" + }, + { + "value": "ResourceNotFound", + "name": "RESOURCE_NOT_FOUND" + } + ] + } + }, + "com.amazonaws.eks#ClusterIssueList": { + "type": "list", + "member": { + "target": "com.amazonaws.eks#ClusterIssue" + } + }, "com.amazonaws.eks#ClusterName": { "type": "string", "traits": { @@ -1082,7 +1181,7 @@ "resolveConflicts": { "target": "com.amazonaws.eks#ResolveConflicts", "traits": { - "smithy.api#documentation": "

How to resolve parameter value conflicts when migrating an existing add-on to an\n Amazon EKS add-on.

" + "smithy.api#documentation": "

How to resolve field value conflicts for an Amazon EKS add-on. Conflicts are\n handled based on the value you choose:

\n \n

If you don't currently have the self-managed version of the add-on installed on your\n cluster, the Amazon EKS add-on is installed. Amazon EKS sets all values\n to default values, regardless of the option that you specify.

" } }, "clientRequestToken": { @@ -1140,7 +1239,7 @@ } ], "traits": { - "smithy.api#documentation": "

Creates an Amazon EKS control plane.

\n

The Amazon EKS control plane consists of control plane instances that run the Kubernetes\n software, such as etcd and the API server. The control plane runs in an\n account managed by Amazon Web Services, and the Kubernetes API is exposed by the Amazon EKS API server\n endpoint. Each Amazon EKS cluster control plane is single tenant and unique. It runs on its\n own set of Amazon EC2 instances.

\n

The cluster control plane is provisioned across multiple Availability Zones and\n fronted by an Elastic Load Balancing Network Load Balancer. Amazon EKS also provisions elastic network interfaces in your VPC\n subnets to provide connectivity from the control plane instances to the nodes (for\n example, to support kubectl exec, logs, and proxy\n data flows).

\n

Amazon EKS nodes run in your Amazon Web Services account and connect to your cluster's control plane over\n the Kubernetes API server endpoint and a certificate file that is created for your\n cluster.

\n \n

In most cases, it takes several minutes to create a cluster. After you create an Amazon EKS cluster,\n you must configure your Kubernetes tooling to communicate with the API server and launch\n nodes into your cluster. For more information, see Managing Cluster\n Authentication and Launching Amazon EKS nodes in the\n Amazon EKS User Guide.

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

Creates an Amazon EKS control plane.

\n

The Amazon EKS control plane consists of control plane instances that run the\n Kubernetes software, such as etcd and the API server. The control plane\n runs in an account managed by Amazon Web Services, and the Kubernetes API is exposed by\n the Amazon EKS API server endpoint. Each Amazon EKS cluster control\n plane is single tenant and unique. It runs on its own set of Amazon EC2\n instances.

\n

The cluster control plane is provisioned across multiple Availability Zones and\n fronted by an Elastic Load Balancing\n Network Load Balancer. Amazon EKS also provisions elastic network interfaces in\n your VPC subnets to provide connectivity from the control plane instances to the nodes\n (for example, to support kubectl exec, logs, and\n proxy data flows).

\n

Amazon EKS nodes run in your Amazon Web Services account and connect to your\n cluster's control plane over the Kubernetes API server endpoint and a certificate file\n that is created for your cluster.

\n \n

In most cases, it takes several minutes to create a cluster. After you create an\n Amazon EKS cluster, you must configure your Kubernetes tooling to\n communicate with the API server and launch nodes into your cluster. For more\n information, see Managing Cluster Authentication and Launching\n Amazon EKS nodes in the Amazon EKS User Guide.

", "smithy.api#http": { "method": "POST", "uri": "/clusters", @@ -1161,7 +1260,7 @@ "version": { "target": "com.amazonaws.eks#String", "traits": { - "smithy.api#documentation": "

The desired Kubernetes version for your cluster. If you don't specify a value here,\n the latest version available in Amazon EKS is used.

" + "smithy.api#documentation": "

The desired Kubernetes version for your cluster. If you don't specify a value here,\n the default version available in Amazon EKS is used.

\n \n

The default version might not be the latest version available.

\n
" } }, "roleArn": { @@ -1174,7 +1273,7 @@ "resourcesVpcConfig": { "target": "com.amazonaws.eks#VpcConfigRequest", "traits": { - "smithy.api#documentation": "

The VPC configuration that's used by the cluster control plane. Amazon EKS VPC resources have\n specific requirements to work properly with Kubernetes. For more information, see Cluster VPC\n Considerations and Cluster Security Group Considerations in the\n Amazon EKS User Guide. You must specify at least two subnets. You can specify up to five\n security groups. However, we recommend that you use a dedicated security group for your\n cluster control plane.

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

The VPC configuration that's used by the cluster control plane. Amazon EKS VPC\n resources have specific requirements to work properly with Kubernetes. For more\n information, see Cluster VPC Considerations and Cluster Security\n Group Considerations in the Amazon EKS User Guide. You must specify at least two\n subnets. You can specify up to five security groups. However, we recommend that you use\n a dedicated security group for your cluster control plane.

", "smithy.api#required": {} } }, @@ -1208,6 +1307,12 @@ "traits": { "smithy.api#documentation": "

The encryption configuration for the cluster.

" } + }, + "outpostConfig": { + "target": "com.amazonaws.eks#OutpostConfigRequest", + "traits": { + "smithy.api#documentation": "

An object representing the configuration of your local Amazon EKS cluster on\n an Amazon Web Services Outpost. Before creating a local cluster on an Outpost, review\n Creating an Amazon EKS cluster on an Amazon Web Services Outpost in\n the Amazon EKS User Guide. This object isn't available for creating Amazon EKS\n clusters on the Amazon Web Services\n cloud.

" + } } } }, @@ -1306,7 +1411,7 @@ "tags": { "target": "com.amazonaws.eks#TagMap", "traits": { - "smithy.api#documentation": "

The metadata to apply to the Fargate profile to assist with categorization and\n organization. Each tag consists of a key and an optional value. You define both.\n Fargate profile tags do not propagate to any other resources associated with the\n Fargate profile, such as the pods that are scheduled with it.

" + "smithy.api#documentation": "

The metadata to apply to the Fargate profile to assist with\n categorization and organization. Each tag consists of a key and an optional value. You\n define both. Fargate profile tags do not propagate to any other resources\n associated with the Fargate profile, such as the pods that are scheduled\n with it.

" } } } @@ -1433,13 +1538,13 @@ "taints": { "target": "com.amazonaws.eks#taintsList", "traits": { - "smithy.api#documentation": "

The Kubernetes taints to be applied to the nodes in the node group. For more information, see Node taints on managed node groups.

" + "smithy.api#documentation": "

The Kubernetes taints to be applied to the nodes in the node group. For more\n information, see Node taints on\n managed node groups.

" } }, "tags": { "target": "com.amazonaws.eks#TagMap", "traits": { - "smithy.api#documentation": "

The metadata to apply to the node group to assist with categorization and\n organization. Each tag consists of a key and an optional value. You\n define both. Node group tags do not propagate to any other resources associated with the node\n group, such as the Amazon EC2 instances or subnets.

" + "smithy.api#documentation": "

The metadata to apply to the node group to assist with categorization and\n organization. Each tag consists of a key and an optional value. You define both. Node\n group tags do not propagate to any other resources associated with the node group, such\n as the Amazon EC2 instances or subnets.

" } }, "clientRequestToken": { @@ -2317,7 +2422,7 @@ "identityProviderConfig": { "target": "com.amazonaws.eks#IdentityProviderConfig", "traits": { - "smithy.api#documentation": "

An object that represents an identity provider configuration.

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

An object representing an identity provider configuration.

", "smithy.api#required": {} } } @@ -2576,7 +2681,7 @@ "identityProviderConfig": { "target": "com.amazonaws.eks#IdentityProviderConfig", "traits": { - "smithy.api#documentation": "

An object that represents an identity provider configuration.

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

An object representing an identity provider configuration.

", "smithy.api#required": {} } }, @@ -2790,7 +2895,7 @@ "tags": { "target": "com.amazonaws.eks#TagMap", "traits": { - "smithy.api#documentation": "

The metadata applied to the Fargate profile to assist with categorization and\n organization. Each tag consists of a key and an optional value. You define both.\n Fargate profile tags do not propagate to any other resources associated with the\n Fargate profile, such as the pods that are scheduled with it.

" + "smithy.api#documentation": "

The metadata applied to the Fargate profile to assist with\n categorization and organization. Each tag consists of a key and an optional value. You\n define both. Fargate profile tags do not propagate to any other resources\n associated with the Fargate profile, such as the pods that are scheduled\n with it.

" } } }, @@ -2912,7 +3017,7 @@ "oidc": { "target": "com.amazonaws.eks#OidcIdentityProviderConfig", "traits": { - "smithy.api#documentation": "

An object that represents an OpenID Connect (OIDC) identity provider\n configuration.

" + "smithy.api#documentation": "

An object representing an OpenID Connect (OIDC) identity provider\n configuration.

" } } }, @@ -3015,7 +3120,7 @@ "code": { "target": "com.amazonaws.eks#NodegroupIssueCode", "traits": { - "smithy.api#documentation": "

A brief description of the error.

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

A brief description of the error.

\n " } }, "message": { @@ -3093,24 +3198,24 @@ "name": { "target": "com.amazonaws.eks#String", "traits": { - "smithy.api#documentation": "

The name of the launch template.

" + "smithy.api#documentation": "

The name of the launch template.

\n

You must specify either the launch template name or the launch template ID in the\n request, but not both.

" } }, "version": { "target": "com.amazonaws.eks#String", "traits": { - "smithy.api#documentation": "

The version of the launch template to use. If no version is specified, then the\n template's default version is used.

" + "smithy.api#documentation": "

The launch template version number, $Latest, or\n $Default.

\n

If the value is $Latest, Amazon EKS uses the latest version of\n the launch template.

\n

If the value is $Default, Amazon EKS uses the default version of\n the launch template.

\n

Default: The default version of the launch template.

" } }, "id": { "target": "com.amazonaws.eks#String", "traits": { - "smithy.api#documentation": "

The ID of the launch template.

" + "smithy.api#documentation": "

The ID of the launch template.

\n

You must specify either the launch template ID or the launch template name in the\n request, but not both.

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

An object representing a node group launch template specification. The launch template\n cannot include \n SubnetId\n , \n IamInstanceProfile\n , \n RequestSpotInstances\n , \n HibernationOptions\n , or \n TerminateInstances\n , or the node group deployment or\n update will fail. For more information about launch templates, see \n CreateLaunchTemplate\n in the Amazon EC2 API\n Reference. For more information about using launch templates with Amazon EKS, see Launch template support in the Amazon EKS User Guide.

\n

Specify either name or id, but not both.

" + "smithy.api#documentation": "

An object representing a node group launch template specification. The launch template\n can't include \n SubnetId\n , \n IamInstanceProfile\n , \n RequestSpotInstances\n , \n HibernationOptions\n , or \n TerminateInstances\n , or the node group deployment or\n update will fail. For more information about launch templates, see \n CreateLaunchTemplate\n in the Amazon EC2 API\n Reference. For more information about using launch templates with Amazon EKS, see Launch template support in the Amazon EKS User Guide.

\n

You must specify either the launch template ID or the launch template name in the\n request, but not both.

" } }, "com.amazonaws.eks#ListAddons": { @@ -3264,7 +3369,7 @@ "include": { "target": "com.amazonaws.eks#IncludeClustersList", "traits": { - "smithy.api#documentation": "

Indicates whether external clusters are included in the returned list. Use 'all' to return connected clusters, or blank to return only Amazon EKS clusters. 'all' must be in lowercase otherwise an error occurs.

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

Indicates whether external clusters are included in the returned list. Use\n 'all' to return connected clusters, or blank to return only Amazon EKS clusters. 'all' must be in lowercase otherwise an error\n occurs.

", "smithy.api#httpQuery": "include" } } @@ -3931,7 +4036,7 @@ "tags": { "target": "com.amazonaws.eks#TagMap", "traits": { - "smithy.api#documentation": "

The metadata applied to the node group to assist with categorization and organization.\n Each tag consists of a key and an optional value. You define both. Node group\n tags do not propagate to any other resources associated with the node group, such as the\n Amazon EC2 instances or subnets.

" + "smithy.api#documentation": "

The metadata applied to the node group to assist with categorization and organization.\n Each tag consists of a key and an optional value. You define both. Node group tags do\n not propagate to any other resources associated with the node group, such as the Amazon EC2 instances or subnets.

" } } }, @@ -4250,7 +4355,7 @@ } }, "traits": { - "smithy.api#documentation": "

An object that represents the configuration for an OpenID Connect (OIDC) identity\n provider.

" + "smithy.api#documentation": "

An object representing the configuration for an OpenID Connect (OIDC) identity\n provider.

" } }, "com.amazonaws.eks#OidcIdentityProviderConfigRequest": { @@ -4312,6 +4417,50 @@ "smithy.api#documentation": "

An object representing an OpenID Connect (OIDC) configuration. Before associating an\n OIDC identity provider to your cluster, review the considerations in Authenticating\n users for your cluster from an OpenID Connect identity provider in the\n Amazon EKS User Guide.

" } }, + "com.amazonaws.eks#OutpostConfigRequest": { + "type": "structure", + "members": { + "outpostArns": { + "target": "com.amazonaws.eks#StringList", + "traits": { + "smithy.api#documentation": "

The ARN of the Outpost that you want to use for your local Amazon EKS\n cluster on Outposts. Only a single Outpost ARN is\n supported.

", + "smithy.api#required": {} + } + }, + "controlPlaneInstanceType": { + "target": "com.amazonaws.eks#String", + "traits": { + "smithy.api#documentation": "

The Amazon EC2 instance type that you want to use for your local Amazon EKS cluster on Outposts. The instance type that you specify is used for all\nKubernetes control plane instances. The instance type can't be changed after cluster\n creation.

\n

Choose an instance type based on the number of nodes that your cluster will have. If\n your cluster will have:

\n \n

For a list of the available Amazon EC2 instance types, see Compute and storage\n in Outposts rack\n features. The control plane is not automatically scaled by Amazon EKS.

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

The configuration of your local Amazon EKS cluster on an Amazon Web Services\n Outpost. Before creating a cluster on an Outpost, review Creating a local Amazon EKS cluster on an Amazon Web Services Outpost in the\n Amazon EKS User Guide. This API isn't available for Amazon EKS clusters on the\n Amazon Web Services cloud.

" + } + }, + "com.amazonaws.eks#OutpostConfigResponse": { + "type": "structure", + "members": { + "outpostArns": { + "target": "com.amazonaws.eks#StringList", + "traits": { + "smithy.api#documentation": "

The ARN of the Outpost that you specified for use with your local Amazon EKS\n cluster on Outposts.

", + "smithy.api#required": {} + } + }, + "controlPlaneInstanceType": { + "target": "com.amazonaws.eks#String", + "traits": { + "smithy.api#documentation": "

The Amazon EC2 instance type used for the control plane. The instance type is\n the same for all control plane\n instances.

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

An object representing the configuration of your local Amazon EKS cluster on\n an Amazon Web Services Outpost. This API isn't available for Amazon EKS clusters\n on the Amazon Web Services cloud.

" + } + }, "com.amazonaws.eks#PercentCapacity": { "type": "integer", "traits": { @@ -4450,6 +4599,10 @@ { "value": "NONE", "name": "NONE" + }, + { + "value": "PRESERVE", + "name": "PRESERVE" } ] } @@ -4549,7 +4702,7 @@ } }, "traits": { - "smithy.api#documentation": "

Required resources (such as service-linked roles) were created and are still propagating. Retry later.

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

Required resources (such as service-linked roles) were created and are still\n propagating. Retry later.

", "smithy.api#error": "client", "smithy.api#httpError": 428 } @@ -4951,7 +5104,7 @@ "resolveConflicts": { "target": "com.amazonaws.eks#ResolveConflicts", "traits": { - "smithy.api#documentation": "

How to resolve parameter value conflicts when applying the new version of the add-on\n to the cluster.

" + "smithy.api#documentation": "

How to resolve field value conflicts for an Amazon EKS add-on if you've\n changed a value from the Amazon EKS default value. Conflicts are handled based\n on the option you choose:

\n " } }, "clientRequestToken": { @@ -5205,7 +5358,7 @@ "taints": { "target": "com.amazonaws.eks#UpdateTaintsPayload", "traits": { - "smithy.api#documentation": "

The Kubernetes taints to be applied to the nodes in the node group after the\n update. For more information, see Node taints on managed node groups.

" + "smithy.api#documentation": "

The Kubernetes taints to be applied to the nodes in the node group after the update.\n For more information, see Node taints on\n managed node groups.

" } }, "scalingConfig": { @@ -5499,7 +5652,7 @@ } }, "traits": { - "smithy.api#documentation": "

An object representing the details of an update to a taints payload. For more information, see Node taints on managed node groups.

" + "smithy.api#documentation": "

An object representing the details of an update to a taints payload. For more\n information, see Node taints on\n managed node groups.

" } }, "com.amazonaws.eks#UpdateType": { diff --git a/codegen/sdk-codegen/aws-models/emr-containers.json b/codegen/sdk-codegen/aws-models/emr-containers.json index bbdb988e8a1..63eec7ca4b9 100644 --- a/codegen/sdk-codegen/aws-models/emr-containers.json +++ b/codegen/sdk-codegen/aws-models/emr-containers.json @@ -41,6 +41,21 @@ }, "com.amazonaws.emrcontainers#AwsChicagoWebService": { "type": "service", + "traits": { + "aws.api#service": { + "sdkId": "EMR containers", + "arnNamespace": "emr-containers", + "cloudFormationName": "EMRcontainers", + "cloudTrailEventSource": "emrcontainers.amazonaws.com", + "endpointPrefix": "emr-containers" + }, + "aws.auth#sigv4": { + "name": "emr-containers" + }, + "aws.protocols#restJson1": {}, + "smithy.api#documentation": "

Amazon EMR on EKS provides a deployment option for Amazon EMR that allows you to run\n open-source big data frameworks on Amazon Elastic Kubernetes Service (Amazon EKS). With\n this deployment option, you can focus on running analytics workloads while Amazon EMR on\n EKS builds, configures, and manages containers for open-source applications. For more\n information about Amazon EMR on EKS concepts and tasks, see What is Amazon EMR on\n EKS.

\n

\n Amazon EMR containers is the API name for Amazon EMR on EKS. The\n emr-containers prefix is used in the following scenarios:

\n ", + "smithy.api#title": "Amazon EMR Containers" + }, "version": "2020-10-01", "operations": [ { @@ -88,22 +103,7 @@ { "target": "com.amazonaws.emrcontainers#UntagResource" } - ], - "traits": { - "aws.api#service": { - "sdkId": "EMR containers", - "arnNamespace": "emr-containers", - "cloudFormationName": "EMRcontainers", - "cloudTrailEventSource": "emrcontainers.amazonaws.com", - "endpointPrefix": "emr-containers" - }, - "aws.auth#sigv4": { - "name": "emr-containers" - }, - "aws.protocols#restJson1": {}, - "smithy.api#documentation": "

Amazon EMR on EKS provides a deployment option for Amazon EMR that allows you to run\n open-source big data frameworks on Amazon Elastic Kubernetes Service (Amazon EKS). With\n this deployment option, you can focus on running analytics workloads while Amazon EMR on\n EKS builds, configures, and manages containers for open-source applications. For more\n information about Amazon EMR on EKS concepts and tasks, see What is Amazon EMR on EKS.

\n

\n Amazon EMR containers is the API name for Amazon EMR on EKS. The\n emr-containers prefix is used in the following scenarios:

\n ", - "smithy.api#title": "Amazon EMR Containers" - } + ] }, "com.amazonaws.emrcontainers#Base64Encoded": { "type": "string", @@ -132,7 +132,7 @@ } ], "traits": { - "smithy.api#documentation": "

Cancels a job run. A job run is a unit of work, such as a Spark jar, PySpark script, or SparkSQL query, that you submit to Amazon EMR on EKS.

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

Cancels a job run. A job run is a unit of work, such as a Spark jar, PySpark script, or\n SparkSQL query, that you submit to Amazon EMR on EKS.

", "smithy.api#http": { "method": "DELETE", "uri": "/virtualclusters/{virtualClusterId}/jobruns/{id}", @@ -226,7 +226,7 @@ } }, "traits": { - "smithy.api#documentation": "

A configuration for CloudWatch monitoring. You can configure your jobs to send log information to CloudWatch Logs.

" + "smithy.api#documentation": "

A configuration for CloudWatch monitoring. You can configure your jobs to send log\n information to CloudWatch Logs.

" } }, "com.amazonaws.emrcontainers#ClusterId": { @@ -263,7 +263,7 @@ } }, "traits": { - "smithy.api#documentation": "

A configuration specification to be used when provisioning virtual clusters, which can include configurations for applications and software bundled with Amazon EMR on EKS. A configuration consists of a classification, properties, and optional nested configurations. A classification refers to an application-specific configuration file. Properties are the settings you want to change in that file.

" + "smithy.api#documentation": "

A configuration specification to be used when provisioning virtual clusters, which can\n include configurations for applications and software bundled with Amazon EMR on EKS. A\n configuration consists of a classification, properties, and optional nested configurations.\n A classification refers to an application-specific configuration file. Properties are the\n settings you want to change in that file.

" } }, "com.amazonaws.emrcontainers#ConfigurationList": { @@ -371,7 +371,7 @@ } ], "traits": { - "smithy.api#documentation": "

Creates a managed endpoint. A managed endpoint is a gateway that connects EMR Studio to Amazon EMR on EKS so that EMR Studio can communicate with your virtual cluster.

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

Creates a managed endpoint. A managed endpoint is a gateway that connects EMR Studio to\n Amazon EMR on EKS so that EMR Studio can communicate with your virtual cluster.

", "smithy.api#http": { "method": "POST", "uri": "/virtualclusters/{virtualClusterId}/endpoints", @@ -424,7 +424,7 @@ "smithy.api#deprecated": { "message": "Customer provided certificate-arn is deprecated and would be removed in future." }, - "smithy.api#documentation": "

The certificate ARN provided by users for the managed endpoint. This fiedd is under deprecation and will be removed in future releases.

" + "smithy.api#documentation": "

The certificate ARN provided by users for the managed endpoint. This field is under\n deprecation and will be removed in future releases.

" } }, "configurationOverrides": { @@ -444,7 +444,7 @@ "tags": { "target": "com.amazonaws.emrcontainers#TagMap", "traits": { - "smithy.api#documentation": "

The tags of the managed endpoint.\n

" + "smithy.api#documentation": "

The tags of the managed endpoint.

" } } } @@ -498,7 +498,7 @@ } ], "traits": { - "smithy.api#documentation": "

Creates a virtual cluster. Virtual cluster is a managed entity on Amazon EMR on EKS. You can create, describe, list and delete virtual clusters. They do not consume any additional resource in your system. A single virtual cluster maps to a single Kubernetes namespace. Given this relationship, you can model virtual clusters the same way you model Kubernetes namespaces to meet your requirements.

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

Creates a virtual cluster. Virtual cluster is a managed entity on Amazon EMR on EKS. You\n can create, describe, list and delete virtual clusters. They do not consume any additional\n resource in your system. A single virtual cluster maps to a single Kubernetes namespace.\n Given this relationship, you can model virtual clusters the same way you model Kubernetes\n namespaces to meet your requirements.

", "smithy.api#http": { "method": "POST", "uri": "/virtualclusters", @@ -585,7 +585,7 @@ } ], "traits": { - "smithy.api#documentation": "

Deletes a managed endpoint. A managed endpoint is a gateway that connects EMR Studio to Amazon EMR on EKS so that EMR Studio can communicate with your virtual cluster.

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

Deletes a managed endpoint. A managed endpoint is a gateway that connects EMR Studio to\n Amazon EMR on EKS so that EMR Studio can communicate with your virtual cluster.

", "smithy.api#http": { "method": "DELETE", "uri": "/virtualclusters/{virtualClusterId}/endpoints/{id}", @@ -648,7 +648,7 @@ } ], "traits": { - "smithy.api#documentation": "

Deletes a virtual cluster. Virtual cluster is a managed entity on Amazon EMR on EKS. You can create, describe, list and delete virtual clusters. They do not consume any additional resource in your system. A single virtual cluster maps to a single Kubernetes namespace. Given this relationship, you can model virtual clusters the same way you model Kubernetes namespaces to meet your requirements.

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

Deletes a virtual cluster. Virtual cluster is a managed entity on Amazon EMR on EKS. You\n can create, describe, list and delete virtual clusters. They do not consume any additional\n resource in your system. A single virtual cluster maps to a single Kubernetes namespace.\n Given this relationship, you can model virtual clusters the same way you model Kubernetes\n namespaces to meet your requirements.

", "smithy.api#http": { "method": "DELETE", "uri": "/virtualclusters/{id}", @@ -700,7 +700,7 @@ } ], "traits": { - "smithy.api#documentation": "

Displays detailed information about a job run. A job run is a unit of work, such as a Spark jar, PySpark script, or SparkSQL query, that you submit to Amazon EMR on EKS.

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

Displays detailed information about a job run. A job run is a unit of work, such as a\n Spark jar, PySpark script, or SparkSQL query, that you submit to Amazon EMR on EKS.

", "smithy.api#http": { "method": "GET", "uri": "/virtualclusters/{virtualClusterId}/jobruns/{id}", @@ -760,7 +760,7 @@ } ], "traits": { - "smithy.api#documentation": "

Displays detailed information about a managed endpoint. A managed endpoint is a gateway that connects EMR Studio to Amazon EMR on EKS so that EMR Studio can communicate with your virtual cluster.

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

Displays detailed information about a managed endpoint. A managed endpoint is a gateway\n that connects EMR Studio to Amazon EMR on EKS so that EMR Studio can communicate with your\n virtual cluster.

", "smithy.api#http": { "method": "GET", "uri": "/virtualclusters/{virtualClusterId}/endpoints/{id}", @@ -820,7 +820,7 @@ } ], "traits": { - "smithy.api#documentation": "

Displays detailed information about a specified virtual cluster. Virtual cluster is a managed entity on Amazon EMR on EKS. You can create, describe, list and delete virtual clusters. They do not consume any additional resource in your system. A single virtual cluster maps to a single Kubernetes namespace. Given this relationship, you can model virtual clusters the same way you model Kubernetes namespaces to meet your requirements.

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

Displays detailed information about a specified virtual cluster. Virtual cluster is a\n managed entity on Amazon EMR on EKS. You can create, describe, list and delete virtual\n clusters. They do not consume any additional resource in your system. A single virtual\n cluster maps to a single Kubernetes namespace. Given this relationship, you can model\n virtual clusters the same way you model Kubernetes namespaces to meet your\n requirements.

", "smithy.api#http": { "method": "GET", "uri": "/virtualclusters/{id}", @@ -923,7 +923,7 @@ "smithy.api#deprecated": { "message": "Customer provided certificate-arn is deprecated and would be removed in future." }, - "smithy.api#documentation": "

The certificate ARN of the endpoint. This field is under deprecation and will be removed in future.

" + "smithy.api#documentation": "

The certificate ARN of the endpoint. This field is under deprecation and will be removed\n in future.

" } }, "certificateAuthority": { @@ -935,7 +935,7 @@ "configurationOverrides": { "target": "com.amazonaws.emrcontainers#ConfigurationOverrides", "traits": { - "smithy.api#documentation": "

The configuration settings that are used to override existing configurations for endpoints.

" + "smithy.api#documentation": "

The configuration settings that are used to override existing configurations for\n endpoints.

" } }, "serverUrl": { @@ -953,31 +953,31 @@ "securityGroup": { "target": "com.amazonaws.emrcontainers#String256", "traits": { - "smithy.api#documentation": "

The security group configuration of the endpoint. \n

" + "smithy.api#documentation": "

The security group configuration of the endpoint.

" } }, "subnetIds": { "target": "com.amazonaws.emrcontainers#SubnetIds", "traits": { - "smithy.api#documentation": "

The subnet IDs of the endpoint.\n

" + "smithy.api#documentation": "

The subnet IDs of the endpoint.

" } }, "stateDetails": { "target": "com.amazonaws.emrcontainers#String256", "traits": { - "smithy.api#documentation": "

\n Additional details of the endpoint state.\n

" + "smithy.api#documentation": "

Additional details of the endpoint state.

" } }, "failureReason": { "target": "com.amazonaws.emrcontainers#FailureReason", "traits": { - "smithy.api#documentation": "

\n The reasons why the endpoint has failed.\n

" + "smithy.api#documentation": "

The reasons why the endpoint has failed.

" } }, "tags": { "target": "com.amazonaws.emrcontainers#TagMap", "traits": { - "smithy.api#documentation": "

The tags of the endpoint. \n

" + "smithy.api#documentation": "

The tags of the endpoint.

" } } }, @@ -1069,7 +1069,7 @@ "min": 1, "max": 10280 }, - "smithy.api#pattern": "^(?!\\s*$)(^[^';|\\u0026\\u003C\\u003E*?`$(){}\\[\\]!#\\\\]*$)$", + "smithy.api#pattern": "\\S", "smithy.api#sensitive": {} } }, @@ -1086,7 +1086,7 @@ "min": 1, "max": 256 }, - "smithy.api#pattern": "^(?!\\s*$)(^[^';|\\u0026\\u003C\\u003E*?`$(){}\\[\\]!#\\\\]*$)$", + "smithy.api#pattern": "\\S", "smithy.api#sensitive": {} } }, @@ -1160,6 +1160,12 @@ "traits": { "smithy.api#documentation": "

The job driver parameters specified for spark submit.

" } + }, + "sparkSqlJobDriver": { + "target": "com.amazonaws.emrcontainers#SparkSqlJobDriver", + "traits": { + "smithy.api#documentation": "

The job driver for job type.

" + } } }, "traits": { @@ -1267,7 +1273,7 @@ } }, "traits": { - "smithy.api#documentation": "

This entity describes a job run. A job run is a unit of work, such as a Spark jar, PySpark script, or SparkSQL query, that you submit to Amazon EMR on EKS.

" + "smithy.api#documentation": "

This entity describes a job run. A job run is a unit of work, such as a Spark jar,\n PySpark script, or SparkSQL query, that you submit to Amazon EMR on EKS.

" } }, "com.amazonaws.emrcontainers#JobRunState": { @@ -1350,7 +1356,7 @@ } ], "traits": { - "smithy.api#documentation": "

Lists job runs based on a set of parameters. A job run is a unit of work, such as a Spark jar, PySpark script, or SparkSQL query, that you submit to Amazon EMR on EKS.

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

Lists job runs based on a set of parameters. A job run is a unit of work, such as a\n Spark jar, PySpark script, or SparkSQL query, that you submit to Amazon EMR on EKS.

", "smithy.api#http": { "method": "GET", "uri": "/virtualclusters/{virtualClusterId}/jobruns", @@ -1359,6 +1365,7 @@ "smithy.api#paginated": { "inputToken": "nextToken", "outputToken": "nextToken", + "items": "jobRuns", "pageSize": "maxResults" } } @@ -1452,7 +1459,7 @@ } ], "traits": { - "smithy.api#documentation": "

Lists managed endpoints based on a set of parameters. A managed endpoint is a gateway that connects EMR Studio to Amazon EMR on EKS so that EMR Studio can communicate with your virtual cluster.

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

Lists managed endpoints based on a set of parameters. A managed endpoint is a gateway\n that connects EMR Studio to Amazon EMR on EKS so that EMR Studio can communicate with your\n virtual cluster.

", "smithy.api#http": { "method": "GET", "uri": "/virtualclusters/{virtualClusterId}/endpoints", @@ -1461,6 +1468,7 @@ "smithy.api#paginated": { "inputToken": "nextToken", "outputToken": "nextToken", + "items": "endpoints", "pageSize": "maxResults" } } @@ -1606,7 +1614,7 @@ } ], "traits": { - "smithy.api#documentation": "

Lists information about the specified virtual cluster. Virtual cluster is a managed entity on Amazon EMR on EKS. You can create, describe, list and delete virtual clusters. They do not consume any additional resource in your system. A single virtual cluster maps to a single Kubernetes namespace. Given this relationship, you can model virtual clusters the same way you model Kubernetes namespaces to meet your requirements.

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

Lists information about the specified virtual cluster. Virtual cluster is a managed\n entity on Amazon EMR on EKS. You can create, describe, list and delete virtual clusters.\n They do not consume any additional resource in your system. A single virtual cluster maps\n to a single Kubernetes namespace. Given this relationship, you can model virtual clusters\n the same way you model Kubernetes namespaces to meet your requirements.

", "smithy.api#http": { "method": "GET", "uri": "/virtualclusters", @@ -1615,6 +1623,7 @@ "smithy.api#paginated": { "inputToken": "nextToken", "outputToken": "nextToken", + "items": "virtualClusters", "pageSize": "maxResults" } } @@ -1632,7 +1641,7 @@ "containerProviderType": { "target": "com.amazonaws.emrcontainers#ContainerProviderType", "traits": { - "smithy.api#documentation": "

The container provider type of the virtual cluster. EKS is the only supported type as of now.

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

The container provider type of the virtual cluster. EKS is the only supported type as of\n now.

", "smithy.api#httpQuery": "containerProviderType" } }, @@ -1826,7 +1835,7 @@ } }, "traits": { - "smithy.api#documentation": "

Amazon S3 configuration for monitoring log publishing. You can configure your jobs to send log information to Amazon S3.

" + "smithy.api#documentation": "

Amazon S3 configuration for monitoring log publishing. You can configure your jobs to\n send log information to Amazon S3.

" } }, "com.amazonaws.emrcontainers#SensitivePropertiesMap": { @@ -1845,6 +1854,37 @@ "smithy.api#sensitive": {} } }, + "com.amazonaws.emrcontainers#SparkSqlJobDriver": { + "type": "structure", + "members": { + "entryPoint": { + "target": "com.amazonaws.emrcontainers#EntryPointPath", + "traits": { + "smithy.api#documentation": "

The SQL file to be executed.

" + } + }, + "sparkSqlParameters": { + "target": "com.amazonaws.emrcontainers#SparkSqlParameters", + "traits": { + "smithy.api#documentation": "

The Spark parameters to be included in the Spark SQL command.

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

The job driver for job type.

" + } + }, + "com.amazonaws.emrcontainers#SparkSqlParameters": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 1, + "max": 102400 + }, + "smithy.api#pattern": "\\S", + "smithy.api#sensitive": {} + } + }, "com.amazonaws.emrcontainers#SparkSubmitJobDriver": { "type": "structure", "members": { @@ -1879,7 +1919,7 @@ "min": 1, "max": 102400 }, - "smithy.api#pattern": "^(?!\\s*$)(^[^';|\\u0026\\u003C\\u003E*?`$(){}\\[\\]!#\\\\]*$)$", + "smithy.api#pattern": "\\S", "smithy.api#sensitive": {} } }, @@ -1903,7 +1943,7 @@ } ], "traits": { - "smithy.api#documentation": "

Starts a job run. A job run is a unit of work, such as a Spark jar, PySpark script, or SparkSQL query, that you submit to Amazon EMR on EKS.

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

Starts a job run. A job run is a unit of work, such as a Spark jar, PySpark script, or\n SparkSQL query, that you submit to Amazon EMR on EKS.

", "smithy.api#http": { "method": "POST", "uri": "/virtualclusters/{virtualClusterId}/jobruns", @@ -2093,7 +2133,7 @@ } ], "traits": { - "smithy.api#documentation": "

Assigns tags to resources. A tag is a label that you assign to an AWS resource. Each tag consists of a key and an optional value, both of which you define. Tags enable you to categorize your AWS resources by attributes such as purpose, owner, or environment. When you have many resources of the same type, you can quickly identify a specific resource based on the tags you've assigned to it. For example, you can define a set of tags for your Amazon EMR on EKS clusters to help you track each cluster's owner and stack level. We recommend that you devise a consistent set of tag keys for each resource type. You can then search and filter the resources based on the tags that you add.

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

Assigns tags to resources. A tag is a label that you assign to an AWS resource. Each tag\n consists of a key and an optional value, both of which you define. Tags enable you to\n categorize your AWS resources by attributes such as purpose, owner, or environment. When\n you have many resources of the same type, you can quickly identify a specific resource\n based on the tags you've assigned to it. For example, you can define a set of tags for your\n Amazon EMR on EKS clusters to help you track each cluster's owner and stack level. We\n recommend that you devise a consistent set of tag keys for each resource type. You can then\n search and filter the resources based on the tags that you add.

", "smithy.api#http": { "method": "POST", "uri": "/tags/{resourceArn}", @@ -2248,7 +2288,7 @@ } }, "traits": { - "smithy.api#documentation": "

This entity describes a virtual cluster. A virtual cluster is a Kubernetes namespace that Amazon EMR is registered with. Amazon EMR uses virtual clusters to run jobs and host endpoints. Multiple virtual clusters can be backed by the same physical cluster. However, each virtual cluster maps to one namespace on an EKS cluster. Virtual clusters do not create any active resources that contribute to your bill or that require lifecycle management outside the service.

" + "smithy.api#documentation": "

This entity describes a virtual cluster. A virtual cluster is a Kubernetes namespace\n that Amazon EMR is registered with. Amazon EMR uses virtual clusters to run jobs and host\n endpoints. Multiple virtual clusters can be backed by the same physical cluster. However,\n each virtual cluster maps to one namespace on an EKS cluster. Virtual clusters do not\n create any active resources that contribute to your bill or that require lifecycle\n management outside the service.

" } }, "com.amazonaws.emrcontainers#VirtualClusterArn": { diff --git a/codegen/sdk-codegen/aws-models/evidently.json b/codegen/sdk-codegen/aws-models/evidently.json index 19832efa9ef..1618a4a2a75 100644 --- a/codegen/sdk-codegen/aws-models/evidently.json +++ b/codegen/sdk-codegen/aws-models/evidently.json @@ -1,5 +1,5 @@ { - "smithy": "1.0", + "smithy": "2.0", "shapes": { "com.amazonaws.evidently#AccessDeniedException": { "type": "structure", @@ -14,6 +14,12 @@ "smithy.api#httpError": 403 } }, + "com.amazonaws.evidently#AppConfigResourceId": { + "type": "string", + "traits": { + "smithy.api#pattern": "[a-z0-9]{4,7}" + } + }, "com.amazonaws.evidently#Arn": { "type": "string", "traits": { @@ -242,7 +248,7 @@ "samplingRate": { "target": "com.amazonaws.evidently#SplitWeight", "traits": { - "smithy.api#box": {}, + "smithy.api#default": null, "smithy.api#documentation": "

The portion of the available audience that you want to allocate to this experiment, in thousandths of a percent. The available audience\n is the total audience minus the audience that you have allocated to overrides or current launches of\n this feature.

\n

This is represented in thousandths of a percent. For example, specify 10,000 to allocate 10% of the available audience.

" } }, @@ -536,6 +542,12 @@ "smithy.api#documentation": "

A structure that contains information about where Evidently is to store\n evaluation events for longer term storage, if you choose to do so. If you choose\n not to store these events, Evidently deletes them after using them to produce metrics and other experiment\n results that you can view.

" } }, + "appConfigResource": { + "target": "com.amazonaws.evidently#ProjectAppConfigResourceConfig", + "traits": { + "smithy.api#documentation": "

Use this parameter if the project will use client-side evaluation powered by AppConfig. Client-side\n evaluation allows your application to assign variations to user\n sessions locally instead of by calling the EvaluateFeature operation. This \n mitigates the latency and availability risks that come with an API call. For more information, \n see \n Client-side evaluation - powered by AppConfig.\n

\n

This parameter is a structure that\n contains information about the AppConfig application and environment that will be used as for client-side evaluation.

\n

To create a project that uses client-side evaluation, you must have the\n evidently:ExportProjectAsConfiguration permission.

" + } + }, "tags": { "target": "com.amazonaws.evidently#TagMap", "traits": { @@ -579,7 +591,7 @@ } ], "traits": { - "smithy.api#documentation": "

Use this operation to define a segment of your audience. A segment\n is a portion of your audience that share one or more characteristics. Examples could be Chrome browser users, \n users in Europe, or Firefox browser users in Europe who also fit other criteria that your application collects,\n such as age.

\n

Using a segment in an experiment limits that experiment to evaluate only the users who match the segment \n criteria. Using one or more segments in a launch allow you to define different traffic splits for the different\n audience segments.

\n \n

For more information about segment pattern syntax, see \n \n Segment rule pattern syntax.

\n \n

The pattern that you define for a segment is matched against the value of evaluationContext, which\n is passed into Evidently in the EvaluateFeature operation,\n when Evidently assigns a feature variation to a user.

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

Use this operation to define a segment of your audience. A segment\n is a portion of your audience that share one or more characteristics. Examples could be Chrome browser users, \n users in Europe, or Firefox browser users in Europe who also fit other criteria that your application collects,\n such as age.

\n

Using a segment in an experiment limits that experiment to evaluate only the users who match the segment \n criteria. Using one or more segments in a launch allows you to define different traffic splits for the different\n audience segments.

\n \n

For more information about segment pattern syntax, see \n \n Segment rule pattern syntax.

\n \n

The pattern that you define for a segment is matched against the value of evaluationContext, which\n is passed into Evidently in the EvaluateFeature operation,\n when Evidently assigns a feature variation to a user.

", "smithy.api#http": { "method": "POST", "uri": "/segments", @@ -600,7 +612,7 @@ "pattern": { "target": "com.amazonaws.evidently#SegmentPattern", "traits": { - "smithy.api#documentation": "

The pattern to use for the segment. For more information about pattern syntax, \n see \n Segment rule pattern syntax.

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

The pattern to use for the segment. For more information about pattern syntax, \n see \n Segment rule pattern syntax.

", "smithy.api#required": {} } }, @@ -1285,29 +1297,6 @@ }, "com.amazonaws.evidently#Evidently": { "type": "service", - "traits": { - "aws.api#service": { - "sdkId": "Evidently", - "arnNamespace": "evidently" - }, - "aws.auth#sigv4": { - "name": "evidently" - }, - "aws.protocols#restJson1": {}, - "smithy.api#cors": { - "additionalAllowedHeaders": [ - "Content-Type", - "X-Amz-Date", - "Authorization", - "X-Api-Key", - "X-Amz-Security-Token", - "x-amz-content-sha256", - "X-Amz-User-Agent" - ] - }, - "smithy.api#documentation": "

You can use Amazon CloudWatch Evidently to safely validate new features by serving \n them to a specified percentage\n of your users while you roll out the feature. You can monitor the performance of the new feature\n to help you decide when to ramp up traffic to your users. This helps you \n reduce risk and identify unintended consequences before you fully launch the feature.

\n

You can also conduct A/B experiments to make feature design decisions based on evidence\n and data. An experiment can test as many as five variations at once. Evidently collects\n experiment data and analyzes it using statistical methods. It also provides clear\n recommendations about which variations perform better. You can test both user-facing features\n and backend features.

", - "smithy.api#title": "Amazon CloudWatch Evidently" - }, "version": "2021-02-01", "operations": [ { @@ -1330,7 +1319,30 @@ { "target": "com.amazonaws.evidently#SegmentResource" } - ] + ], + "traits": { + "aws.api#service": { + "sdkId": "Evidently", + "arnNamespace": "evidently" + }, + "aws.auth#sigv4": { + "name": "evidently" + }, + "aws.protocols#restJson1": {}, + "smithy.api#cors": { + "additionalAllowedHeaders": [ + "Content-Type", + "X-Amz-Date", + "Authorization", + "X-Api-Key", + "X-Amz-Security-Token", + "x-amz-content-sha256", + "X-Amz-User-Agent" + ] + }, + "smithy.api#documentation": "

You can use Amazon CloudWatch Evidently to safely validate new features by serving \n them to a specified percentage\n of your users while you roll out the feature. You can monitor the performance of the new feature\n to help you decide when to ramp up traffic to your users. This helps you \n reduce risk and identify unintended consequences before you fully launch the feature.

\n

You can also conduct A/B experiments to make feature design decisions based on evidence\n and data. An experiment can test as many as five variations at once. Evidently collects\n experiment data and analyzes it using statistical methods. It also provides clear\n recommendations about which variations perform better. You can test both user-facing features\n and backend features.

", + "smithy.api#title": "Amazon CloudWatch Evidently" + } }, "com.amazonaws.evidently#Experiment": { "type": "structure", @@ -1421,6 +1433,7 @@ "samplingRate": { "target": "com.amazonaws.evidently#SplitWeight", "traits": { + "smithy.api#default": 0, "smithy.api#documentation": "

In thousandths of a percent, the amount of the available audience that is allocated to this experiment. \n The available audience\n is the total audience minus the audience that you have allocated to overrides or current launches of\n this feature.

\n

This is represented in thousandths of a percent, so a value of 10,000 is 10% of the available audience.

" } }, @@ -2141,7 +2154,7 @@ } ], "traits": { - "smithy.api#documentation": "

Retrieves the results of a running or completed experiment. No results are available until\n there have been 100 events for each variation and at least 10 minutes have passed since the start of the experiment.

\n

Experiment\n results are available up to 63 days after the start of the experiment. They are not available after that because\n of CloudWatch data retention policies.

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

Retrieves the results of a running or completed experiment. No results are available until\n there have been 100 events for each variation and at least 10 minutes have passed since the start of the experiment.\n To increase the statistical power, Evidently performs an additional offline p-value analysis at the end of the experiment.\n Offline p-value analysis can detect statistical significance in some cases where the anytime p-values used during \n the experiment do not find statistical significance.

\n

Experiment\n results are available up to 63 days after the start of the experiment. They are not available after that because\n of CloudWatch data retention policies.

", "smithy.api#http": { "method": "POST", "uri": "/projects/{project}/experiments/{experiment}/results", @@ -2215,6 +2228,7 @@ "period": { "target": "com.amazonaws.evidently#ResultsPeriod", "traits": { + "smithy.api#default": 0, "smithy.api#documentation": "

In seconds, the amount of time to aggregate results together.

" } } @@ -3404,7 +3418,6 @@ "com.amazonaws.evidently#MaxExperiments": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 100 @@ -3414,7 +3427,6 @@ "com.amazonaws.evidently#MaxFeatures": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 100 @@ -3424,7 +3436,6 @@ "com.amazonaws.evidently#MaxLaunches": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 100 @@ -3434,7 +3445,6 @@ "com.amazonaws.evidently#MaxProjects": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 50 @@ -3444,7 +3454,6 @@ "com.amazonaws.evidently#MaxReferences": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 100 @@ -3454,7 +3463,6 @@ "com.amazonaws.evidently#MaxSegments": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 50 @@ -3814,6 +3822,12 @@ "smithy.api#documentation": "

A structure that contains information about where Evidently is to store\n evaluation events for longer term storage.

" } }, + "appConfigResource": { + "target": "com.amazonaws.evidently#ProjectAppConfigResource", + "traits": { + "smithy.api#documentation": "

This structure defines the configuration of how your application \n integrates with AppConfig to run client-side evaluation.

" + } + }, "tags": { "target": "com.amazonaws.evidently#TagMap", "traits": { @@ -3825,6 +3839,55 @@ "smithy.api#documentation": "

This structure defines a project, which is the logical object in Evidently that can contain features, launches, and \n experiments. Use projects to group similar features together.

" } }, + "com.amazonaws.evidently#ProjectAppConfigResource": { + "type": "structure", + "members": { + "applicationId": { + "target": "com.amazonaws.evidently#AppConfigResourceId", + "traits": { + "smithy.api#documentation": "

The ID of the AppConfig application to use for client-side evaluation.

", + "smithy.api#required": {} + } + }, + "environmentId": { + "target": "com.amazonaws.evidently#AppConfigResourceId", + "traits": { + "smithy.api#documentation": "

The ID of the AppConfig environment to use for client-side evaluation. This must be an \n environment that is within the application that you specify for applicationId.

", + "smithy.api#required": {} + } + }, + "configurationProfileId": { + "target": "com.amazonaws.evidently#AppConfigResourceId", + "traits": { + "smithy.api#documentation": "

The ID of the AppConfig profile to use for client-side evaluation.

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

This is a structure that defines the configuration of how your application \n integrates with AppConfig to run client-side evaluation.

" + } + }, + "com.amazonaws.evidently#ProjectAppConfigResourceConfig": { + "type": "structure", + "members": { + "applicationId": { + "target": "com.amazonaws.evidently#AppConfigResourceId", + "traits": { + "smithy.api#documentation": "

The ID of the AppConfig application to use for client-side evaluation.

" + } + }, + "environmentId": { + "target": "com.amazonaws.evidently#AppConfigResourceId", + "traits": { + "smithy.api#documentation": "

The ID of the AppConfig environment to use for client-side evaluation. This must be an \n environment that is within the application that you specify for applicationId.

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

Use this parameter to configure client-side evaluation for your project. Client-side evaluation allows your application to assign \n variations to user\n sessions locally instead of by calling the EvaluateFeature operation to assign the \n variations. This mitigates the latency and availability risks that come with an API call.

\n

\n ProjectAppConfigResource is a structure that defines the configuration of how your application \n integrates with AppConfig to run client-side evaluation.

" + } + }, "com.amazonaws.evidently#ProjectArn": { "type": "string", "traits": { @@ -4283,6 +4346,7 @@ "com.amazonaws.evidently#ResultsPeriod": { "type": "long", "traits": { + "smithy.api#default": 0, "smithy.api#range": { "min": 300, "max": 90000 @@ -4495,7 +4559,7 @@ "pattern": { "target": "com.amazonaws.evidently#SegmentPattern", "traits": { - "smithy.api#documentation": "

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

The pattern that defines the attributes to use to evalute whether a user session will be in the segment. \n For more information about the pattern syntax, see \n Segment rule pattern syntax.

", "smithy.api#required": {} } }, @@ -4722,6 +4786,7 @@ "com.amazonaws.evidently#SplitWeight": { "type": "long", "traits": { + "smithy.api#default": 0, "smithy.api#range": { "min": 0, "max": 100000 @@ -5463,7 +5528,7 @@ "samplingRate": { "target": "com.amazonaws.evidently#SplitWeight", "traits": { - "smithy.api#box": {}, + "smithy.api#default": null, "smithy.api#documentation": "

The portion of the available audience that you want to allocate to this experiment, in thousandths of a percent. The available audience\n is the total audience minus the audience that you have allocated to overrides or current launches of\n this feature.

\n

This is represented in thousandths of a percent. For example, specify 20,000 to allocate 20% of the available audience.

" } }, @@ -5476,6 +5541,7 @@ "removeSegment": { "target": "smithy.api#PrimitiveBoolean", "traits": { + "smithy.api#default": false, "smithy.api#documentation": "

Removes a segment from being used in an experiment. You can't use this parameter if the experiment is currently\n running.

" } }, @@ -5812,6 +5878,12 @@ "smithy.api#required": {} } }, + "appConfigResource": { + "target": "com.amazonaws.evidently#ProjectAppConfigResourceConfig", + "traits": { + "smithy.api#documentation": "

Use this parameter if the project will use client-side evaluation powered by AppConfig. Client-side\n evaluation allows your application to assign variations to user\n sessions locally instead of by calling the EvaluateFeature operation. This \n mitigates the latency and availability risks that come with an API call. allows\n you to

\n

This parameter is a structure that\n contains information about the AppConfig application that will be used for client-side evaluation.

" + } + }, "description": { "target": "com.amazonaws.evidently#Description", "traits": { diff --git a/codegen/sdk-codegen/aws-models/fsx.json b/codegen/sdk-codegen/aws-models/fsx.json index ea48eae69fb..d6162772772 100644 --- a/codegen/sdk-codegen/aws-models/fsx.json +++ b/codegen/sdk-codegen/aws-models/fsx.json @@ -1894,7 +1894,7 @@ "SecurityStyle": { "target": "com.amazonaws.fsx#SecurityStyle", "traits": { - "smithy.api#documentation": "

The security style for the volume. If a volume's security style is not specified, \n it is automatically set to the root volume's security style. \n Specify one of the following values:

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

Specifies the security style for the volume. If a volume's security style is not specified, \n it is automatically set to the root volume's security style. The security style determines the type of permissions \n that FSx for ONTAP uses to control data access. For more information, see \n Volume security style \n in the Amazon FSx for NetApp ONTAP User Guide.\n Specify one of the following values:

\n " } }, "SizeInMegabytes": { @@ -4546,12 +4546,12 @@ "Message": { "target": "com.amazonaws.fsx#ErrorMessage", "traits": { - "smithy.api#documentation": "

A message describing any failures that occurred during file system creation.

" + "smithy.api#documentation": "

A message describing any failures that occurred.

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

A structure providing details of any failures that occurred when creating a file\n system.

" + "smithy.api#documentation": "

A structure providing details of any failures that occurred.

" } }, "com.amazonaws.fsx#FileSystemId": { diff --git a/codegen/sdk-codegen/aws-models/identitystore.json b/codegen/sdk-codegen/aws-models/identitystore.json index c5e83718389..f09b7c98027 100644 --- a/codegen/sdk-codegen/aws-models/identitystore.json +++ b/codegen/sdk-codegen/aws-models/identitystore.json @@ -55,7 +55,7 @@ "name": "identitystore" }, "aws.protocols#awsJson1_1": {}, - "smithy.api#documentation": "

The AWS Single Sign-On (SSO) Identity Store service provides a single place to retrieve all of your\n identities (users and groups). For more information about AWS, see the AWS Single Sign-On User\n Guide.

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

The Identity Store service used by AWS IAM Identity Center (successor to AWS Single Sign-On) provides a single place to retrieve all of\n your identities (users and groups). For more information, see the IAM Identity Center User\n Guide.

\n \n \n

Although AWS Single Sign-On was renamed, the sso and\n identitystore API namespaces will continue to retain their original name for\n backward compatibility purposes. For more information, see IAM Identity Center rename.

\n
\n \n

This reference guide describes the identity store operations that you can call\n programatically and includes detailed information on data types and errors.

", "smithy.api#title": "AWS SSO Identity Store" } }, @@ -84,7 +84,7 @@ "StreetAddress": { "target": "com.amazonaws.identitystore#SensitiveStringType", "traits": { - "smithy.api#documentation": "

The street of the address.

" + "smithy.api#documentation": "

The\n street\n of the address.

" } }, "Locality": { @@ -96,7 +96,7 @@ "Region": { "target": "com.amazonaws.identitystore#SensitiveStringType", "traits": { - "smithy.api#documentation": "

The region of the address.

" + "smithy.api#documentation": "

The\n region\n of the address.

" } }, "PostalCode": { @@ -127,7 +127,7 @@ "target": "com.amazonaws.identitystore#SensitiveBooleanType", "traits": { "smithy.api#default": false, - "smithy.api#documentation": "

A boolean representing whether this is the primary address for the associated resource.

" + "smithy.api#documentation": "

A\n Boolean\n value\n representing whether this is the primary address for the associated\n resource.

" } } }, @@ -164,7 +164,7 @@ } }, "traits": { - "smithy.api#documentation": "

A unique identifier for the group value that is not the group's primary identifier. This value can be\n an identifier from an external identity provider (IdP) that is associated with the group or a unique attribute. For example, a\n unique GroupDisplayName.

" + "smithy.api#documentation": "

A unique identifier for a user or group that is not the its primary identifier. This value can be\n an identifier from an external identity provider (IdP) that is associated with the group or a unique attribute. For example, a\n unique GroupDisplayName.

" } }, "com.amazonaws.identitystore#AttributeOperation": { @@ -180,7 +180,7 @@ "AttributeValue": { "target": "com.amazonaws.identitystore#AttributeValue", "traits": { - "smithy.api#documentation": "

The value of the attribute.

" + "smithy.api#documentation": "

The value of the attribute. This is a Document type.\n This type is not supported by Java V1, Go V1, and older versions of the AWS CLI.

" } } }, @@ -213,7 +213,7 @@ "com.amazonaws.identitystore#AttributeValue": { "type": "document", "traits": { - "smithy.api#documentation": "

The value of the attribute.

" + "smithy.api#documentation": "

The value of the attribute. This is a Document type.\n This type is not supported by Java V1, Go V1, and older versions of the AWS CLI.

" } }, "com.amazonaws.identitystore#ConflictException": { @@ -340,7 +340,7 @@ "MembershipId": { "target": "com.amazonaws.identitystore#ResourceId", "traits": { - "smithy.api#documentation": "

The identifier for a GroupMembership in the identity store.

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

The identifier for a newly created GroupMembership in an identity store.

", "smithy.api#required": {} } }, @@ -383,7 +383,7 @@ "GroupId": { "target": "com.amazonaws.identitystore#ResourceId", "traits": { - "smithy.api#documentation": "

The identifier of the newly created group in the identity store.

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

The\n identifier\n of the newly created group in the identity store.

", "smithy.api#required": {} } }, @@ -435,7 +435,7 @@ "UserName": { "target": "com.amazonaws.identitystore#UserName", "traits": { - "smithy.api#documentation": "

A unique string used to identify the user. The length limit is 128 characters. \n This value can consist of letters, accented characters, symbols, numbers, and punctuation. The characters <>;:% are excluded. \n This value is specified at the time the user is created and stored as an attribute of the user object in the identity store.

" + "smithy.api#documentation": "

A unique string used to identify the user. The length limit is 128 characters. \n This value can consist of letters, accented characters, symbols, numbers, and punctuation. \n This value is specified at the time the user is created and stored as an attribute of the user object in the identity store.

" } }, "Name": { @@ -592,7 +592,7 @@ "MembershipId": { "target": "com.amazonaws.identitystore#ResourceId", "traits": { - "smithy.api#documentation": "

The identifier for a GroupMembership in the identity store.

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

The identifier for a GroupMembership in an identity store.

", "smithy.api#required": {} } } @@ -689,7 +689,7 @@ } ], "traits": { - "smithy.api#documentation": "

Retrieves the group metadata and attributes from GroupId in an identity store.

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

Retrieves the group metadata and attributes from GroupId in an identity\n store.

", "smithy.api#readonly": {} } }, @@ -710,7 +710,7 @@ } ], "traits": { - "smithy.api#documentation": "

Retrieves membership metadata and attributes from MembershipId in a group.

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

Retrieves membership metadata and attributes from MembershipId in an identity store.

", "smithy.api#readonly": {} } }, @@ -727,7 +727,7 @@ "MembershipId": { "target": "com.amazonaws.identitystore#ResourceId", "traits": { - "smithy.api#documentation": "

The identifier for a GroupMembership in the identity store.

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

The identifier for a GroupMembership in an identity store.

", "smithy.api#required": {} } } @@ -746,7 +746,7 @@ "MembershipId": { "target": "com.amazonaws.identitystore#ResourceId", "traits": { - "smithy.api#documentation": "

The identifier for a GroupMembership in the identity store.

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

The identifier for a GroupMembership in an identity store.

", "smithy.api#required": {} } }, @@ -867,7 +867,7 @@ "UserName": { "target": "com.amazonaws.identitystore#UserName", "traits": { - "smithy.api#documentation": "

The user’s username value. The length limit is 128 characters. This value can consist of\n letters, accented characters, symbols, numbers, and punctuation. The characters\n <>;:% are excluded. This value is specified at the time the user is\n created and stored as an attribute of the user object in the identity store.

" + "smithy.api#documentation": "

A unique string used to identify the user. The length limit is 128 characters. This value can consist of\n letters, accented characters, symbols, numbers, and punctuation. This value is specified at the time the user is\n created and stored as an attribute of the user object in the identity store.

" } }, "UserId": { @@ -983,7 +983,7 @@ "target": "com.amazonaws.identitystore#SensitiveBooleanType", "traits": { "smithy.api#default": false, - "smithy.api#documentation": "

A boolean representing whether this is the primary email for the associated resource.

" + "smithy.api#documentation": "

A\n Boolean\n value\n representing whether this is the primary email\n address\n for the associated resource.

" } } }, @@ -1075,13 +1075,13 @@ "AttributeValue": { "target": "com.amazonaws.identitystore#SensitiveStringType", "traits": { - "smithy.api#documentation": "

Represents the data for an attribute. Each attribute value is described as a name-value pair.

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

Represents the data for an attribute. Each attribute value is described as a name-value\n pair.

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

A query filter used by ListUsers and ListGroups. This filter object provides the attribute name and attribute value to\n search users or groups.

" + "smithy.api#documentation": "

A query filter used by ListUsers and ListGroups. This filter\n object provides the attribute name and attribute value to search users or groups.

" } }, "com.amazonaws.identitystore#Filters": { @@ -1130,7 +1130,7 @@ "AlternateIdentifier": { "target": "com.amazonaws.identitystore#AlternateIdentifier", "traits": { - "smithy.api#documentation": "

A unique identifier for the group value that is not the group's primary identifier. This value can be\n an identifier from an external identity provider (IdP) that is associated with the group or a unique attribute. For example, a\n unique GroupDisplayName.

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

A unique identifier for an identity resource that is not the primary identifier. This value can be\n an identifier from an external identity provider (IdP) that is associated with the group or a unique attribute. For example, a\n unique GroupDisplayName.

", "smithy.api#required": {} } } @@ -1172,7 +1172,7 @@ } ], "traits": { - "smithy.api#documentation": "

Retrieves the MembershipId in a group.

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

Retrieves the MembershipId in an identity store.

", "smithy.api#readonly": {} } }, @@ -1208,7 +1208,7 @@ "MembershipId": { "target": "com.amazonaws.identitystore#ResourceId", "traits": { - "smithy.api#documentation": "

The identifier for a GroupMembership in the identity store.

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

The identifier for a GroupMembership in an identity store.

", "smithy.api#required": {} } }, @@ -1255,7 +1255,7 @@ "AlternateIdentifier": { "target": "com.amazonaws.identitystore#AlternateIdentifier", "traits": { - "smithy.api#documentation": "

Any unique attribute associated with a user that is not the UserId.

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

A unique identifier for an identity resource that is not the primary identifier.

", "smithy.api#required": {} } } @@ -1293,7 +1293,7 @@ "DisplayName": { "target": "com.amazonaws.identitystore#GroupDisplayName", "traits": { - "smithy.api#documentation": "

The group’s display name value. The length limit is 1,024 characters. This\n value can consist of letters, accented characters, symbols, numbers, punctuation, tab, new\n line, carriage return, space, and nonbreaking space in this attribute. The characters\n <>;:% are excluded. This value is specified at the time the group\n is created and stored as an attribute of the group object in the identity store.

" + "smithy.api#documentation": "

The group’s display name value. The length limit is 1,024 characters. This\n value can consist of letters, accented characters, symbols, numbers, punctuation, tab, new\n line, carriage return, space, and nonbreaking space in this attribute. The characters\n <>;:% are excluded. This value is specified at the time the group is\n created and stored as an attribute of the group object in the identity store.

" } }, "ExternalIds": { @@ -1356,7 +1356,7 @@ "MembershipId": { "target": "com.amazonaws.identitystore#ResourceId", "traits": { - "smithy.api#documentation": "

The identifier for a GroupMembership object in the identity store.

" + "smithy.api#documentation": "

The identifier for a GroupMembership object in an identity store.

" } }, "GroupId": { @@ -1531,7 +1531,7 @@ } ], "traits": { - "smithy.api#documentation": "

Returns if a member exists in specified groups.

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

Checks the user's membership in all requested groups and returns if the member exists in all queried groups.

", "smithy.api#readonly": {} } }, @@ -1567,7 +1567,7 @@ "Results": { "target": "com.amazonaws.identitystore#GroupMembershipExistenceResults", "traits": { - "smithy.api#documentation": "

An object containing results of batch IsMemberInGroups call.

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

A list containing the results of membership existence checks.

", "smithy.api#required": {} } } @@ -1653,7 +1653,7 @@ "NextToken": { "target": "com.amazonaws.identitystore#NextToken", "traits": { - "smithy.api#documentation": "

The pagination token used for the ListUsers, ListGroups and ListGroupMemberships API operations. This value is generated by the identity store service. It is returned in the API response if the total results are more than the size of one page. This token is also returned when it is used in the API request to search for the next page.

" + "smithy.api#documentation": "

The pagination token used for the ListUsers, ListGroups, and ListGroupMemberships API operations. This value is generated by the identity store service. It is returned in the API response if the total results are more than the size of one page. This token is also returned when it is used in the API request to search for the next page.

" } } } @@ -1671,7 +1671,7 @@ "NextToken": { "target": "com.amazonaws.identitystore#NextToken", "traits": { - "smithy.api#documentation": "

The pagination token used for the ListUsers, ListGroups and ListGroupMemberships API operations. This value is generated by the identity store service. It is returned in the API response if the total results are more than the size of one page. This token is also returned when it is used in the API request to search for the next page.\n

" + "smithy.api#documentation": "

The pagination token used for the ListUsers, ListGroups, and ListGroupMemberships API operations. This value is generated by the identity store service. It is returned in the API response if the total results are more than the size of one page. This token is also returned when it is used in the API request to search for the next page.\n

" } } } @@ -1696,7 +1696,7 @@ "MaxResults": { "target": "com.amazonaws.identitystore#MaxResults", "traits": { - "smithy.api#documentation": "

The maximum number of results to be returned per request. This parameter is used in the\n ListUsers and ListGroups requests to specify how many results\n to return in one page. The length limit is 50 characters.

" + "smithy.api#documentation": "

The maximum number of results to be returned per request. This parameter is used in all\n List requests to specify how many results to return in one page.

" } }, "NextToken": { @@ -1720,7 +1720,7 @@ "NextToken": { "target": "com.amazonaws.identitystore#NextToken", "traits": { - "smithy.api#documentation": "

The pagination token used for the ListUsers, ListGroups and ListGroupMemberships API operations. This value is generated by the identity store service. It is returned in the API response if the total results are more than the size of one page. This token is also returned when it is used in the API request to search for the next page.

" + "smithy.api#documentation": "

The pagination token used for the ListUsers, ListGroups, and ListGroupMemberships API operations. This value is generated by the identity store service. It is returned in the API response if the total results are more than the size of one page. This token is also returned when it is used in the API request to search for the next page.

" } } } @@ -1742,7 +1742,7 @@ } ], "traits": { - "smithy.api#documentation": "

\n Filtering for a group by the group DisplayName attribute is deprecated. Instead, use the GetGroupId API action.\n

\n

Lists all groups in the identity store. Returns a paginated list of complete Group objects.

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

Lists the attribute name and value of the group that you specified in the search. We\n only support DisplayName as a valid filter attribute path currently, and\n filter is required. This API returns minimum attributes, including GroupId and\n group DisplayName in the response.

", "smithy.api#paginated": { "inputToken": "NextToken", "items": "Groups", @@ -1780,7 +1780,7 @@ "smithy.api#deprecated": { "message": "Using filters with ListGroups API is deprecated, please use GetGroupId API instead." }, - "smithy.api#documentation": "

A list of Filter objects that is used in the ListUsers and\n ListGroups requests.

" + "smithy.api#documentation": "

A list of Filter objects, which is used in the ListUsers and\n ListGroups requests.

" } } } @@ -1820,7 +1820,7 @@ } ], "traits": { - "smithy.api#documentation": "

\n Filtering for a user by the UserName attribute is deprecated. Instead, use the GetUserId API action.\n

\n

Lists all users in the identity store. Returns a paginated list of complete User objects.

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

Lists the attribute name and value of the user that you specified in the search. We only\n support UserName as a valid filter attribute path currently, and filter is\n required. This API returns minimum attributes, including UserId and\n UserName in the response.

", "smithy.api#paginated": { "inputToken": "NextToken", "items": "Users", @@ -1858,7 +1858,7 @@ "smithy.api#deprecated": { "message": "Using filters with ListUsers API is deprecated, please use GetGroupId API instead." }, - "smithy.api#documentation": "

A list of Filter objects that is used in the ListUsers and\n ListGroups requests.

" + "smithy.api#documentation": "

A list of Filter objects, which is used in the ListUsers and\n ListGroups requests.

" } } } @@ -1945,7 +1945,7 @@ } }, "traits": { - "smithy.api#documentation": "

The name of the user.

" + "smithy.api#documentation": "

The\n full name\n of the user.

" } }, "com.amazonaws.identitystore#NextToken": { @@ -1964,7 +1964,7 @@ "Value": { "target": "com.amazonaws.identitystore#SensitiveStringType", "traits": { - "smithy.api#documentation": "

A string containing a phone number. For example, \"8675309\" or \"+1 (800) 123-4567\".

" + "smithy.api#documentation": "

A string containing a phone number. For example,\n \"8675309\"\n or \"+1 (800) 123-4567\".

" } }, "Type": { @@ -1977,7 +1977,7 @@ "target": "com.amazonaws.identitystore#SensitiveBooleanType", "traits": { "smithy.api#default": false, - "smithy.api#documentation": "

A boolean representing whether this is the primary phone number for the associated resource.

" + "smithy.api#documentation": "

A\n Boolean\n value\n representing whether this is the primary phone number for the associated\n resource.

" } } }, @@ -2072,11 +2072,15 @@ } }, "com.amazonaws.identitystore#RetryAfterSeconds": { - "type": "integer" + "type": "integer", + "traits": { + "smithy.api#default": 0 + } }, "com.amazonaws.identitystore#SensitiveBooleanType": { "type": "boolean", "traits": { + "smithy.api#default": false, "smithy.api#sensitive": {} } }, @@ -2153,7 +2157,7 @@ "AttributeValue": { "target": "com.amazonaws.identitystore#AttributeValue", "traits": { - "smithy.api#documentation": "

The value of the attribute.

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

The value of the attribute. This is a Document type.\n This type is not supported by Java V1, Go V1, and older versions of the AWS CLI.

", "smithy.api#required": {} } } @@ -2280,7 +2284,7 @@ "UserName": { "target": "com.amazonaws.identitystore#UserName", "traits": { - "smithy.api#documentation": "

The user’s user name value. The length limit is 128 characters. This value can\n consist of letters, accented characters, symbols, numbers, and punctuation. The characters\n <>;:% are excluded. This value is specified at the time the user is\n created and stored as an attribute of the user object in the identity store.

" + "smithy.api#documentation": "

A unique string used to identify the user. The length limit is 128 characters. This value can\n consist of letters, accented characters, symbols, numbers, and punctuation. This value is specified at the time the user is\n created and stored as an attribute of the user object in the identity store.

" } }, "UserId": { @@ -2347,7 +2351,7 @@ "Title": { "target": "com.amazonaws.identitystore#SensitiveStringType", "traits": { - "smithy.api#documentation": "

A string containing the user's title. Possible values depend on each customer's specific needs, so they are left unspecified

" + "smithy.api#documentation": "

A string containing the user's title. Possible values depend on each customer's specific\n needs, so they are left\n unspecified.

" } }, "PreferredLanguage": { @@ -2365,7 +2369,7 @@ "Timezone": { "target": "com.amazonaws.identitystore#SensitiveStringType", "traits": { - "smithy.api#documentation": "

A string containing the user's time zone.

" + "smithy.api#documentation": "

A string containing the\n user's\n time zone.

" } }, "IdentityStoreId": { diff --git a/codegen/sdk-codegen/aws-models/inspector2.json b/codegen/sdk-codegen/aws-models/inspector2.json index 921f67db439..2510563bd88 100644 --- a/codegen/sdk-codegen/aws-models/inspector2.json +++ b/codegen/sdk-codegen/aws-models/inspector2.json @@ -1,5 +1,5 @@ { - "smithy": "1.0", + "smithy": "2.0", "shapes": { "com.amazonaws.inspector2#AccessDeniedException": { "type": "structure", @@ -109,7 +109,7 @@ } }, "com.amazonaws.inspector2#AccountIdSet": { - "type": "set", + "type": "list", "member": { "target": "com.amazonaws.inspector2#AccountId" }, @@ -117,7 +117,8 @@ "smithy.api#length": { "min": 0, "max": 100 - } + }, + "smithy.api#uniqueItems": {} } }, "com.amazonaws.inspector2#AccountList": { @@ -187,7 +188,10 @@ } }, "com.amazonaws.inspector2#AggCounts": { - "type": "long" + "type": "long", + "traits": { + "smithy.api#default": 0 + } }, "com.amazonaws.inspector2#AggregationFindingType": { "type": "string", @@ -1067,6 +1071,7 @@ "count": { "target": "com.amazonaws.inspector2#AggCounts", "traits": { + "smithy.api#default": 0, "smithy.api#documentation": "

The number of resources.

" } }, @@ -2975,6 +2980,12 @@ "traits": { "smithy.api#documentation": "

Details on the related vulnerabilities used to filter findings.

" } + }, + "fixAvailable": { + "target": "com.amazonaws.inspector2#StringFilterList", + "traits": { + "smithy.api#documentation": "

Details on whether a fix is available through a version update. This value can be YES, NO, or PARTIAL. A PARTIAL fix means that some, but not all, of the packages identified in the finding have fixes available through updated versions.

" + } } }, "traits": { @@ -3122,6 +3133,12 @@ "traits": { "smithy.api#documentation": "

An object that contains the details of a package vulnerability finding.

" } + }, + "fixAvailable": { + "target": "com.amazonaws.inspector2#FixAvailable", + "traits": { + "smithy.api#documentation": "

Details on whether a fix is available through a version update. This value can be YES, NO, or PARTIAL. A PARTIAL fix means that some, but not all, of the packages identified in the finding have fixes available through updated versions.

" + } } }, "traits": { @@ -3271,6 +3288,25 @@ ] } }, + "com.amazonaws.inspector2#FixAvailable": { + "type": "string", + "traits": { + "smithy.api#enum": [ + { + "value": "YES", + "name": "YES" + }, + { + "value": "NO", + "name": "NO" + }, + { + "value": "PARTIAL", + "name": "PARTIAL" + } + ] + } + }, "com.amazonaws.inspector2#FreeTrialAccountInfo": { "type": "structure", "members": { @@ -3800,25 +3836,6 @@ }, "com.amazonaws.inspector2#Inspector2": { "type": "service", - "traits": { - "aws.api#service": { - "sdkId": "Inspector2", - "arnNamespace": "inspector2", - "cloudTrailEventSource": "inspector2.amazon.aws", - "cloudFormationName": "Inspector2" - }, - "aws.auth#sigv4": { - "name": "inspector2" - }, - "aws.protocols#restJson1": {}, - "smithy.api#cors": { - "additionalAllowedHeaders": [ - "*" - ] - }, - "smithy.api#documentation": "

Amazon Inspector is a vulnerability discovery service that automates continuous scanning for\n security vulnerabilities within your Amazon EC2 and Amazon ECR environments.

", - "smithy.api#title": "Inspector2" - }, "version": "2020-06-08", "operations": [ { @@ -3917,7 +3934,26 @@ { "target": "com.amazonaws.inspector2#UpdateOrganizationConfiguration" } - ] + ], + "traits": { + "aws.api#service": { + "sdkId": "Inspector2", + "arnNamespace": "inspector2", + "cloudTrailEventSource": "inspector2.amazon.aws", + "cloudFormationName": "Inspector2" + }, + "aws.auth#sigv4": { + "name": "inspector2" + }, + "aws.protocols#restJson1": {}, + "smithy.api#cors": { + "additionalAllowedHeaders": [ + "*" + ] + }, + "smithy.api#documentation": "

Amazon Inspector is a vulnerability discovery service that automates continuous scanning for\n security vulnerabilities within your Amazon EC2 and Amazon ECR environments.

", + "smithy.api#title": "Inspector2" + } }, "com.amazonaws.inspector2#InspectorScoreDetails": { "type": "structure", @@ -4028,7 +4064,6 @@ "com.amazonaws.inspector2#ListAccountPermissionsMaxResults": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 1024 @@ -4113,7 +4148,6 @@ "com.amazonaws.inspector2#ListCoverageMaxResults": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 200 @@ -4314,7 +4348,6 @@ "com.amazonaws.inspector2#ListDelegatedAdminMaxResults": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 5 @@ -4324,7 +4357,6 @@ "com.amazonaws.inspector2#ListFilterMaxResults": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 100 @@ -4452,7 +4484,6 @@ "com.amazonaws.inspector2#ListFindingAggregationsMaxResults": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 100 @@ -4556,7 +4587,6 @@ "com.amazonaws.inspector2#ListFindingsMaxResults": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 100 @@ -4649,7 +4679,6 @@ "com.amazonaws.inspector2#ListMembersMaxResults": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 50 @@ -4791,7 +4820,6 @@ "com.amazonaws.inspector2#ListUsageTotalsMaxResults": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 1, "max": 500 @@ -4973,6 +5001,7 @@ "com.amazonaws.inspector2#MonthlyCostEstimate": { "type": "double", "traits": { + "smithy.api#default": 0, "smithy.api#range": { "min": 0 } @@ -5186,7 +5215,10 @@ } }, "com.amazonaws.inspector2#PackageEpoch": { - "type": "integer" + "type": "integer", + "traits": { + "smithy.api#default": 0 + } }, "com.amazonaws.inspector2#PackageFilter": { "type": "structure", @@ -5374,8 +5406,7 @@ "vulnerablePackages": { "target": "com.amazonaws.inspector2#VulnerablePackageList", "traits": { - "smithy.api#documentation": "

The packages impacted by this vulnerability.

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

The packages impacted by this vulnerability.

" } }, "source": { @@ -5478,7 +5509,6 @@ "com.amazonaws.inspector2#Port": { "type": "integer", "traits": { - "smithy.api#box": {}, "smithy.api#range": { "min": 0, "max": 65535 @@ -6066,6 +6096,14 @@ { "value": "PENDING_DISABLE", "name": "PENDING_DISABLE" + }, + { + "value": "NO_INVENTORY", + "name": "NO_INVENTORY" + }, + { + "value": "STALE_INVENTORY", + "name": "STALE_INVENTORY" } ] } @@ -6924,12 +6962,14 @@ "total": { "target": "com.amazonaws.inspector2#UsageValue", "traits": { + "smithy.api#default": 0, "smithy.api#documentation": "

The total of usage.

" } }, "estimatedMonthlyCost": { "target": "com.amazonaws.inspector2#MonthlyCostEstimate", "traits": { + "smithy.api#default": 0, "smithy.api#documentation": "

The estimated monthly cost of Amazon Inspector.

" } }, @@ -7016,6 +7056,7 @@ "com.amazonaws.inspector2#UsageValue": { "type": "double", "traits": { + "smithy.api#default": 0, "smithy.api#range": { "min": 0 } @@ -7138,6 +7179,7 @@ "epoch": { "target": "com.amazonaws.inspector2#PackageEpoch", "traits": { + "smithy.api#default": 0, "smithy.api#documentation": "

The epoch of the vulnerable package.

" } }, @@ -7170,6 +7212,12 @@ "traits": { "smithy.api#documentation": "

The version of the package that contains the vulnerability fix.

" } + }, + "remediation": { + "target": "com.amazonaws.inspector2#VulnerablePackageRemediation", + "traits": { + "smithy.api#documentation": "

The code to run in your environment to update packages with a fix available.

" + } } }, "traits": { @@ -7181,6 +7229,15 @@ "member": { "target": "com.amazonaws.inspector2#VulnerablePackage" } + }, + "com.amazonaws.inspector2#VulnerablePackageRemediation": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 1, + "max": 1024 + } + } } } } \ No newline at end of file diff --git a/codegen/sdk-codegen/aws-models/iotsitewise.json b/codegen/sdk-codegen/aws-models/iotsitewise.json index a2a73044295..6b881856c43 100644 --- a/codegen/sdk-codegen/aws-models/iotsitewise.json +++ b/codegen/sdk-codegen/aws-models/iotsitewise.json @@ -3249,7 +3249,7 @@ "assetName": { "target": "com.amazonaws.iotsitewise#Name", "traits": { - "smithy.api#documentation": "

A unique, friendly name for the asset.

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

A friendly name for the asset.

", "smithy.api#required": {} } }, @@ -3339,7 +3339,7 @@ } ], "traits": { - "smithy.api#documentation": "\n

This API operation is in preview release for IoT SiteWise and is subject to change. \n We recommend that you use this operation only with test data, and not in production environments.

\n
\n

Defines a job to ingest data to IoT SiteWise from Amazon S3. For more information, \n see Create a bulk import job (CLI) \n in the Amazon Simple Storage Service User Guide.

\n \n

You must enable IoT SiteWise to export data to Amazon S3 before you create a bulk import job. \n For more information about how to configure storage settings, \n see PutStorageConfiguration.

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

Defines a job to ingest data to IoT SiteWise from Amazon S3. For more information, \n see Create a bulk import job (CLI) \n in the Amazon Simple Storage Service User Guide.

\n \n

You must enable IoT SiteWise to export data to Amazon S3 before you create a bulk import job. \n For more information about how to configure storage settings, \n see PutStorageConfiguration.

\n
", "smithy.api#endpoint": { "hostPrefix": "data." }, @@ -4985,7 +4985,7 @@ } ], "traits": { - "smithy.api#documentation": "\n

This API operation is in preview release for IoT SiteWise and is subject to change. \n We recommend that you use this operation only with test data, and not in production environments.

\n
\n

Retrieves information about a bulk import job request. For more information, \n see Describe a bulk import job (CLI) \n in the Amazon Simple Storage Service User Guide.

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

Retrieves information about a bulk import job request. For more information, \n see Describe a bulk import job (CLI) \n in the Amazon Simple Storage Service User Guide.

", "smithy.api#endpoint": { "hostPrefix": "data." }, @@ -7956,7 +7956,7 @@ } ], "traits": { - "smithy.api#documentation": "\n

This API operation is in preview release for IoT SiteWise and is subject to change. \n We recommend that you use this operation only with test data, and not in production environments.

\n
\n

Retrieves a paginated list of bulk import job requests. For more information, \n see List bulk import jobs (CLI) \n in the Amazon Simple Storage Service User Guide.

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

Retrieves a paginated list of bulk import job requests. For more information, \n see List bulk import jobs (CLI) \n in the IoT SiteWise User Guide.

", "smithy.api#endpoint": { "hostPrefix": "data." }, @@ -10528,6 +10528,12 @@ "smithy.api#documentation": "

A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don't reuse this client token if a new idempotent request is required.

", "smithy.api#idempotencyToken": {} } + }, + "propertyUnit": { + "target": "com.amazonaws.iotsitewise#PropertyUnit", + "traits": { + "smithy.api#documentation": "

The unit of measure (such as Newtons or RPM) of the asset property. If you don't specify a value for this parameter, the service uses the \n value of the assetModelProperty in the asset model.

" + } } } }, @@ -10545,7 +10551,7 @@ "assetName": { "target": "com.amazonaws.iotsitewise#Name", "traits": { - "smithy.api#documentation": "

A unique, friendly name for the asset.

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

A friendly name for the asset.

", "smithy.api#required": {} } }, diff --git a/codegen/sdk-codegen/aws-models/kendra.json b/codegen/sdk-codegen/aws-models/kendra.json index 5425b26c079..14125fef8dc 100644 --- a/codegen/sdk-codegen/aws-models/kendra.json +++ b/codegen/sdk-codegen/aws-models/kendra.json @@ -677,48 +677,48 @@ "EqualsTo": { "target": "com.amazonaws.kendra#DocumentAttribute", "traits": { - "smithy.api#documentation": "

Performs an equals operation on two document attributes.

" + "smithy.api#documentation": "

Performs an equals operation on two document attributes or metadata fields.

" } }, "ContainsAll": { "target": "com.amazonaws.kendra#DocumentAttribute", "traits": { - "smithy.api#documentation": "

Returns true when a document contains all of the specified document\n attributes. This filter is only applicable to\n StringListValue metadata.

" + "smithy.api#documentation": "

Returns true when a document contains all of the specified document\n attributes or metadata fields. This filter is only applicable to\n StringListValue metadata.

" } }, "ContainsAny": { "target": "com.amazonaws.kendra#DocumentAttribute", "traits": { - "smithy.api#documentation": "

Returns true when a document contains any of the specified document\n attributes. This filter is only applicable to\n StringListValue metadata.

" + "smithy.api#documentation": "

Returns true when a document contains any of the specified document\n attributes or metadata fields. This filter is only applicable to\n StringListValue metadata.

" } }, "GreaterThan": { "target": "com.amazonaws.kendra#DocumentAttribute", "traits": { - "smithy.api#documentation": "

Performs a greater than operation on two document attributes. Use\n with a document attribute of type Date or\n Long.

" + "smithy.api#documentation": "

Performs a greater than operation on two document attributes or metadata fields. Use\n with a document attribute of type Date or\n Long.

" } }, "GreaterThanOrEquals": { "target": "com.amazonaws.kendra#DocumentAttribute", "traits": { - "smithy.api#documentation": "

Performs a greater or equals than operation on two document\n attributes. Use with a document attribute of type Date\n or Long.

" + "smithy.api#documentation": "

Performs a greater or equals than operation on two document\n attributes or metadata fields. Use with a document attribute of type Date\n or Long.

" } }, "LessThan": { "target": "com.amazonaws.kendra#DocumentAttribute", "traits": { - "smithy.api#documentation": "

Performs a less than operation on two document attributes. Use with\n a document attribute of type Date or\n Long.

" + "smithy.api#documentation": "

Performs a less than operation on two document attributes or metadata fields. Use with\n a document attribute of type Date or\n Long.

" } }, "LessThanOrEquals": { "target": "com.amazonaws.kendra#DocumentAttribute", "traits": { - "smithy.api#documentation": "

Performs a less than or equals operation on two document attributes.\n Use with a document attribute of type Date or\n Long.

" + "smithy.api#documentation": "

Performs a less than or equals operation on two document attributes or metadata fields.\n Use with a document attribute of type Date or\n Long.

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

Provides filtering the query results based on document\n attributes.

\n

When you use the AndAllFilters or\n OrAllFilters, filters you can use 2 layers under the\n first attribute filter. For example, you can use:

\n

\n \n

\n
    \n
  1. \n

    \n \n

    \n
  2. \n
  3. \n

    \n \n

    \n
  4. \n
\n

If you use more than 2 layers, you receive a\n ValidationException exception with the message\n \"AttributeFilter cannot have a depth of more \n than 2.\"

\n

If you use more than 10 attribute filters in a given list for \n AndAllFilters or OrAllFilters, you receive \n a ValidationException with the message \n \"AttributeFilter cannot have a length of more than 10\".

" + "smithy.api#documentation": "

Provides filtering the query results based on document\n attributes or metadata fields.

\n

When you use the AndAllFilters or\n OrAllFilters, filters you can use 2 layers under the\n first attribute filter. For example, you can use:

\n

\n \n

\n
    \n
  1. \n

    \n \n

    \n
  2. \n
  3. \n

    \n \n

    \n
  4. \n
\n

If you use more than 2 layers, you receive a\n ValidationException exception with the message\n \"AttributeFilter cannot have a depth of more \n than 2.\"

\n

If you use more than 10 attribute filters in a given list for \n AndAllFilters or OrAllFilters, you receive \n a ValidationException with the message \n \"AttributeFilter cannot have a length of more than 10\".

" } }, "com.amazonaws.kendra#AttributeFilterList": { @@ -11087,6 +11087,10 @@ { "value": "SHAREPOINT_ONLINE", "name": "SHAREPOINT_ONLINE" + }, + { + "value": "SHAREPOINT_2019", + "name": "SHAREPOINT_2019" } ] } diff --git a/codegen/sdk-codegen/aws-models/lex-models-v2.json b/codegen/sdk-codegen/aws-models/lex-models-v2.json index 9c3613d4451..ac472e5886c 100644 --- a/codegen/sdk-codegen/aws-models/lex-models-v2.json +++ b/codegen/sdk-codegen/aws-models/lex-models-v2.json @@ -1655,6 +1655,20 @@ "smithy.api#documentation": "

Contains information about code hooks that Amazon Lex calls during a\n conversation.

" } }, + "com.amazonaws.lexmodelsv2#CompositeSlotTypeSetting": { + "type": "structure", + "members": { + "subSlots": { + "target": "com.amazonaws.lexmodelsv2#SubSlotTypeList", + "traits": { + "smithy.api#documentation": "

Subslots in the composite slot.

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

A composite slot is a combination of two or more slots \n that capture multiple pieces of information in a single user input.

" + } + }, "com.amazonaws.lexmodelsv2#Condition": { "type": "structure", "members": { @@ -3072,6 +3086,12 @@ "traits": { "smithy.api#documentation": "

Indicates whether the slot returns multiple values in one response.\n Multi-value slots are only available in the en-US locale. If you set\n this value to true in any other locale, Amazon Lex throws a\n ValidationException.

\n

If the multipleValuesSetting is not set, the default\n value is false.

" } + }, + "subSlotSetting": { + "target": "com.amazonaws.lexmodelsv2#SubSlotSetting", + "traits": { + "smithy.api#documentation": "

Specifications for the constituent sub slots and the \n expression for the composite slot.

" + } } } }, @@ -3149,6 +3169,12 @@ "traits": { "smithy.api#documentation": "

Indicates whether the slot returns multiple values in one\n response.

" } + }, + "subSlotSetting": { + "target": "com.amazonaws.lexmodelsv2#SubSlotSetting", + "traits": { + "smithy.api#documentation": "

Specifications for the constituent sub slots and the \n expression for the composite slot.

" + } } } }, @@ -3252,6 +3278,12 @@ "traits": { "smithy.api#documentation": "

Sets the type of external information used to create the slot\n type.

" } + }, + "compositeSlotTypeSetting": { + "target": "com.amazonaws.lexmodelsv2#CompositeSlotTypeSetting", + "traits": { + "smithy.api#documentation": "

Specifications for a composite slot type.

" + } } } }, @@ -3323,6 +3355,12 @@ "traits": { "smithy.api#documentation": "

The type of external information used to create the slot\n type.

" } + }, + "compositeSlotTypeSetting": { + "target": "com.amazonaws.lexmodelsv2#CompositeSlotTypeSetting", + "traits": { + "smithy.api#documentation": "

Specifications for a composite slot type.

" + } } } }, @@ -6293,6 +6331,12 @@ "traits": { "smithy.api#documentation": "

Indicates whether the slot accepts multiple values in a single\n utterance.

\n

If the multipleValuesSetting is not set, the default\n value is false.

" } + }, + "subSlotSetting": { + "target": "com.amazonaws.lexmodelsv2#SubSlotSetting", + "traits": { + "smithy.api#documentation": "

Specifications for the constituent sub slots and the \n expression for the composite slot.

" + } } } }, @@ -6438,6 +6482,12 @@ }, "externalSourceSetting": { "target": "com.amazonaws.lexmodelsv2#ExternalSourceSetting" + }, + "compositeSlotTypeSetting": { + "target": "com.amazonaws.lexmodelsv2#CompositeSlotTypeSetting", + "traits": { + "smithy.api#documentation": "

Specifications for a composite slot type.

" + } } } }, @@ -11161,6 +11211,10 @@ { "value": "ExternalGrammar", "name": "ExternalGrammar" + }, + { + "value": "Composite", + "name": "Composite" } ] } @@ -11425,7 +11479,7 @@ } }, "traits": { - "smithy.api#documentation": "

Settings that you can use for eliciting a slot value.

" + "smithy.api#documentation": "

Specifies the elicitation setting details for constituent sub slots of a composite slot.

" } }, "com.amazonaws.lexmodelsv2#SlotValueOverride": { @@ -11489,6 +11543,10 @@ { "value": "TopResolution", "name": "TopResolution" + }, + { + "value": "Concatenation", + "name": "Concatenation" } ] } @@ -11541,6 +11599,28 @@ ] } }, + "com.amazonaws.lexmodelsv2#Specifications": { + "type": "structure", + "members": { + "slotTypeId": { + "target": "com.amazonaws.lexmodelsv2#BuiltInOrCustomSlotTypeId", + "traits": { + "smithy.api#documentation": "

The unique identifier assigned to the slot type.

", + "smithy.api#required": {} + } + }, + "valueElicitationSetting": { + "target": "com.amazonaws.lexmodelsv2#SubSlotValueElicitationSetting", + "traits": { + "smithy.api#documentation": "

Specifies the elicitation setting details for constituent sub slots of a composite slot.

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

Subslot specifications.

" + } + }, "com.amazonaws.lexmodelsv2#StartBotRecommendation": { "type": "operation", "input": { @@ -11959,6 +12039,111 @@ "target": "com.amazonaws.lexmodelsv2#String" } }, + "com.amazonaws.lexmodelsv2#SubSlotExpression": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 0, + "max": 640 + }, + "smithy.api#pattern": "^[0-9A-Za-z_\\s\\(\\)]+$" + } + }, + "com.amazonaws.lexmodelsv2#SubSlotSetting": { + "type": "structure", + "members": { + "expression": { + "target": "com.amazonaws.lexmodelsv2#SubSlotExpression", + "traits": { + "smithy.api#documentation": "

The expression text for defining the constituent sub slots in the composite slot using logical AND and OR operators.

" + } + }, + "slotSpecifications": { + "target": "com.amazonaws.lexmodelsv2#SubSlotSpecificationMap", + "traits": { + "smithy.api#documentation": "

Specifications for the constituent sub slots of a composite slot.

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

Specifications for the constituent sub slots and the \n expression for the composite slot.

" + } + }, + "com.amazonaws.lexmodelsv2#SubSlotSpecificationMap": { + "type": "map", + "key": { + "target": "com.amazonaws.lexmodelsv2#Name" + }, + "value": { + "target": "com.amazonaws.lexmodelsv2#Specifications" + }, + "traits": { + "smithy.api#length": { + "min": 0, + "max": 6 + } + } + }, + "com.amazonaws.lexmodelsv2#SubSlotTypeComposition": { + "type": "structure", + "members": { + "name": { + "target": "com.amazonaws.lexmodelsv2#Name", + "traits": { + "smithy.api#documentation": "

Name of a constituent sub slot inside a composite slot.

", + "smithy.api#required": {} + } + }, + "slotTypeId": { + "target": "com.amazonaws.lexmodelsv2#BuiltInOrCustomSlotTypeId", + "traits": { + "smithy.api#documentation": "

The unique identifier assigned to a slot type. \n This refers to either a built-in slot type or the unique slotTypeId of a custom slot type.

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

Subslot type composition.

" + } + }, + "com.amazonaws.lexmodelsv2#SubSlotTypeList": { + "type": "list", + "member": { + "target": "com.amazonaws.lexmodelsv2#SubSlotTypeComposition" + }, + "traits": { + "smithy.api#length": { + "min": 0, + "max": 6 + } + } + }, + "com.amazonaws.lexmodelsv2#SubSlotValueElicitationSetting": { + "type": "structure", + "members": { + "defaultValueSpecification": { + "target": "com.amazonaws.lexmodelsv2#SlotDefaultValueSpecification" + }, + "promptSpecification": { + "target": "com.amazonaws.lexmodelsv2#PromptSpecification", + "traits": { + "smithy.api#required": {} + } + }, + "sampleUtterances": { + "target": "com.amazonaws.lexmodelsv2#SampleUtterancesList", + "traits": { + "smithy.api#documentation": "

If you know a specific pattern that users might respond to an Amazon Lex request for a sub slot value, \n you can provide those utterances to improve accuracy. This is optional. In most cases Amazon Lex is capable \n of understanding user utterances. This is similar to SampleUtterances for slots.

" + } + }, + "waitAndContinueSpecification": { + "target": "com.amazonaws.lexmodelsv2#WaitAndContinueSpecification" + } + }, + "traits": { + "smithy.api#documentation": "

Subslot elicitation settings.

\n

\n DefaultValueSpecification is a list of default values for a constituent sub slot in a composite slot. Default values are used when \n Amazon Lex hasn't determined a value for a slot. You can specify default values from context variables, \n session attributes, and defined values. This is similar to DefaultValueSpecification for slots.

\n

\n PromptSpecification is the prompt that Amazon Lex uses to elicit the sub slot value from the user. \n This is similar to PromptSpecification for slots.

" + } + }, "com.amazonaws.lexmodelsv2#SynonymList": { "type": "list", "member": { @@ -13449,6 +13634,12 @@ "traits": { "smithy.api#documentation": "

Determines whether the slot accepts multiple values in one response.\n Multiple value slots are only available in the en-US locale. If you set\n this value to true in any other locale, Amazon Lex throws a\n ValidationException.

\n

If the multipleValuesSetting is not set, the default\n value is false.

" } + }, + "subSlotSetting": { + "target": "com.amazonaws.lexmodelsv2#SubSlotSetting", + "traits": { + "smithy.api#documentation": "

Specifications for the constituent sub slots and the \n expression for the composite slot.

" + } } } }, @@ -13532,6 +13723,12 @@ "traits": { "smithy.api#documentation": "

Indicates whether the slot accepts multiple values in one\n response.

" } + }, + "subSlotSetting": { + "target": "com.amazonaws.lexmodelsv2#SubSlotSetting", + "traits": { + "smithy.api#documentation": "

Specifications for the constituent sub slots and the \n expression for the composite slot.

" + } } } }, @@ -13640,6 +13837,12 @@ }, "externalSourceSetting": { "target": "com.amazonaws.lexmodelsv2#ExternalSourceSetting" + }, + "compositeSlotTypeSetting": { + "target": "com.amazonaws.lexmodelsv2#CompositeSlotTypeSetting", + "traits": { + "smithy.api#documentation": "

Specifications for a composite slot type.

" + } } } }, @@ -13714,6 +13917,12 @@ }, "externalSourceSetting": { "target": "com.amazonaws.lexmodelsv2#ExternalSourceSetting" + }, + "compositeSlotTypeSetting": { + "target": "com.amazonaws.lexmodelsv2#CompositeSlotTypeSetting", + "traits": { + "smithy.api#documentation": "

Specifications for a composite slot type.

" + } } } }, diff --git a/codegen/sdk-codegen/aws-models/lex-runtime-v2.json b/codegen/sdk-codegen/aws-models/lex-runtime-v2.json index 61c201dbd6f..333a12c8b90 100644 --- a/codegen/sdk-codegen/aws-models/lex-runtime-v2.json +++ b/codegen/sdk-codegen/aws-models/lex-runtime-v2.json @@ -43,8 +43,13 @@ "name": "lex" }, "aws.protocols#restJson1": { - "http": ["http/1.1", "h2"], - "eventStreamHttp": ["h2"] + "http": [ + "http/1.1", + "h2" + ], + "eventStreamHttp": [ + "h2" + ] }, "smithy.api#documentation": "

", "smithy.api#title": "Amazon Lex Runtime V2" @@ -401,7 +406,7 @@ "welcomeMessages": { "target": "com.amazonaws.lexruntimev2#Messages", "traits": { - "smithy.api#documentation": "

A list of messages to send to the user.

" + "smithy.api#documentation": "

A list of messages to send to the user.

\n

If you set the welcomeMessage field, you must also set\n the \n DialogAction\n structure's \n type\n field.

" } }, "disablePlayback": { @@ -640,7 +645,7 @@ "type": { "target": "com.amazonaws.lexruntimev2#DialogActionType", "traits": { - "smithy.api#documentation": "

The next action that the bot should take in its interaction with the\n user. The possible values are:

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

The next action that the bot should take in its interaction with the\n user. The possible values are:

\n ", "smithy.api#required": {} } }, @@ -655,6 +660,12 @@ "traits": { "smithy.api#documentation": "

Configures the slot to use spell-by-letter or spell-by-word style.\n When you use a style on a slot, users can spell out their input to make\n it clear to your bot.

\n \n

For more information, see \n Using spelling to enter slot values .

" } + }, + "subSlotToElicit": { + "target": "com.amazonaws.lexruntimev2#ElicitSubSlot", + "traits": { + "smithy.api#documentation": "

The name of the constituent sub slot of the composite slot \n specified in slotToElicit that should be elicited from the user.

" + } } }, "traits": { @@ -715,6 +726,27 @@ "com.amazonaws.lexruntimev2#Double": { "type": "double" }, + "com.amazonaws.lexruntimev2#ElicitSubSlot": { + "type": "structure", + "members": { + "name": { + "target": "com.amazonaws.lexruntimev2#NonEmptyString", + "traits": { + "smithy.api#documentation": "

The name of the slot that should be elicited from the user.

", + "smithy.api#required": {} + } + }, + "subSlotToElicit": { + "target": "com.amazonaws.lexruntimev2#ElicitSubSlot", + "traits": { + "smithy.api#documentation": "

The field is not supported.

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

The specific constituent sub slot of the composite slot to elicit in dialog action.

" + } + }, "com.amazonaws.lexruntimev2#EpochMillis": { "type": "long" }, @@ -1709,8 +1741,13 @@ "runtimeHintValues": { "target": "com.amazonaws.lexruntimev2#RuntimeHintValuesList", "traits": { - "smithy.api#documentation": "

One or more strings that Amazon Lex V2 should look for in the input to the\n bot. Each phrase is given preference when deciding on slot\n values.

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

One or more strings that Amazon Lex V2 should look for in the input to the\n bot. Each phrase is given preference when deciding on slot\n values.

" + } + }, + "subSlotHints": { + "target": "com.amazonaws.lexruntimev2#SlotHintsSlotMap", + "traits": { + "smithy.api#documentation": "

A map of constituent sub slot names inside a composite slot in the intent and the phrases \n that should be added for each sub slot. Inside each composite slot hints, this structure provides \n a mechanism to add granular sub slot phrases. Only sub slot hints are supported for composite slots. \n The intent name, composite slot name and the constituent sub slot names must exist.

" } } }, @@ -1760,12 +1797,12 @@ "slotHints": { "target": "com.amazonaws.lexruntimev2#SlotHintsIntentMap", "traits": { - "smithy.api#documentation": "

A list of the slots in the intent that should have runtime hints\n added, and the phrases that should be added for each slot.

\n

The first level of the slotHints map is the name of the\n intent. The second level is the name of the slot within the intent. For\n more information, see Using hints to improve\n accuracy.

\n

The intent name and slot name must exist.

" + "smithy.api#documentation": "

A list of the slots in the intent that should have runtime hints\n added, and the phrases that should be added for each slot.

\n

The first level of the slotHints map is the name of the\n intent. The second level is the name of the slot within the intent. For\n more information, see Using hints to improve\n accuracy.

\n

The intent name and slot name must exist.

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

You can provide Amazon Lex V2 with hints to the phrases that a customer is\n likely to use for a slot. When a slot with hints is resolved, the\n phrases in the runtime hints are preferred in the resolution. You can\n provide hints for a maximum of 100 intents. You can provide a maximum\n of 100 slots.

\n

Before you can use runtime hints with an existing bot, you must\n first rebuild the bot.

\n

For more information, see Using hints to improve\n accuracy.

" + "smithy.api#documentation": "

You can provide Amazon Lex V2 with hints to the phrases that a customer is\n likely to use for a slot. When a slot with hints is resolved, the\n phrases in the runtime hints are preferred in the resolution. You can\n provide hints for a maximum of 100 intents. You can provide a maximum\n of 100 slots.

\n

Before you can use runtime hints with an existing bot, you must\n first rebuild the bot.

\n

For more information, see Using runtime hints to\n improve recognition of slot values.

" } }, "com.amazonaws.lexruntimev2#SensitiveNonEmptyString": { @@ -1892,7 +1929,7 @@ "runtimeHints": { "target": "com.amazonaws.lexruntimev2#RuntimeHints", "traits": { - "smithy.api#documentation": "

Hints for phrases that a customer is likely to use \n for a slot. Amazon Lex V2 uses the hints to help determine the correct\n value of a slot.

" + "smithy.api#documentation": "

Hints for phrases that a customer is likely to use for a slot. Amazon Lex V2\n uses the hints to help determine the correct value of a slot.

" } } }, @@ -1911,6 +1948,10 @@ { "value": "List", "name": "LIST" + }, + { + "value": "Composite", + "name": "COMPOSITE" } ] } @@ -1935,6 +1976,12 @@ "traits": { "smithy.api#documentation": "

A list of one or more values that the user provided for the slot.\n For example, if a for a slot that elicits pizza toppings, the values\n might be \"pepperoni\" and \"pineapple.\"

" } + }, + "subSlots": { + "target": "com.amazonaws.lexruntimev2#Slots", + "traits": { + "smithy.api#documentation": "

The constituent sub slots of a composite slot.

" + } } }, "traits": { diff --git a/codegen/sdk-codegen/aws-models/lookoutmetrics.json b/codegen/sdk-codegen/aws-models/lookoutmetrics.json index 86cb9e2de11..3d8a99f7b73 100644 --- a/codegen/sdk-codegen/aws-models/lookoutmetrics.json +++ b/codegen/sdk-codegen/aws-models/lookoutmetrics.json @@ -1453,6 +1453,12 @@ "traits": { "smithy.api#documentation": "

A list of tags to apply to the dataset.

" } + }, + "DimensionFilterList": { + "target": "com.amazonaws.lookoutmetrics#MetricSetDimensionFilterList", + "traits": { + "smithy.api#documentation": "

A list of filters that specify which data is kept for anomaly detection.

" + } } } }, @@ -2186,6 +2192,12 @@ "traits": { "smithy.api#documentation": "

Contains information about the dataset's source data.

" } + }, + "DimensionFilterList": { + "target": "com.amazonaws.lookoutmetrics#MetricSetDimensionFilterList", + "traits": { + "smithy.api#documentation": "

The dimensions and their values that were used to filter the dataset.

" + } } } }, @@ -2625,6 +2637,48 @@ "smithy.api#documentation": "

Contains information about a source file's formatting.

" } }, + "com.amazonaws.lookoutmetrics#Filter": { + "type": "structure", + "members": { + "DimensionValue": { + "target": "com.amazonaws.lookoutmetrics#DimensionValue", + "traits": { + "smithy.api#documentation": "

The value that you want to include in the filter.

" + } + }, + "FilterOperation": { + "target": "com.amazonaws.lookoutmetrics#FilterOperation", + "traits": { + "smithy.api#documentation": "

The condition to apply.

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

Describes a filter for choosing a subset of dimension values. Each filter consists of the dimension that you want to include and the condition statement. The condition statement is specified in the FilterOperation object.

" + } + }, + "com.amazonaws.lookoutmetrics#FilterList": { + "type": "list", + "member": { + "target": "com.amazonaws.lookoutmetrics#Filter" + }, + "traits": { + "smithy.api#length": { + "min": 1 + } + } + }, + "com.amazonaws.lookoutmetrics#FilterOperation": { + "type": "string", + "traits": { + "smithy.api#enum": [ + { + "value": "EQUALS", + "name": "EQUALS" + } + ] + } + }, "com.amazonaws.lookoutmetrics#FlowName": { "type": "string", "traits": { @@ -3973,6 +4027,32 @@ "smithy.api#pattern": "\\S" } }, + "com.amazonaws.lookoutmetrics#MetricSetDimensionFilter": { + "type": "structure", + "members": { + "Name": { + "target": "com.amazonaws.lookoutmetrics#ColumnName", + "traits": { + "smithy.api#documentation": "

The dimension that you want to filter on.

" + } + }, + "FilterList": { + "target": "com.amazonaws.lookoutmetrics#FilterList", + "traits": { + "smithy.api#documentation": "

The list of filters that you are applying.

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

Describes a list of filters for choosing a subset of dimension values. Each filter consists of the dimension and one of its values that you want to include. When multiple dimensions or values are specified, the dimensions are joined with an AND operation and the values are joined with an OR operation.

" + } + }, + "com.amazonaws.lookoutmetrics#MetricSetDimensionFilterList": { + "type": "list", + "member": { + "target": "com.amazonaws.lookoutmetrics#MetricSetDimensionFilter" + } + }, "com.amazonaws.lookoutmetrics#MetricSetName": { "type": "string", "traits": { @@ -5224,6 +5304,12 @@ }, "MetricSource": { "target": "com.amazonaws.lookoutmetrics#MetricSource" + }, + "DimensionFilterList": { + "target": "com.amazonaws.lookoutmetrics#MetricSetDimensionFilterList", + "traits": { + "smithy.api#documentation": "

Describes a list of filters for choosing specific dimensions and specific values. Each\n filter consists of the dimension and one of its values that you want to include. When\n multiple dimensions or values are specified, the dimensions are joined with an AND operation\n and the values are joined with an OR operation.

" + } } } }, diff --git a/codegen/sdk-codegen/aws-models/medialive.json b/codegen/sdk-codegen/aws-models/medialive.json index c96275ec0d5..ebad48a220b 100644 --- a/codegen/sdk-codegen/aws-models/medialive.json +++ b/codegen/sdk-codegen/aws-models/medialive.json @@ -699,6 +699,12 @@ "smithy.api#jsonName": "ac3Settings" } }, + "Eac3AtmosSettings": { + "target": "com.amazonaws.medialive#Eac3AtmosSettings", + "traits": { + "smithy.api#jsonName": "eac3AtmosSettings" + } + }, "Eac3Settings": { "target": "com.amazonaws.medialive#Eac3Settings", "traits": { @@ -6456,6 +6462,13 @@ ] } }, + "com.amazonaws.medialive#DolbyVision81Settings": { + "type": "structure", + "members": {}, + "traits": { + "smithy.api#documentation": "Dolby Vision Profile 8.1 Settings" + } + }, "com.amazonaws.medialive#DvbNitSettings": { "type": "structure", "members": { @@ -6883,6 +6896,147 @@ "smithy.api#documentation": "DVB Time and Date Table (SDT)" } }, + "com.amazonaws.medialive#Eac3AtmosCodingMode": { + "type": "string", + "traits": { + "smithy.api#documentation": "Eac3 Atmos Coding Mode", + "smithy.api#enum": [ + { + "value": "CODING_MODE_5_1_4", + "name": "CODING_MODE_5_1_4" + }, + { + "value": "CODING_MODE_7_1_4", + "name": "CODING_MODE_7_1_4" + }, + { + "value": "CODING_MODE_9_1_6", + "name": "CODING_MODE_9_1_6" + } + ] + } + }, + "com.amazonaws.medialive#Eac3AtmosDrcLine": { + "type": "string", + "traits": { + "smithy.api#documentation": "Eac3 Atmos Drc Line", + "smithy.api#enum": [ + { + "value": "FILM_LIGHT", + "name": "FILM_LIGHT" + }, + { + "value": "FILM_STANDARD", + "name": "FILM_STANDARD" + }, + { + "value": "MUSIC_LIGHT", + "name": "MUSIC_LIGHT" + }, + { + "value": "MUSIC_STANDARD", + "name": "MUSIC_STANDARD" + }, + { + "value": "NONE", + "name": "NONE" + }, + { + "value": "SPEECH", + "name": "SPEECH" + } + ] + } + }, + "com.amazonaws.medialive#Eac3AtmosDrcRf": { + "type": "string", + "traits": { + "smithy.api#documentation": "Eac3 Atmos Drc Rf", + "smithy.api#enum": [ + { + "value": "FILM_LIGHT", + "name": "FILM_LIGHT" + }, + { + "value": "FILM_STANDARD", + "name": "FILM_STANDARD" + }, + { + "value": "MUSIC_LIGHT", + "name": "MUSIC_LIGHT" + }, + { + "value": "MUSIC_STANDARD", + "name": "MUSIC_STANDARD" + }, + { + "value": "NONE", + "name": "NONE" + }, + { + "value": "SPEECH", + "name": "SPEECH" + } + ] + } + }, + "com.amazonaws.medialive#Eac3AtmosSettings": { + "type": "structure", + "members": { + "Bitrate": { + "target": "com.amazonaws.medialive#__double", + "traits": { + "smithy.api#documentation": "Average bitrate in bits/second. Valid bitrates depend on the coding mode.\n// * @affectsRightSizing true", + "smithy.api#jsonName": "bitrate" + } + }, + "CodingMode": { + "target": "com.amazonaws.medialive#Eac3AtmosCodingMode", + "traits": { + "smithy.api#documentation": "Dolby Digital Plus with Dolby Atmos coding mode. Determines number of channels.", + "smithy.api#jsonName": "codingMode" + } + }, + "Dialnorm": { + "target": "com.amazonaws.medialive#__integerMin1Max31", + "traits": { + "smithy.api#documentation": "Sets the dialnorm for the output. Default 23.", + "smithy.api#jsonName": "dialnorm" + } + }, + "DrcLine": { + "target": "com.amazonaws.medialive#Eac3AtmosDrcLine", + "traits": { + "smithy.api#documentation": "Sets the Dolby dynamic range compression profile.", + "smithy.api#jsonName": "drcLine" + } + }, + "DrcRf": { + "target": "com.amazonaws.medialive#Eac3AtmosDrcRf", + "traits": { + "smithy.api#documentation": "Sets the profile for heavy Dolby dynamic range compression, ensures that the instantaneous signal peaks do not exceed specified levels.", + "smithy.api#jsonName": "drcRf" + } + }, + "HeightTrim": { + "target": "com.amazonaws.medialive#__double", + "traits": { + "smithy.api#documentation": "Height dimensional trim. Sets the maximum amount to attenuate the height channels when the downstream player isn??t configured to handle Dolby Digital Plus with Dolby Atmos and must remix the channels.", + "smithy.api#jsonName": "heightTrim" + } + }, + "SurroundTrim": { + "target": "com.amazonaws.medialive#__double", + "traits": { + "smithy.api#documentation": "Surround dimensional trim. Sets the maximum amount to attenuate the surround channels when the downstream player isn't configured to handle Dolby Digital Plus with Dolby Atmos and must remix the channels.", + "smithy.api#jsonName": "surroundTrim" + } + } + }, + "traits": { + "smithy.api#documentation": "Eac3 Atmos Settings" + } + }, "com.amazonaws.medialive#Eac3AttenuationControl": { "type": "string", "traits": { @@ -8965,6 +9119,12 @@ "smithy.api#jsonName": "colorSpacePassthroughSettings" } }, + "DolbyVision81Settings": { + "target": "com.amazonaws.medialive#DolbyVision81Settings", + "traits": { + "smithy.api#jsonName": "dolbyVision81Settings" + } + }, "Hdr10Settings": { "target": "com.amazonaws.medialive#Hdr10Settings", "traits": { diff --git a/codegen/sdk-codegen/aws-models/pi.json b/codegen/sdk-codegen/aws-models/pi.json index c772fc74247..b90087e0b59 100644 --- a/codegen/sdk-codegen/aws-models/pi.json +++ b/codegen/sdk-codegen/aws-models/pi.json @@ -781,7 +781,7 @@ "smithy.api#box": {}, "smithy.api#range": { "min": 1, - "max": 10 + "max": 25 } } }, @@ -957,7 +957,7 @@ "smithy.api#box": {}, "smithy.api#range": { "min": 0, - "max": 20 + "max": 25 } } }, diff --git a/codegen/sdk-codegen/aws-models/redshift.json b/codegen/sdk-codegen/aws-models/redshift.json index 1948ee69838..defe31650d6 100644 --- a/codegen/sdk-codegen/aws-models/redshift.json +++ b/codegen/sdk-codegen/aws-models/redshift.json @@ -236,18 +236,18 @@ "AquaStatus": { "target": "com.amazonaws.redshift#AquaStatus", "traits": { - "smithy.api#documentation": "

The value indicates the status of AQUA on the cluster. Possible values include the following.

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

This field is retired. Amazon Redshift automatically determines whether to use AQUA (Advanced Query Accelerator).

" } }, "AquaConfigurationStatus": { "target": "com.amazonaws.redshift#AquaConfigurationStatus", "traits": { - "smithy.api#documentation": "

The value represents how the cluster is configured to use AQUA. Possible values include the following.

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

This field is retired. Amazon Redshift automatically determines whether to use AQUA (Advanced Query Accelerator).

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

The AQUA (Advanced Query Accelerator) configuration of the cluster.

" + "smithy.api#documentation": "

The operation that uses this structure is retired. Amazon Redshift automatically determines whether to use AQUA (Advanced Query Accelerator).

" } }, "com.amazonaws.redshift#AquaConfigurationStatus": { @@ -1328,7 +1328,7 @@ "AquaConfiguration": { "target": "com.amazonaws.redshift#AquaConfiguration", "traits": { - "smithy.api#documentation": "

The AQUA (Advanced Query Accelerator) configuration of the cluster.

" + "smithy.api#documentation": "

This field is retired. Amazon Redshift automatically determines whether to use AQUA (Advanced Query Accelerator).

" } }, "DefaultIamRoleArn": { @@ -2653,7 +2653,7 @@ "ElasticIp": { "target": "com.amazonaws.redshift#String", "traits": { - "smithy.api#documentation": "

The Elastic IP (EIP) address for the cluster. You don't have to specify the EIP for a \n publicly accessible cluster with AvailabilityZoneRelocation turned on.

\n

Constraints: The cluster must be provisioned in EC2-VPC and publicly-accessible\n through an Internet gateway. For more information about provisioning clusters in\n EC2-VPC, go to Supported\n Platforms to Launch Your Cluster in the Amazon Redshift Cluster Management Guide.

" + "smithy.api#documentation": "

The Elastic IP (EIP) address for the cluster.

\n

Constraints: The cluster must be provisioned in EC2-VPC and publicly-accessible\n through an Internet gateway. For more information about provisioning clusters in\n EC2-VPC, go to Supported\n Platforms to Launch Your Cluster in the Amazon Redshift Cluster Management Guide.

" } }, "Tags": { @@ -2707,7 +2707,7 @@ "AquaConfigurationStatus": { "target": "com.amazonaws.redshift#AquaConfigurationStatus", "traits": { - "smithy.api#documentation": "

The value represents how the cluster is configured to use AQUA (Advanced Query Accelerator) when it is created. Possible values include the following.

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

This parameter is retired. It does not set the AQUA configuration status. Amazon Redshift automatically determines whether to use AQUA (Advanced Query Accelerator).

" } }, "DefaultIamRoleArn": { @@ -8050,14 +8050,14 @@ "DbUser": { "target": "com.amazonaws.redshift#String", "traits": { - "smithy.api#documentation": "

The name of a database user. If a user name matching DbUser exists in\n the database, the temporary user credentials have the same permissions as the existing\n user. If DbUser doesn't exist in the database and Autocreate\n is True, a new user is created using the value for DbUser with\n PUBLIC permissions. If a database user matching the value for DbUser\n doesn't exist and Autocreate is False, then the command\n succeeds but the connection attempt will fail because the user doesn't exist in the\n database.

\n

For more information, see CREATE USER in the Amazon\n Redshift Database Developer Guide.

\n

Constraints:

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

The name of a database user. If a user name matching DbUser exists in\n the database, the temporary user credentials have the same permissions as the existing\n user. If DbUser doesn't exist in the database and Autocreate\n is True, a new user is created using the value for DbUser with\n PUBLIC permissions. If a database user matching the value for DbUser\n doesn't exist and Autocreate is False, then the command\n succeeds but the connection attempt will fail because the user doesn't exist in the\n database.

\n

For more information, see CREATE USER in the Amazon\n Redshift Database Developer Guide.

\n

Constraints:

\n ", "smithy.api#required": {} } }, "DbName": { "target": "com.amazonaws.redshift#String", "traits": { - "smithy.api#documentation": "

The name of a database that DbUser is authorized to log on to. If\n DbName is not specified, DbUser can log on to any existing\n database.

\n

Constraints:

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

The name of a database that DbUser is authorized to log on to. If\n DbName is not specified, DbUser can log on to any existing\n database.

\n

Constraints:

\n " } }, "ClusterIdentifier": { @@ -9376,7 +9376,7 @@ } ], "traits": { - "smithy.api#documentation": "

Modifies whether a cluster can use AQUA (Advanced Query Accelerator).

" + "smithy.api#documentation": "

This operation is retired. Calling this operation does not change AQUA configuration. Amazon Redshift automatically determines whether to use AQUA (Advanced Query Accelerator).

" } }, "com.amazonaws.redshift#ModifyAquaInputMessage": { @@ -9392,7 +9392,7 @@ "AquaConfigurationStatus": { "target": "com.amazonaws.redshift#AquaConfigurationStatus", "traits": { - "smithy.api#documentation": "

The new value of AQUA configuration status. Possible values include the following.

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

This parameter is retired. Amazon Redshift automatically determines whether to use AQUA (Advanced Query Accelerator).

" } } } @@ -9403,7 +9403,7 @@ "AquaConfiguration": { "target": "com.amazonaws.redshift#AquaConfiguration", "traits": { - "smithy.api#documentation": "

The updated AQUA configuration of the cluster.

" + "smithy.api#documentation": "

This parameter is retired. Amazon Redshift automatically determines whether to use AQUA (Advanced Query Accelerator).

" } } } @@ -12645,13 +12645,13 @@ "SnapshotIdentifier": { "target": "com.amazonaws.redshift#String", "traits": { - "smithy.api#documentation": "

The name of the snapshot from which to create the new cluster. This parameter isn't\n case sensitive.

\n

Example: my-snapshot-id\n

" + "smithy.api#documentation": "

The name of the snapshot from which to create the new cluster. This parameter isn't\n case sensitive. You can specify this parameter or snapshotArn, but not both.

\n

Example: my-snapshot-id\n

" } }, "SnapshotArn": { "target": "com.amazonaws.redshift#String", "traits": { - "smithy.api#documentation": "

The Amazon Resource Name (ARN) of the snapshot associated with the message to restore from a cluster.

" + "smithy.api#documentation": "

The Amazon Resource Name (ARN) of the snapshot associated with the message to restore from a cluster. You can specify\n this parameter or snapshotIdentifier, but not both.

" } }, "SnapshotClusterIdentifier": { @@ -12711,7 +12711,7 @@ "ElasticIp": { "target": "com.amazonaws.redshift#String", "traits": { - "smithy.api#documentation": "

The elastic IP (EIP) address for the cluster. You don't have to specify the EIP for a \n publicly accessible cluster with AvailabilityZoneRelocation turned on.

" + "smithy.api#documentation": "

The elastic IP (EIP) address for the cluster.

" } }, "ClusterParameterGroupName": { @@ -12807,7 +12807,7 @@ "AquaConfigurationStatus": { "target": "com.amazonaws.redshift#AquaConfigurationStatus", "traits": { - "smithy.api#documentation": "

The value represents how the cluster is configured to use AQUA (Advanced Query Accelerator) after the cluster is restored. Possible values include the following.

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

This parameter is retired. It does not set the AQUA configuration status. Amazon Redshift automatically determines whether to use AQUA (Advanced Query Accelerator).

" } }, "DefaultIamRoleArn": { diff --git a/codegen/sdk-codegen/aws-models/route-53.json b/codegen/sdk-codegen/aws-models/route-53.json index 9e2c923899f..bfb7ed6803e 100644 --- a/codegen/sdk-codegen/aws-models/route-53.json +++ b/codegen/sdk-codegen/aws-models/route-53.json @@ -56,7 +56,7 @@ "name": "route53" }, "aws.protocols#restXml": {}, - "smithy.api#documentation": "

Amazon Route 53 is a highly available and scalable Domain Name System (DNS) web\n\t\t\tservice.

\n\t\t

You can use Route 53 to:

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

Amazon Route 53 is a highly available and scalable Domain Name System (DNS) web\n\t\t\tservice.

", "smithy.api#title": "Amazon Route 53", "smithy.api#xmlNamespace": { "uri": "https://route53.amazonaws.com/doc/2013-04-01/" @@ -638,7 +638,7 @@ } ], "traits": { - "smithy.api#documentation": "

Creates, changes, or deletes CIDR blocks within a collection. Contains authoritative\n\t\t\tIP information mapping blocks to one or multiple locations.

\n\t\t

A change request can update multiple locations in a collection at a time, which is\n\t\t\thelpful if you want to move one or more CIDR blocks from one location to another in one\n\t\t\ttransaction, without downtime.

\n\t\t

\n Limits\n

\n\t\t

The max number of CIDR blocks included in the request is 1000. As a result, big updates\n\t\t\trequire multiple API calls.

\n\t\t

\n PUT and DELETE_IF_EXISTS\n

\n\t\t

Use ChangeCidrCollection to perform the following actions:

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

Creates, changes, or deletes CIDR blocks within a collection. Contains authoritative\n\t\t\tIP information mapping blocks to one or multiple locations.

\n\t\t

A change request can update multiple locations in a collection at a time, which is\n\t\t\thelpful if you want to move one or more CIDR blocks from one location to another in one\n\t\t\ttransaction, without downtime.

\n\t\t

\n Limits\n

\n\t\t

The max number of CIDR blocks included in the request is\n\t\t\t1000.\n\t\t\tAs a result, big updates require multiple API calls.

\n\t\t

\n PUT and DELETE_IF_EXISTS\n

\n\t\t

Use ChangeCidrCollection to perform the following actions:

\n\t\t ", "smithy.api#http": { "method": "POST", "uri": "/2013-04-01/cidrcollection/{Id}", @@ -1283,6 +1283,10 @@ "value": "me-south-1", "name": "me_south_1" }, + { + "value": "me-central-1", + "name": "me_central_1" + }, { "value": "ap-south-1", "name": "ap_south_1" @@ -1509,7 +1513,7 @@ } ], "traits": { - "smithy.api#documentation": "

Creates a CIDR collection in the current Amazon Web Services account.

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

Creates a CIDR collection in the\n\t\t\tcurrent\n\t\t\t\tAmazon Web Services account.

", "smithy.api#http": { "method": "POST", "uri": "/2013-04-01/cidrcollection", @@ -5928,7 +5932,7 @@ "NextToken": { "target": "com.amazonaws.route53#PaginationToken", "traits": { - "smithy.api#documentation": "

An opaque pagination token to indicate where the service is to begin enumerating\n\t\t\tresults.

\n\t\t

If no value is provided, the listing of results starts from the beginning.

" + "smithy.api#documentation": "

An opaque\n\t\t\tpagination token to indicate where the service is to begin enumerating results.

\n\t\t

If no value is provided, the listing of results starts from the beginning.

" } }, "CidrLocations": { @@ -9706,6 +9710,10 @@ "value": "us-isob-east-1", "name": "us_isob_east_1" }, + { + "value": "me-central-1", + "name": "me_central_1" + }, { "value": "ap-southeast-1", "name": "ap_southeast_1" diff --git a/codegen/sdk-codegen/aws-models/sagemaker.json b/codegen/sdk-codegen/aws-models/sagemaker.json index d1fc5dc6034..5e914385677 100644 --- a/codegen/sdk-codegen/aws-models/sagemaker.json +++ b/codegen/sdk-codegen/aws-models/sagemaker.json @@ -2110,7 +2110,7 @@ "MaxRuntimePerTrainingJobInSeconds": { "target": "com.amazonaws.sagemaker#MaxRuntimePerTrainingJobInSeconds", "traits": { - "smithy.api#documentation": "

The maximum time, in seconds, that each training job executed inside hyperparameter tuning is allowed to run as part of a\n hyperparameter tuning job. For more information, see the used by the action.

" + "smithy.api#documentation": "

The maximum time, in seconds, that each training job executed inside hyperparameter\n tuning is allowed to run as part of a hyperparameter tuning job. For more information, see\n the used by the action.

" } }, "MaxAutoMLJobRuntimeInSeconds": { @@ -2150,6 +2150,12 @@ "traits": { "smithy.api#documentation": "

The configuration for generating a candidate for an AutoML job (optional).

" } + }, + "Mode": { + "target": "com.amazonaws.sagemaker#AutoMLMode", + "traits": { + "smithy.api#documentation": "

The method that Autopilot uses to train the data. You can either specify the mode manually\n or let Autopilot choose for you based on the dataset size by selecting AUTO. In\n AUTO mode, Autopilot chooses ENSEMBLING for datasets smaller than\n 100 MB, and HYPERPARAMETER_TUNING for larger ones.

\n

The ENSEMBLING mode uses a multi-stack ensemble model to predict\n classification and regression tasks directly from your dataset. This machine learning mode\n combines several base models to produce an optimal predictive model. It then uses a\n stacking ensemble method to combine predictions from contributing members. A multi-stack\n ensemble model can provide better performance over a single model by combining the\n predictive capabilities of multiple models. See Autopilot algorithm support for a list of algorithms supported by\n ENSEMBLING mode.

\n

The HYPERPARAMETER_TUNING (HPO) mode uses the best hyperparameters to train\n the best version of a model. HPO will automatically select an algorithm for the type of\n problem you want to solve. Then HPO finds the best hyperparameters according to your\n objective metric. See Autopilot algorithm support for a list of algorithms supported by\n HYPERPARAMETER_TUNING mode.

" + } } }, "traits": { @@ -2471,6 +2477,25 @@ ] } }, + "com.amazonaws.sagemaker#AutoMLMode": { + "type": "string", + "traits": { + "smithy.api#enum": [ + { + "value": "AUTO", + "name": "AUTO" + }, + { + "value": "ENSEMBLING", + "name": "ENSEMBLING" + }, + { + "value": "HYPERPARAMETER_TUNING", + "name": "HYPERPARAMETER_TUNING" + } + ] + } + }, "com.amazonaws.sagemaker#AutoMLNameContains": { "type": "string", "traits": { @@ -2534,7 +2559,7 @@ "S3DataType": { "target": "com.amazonaws.sagemaker#AutoMLS3DataType", "traits": { - "smithy.api#documentation": "

The data type.

\n

A ManifestFile should have the format shown below:

\n

\n [ {\"prefix\": \"s3://DOC-EXAMPLE-BUCKET/DOC-EXAMPLE-FOLDER/DOC-EXAMPLE-PREFIX/\"}, \n

\n

\n \"DOC-EXAMPLE-RELATIVE-PATH/DOC-EXAMPLE-FOLDER/DATA-1\",\n

\n

\n \"DOC-EXAMPLE-RELATIVE-PATH/DOC-EXAMPLE-FOLDER/DATA-2\",\n

\n

\n ... \"DOC-EXAMPLE-RELATIVE-PATH/DOC-EXAMPLE-FOLDER/DATA-N\" ]\n

\n

An S3Prefix should have the following format:

\n

\n s3://DOC-EXAMPLE-BUCKET/DOC-EXAMPLE-FOLDER-OR-FILE\n

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

The data type.

\n

A ManifestFile should have the format shown below:

\n

\n [ {\"prefix\": \"s3://DOC-EXAMPLE-BUCKET/DOC-EXAMPLE-FOLDER/DOC-EXAMPLE-PREFIX/\"},\n \n

\n

\n \"DOC-EXAMPLE-RELATIVE-PATH/DOC-EXAMPLE-FOLDER/DATA-1\",\n

\n

\n \"DOC-EXAMPLE-RELATIVE-PATH/DOC-EXAMPLE-FOLDER/DATA-2\",\n

\n

\n ... \"DOC-EXAMPLE-RELATIVE-PATH/DOC-EXAMPLE-FOLDER/DATA-N\" ]\n

\n

An S3Prefix should have the following format:

\n

\n s3://DOC-EXAMPLE-BUCKET/DOC-EXAMPLE-FOLDER-OR-FILE\n

", "smithy.api#required": {} } }, @@ -7616,7 +7641,7 @@ } ], "traits": { - "smithy.api#documentation": "

Starts a model training job. After training completes, SageMaker saves the resulting\n model artifacts to an Amazon S3 location that you specify.

\n

If you choose to host your model using SageMaker hosting services, you can use the\n resulting model artifacts as part of the model. You can also use the artifacts in a\n machine learning service other than SageMaker, provided that you know how to use them for\n inference. \n

\n

In the request body, you provide the following:

\n \n

For more information about SageMaker, see How It Works.

" + "smithy.api#documentation": "

Starts a model training job. After training completes, SageMaker saves the resulting\n model artifacts to an Amazon S3 location that you specify.

\n

If you choose to host your model using SageMaker hosting services, you can use the\n resulting model artifacts as part of the model. You can also use the artifacts in a\n machine learning service other than SageMaker, provided that you know how to use them for\n inference. \n

\n

In the request body, you provide the following:

\n \n

For more information about SageMaker, see How It Works.

" } }, "com.amazonaws.sagemaker#CreateTrainingJobRequest": { @@ -7632,7 +7657,7 @@ "HyperParameters": { "target": "com.amazonaws.sagemaker#HyperParameters", "traits": { - "smithy.api#documentation": "

Algorithm-specific parameters that influence the quality of the model. You set\n hyperparameters before you start the learning process. For a list of hyperparameters for\n each training algorithm provided by SageMaker, see Algorithms.

\n

You can specify a maximum of 100 hyperparameters. Each hyperparameter is a\n key-value pair. Each key and value is limited to 256 characters, as specified by the\n Length Constraint.

" + "smithy.api#documentation": "

Algorithm-specific parameters that influence the quality of the model. You set\n hyperparameters before you start the learning process. For a list of hyperparameters for\n each training algorithm provided by SageMaker, see Algorithms.

\n

You can specify a maximum of 100 hyperparameters. Each hyperparameter is a\n key-value pair. Each key and value is limited to 256 characters, as specified by the\n Length Constraint.

\n \n

You must not include any security-sensitive information, such as \n account access IDs, secrets, and tokens, in the dictionary for configuring \n hyperparameters. SageMaker rejects the training job request and returns an \n exception error for detected credentials, if such user input is found.

\n
" } }, "AlgorithmSpecification": { @@ -20647,6 +20672,89 @@ "target": "com.amazonaws.sagemaker#HyperParameterTuningJobObjective" } }, + "com.amazonaws.sagemaker#HyperParameterTuningJobSearchEntity": { + "type": "structure", + "members": { + "HyperParameterTuningJobName": { + "target": "com.amazonaws.sagemaker#HyperParameterTuningJobName", + "traits": { + "smithy.api#documentation": "

The name of a hyperparameter tuning job.

" + } + }, + "HyperParameterTuningJobArn": { + "target": "com.amazonaws.sagemaker#HyperParameterTuningJobArn", + "traits": { + "smithy.api#documentation": "

The Amazon Resource Name (ARN) of a hyperparameter tuning job.

" + } + }, + "HyperParameterTuningJobConfig": { + "target": "com.amazonaws.sagemaker#HyperParameterTuningJobConfig" + }, + "TrainingJobDefinition": { + "target": "com.amazonaws.sagemaker#HyperParameterTrainingJobDefinition" + }, + "TrainingJobDefinitions": { + "target": "com.amazonaws.sagemaker#HyperParameterTrainingJobDefinitions", + "traits": { + "smithy.api#documentation": "

The job definitions included in a hyperparameter tuning job.

" + } + }, + "HyperParameterTuningJobStatus": { + "target": "com.amazonaws.sagemaker#HyperParameterTuningJobStatus", + "traits": { + "smithy.api#documentation": "

The status of a hyperparameter tuning job.

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

The time that a hyperparameter tuning job was created.

" + } + }, + "HyperParameterTuningEndTime": { + "target": "com.amazonaws.sagemaker#Timestamp", + "traits": { + "smithy.api#documentation": "

The time that a hyperparameter tuning job ended.

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

The time that a hyperparameter tuning job was last modified.

" + } + }, + "TrainingJobStatusCounters": { + "target": "com.amazonaws.sagemaker#TrainingJobStatusCounters" + }, + "ObjectiveStatusCounters": { + "target": "com.amazonaws.sagemaker#ObjectiveStatusCounters" + }, + "BestTrainingJob": { + "target": "com.amazonaws.sagemaker#HyperParameterTrainingJobSummary" + }, + "OverallBestTrainingJob": { + "target": "com.amazonaws.sagemaker#HyperParameterTrainingJobSummary" + }, + "WarmStartConfig": { + "target": "com.amazonaws.sagemaker#HyperParameterTuningJobWarmStartConfig" + }, + "FailureReason": { + "target": "com.amazonaws.sagemaker#FailureReason", + "traits": { + "smithy.api#documentation": "

The error that was created when a hyperparameter tuning job failed.

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

The tags associated with a hyperparameter tuning job. For more information see Tagging Amazon Web Services resources.

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

An entity having characteristics over which a user can search for a hyperparameter\n tuning job.

" + } + }, "com.amazonaws.sagemaker#HyperParameterTuningJobSortByOptions": { "type": "string", "traits": { @@ -34074,6 +34182,24 @@ "traits": { "smithy.api#documentation": "

The serverless configuration for an endpoint. Specifies a serverless endpoint configuration instead of an instance-based endpoint configuration.

" } + }, + "VolumeSizeInGB": { + "target": "com.amazonaws.sagemaker#ProductionVariantVolumeSizeInGB", + "traits": { + "smithy.api#documentation": "

The size, in GB, of the ML storage volume attached to individual\n inference instance associated with the production variant. Currenly only\n Amazon EBS gp2 storage volumes are supported.

" + } + }, + "ModelDataDownloadTimeoutInSeconds": { + "target": "com.amazonaws.sagemaker#ProductionVariantModelDataDownloadTimeoutInSeconds", + "traits": { + "smithy.api#documentation": "

The timeout value, in seconds, to download and extract the\n model that you want to host from Amazon S3 to the individual inference instance associated with\n this production variant.

" + } + }, + "ContainerStartupHealthCheckTimeoutInSeconds": { + "target": "com.amazonaws.sagemaker#ProductionVariantContainerStartupHealthCheckTimeoutInSeconds", + "traits": { + "smithy.api#documentation": "

The timeout value, in seconds, for your inference container\n to pass health check by SageMaker Hosting. For more information about health\n check, see How\n Your Container Should Respond to Health Check (Ping)\n Requests.

" + } } }, "traits": { @@ -34111,6 +34237,16 @@ ] } }, + "com.amazonaws.sagemaker#ProductionVariantContainerStartupHealthCheckTimeoutInSeconds": { + "type": "integer", + "traits": { + "smithy.api#box": {}, + "smithy.api#range": { + "min": 60, + "max": 3600 + } + } + }, "com.amazonaws.sagemaker#ProductionVariantCoreDumpConfig": { "type": "structure", "members": { @@ -34487,6 +34623,16 @@ } } }, + "com.amazonaws.sagemaker#ProductionVariantModelDataDownloadTimeoutInSeconds": { + "type": "integer", + "traits": { + "smithy.api#box": {}, + "smithy.api#range": { + "min": 60, + "max": 3600 + } + } + }, "com.amazonaws.sagemaker#ProductionVariantServerlessConfig": { "type": "structure", "members": { @@ -34622,6 +34768,16 @@ } } }, + "com.amazonaws.sagemaker#ProductionVariantVolumeSizeInGB": { + "type": "integer", + "traits": { + "smithy.api#box": {}, + "smithy.api#range": { + "min": 1, + "max": 512 + } + } + }, "com.amazonaws.sagemaker#ProfilerConfig": { "type": "structure", "members": { @@ -36545,6 +36701,10 @@ { "value": "FeatureMetadata", "name": "FEATURE_METADATA" + }, + { + "value": "HyperParameterTuningJob", + "name": "HYPER_PARAMETER_TUNING_JOB" } ] } @@ -37864,6 +38024,12 @@ "traits": { "smithy.api#documentation": "

The feature metadata used to search through the features.

" } + }, + "HyperParameterTuningJob": { + "target": "com.amazonaws.sagemaker#HyperParameterTuningJobSearchEntity", + "traits": { + "smithy.api#documentation": "

The properties of a hyperparameter tuning job.

" + } } }, "traits": { @@ -39356,7 +39522,7 @@ "MaxRuntimeInSeconds": { "target": "com.amazonaws.sagemaker#MaxRuntimeInSeconds", "traits": { - "smithy.api#documentation": "

The maximum length of time, in seconds, that a training or compilation job can run\n before it is stopped.

\n

For compilation jobs, if the job does not complete during this time, a\n TimeOut error is generated. We recommend starting with 900 seconds and\n increasing as necessary based on your model.

\n

For all other jobs, if the job does not complete during this time, SageMaker ends the job.\n When RetryStrategy is specified in the job request,\n MaxRuntimeInSeconds specifies the maximum time for all of the attempts\n in total, not each individual attempt. The default value is 1 day. The maximum value is\n 28 days.

\n

The maximum time that a TrainingJob can run in total, including any time spent\n publishing metrics or archiving and uploading models after it has been stopped, is 30\n days.

" + "smithy.api#documentation": "

The maximum length of time, in seconds, that a training or compilation job can run\n before it is stopped.

\n

For compilation jobs, if the job does not complete during this time, a\n TimeOut error is generated. We recommend starting with 900 seconds and\n increasing as necessary based on your model.

\n

For all other jobs, if the job does not complete during this time, SageMaker ends the job.\n When RetryStrategy is specified in the job request,\n MaxRuntimeInSeconds specifies the maximum time for all of the attempts\n in total, not each individual attempt. The default value is 1 day. The maximum value is\n 28 days.

\n

The maximum time that a TrainingJob can run in total, including any time\n spent publishing metrics or archiving and uploading models after it has been stopped, is\n 30 days.

" } }, "MaxWaitTimeInSeconds": { diff --git a/codegen/sdk-codegen/aws-models/sns.json b/codegen/sdk-codegen/aws-models/sns.json index eb57470506f..0c906caa14c 100644 --- a/codegen/sdk-codegen/aws-models/sns.json +++ b/codegen/sdk-codegen/aws-models/sns.json @@ -40,6 +40,9 @@ "input": { "target": "com.amazonaws.sns#AddPermissionInput" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.sns#AuthorizationErrorException" @@ -155,6 +158,9 @@ { "target": "com.amazonaws.sns#DeleteTopic" }, + { + "target": "com.amazonaws.sns#GetDataProtectionPolicy" + }, { "target": "com.amazonaws.sns#GetEndpointAttributes" }, @@ -209,6 +215,9 @@ { "target": "com.amazonaws.sns#PublishBatch" }, + { + "target": "com.amazonaws.sns#PutDataProtectionPolicy" + }, { "target": "com.amazonaws.sns#RemovePermission" }, @@ -741,6 +750,12 @@ "traits": { "smithy.api#documentation": "

The list of tags to add to a new topic.

\n \n

To be able to tag a topic on creation, you must have the\n sns:CreateTopic and sns:TagResource\n permissions.

\n
" } + }, + "DataProtectionPolicy": { + "target": "com.amazonaws.sns#attributeValue", + "traits": { + "smithy.api#documentation": "

The body of the policy document you want to use for this topic.

\n

You can only add one policy per topic.

\n

The policy must be in JSON string format.

\n

Length Constraints: Maximum length of 30,720.

" + } } }, "traits": { @@ -772,6 +787,9 @@ "input": { "target": "com.amazonaws.sns#DeleteEndpointInput" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.sns#AuthorizationErrorException" @@ -807,6 +825,9 @@ "input": { "target": "com.amazonaws.sns#DeletePlatformApplicationInput" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.sns#AuthorizationErrorException" @@ -890,6 +911,9 @@ "input": { "target": "com.amazonaws.sns#DeleteTopicInput" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.sns#AuthorizationErrorException" @@ -1006,6 +1030,58 @@ "smithy.api#httpError": 403 } }, + "com.amazonaws.sns#GetDataProtectionPolicy": { + "type": "operation", + "input": { + "target": "com.amazonaws.sns#GetDataProtectionPolicyInput" + }, + "output": { + "target": "com.amazonaws.sns#GetDataProtectionPolicyResponse" + }, + "errors": [ + { + "target": "com.amazonaws.sns#AuthorizationErrorException" + }, + { + "target": "com.amazonaws.sns#InternalErrorException" + }, + { + "target": "com.amazonaws.sns#InvalidParameterException" + }, + { + "target": "com.amazonaws.sns#InvalidSecurityException" + }, + { + "target": "com.amazonaws.sns#NotFoundException" + } + ], + "traits": { + "smithy.api#documentation": "

Retrieves the specified inline DataProtectionPolicy document that is stored in the specified Amazon SNS topic.

" + } + }, + "com.amazonaws.sns#GetDataProtectionPolicyInput": { + "type": "structure", + "members": { + "ResourceArn": { + "target": "com.amazonaws.sns#topicARN", + "traits": { + "smithy.api#documentation": "

The ARN of the topic whose DataProtectionPolicy you want to get.

\n

For more information about ARNs, see Amazon Resource Names (ARNs)\n in the Amazon Web Services General Reference.

", + "smithy.api#required": {} + } + } + } + }, + "com.amazonaws.sns#GetDataProtectionPolicyResponse": { + "type": "structure", + "members": { + "DataProtectionPolicy": { + "target": "com.amazonaws.sns#attributeValue", + "traits": { + "smithy.api#documentation": "

Retrieves the DataProtectionPolicy in JSON string format.

" + } + } + } + }, "com.amazonaws.sns#GetEndpointAttributes": { "type": "operation", "input": { @@ -1697,6 +1773,7 @@ "smithy.api#paginated": { "inputToken": "NextToken", "outputToken": "NextToken", + "items": "PhoneNumbers", "pageSize": "MaxResults" } } @@ -2538,6 +2615,9 @@ }, { "target": "com.amazonaws.sns#PlatformApplicationDisabledException" + }, + { + "target": "com.amazonaws.sns#ValidationException" } ], "traits": { @@ -2609,6 +2689,9 @@ }, { "target": "com.amazonaws.sns#TooManyEntriesInBatchRequestException" + }, + { + "target": "com.amazonaws.sns#ValidationException" } ], "traits": { @@ -2824,11 +2907,62 @@ "smithy.api#documentation": "

Response for Publish action.

" } }, + "com.amazonaws.sns#PutDataProtectionPolicy": { + "type": "operation", + "input": { + "target": "com.amazonaws.sns#PutDataProtectionPolicyInput" + }, + "output": { + "target": "smithy.api#Unit" + }, + "errors": [ + { + "target": "com.amazonaws.sns#AuthorizationErrorException" + }, + { + "target": "com.amazonaws.sns#InternalErrorException" + }, + { + "target": "com.amazonaws.sns#InvalidParameterException" + }, + { + "target": "com.amazonaws.sns#InvalidSecurityException" + }, + { + "target": "com.amazonaws.sns#NotFoundException" + } + ], + "traits": { + "smithy.api#documentation": "

Adds or updates an inline policy document that is stored in the specified Amazon SNS topic.

" + } + }, + "com.amazonaws.sns#PutDataProtectionPolicyInput": { + "type": "structure", + "members": { + "ResourceArn": { + "target": "com.amazonaws.sns#topicARN", + "traits": { + "smithy.api#documentation": "

The ARN of the topic whose DataProtectionPolicy you want to add or update.

\n

For more information about ARNs, see Amazon Resource Names (ARNs)\n in the Amazon Web Services General Reference.

", + "smithy.api#required": {} + } + }, + "DataProtectionPolicy": { + "target": "com.amazonaws.sns#attributeValue", + "traits": { + "smithy.api#documentation": "

The JSON serialization of the topic's DataProtectionPolicy.

\n

The DataProtectionPolicy must be in JSON string format.

\n

Length Constraints: Maximum length of 30,720.

", + "smithy.api#required": {} + } + } + } + }, "com.amazonaws.sns#RemovePermission": { "type": "operation", "input": { "target": "com.amazonaws.sns#RemovePermissionInput" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.sns#AuthorizationErrorException" @@ -2953,6 +3087,9 @@ "input": { "target": "com.amazonaws.sns#SetEndpointAttributesInput" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.sns#AuthorizationErrorException" @@ -2998,6 +3135,9 @@ "input": { "target": "com.amazonaws.sns#SetPlatformApplicationAttributesInput" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.sns#AuthorizationErrorException" @@ -3091,6 +3231,9 @@ "input": { "target": "com.amazonaws.sns#SetSubscriptionAttributesInput" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.sns#AuthorizationErrorException" @@ -3145,6 +3288,9 @@ "input": { "target": "com.amazonaws.sns#SetTopicAttributesInput" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.sns#AuthorizationErrorException" @@ -3608,6 +3754,9 @@ "input": { "target": "com.amazonaws.sns#UnsubscribeInput" }, + "output": { + "target": "smithy.api#Unit" + }, "errors": [ { "target": "com.amazonaws.sns#AuthorizationErrorException" diff --git a/codegen/sdk-codegen/aws-models/ssm.json b/codegen/sdk-codegen/aws-models/ssm.json index 04f069cca38..3933b7bfdf5 100644 --- a/codegen/sdk-codegen/aws-models/ssm.json +++ b/codegen/sdk-codegen/aws-models/ssm.json @@ -4301,6 +4301,9 @@ { "target": "com.amazonaws.ssm#InvalidSchedule" }, + { + "target": "com.amazonaws.ssm#InvalidTag" + }, { "target": "com.amazonaws.ssm#InvalidTarget" }, @@ -4638,6 +4641,12 @@ "traits": { "smithy.api#documentation": "

A key-value mapping of document parameters to target resources. Both Targets and TargetMaps\n can't be specified together.

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

Adds or overwrites one or more tags for a State Manager association. Tags\n are metadata that you can assign to your Amazon Web Services resources. Tags enable you to categorize your\n resources in different ways, for example, by purpose, owner, or environment. Each tag consists of\n a key and an optional value, both of which you define.

" + } } } }, @@ -4709,7 +4718,7 @@ "Name": { "target": "com.amazonaws.ssm#DocumentName", "traits": { - "smithy.api#documentation": "

A name for the SSM document.

\n \n

You can't use the following strings as document name prefixes. These are reserved by Amazon Web Services\n for use as document name prefixes:

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

A name for the SSM document.

\n \n

You can't use the following strings as document name prefixes. These are reserved by Amazon Web Services\n for use as document name prefixes:

\n \n
", "smithy.api#required": {} } }, @@ -6981,7 +6990,7 @@ "Filters": { "target": "com.amazonaws.ssm#InstanceInformationStringFilterList", "traits": { - "smithy.api#documentation": "

One or more filters. Use a filter to return a more specific list of managed nodes. You can\n filter based on tags applied to EC2 instances. Use this Filters data type instead of\n InstanceInformationFilterList, which is deprecated.

" + "smithy.api#documentation": "

One or more filters. Use a filter to return a more specific list of managed nodes. You can\n filter based on tags applied to your managed nodes. Use this Filters data type\n instead of InstanceInformationFilterList, which is deprecated.

" } }, "MaxResults": { @@ -12549,7 +12558,7 @@ "Key": { "target": "com.amazonaws.ssm#InstanceInformationStringFilterKey", "traits": { - "smithy.api#documentation": "

The filter key name to describe your managed nodes. For example:

\n

\"InstanceIds\"|\"AgentVersion\"|\"PingStatus\"|\"PlatformTypes\"|\"ActivationIds\"|\"IamRole\"|\"ResourceType\"|\"AssociationStatus\"|\"Tag\n Key\"

\n \n

\n Tag key isn't a valid filter. You must specify either tag-key or\n tag:keyname and a string. Here are some valid examples: tag-key, tag:123, tag:al!,\n tag:Windows. Here are some invalid examples: tag-keys, Tag Key, tag:,\n tagKey, abc:keyname.

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

The filter key name to describe your managed nodes. For example:

\n

\"InstanceIds\" | \"AgentVersion\" | \"PingStatus\" | \"PlatformTypes\" | \"ActivationIds\" |\n \"IamRole\" | \"ResourceType\" | \"AssociationStatus\" | \"tag-key\" | \"tag:{keyname}\n

\n \n

\n Tag Key isn't a valid filter. You must specify either tag-key or\n tag:{keyname} and a string. Here are some valid examples: tag-key,\n tag:123, tag:al!, tag:Windows. Here are some\n invalid examples: tag-keys, Tag Key,\n tag:, tagKey, abc:keyname.

\n
", "smithy.api#required": {} } }, @@ -13567,6 +13576,22 @@ "smithy.api#error": "client" } }, + "com.amazonaws.ssm#InvalidTag": { + "type": "structure", + "members": { + "Message": { + "target": "com.amazonaws.ssm#String" + } + }, + "traits": { + "aws.protocols#awsQueryError": { + "code": "InvalidTag", + "httpResponseCode": 400 + }, + "smithy.api#documentation": "

The specified tag key or value is not valid.

", + "smithy.api#error": "client" + } + }, "com.amazonaws.ssm#InvalidTarget": { "type": "structure", "members": { @@ -22333,6 +22358,10 @@ { "value": "Automation", "name": "AUTOMATION" + }, + { + "value": "Association", + "name": "ASSOCIATION" } ] } @@ -22884,7 +22913,7 @@ "ServiceRoleArn": { "target": "com.amazonaws.ssm#ServiceRole", "traits": { - "smithy.api#documentation": "

The ARN of the Identity and Access Management (IAM) service role to use to publish\n Amazon Simple Notification Service (Amazon SNS) notifications for Run Command commands.

" + "smithy.api#documentation": "

The ARN of the Identity and Access Management (IAM) service role to use to publish\n Amazon Simple Notification Service (Amazon SNS) notifications for Run Command commands.

\n

This role must provide the sns:Publish permission for your notification topic.\n For information about creating and using this service role, see Monitoring Systems Manager status changes using Amazon SNS notifications in the\n Amazon Web Services Systems Manager User Guide.

" } }, "NotificationConfig": { @@ -23805,7 +23834,7 @@ "TokenValue": { "target": "com.amazonaws.ssm#TokenValue", "traits": { - "smithy.api#documentation": "

An encrypted token value containing session and caller information. Used to authenticate the\n connection to the managed node.

" + "smithy.api#documentation": "

An encrypted token value containing session and caller information. This token is used to authenticate the connection to the managed node, and is valid only long enough to ensure the connection is successful. Never share your session's token.

" } }, "StreamUrl": { diff --git a/codegen/sdk-codegen/aws-models/transfer.json b/codegen/sdk-codegen/aws-models/transfer.json index f0483129583..7dd5b896821 100644 --- a/codegen/sdk-codegen/aws-models/transfer.json +++ b/codegen/sdk-codegen/aws-models/transfer.json @@ -1287,6 +1287,54 @@ } } }, + "com.amazonaws.transfer#DeleteHostKey": { + "type": "operation", + "input": { + "target": "com.amazonaws.transfer#DeleteHostKeyRequest" + }, + "output": { + "target": "smithy.api#Unit" + }, + "errors": [ + { + "target": "com.amazonaws.transfer#InternalServiceError" + }, + { + "target": "com.amazonaws.transfer#InvalidRequestException" + }, + { + "target": "com.amazonaws.transfer#ResourceNotFoundException" + }, + { + "target": "com.amazonaws.transfer#ServiceUnavailableException" + }, + { + "target": "com.amazonaws.transfer#ThrottlingException" + } + ], + "traits": { + "smithy.api#documentation": "

Deletes the host key that's specified in the HoskKeyId parameter.

" + } + }, + "com.amazonaws.transfer#DeleteHostKeyRequest": { + "type": "structure", + "members": { + "ServerId": { + "target": "com.amazonaws.transfer#ServerId", + "traits": { + "smithy.api#documentation": "

Provide the ID of the server that contains the host key that you are deleting.

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

The ID of the host key that you are deleting.

", + "smithy.api#required": {} + } + } + } + }, "com.amazonaws.transfer#DeleteProfile": { "type": "operation", "input": { @@ -1812,6 +1860,63 @@ } } }, + "com.amazonaws.transfer#DescribeHostKey": { + "type": "operation", + "input": { + "target": "com.amazonaws.transfer#DescribeHostKeyRequest" + }, + "output": { + "target": "com.amazonaws.transfer#DescribeHostKeyResponse" + }, + "errors": [ + { + "target": "com.amazonaws.transfer#InternalServiceError" + }, + { + "target": "com.amazonaws.transfer#InvalidRequestException" + }, + { + "target": "com.amazonaws.transfer#ResourceNotFoundException" + }, + { + "target": "com.amazonaws.transfer#ServiceUnavailableException" + } + ], + "traits": { + "smithy.api#documentation": "

Returns the details of the host key that's specified by the HostKeyId and ServerId.

" + } + }, + "com.amazonaws.transfer#DescribeHostKeyRequest": { + "type": "structure", + "members": { + "ServerId": { + "target": "com.amazonaws.transfer#ServerId", + "traits": { + "smithy.api#documentation": "

Provide the ID of the server that contains the host key that you want described.

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

Provide the ID of the host key that you want described.

", + "smithy.api#required": {} + } + } + } + }, + "com.amazonaws.transfer#DescribeHostKeyResponse": { + "type": "structure", + "members": { + "HostKey": { + "target": "com.amazonaws.transfer#DescribedHostKey", + "traits": { + "smithy.api#documentation": "

Returns the details for the specified host key.

", + "smithy.api#required": {} + } + } + } + }, "com.amazonaws.transfer#DescribeProfile": { "type": "operation", "input": { @@ -2441,6 +2546,57 @@ "smithy.api#documentation": "

The details for an execution object.

" } }, + "com.amazonaws.transfer#DescribedHostKey": { + "type": "structure", + "members": { + "Arn": { + "target": "com.amazonaws.transfer#Arn", + "traits": { + "smithy.api#documentation": "

The unique Amazon Resource Name (ARN) for the host key.

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

A unique identifier for the host key.

" + } + }, + "HostKeyFingerprint": { + "target": "com.amazonaws.transfer#HostKeyFingerprint", + "traits": { + "smithy.api#documentation": "

The public key fingerprint, which is a short sequence of bytes used to identify the longer public key.

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

The text description for this host key.

" + } + }, + "Type": { + "target": "com.amazonaws.transfer#HostKeyType", + "traits": { + "smithy.api#documentation": "

The encryption algorithm used for the host key. The Type is one of the\n following values:

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

The date on which the host key was added to the server.

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

Key-value pairs that can be used to group and search for host keys.

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

The details for a server host key.

" + } + }, "com.amazonaws.transfer#DescribedProfile": { "type": "structure", "members": { @@ -3211,9 +3367,32 @@ "smithy.api#sensitive": {} } }, + "com.amazonaws.transfer#HostKeyDescription": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 0, + "max": 200 + }, + "smithy.api#pattern": "^[\\p{Print}]*$" + } + }, "com.amazonaws.transfer#HostKeyFingerprint": { "type": "string" }, + "com.amazonaws.transfer#HostKeyId": { + "type": "string", + "traits": { + "smithy.api#length": { + "min": 25, + "max": 25 + }, + "smithy.api#pattern": "^hostkey-[0-9a-f]{17}$" + } + }, + "com.amazonaws.transfer#HostKeyType": { + "type": "string" + }, "com.amazonaws.transfer#IdentityProviderDetails": { "type": "structure", "members": { @@ -3363,6 +3542,88 @@ } } }, + "com.amazonaws.transfer#ImportHostKey": { + "type": "operation", + "input": { + "target": "com.amazonaws.transfer#ImportHostKeyRequest" + }, + "output": { + "target": "com.amazonaws.transfer#ImportHostKeyResponse" + }, + "errors": [ + { + "target": "com.amazonaws.transfer#InternalServiceError" + }, + { + "target": "com.amazonaws.transfer#InvalidRequestException" + }, + { + "target": "com.amazonaws.transfer#ResourceExistsException" + }, + { + "target": "com.amazonaws.transfer#ResourceNotFoundException" + }, + { + "target": "com.amazonaws.transfer#ServiceUnavailableException" + }, + { + "target": "com.amazonaws.transfer#ThrottlingException" + } + ], + "traits": { + "smithy.api#documentation": "

Adds a host key to the server specified by the ServerId parameter.

" + } + }, + "com.amazonaws.transfer#ImportHostKeyRequest": { + "type": "structure", + "members": { + "ServerId": { + "target": "com.amazonaws.transfer#ServerId", + "traits": { + "smithy.api#documentation": "

Provide the ID of the server that contains the host key that you are importing.

", + "smithy.api#required": {} + } + }, + "HostKeyBody": { + "target": "com.amazonaws.transfer#HostKey", + "traits": { + "smithy.api#documentation": "

The public key portion of an SSH key pair.

\n

Transfer Family accepts RSA, ECDSA, and ED25519 keys.

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

Enter a text description to identify this host key.

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

Key-value pairs that can be used to group and search for host keys.

" + } + } + } + }, + "com.amazonaws.transfer#ImportHostKeyResponse": { + "type": "structure", + "members": { + "ServerId": { + "target": "com.amazonaws.transfer#ServerId", + "traits": { + "smithy.api#documentation": "

Returns the server ID that contains the imported key.

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

Returns the host key ID for the imported key.

", + "smithy.api#required": {} + } + } + } + }, "com.amazonaws.transfer#ImportSshPublicKey": { "type": "operation", "input": { @@ -3903,6 +4164,84 @@ } } }, + "com.amazonaws.transfer#ListHostKeys": { + "type": "operation", + "input": { + "target": "com.amazonaws.transfer#ListHostKeysRequest" + }, + "output": { + "target": "com.amazonaws.transfer#ListHostKeysResponse" + }, + "errors": [ + { + "target": "com.amazonaws.transfer#InternalServiceError" + }, + { + "target": "com.amazonaws.transfer#InvalidNextTokenException" + }, + { + "target": "com.amazonaws.transfer#InvalidRequestException" + }, + { + "target": "com.amazonaws.transfer#ResourceNotFoundException" + }, + { + "target": "com.amazonaws.transfer#ServiceUnavailableException" + } + ], + "traits": { + "smithy.api#documentation": "

Returns a list of host keys for the server specified by the ServerId paramter.

" + } + }, + "com.amazonaws.transfer#ListHostKeysRequest": { + "type": "structure", + "members": { + "MaxResults": { + "target": "com.amazonaws.transfer#MaxResults", + "traits": { + "smithy.api#documentation": "

The maximum number of host keys to return.

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

When there are additional results that were not returned, a NextToken\n parameter is returned. You can use that value for a subsequent call to\n ListHostKeys to continue listing results.

" + } + }, + "ServerId": { + "target": "com.amazonaws.transfer#ServerId", + "traits": { + "smithy.api#documentation": "

Provide the ID of the server that contains the host keys that you want to view.

", + "smithy.api#required": {} + } + } + } + }, + "com.amazonaws.transfer#ListHostKeysResponse": { + "type": "structure", + "members": { + "NextToken": { + "target": "com.amazonaws.transfer#NextToken", + "traits": { + "smithy.api#documentation": "

Returns a token that you can use to call ListHostKeys again and receive\n additional results, if there are any.

" + } + }, + "ServerId": { + "target": "com.amazonaws.transfer#ServerId", + "traits": { + "smithy.api#documentation": "

Returns the server ID that contains the listed host keys.

", + "smithy.api#required": {} + } + }, + "HostKeys": { + "target": "com.amazonaws.transfer#ListedHostKeys", + "traits": { + "smithy.api#documentation": "

Returns an array, where each item contains the details of a host key.

", + "smithy.api#required": {} + } + } + } + }, "com.amazonaws.transfer#ListProfiles": { "type": "operation", "input": { @@ -4569,6 +4908,57 @@ "target": "com.amazonaws.transfer#ListedExecution" } }, + "com.amazonaws.transfer#ListedHostKey": { + "type": "structure", + "members": { + "Arn": { + "target": "com.amazonaws.transfer#Arn", + "traits": { + "smithy.api#documentation": "

Specifies the unique Amazon Resource Name (ARN) of the host key.

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

" + } + }, + "Fingerprint": { + "target": "com.amazonaws.transfer#HostKeyFingerprint", + "traits": { + "smithy.api#documentation": "

The public key fingerprint, which is a short sequence of bytes used to identify the longer public key.

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

The current description for the host key. You can change it by calling the UpdateHostKey operation and providing a new description.

" + } + }, + "Type": { + "target": "com.amazonaws.transfer#HostKeyType", + "traits": { + "smithy.api#documentation": "

The encryption algorithm used for the host key. The Type is one of the\n following values:

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

The date on which the host key was added to the server.

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

Returns properties of the host key that is specified.

" + } + }, + "com.amazonaws.transfer#ListedHostKeys": { + "type": "list", + "member": { + "target": "com.amazonaws.transfer#ListedHostKey" + } + }, "com.amazonaws.transfer#ListedProfile": { "type": "structure", "members": { @@ -6153,6 +6543,9 @@ { "target": "com.amazonaws.transfer#DeleteConnector" }, + { + "target": "com.amazonaws.transfer#DeleteHostKey" + }, { "target": "com.amazonaws.transfer#DeleteProfile" }, @@ -6183,6 +6576,9 @@ { "target": "com.amazonaws.transfer#DescribeExecution" }, + { + "target": "com.amazonaws.transfer#DescribeHostKey" + }, { "target": "com.amazonaws.transfer#DescribeProfile" }, @@ -6201,6 +6597,9 @@ { "target": "com.amazonaws.transfer#ImportCertificate" }, + { + "target": "com.amazonaws.transfer#ImportHostKey" + }, { "target": "com.amazonaws.transfer#ImportSshPublicKey" }, @@ -6219,6 +6618,9 @@ { "target": "com.amazonaws.transfer#ListExecutions" }, + { + "target": "com.amazonaws.transfer#ListHostKeys" + }, { "target": "com.amazonaws.transfer#ListProfiles" }, @@ -6270,6 +6672,9 @@ { "target": "com.amazonaws.transfer#UpdateConnector" }, + { + "target": "com.amazonaws.transfer#UpdateHostKey" + }, { "target": "com.amazonaws.transfer#UpdateProfile" }, @@ -6667,6 +7072,80 @@ } } }, + "com.amazonaws.transfer#UpdateHostKey": { + "type": "operation", + "input": { + "target": "com.amazonaws.transfer#UpdateHostKeyRequest" + }, + "output": { + "target": "com.amazonaws.transfer#UpdateHostKeyResponse" + }, + "errors": [ + { + "target": "com.amazonaws.transfer#InternalServiceError" + }, + { + "target": "com.amazonaws.transfer#InvalidRequestException" + }, + { + "target": "com.amazonaws.transfer#ResourceNotFoundException" + }, + { + "target": "com.amazonaws.transfer#ServiceUnavailableException" + }, + { + "target": "com.amazonaws.transfer#ThrottlingException" + } + ], + "traits": { + "smithy.api#documentation": "

Updates the description for the host key specified by the specified by the ServerId and HostKeyId parameters.

" + } + }, + "com.amazonaws.transfer#UpdateHostKeyRequest": { + "type": "structure", + "members": { + "ServerId": { + "target": "com.amazonaws.transfer#ServerId", + "traits": { + "smithy.api#documentation": "

Provide the ID of the server that contains the host key that you are updating.

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

Provide the ID of the host key that you are updating.

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

Provide an updated description for the host key.

", + "smithy.api#required": {} + } + } + } + }, + "com.amazonaws.transfer#UpdateHostKeyResponse": { + "type": "structure", + "members": { + "ServerId": { + "target": "com.amazonaws.transfer#ServerId", + "traits": { + "smithy.api#documentation": "

Returns the server ID for the server that contains the updated host key.

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

Returns the host key ID for the updated host key.

", + "smithy.api#required": {} + } + } + } + }, "com.amazonaws.transfer#UpdateProfile": { "type": "operation", "input": { diff --git a/internal/repotools/cmd/syncAPIModels/main.go b/internal/repotools/cmd/syncAPIModels/main.go index b6bcd2c4c42..af17e8e5916 100644 --- a/internal/repotools/cmd/syncAPIModels/main.go +++ b/internal/repotools/cmd/syncAPIModels/main.go @@ -97,7 +97,7 @@ func findSmithyModels(modelPath string) (map[string]SourceModel, error) { path, err) return err } - if !strings.HasPrefix(check.Smithy, "1.") { + if !strings.HasPrefix(check.Smithy, "1.") && !strings.HasPrefix(check.Smithy, "2.") { return nil } var shapes map[string]SmithyShape diff --git a/service/amplifyuibuilder/api_op_CreateForm.go b/service/amplifyuibuilder/api_op_CreateForm.go new file mode 100644 index 00000000000..a2b608955bc --- /dev/null +++ b/service/amplifyuibuilder/api_op_CreateForm.go @@ -0,0 +1,171 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package amplifyuibuilder + +import ( + "context" + "fmt" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/amplifyuibuilder/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Creates a new form for an Amplify app. +func (c *Client) CreateForm(ctx context.Context, params *CreateFormInput, optFns ...func(*Options)) (*CreateFormOutput, error) { + if params == nil { + params = &CreateFormInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "CreateForm", params, optFns, c.addOperationCreateFormMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*CreateFormOutput) + out.ResultMetadata = metadata + return out, nil +} + +type CreateFormInput struct { + + // The unique ID of the Amplify app to associate with the form. + // + // This member is required. + AppId *string + + // The name of the backend environment that is a part of the Amplify app. + // + // This member is required. + EnvironmentName *string + + // Represents the configuration of the form to create. + // + // This member is required. + FormToCreate *types.CreateFormData + + // The unique client token. + ClientToken *string + + noSmithyDocumentSerde +} + +type CreateFormOutput struct { + + // Describes the configuration of the new form. + Entity *types.Form + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationCreateFormMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpCreateForm{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpCreateForm{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addIdempotencyToken_opCreateFormMiddleware(stack, options); err != nil { + return err + } + if err = addOpCreateFormValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreateForm(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +type idempotencyToken_initializeOpCreateForm struct { + tokenProvider IdempotencyTokenProvider +} + +func (*idempotencyToken_initializeOpCreateForm) ID() string { + return "OperationIdempotencyTokenAutoFill" +} + +func (m *idempotencyToken_initializeOpCreateForm) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + if m.tokenProvider == nil { + return next.HandleInitialize(ctx, in) + } + + input, ok := in.Parameters.(*CreateFormInput) + if !ok { + return out, metadata, fmt.Errorf("expected middleware input to be of type *CreateFormInput ") + } + + if input.ClientToken == nil { + t, err := m.tokenProvider.GetIdempotencyToken() + if err != nil { + return out, metadata, err + } + input.ClientToken = &t + } + return next.HandleInitialize(ctx, in) +} +func addIdempotencyToken_opCreateFormMiddleware(stack *middleware.Stack, cfg Options) error { + return stack.Initialize.Add(&idempotencyToken_initializeOpCreateForm{tokenProvider: cfg.IdempotencyTokenProvider}, middleware.Before) +} + +func newServiceMetadataMiddleware_opCreateForm(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "amplifyuibuilder", + OperationName: "CreateForm", + } +} diff --git a/service/amplifyuibuilder/api_op_DeleteForm.go b/service/amplifyuibuilder/api_op_DeleteForm.go new file mode 100644 index 00000000000..5c96222195c --- /dev/null +++ b/service/amplifyuibuilder/api_op_DeleteForm.go @@ -0,0 +1,126 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package amplifyuibuilder + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Deletes a form from an Amplify app. +func (c *Client) DeleteForm(ctx context.Context, params *DeleteFormInput, optFns ...func(*Options)) (*DeleteFormOutput, error) { + if params == nil { + params = &DeleteFormInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DeleteForm", params, optFns, c.addOperationDeleteFormMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DeleteFormOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DeleteFormInput struct { + + // The unique ID of the Amplify app associated with the form to delete. + // + // This member is required. + AppId *string + + // The name of the backend environment that is a part of the Amplify app. + // + // This member is required. + EnvironmentName *string + + // The unique ID of the form to delete. + // + // This member is required. + Id *string + + noSmithyDocumentSerde +} + +type DeleteFormOutput struct { + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDeleteFormMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpDeleteForm{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpDeleteForm{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpDeleteFormValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteForm(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opDeleteForm(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "amplifyuibuilder", + OperationName: "DeleteForm", + } +} diff --git a/service/amplifyuibuilder/api_op_ExportForms.go b/service/amplifyuibuilder/api_op_ExportForms.go new file mode 100644 index 00000000000..96ba397d21f --- /dev/null +++ b/service/amplifyuibuilder/api_op_ExportForms.go @@ -0,0 +1,213 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package amplifyuibuilder + +import ( + "context" + "fmt" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/amplifyuibuilder/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Exports form configurations to code that is ready to integrate into an Amplify +// app. +func (c *Client) ExportForms(ctx context.Context, params *ExportFormsInput, optFns ...func(*Options)) (*ExportFormsOutput, error) { + if params == nil { + params = &ExportFormsInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "ExportForms", params, optFns, c.addOperationExportFormsMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*ExportFormsOutput) + out.ResultMetadata = metadata + return out, nil +} + +type ExportFormsInput struct { + + // The unique ID of the Amplify app to export forms to. + // + // This member is required. + AppId *string + + // The name of the backend environment that is a part of the Amplify app. + // + // This member is required. + EnvironmentName *string + + // The token to request the next page of results. + NextToken *string + + noSmithyDocumentSerde +} + +type ExportFormsOutput struct { + + // Represents the configuration of the exported forms. + // + // This member is required. + Entities []types.Form + + // The pagination token that's included if more results are available. + NextToken *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationExportFormsMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpExportForms{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpExportForms{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpExportFormsValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opExportForms(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +// ExportFormsAPIClient is a client that implements the ExportForms operation. +type ExportFormsAPIClient interface { + ExportForms(context.Context, *ExportFormsInput, ...func(*Options)) (*ExportFormsOutput, error) +} + +var _ ExportFormsAPIClient = (*Client)(nil) + +// ExportFormsPaginatorOptions is the paginator options for ExportForms +type ExportFormsPaginatorOptions struct { + // Set to true if pagination should stop if the service returns a pagination token + // that matches the most recent token provided to the service. + StopOnDuplicateToken bool +} + +// ExportFormsPaginator is a paginator for ExportForms +type ExportFormsPaginator struct { + options ExportFormsPaginatorOptions + client ExportFormsAPIClient + params *ExportFormsInput + nextToken *string + firstPage bool +} + +// NewExportFormsPaginator returns a new ExportFormsPaginator +func NewExportFormsPaginator(client ExportFormsAPIClient, params *ExportFormsInput, optFns ...func(*ExportFormsPaginatorOptions)) *ExportFormsPaginator { + if params == nil { + params = &ExportFormsInput{} + } + + options := ExportFormsPaginatorOptions{} + + for _, fn := range optFns { + fn(&options) + } + + return &ExportFormsPaginator{ + options: options, + client: client, + params: params, + firstPage: true, + nextToken: params.NextToken, + } +} + +// HasMorePages returns a boolean indicating whether more pages are available +func (p *ExportFormsPaginator) HasMorePages() bool { + return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0) +} + +// NextPage retrieves the next ExportForms page. +func (p *ExportFormsPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ExportFormsOutput, error) { + if !p.HasMorePages() { + return nil, fmt.Errorf("no more pages available") + } + + params := *p.params + params.NextToken = p.nextToken + + result, err := p.client.ExportForms(ctx, ¶ms, optFns...) + if err != nil { + return nil, err + } + p.firstPage = false + + prevToken := p.nextToken + p.nextToken = result.NextToken + + if p.options.StopOnDuplicateToken && + prevToken != nil && + p.nextToken != nil && + *prevToken == *p.nextToken { + p.nextToken = nil + } + + return result, nil +} + +func newServiceMetadataMiddleware_opExportForms(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "amplifyuibuilder", + OperationName: "ExportForms", + } +} diff --git a/service/amplifyuibuilder/api_op_GetForm.go b/service/amplifyuibuilder/api_op_GetForm.go new file mode 100644 index 00000000000..a2b59910f91 --- /dev/null +++ b/service/amplifyuibuilder/api_op_GetForm.go @@ -0,0 +1,131 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package amplifyuibuilder + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/amplifyuibuilder/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Returns an existing form for an Amplify app. +func (c *Client) GetForm(ctx context.Context, params *GetFormInput, optFns ...func(*Options)) (*GetFormOutput, error) { + if params == nil { + params = &GetFormInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "GetForm", params, optFns, c.addOperationGetFormMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*GetFormOutput) + out.ResultMetadata = metadata + return out, nil +} + +type GetFormInput struct { + + // The unique ID of the Amplify app. + // + // This member is required. + AppId *string + + // The name of the backend environment that is part of the Amplify app. + // + // This member is required. + EnvironmentName *string + + // The unique ID of the form. + // + // This member is required. + Id *string + + noSmithyDocumentSerde +} + +type GetFormOutput struct { + + // Represents the configuration settings for the form. + Form *types.Form + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationGetFormMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpGetForm{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpGetForm{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpGetFormValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetForm(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opGetForm(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "amplifyuibuilder", + OperationName: "GetForm", + } +} diff --git a/service/amplifyuibuilder/api_op_GetMetadata.go b/service/amplifyuibuilder/api_op_GetMetadata.go new file mode 100644 index 00000000000..9ec25ab4771 --- /dev/null +++ b/service/amplifyuibuilder/api_op_GetMetadata.go @@ -0,0 +1,127 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package amplifyuibuilder + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Returns existing metadata for an Amplify app. +func (c *Client) GetMetadata(ctx context.Context, params *GetMetadataInput, optFns ...func(*Options)) (*GetMetadataOutput, error) { + if params == nil { + params = &GetMetadataInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "GetMetadata", params, optFns, c.addOperationGetMetadataMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*GetMetadataOutput) + out.ResultMetadata = metadata + return out, nil +} + +type GetMetadataInput struct { + + // The unique ID of the Amplify app. + // + // This member is required. + AppId *string + + // The name of the backend environment that is part of the Amplify app. + // + // This member is required. + EnvironmentName *string + + noSmithyDocumentSerde +} + +type GetMetadataOutput struct { + + // Represents the configuration settings for the features metadata. + // + // This member is required. + Features map[string]string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationGetMetadataMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpGetMetadata{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpGetMetadata{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpGetMetadataValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetMetadata(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opGetMetadata(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "amplifyuibuilder", + OperationName: "GetMetadata", + } +} diff --git a/service/amplifyuibuilder/api_op_ListForms.go b/service/amplifyuibuilder/api_op_ListForms.go new file mode 100644 index 00000000000..dae63a398e0 --- /dev/null +++ b/service/amplifyuibuilder/api_op_ListForms.go @@ -0,0 +1,223 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package amplifyuibuilder + +import ( + "context" + "fmt" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/amplifyuibuilder/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Retrieves a list of forms for a specified Amplify app and backend environment. +func (c *Client) ListForms(ctx context.Context, params *ListFormsInput, optFns ...func(*Options)) (*ListFormsOutput, error) { + if params == nil { + params = &ListFormsInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "ListForms", params, optFns, c.addOperationListFormsMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*ListFormsOutput) + out.ResultMetadata = metadata + return out, nil +} + +type ListFormsInput struct { + + // The unique ID for the Amplify app. + // + // This member is required. + AppId *string + + // The name of the backend environment that is a part of the Amplify app. + // + // This member is required. + EnvironmentName *string + + // The maximum number of forms to retrieve. + MaxResults int32 + + // The token to request the next page of results. + NextToken *string + + noSmithyDocumentSerde +} + +type ListFormsOutput struct { + + // The list of forms for the Amplify app. + // + // This member is required. + Entities []types.FormSummary + + // The pagination token that's included if more results are available. + NextToken *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationListFormsMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpListForms{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpListForms{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpListFormsValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opListForms(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +// ListFormsAPIClient is a client that implements the ListForms operation. +type ListFormsAPIClient interface { + ListForms(context.Context, *ListFormsInput, ...func(*Options)) (*ListFormsOutput, error) +} + +var _ ListFormsAPIClient = (*Client)(nil) + +// ListFormsPaginatorOptions is the paginator options for ListForms +type ListFormsPaginatorOptions struct { + // The maximum number of forms to retrieve. + Limit int32 + + // Set to true if pagination should stop if the service returns a pagination token + // that matches the most recent token provided to the service. + StopOnDuplicateToken bool +} + +// ListFormsPaginator is a paginator for ListForms +type ListFormsPaginator struct { + options ListFormsPaginatorOptions + client ListFormsAPIClient + params *ListFormsInput + nextToken *string + firstPage bool +} + +// NewListFormsPaginator returns a new ListFormsPaginator +func NewListFormsPaginator(client ListFormsAPIClient, params *ListFormsInput, optFns ...func(*ListFormsPaginatorOptions)) *ListFormsPaginator { + if params == nil { + params = &ListFormsInput{} + } + + options := ListFormsPaginatorOptions{} + if params.MaxResults != 0 { + options.Limit = params.MaxResults + } + + for _, fn := range optFns { + fn(&options) + } + + return &ListFormsPaginator{ + options: options, + client: client, + params: params, + firstPage: true, + nextToken: params.NextToken, + } +} + +// HasMorePages returns a boolean indicating whether more pages are available +func (p *ListFormsPaginator) HasMorePages() bool { + return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0) +} + +// NextPage retrieves the next ListForms page. +func (p *ListFormsPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ListFormsOutput, error) { + if !p.HasMorePages() { + return nil, fmt.Errorf("no more pages available") + } + + params := *p.params + params.NextToken = p.nextToken + + params.MaxResults = p.options.Limit + + result, err := p.client.ListForms(ctx, ¶ms, optFns...) + if err != nil { + return nil, err + } + p.firstPage = false + + prevToken := p.nextToken + p.nextToken = result.NextToken + + if p.options.StopOnDuplicateToken && + prevToken != nil && + p.nextToken != nil && + *prevToken == *p.nextToken { + p.nextToken = nil + } + + return result, nil +} + +func newServiceMetadataMiddleware_opListForms(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "amplifyuibuilder", + OperationName: "ListForms", + } +} diff --git a/service/amplifyuibuilder/api_op_PutMetadataFlag.go b/service/amplifyuibuilder/api_op_PutMetadataFlag.go new file mode 100644 index 00000000000..67045379cae --- /dev/null +++ b/service/amplifyuibuilder/api_op_PutMetadataFlag.go @@ -0,0 +1,132 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package amplifyuibuilder + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/amplifyuibuilder/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Stores the metadata information about a feature on a form or view. +func (c *Client) PutMetadataFlag(ctx context.Context, params *PutMetadataFlagInput, optFns ...func(*Options)) (*PutMetadataFlagOutput, error) { + if params == nil { + params = &PutMetadataFlagInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "PutMetadataFlag", params, optFns, c.addOperationPutMetadataFlagMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*PutMetadataFlagOutput) + out.ResultMetadata = metadata + return out, nil +} + +type PutMetadataFlagInput struct { + + // The unique ID for the Amplify app. + // + // This member is required. + AppId *string + + // The metadata information to store. + // + // This member is required. + Body *types.PutMetadataFlagBody + + // The name of the backend environment that is part of the Amplify app. + // + // This member is required. + EnvironmentName *string + + // The name of the feature associated with the metadata. + // + // This member is required. + FeatureName *string + + noSmithyDocumentSerde +} + +type PutMetadataFlagOutput struct { + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationPutMetadataFlagMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpPutMetadataFlag{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpPutMetadataFlag{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpPutMetadataFlagValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutMetadataFlag(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opPutMetadataFlag(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "amplifyuibuilder", + OperationName: "PutMetadataFlag", + } +} diff --git a/service/amplifyuibuilder/api_op_UpdateForm.go b/service/amplifyuibuilder/api_op_UpdateForm.go new file mode 100644 index 00000000000..82fade80713 --- /dev/null +++ b/service/amplifyuibuilder/api_op_UpdateForm.go @@ -0,0 +1,176 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package amplifyuibuilder + +import ( + "context" + "fmt" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/amplifyuibuilder/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Updates an existing form. +func (c *Client) UpdateForm(ctx context.Context, params *UpdateFormInput, optFns ...func(*Options)) (*UpdateFormOutput, error) { + if params == nil { + params = &UpdateFormInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "UpdateForm", params, optFns, c.addOperationUpdateFormMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*UpdateFormOutput) + out.ResultMetadata = metadata + return out, nil +} + +type UpdateFormInput struct { + + // The unique ID for the Amplify app. + // + // This member is required. + AppId *string + + // The name of the backend environment that is part of the Amplify app. + // + // This member is required. + EnvironmentName *string + + // The unique ID for the form. + // + // This member is required. + Id *string + + // The request accepts the following data in JSON format. + // + // This member is required. + UpdatedForm *types.UpdateFormData + + // The unique client token. + ClientToken *string + + noSmithyDocumentSerde +} + +type UpdateFormOutput struct { + + // Describes the configuration of the updated form. + Entity *types.Form + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationUpdateFormMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpUpdateForm{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpUpdateForm{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addIdempotencyToken_opUpdateFormMiddleware(stack, options); err != nil { + return err + } + if err = addOpUpdateFormValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opUpdateForm(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +type idempotencyToken_initializeOpUpdateForm struct { + tokenProvider IdempotencyTokenProvider +} + +func (*idempotencyToken_initializeOpUpdateForm) ID() string { + return "OperationIdempotencyTokenAutoFill" +} + +func (m *idempotencyToken_initializeOpUpdateForm) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + if m.tokenProvider == nil { + return next.HandleInitialize(ctx, in) + } + + input, ok := in.Parameters.(*UpdateFormInput) + if !ok { + return out, metadata, fmt.Errorf("expected middleware input to be of type *UpdateFormInput ") + } + + if input.ClientToken == nil { + t, err := m.tokenProvider.GetIdempotencyToken() + if err != nil { + return out, metadata, err + } + input.ClientToken = &t + } + return next.HandleInitialize(ctx, in) +} +func addIdempotencyToken_opUpdateFormMiddleware(stack *middleware.Stack, cfg Options) error { + return stack.Initialize.Add(&idempotencyToken_initializeOpUpdateForm{tokenProvider: cfg.IdempotencyTokenProvider}, middleware.Before) +} + +func newServiceMetadataMiddleware_opUpdateForm(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "amplifyuibuilder", + OperationName: "UpdateForm", + } +} diff --git a/service/amplifyuibuilder/deserializers.go b/service/amplifyuibuilder/deserializers.go index 39a09610d51..2a42766d4db 100644 --- a/service/amplifyuibuilder/deserializers.go +++ b/service/amplifyuibuilder/deserializers.go @@ -17,6 +17,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" "io" "io/ioutil" + "math" "strings" ) @@ -176,6 +177,162 @@ func awsRestjson1_deserializeOpDocumentCreateComponentOutput(v **CreateComponent return nil } +type awsRestjson1_deserializeOpCreateForm struct { +} + +func (*awsRestjson1_deserializeOpCreateForm) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpCreateForm) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsRestjson1_deserializeOpErrorCreateForm(response, &metadata) + } + output := &CreateFormOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsRestjson1_deserializeDocumentForm(&output.Entity, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body with invalid JSON, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + return out, metadata, err +} + +func awsRestjson1_deserializeOpErrorCreateForm(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("InvalidParameterException", errorCode): + return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + + case strings.EqualFold("ResourceConflictException", errorCode): + return awsRestjson1_deserializeErrorResourceConflictException(response, errorBody) + + case strings.EqualFold("ServiceQuotaExceededException", errorCode): + return awsRestjson1_deserializeErrorServiceQuotaExceededException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +func awsRestjson1_deserializeOpDocumentCreateFormOutput(v **CreateFormOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *CreateFormOutput + if *v == nil { + sv = &CreateFormOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "entity": + if err := awsRestjson1_deserializeDocumentForm(&sv.Entity, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + type awsRestjson1_deserializeOpCreateTheme struct { } @@ -427,6 +584,101 @@ func awsRestjson1_deserializeOpErrorDeleteComponent(response *smithyhttp.Respons } } +type awsRestjson1_deserializeOpDeleteForm struct { +} + +func (*awsRestjson1_deserializeOpDeleteForm) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpDeleteForm) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsRestjson1_deserializeOpErrorDeleteForm(response, &metadata) + } + output := &DeleteFormOutput{} + out.Result = output + + if _, err = io.Copy(ioutil.Discard, response.Body); err != nil { + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to discard response body, %w", err), + } + } + + return out, metadata, err +} + +func awsRestjson1_deserializeOpErrorDeleteForm(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("InvalidParameterException", errorCode): + return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + type awsRestjson1_deserializeOpDeleteTheme struct { } @@ -854,14 +1106,14 @@ func awsRestjson1_deserializeOpDocumentExportComponentsOutput(v **ExportComponen return nil } -type awsRestjson1_deserializeOpExportThemes struct { +type awsRestjson1_deserializeOpExportForms struct { } -func (*awsRestjson1_deserializeOpExportThemes) ID() string { +func (*awsRestjson1_deserializeOpExportForms) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpExportThemes) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpExportForms) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -875,9 +1127,9 @@ func (m *awsRestjson1_deserializeOpExportThemes) HandleDeserialize(ctx context.C } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorExportThemes(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorExportForms(response, &metadata) } - output := &ExportThemesOutput{} + output := &ExportFormsOutput{} out.Result = output var buff [1024]byte @@ -898,7 +1150,7 @@ func (m *awsRestjson1_deserializeOpExportThemes) HandleDeserialize(ctx context.C return out, metadata, err } - err = awsRestjson1_deserializeOpDocumentExportThemesOutput(&output, shape) + err = awsRestjson1_deserializeOpDocumentExportFormsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -911,7 +1163,7 @@ func (m *awsRestjson1_deserializeOpExportThemes) HandleDeserialize(ctx context.C return out, metadata, err } -func awsRestjson1_deserializeOpErrorExportThemes(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorExportForms(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -968,7 +1220,7 @@ func awsRestjson1_deserializeOpErrorExportThemes(response *smithyhttp.Response, } } -func awsRestjson1_deserializeOpDocumentExportThemesOutput(v **ExportThemesOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentExportFormsOutput(v **ExportFormsOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -981,9 +1233,9 @@ func awsRestjson1_deserializeOpDocumentExportThemesOutput(v **ExportThemesOutput return fmt.Errorf("unexpected JSON type %v", value) } - var sv *ExportThemesOutput + var sv *ExportFormsOutput if *v == nil { - sv = &ExportThemesOutput{} + sv = &ExportFormsOutput{} } else { sv = *v } @@ -991,7 +1243,7 @@ func awsRestjson1_deserializeOpDocumentExportThemesOutput(v **ExportThemesOutput for key, value := range shape { switch key { case "entities": - if err := awsRestjson1_deserializeDocumentThemeList(&sv.Entities, value); err != nil { + if err := awsRestjson1_deserializeDocumentFormList(&sv.Entities, value); err != nil { return err } @@ -1013,14 +1265,14 @@ func awsRestjson1_deserializeOpDocumentExportThemesOutput(v **ExportThemesOutput return nil } -type awsRestjson1_deserializeOpGetComponent struct { +type awsRestjson1_deserializeOpExportThemes struct { } -func (*awsRestjson1_deserializeOpGetComponent) ID() string { +func (*awsRestjson1_deserializeOpExportThemes) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpGetComponent) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpExportThemes) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -1034,9 +1286,9 @@ func (m *awsRestjson1_deserializeOpGetComponent) HandleDeserialize(ctx context.C } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorGetComponent(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorExportThemes(response, &metadata) } - output := &GetComponentOutput{} + output := &ExportThemesOutput{} out.Result = output var buff [1024]byte @@ -1057,7 +1309,7 @@ func (m *awsRestjson1_deserializeOpGetComponent) HandleDeserialize(ctx context.C return out, metadata, err } - err = awsRestjson1_deserializeDocumentComponent(&output.Component, shape) + err = awsRestjson1_deserializeOpDocumentExportThemesOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1070,7 +1322,7 @@ func (m *awsRestjson1_deserializeOpGetComponent) HandleDeserialize(ctx context.C return out, metadata, err } -func awsRestjson1_deserializeOpErrorGetComponent(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorExportThemes(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -1117,9 +1369,6 @@ func awsRestjson1_deserializeOpErrorGetComponent(response *smithyhttp.Response, case strings.EqualFold("InvalidParameterException", errorCode): return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): - return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) - default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -1130,7 +1379,7 @@ func awsRestjson1_deserializeOpErrorGetComponent(response *smithyhttp.Response, } } -func awsRestjson1_deserializeOpDocumentGetComponentOutput(v **GetComponentOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentExportThemesOutput(v **ExportThemesOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -1143,20 +1392,29 @@ func awsRestjson1_deserializeOpDocumentGetComponentOutput(v **GetComponentOutput return fmt.Errorf("unexpected JSON type %v", value) } - var sv *GetComponentOutput + var sv *ExportThemesOutput if *v == nil { - sv = &GetComponentOutput{} + sv = &ExportThemesOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "component": - if err := awsRestjson1_deserializeDocumentComponent(&sv.Component, value); err != nil { + case "entities": + if err := awsRestjson1_deserializeDocumentThemeList(&sv.Entities, value); err != nil { return err } + case "nextToken": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.NextToken = ptr.String(jtv) + } + default: _, _ = key, value @@ -1166,14 +1424,14 @@ func awsRestjson1_deserializeOpDocumentGetComponentOutput(v **GetComponentOutput return nil } -type awsRestjson1_deserializeOpGetTheme struct { +type awsRestjson1_deserializeOpGetComponent struct { } -func (*awsRestjson1_deserializeOpGetTheme) ID() string { +func (*awsRestjson1_deserializeOpGetComponent) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpGetTheme) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpGetComponent) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -1187,9 +1445,9 @@ func (m *awsRestjson1_deserializeOpGetTheme) HandleDeserialize(ctx context.Conte } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorGetTheme(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorGetComponent(response, &metadata) } - output := &GetThemeOutput{} + output := &GetComponentOutput{} out.Result = output var buff [1024]byte @@ -1210,7 +1468,7 @@ func (m *awsRestjson1_deserializeOpGetTheme) HandleDeserialize(ctx context.Conte return out, metadata, err } - err = awsRestjson1_deserializeDocumentTheme(&output.Theme, shape) + err = awsRestjson1_deserializeDocumentComponent(&output.Component, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1223,7 +1481,7 @@ func (m *awsRestjson1_deserializeOpGetTheme) HandleDeserialize(ctx context.Conte return out, metadata, err } -func awsRestjson1_deserializeOpErrorGetTheme(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorGetComponent(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -1283,7 +1541,7 @@ func awsRestjson1_deserializeOpErrorGetTheme(response *smithyhttp.Response, meta } } -func awsRestjson1_deserializeOpDocumentGetThemeOutput(v **GetThemeOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentGetComponentOutput(v **GetComponentOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -1296,17 +1554,17 @@ func awsRestjson1_deserializeOpDocumentGetThemeOutput(v **GetThemeOutput, value return fmt.Errorf("unexpected JSON type %v", value) } - var sv *GetThemeOutput + var sv *GetComponentOutput if *v == nil { - sv = &GetThemeOutput{} + sv = &GetComponentOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "theme": - if err := awsRestjson1_deserializeDocumentTheme(&sv.Theme, value); err != nil { + case "component": + if err := awsRestjson1_deserializeDocumentComponent(&sv.Component, value); err != nil { return err } @@ -1319,14 +1577,14 @@ func awsRestjson1_deserializeOpDocumentGetThemeOutput(v **GetThemeOutput, value return nil } -type awsRestjson1_deserializeOpListComponents struct { +type awsRestjson1_deserializeOpGetForm struct { } -func (*awsRestjson1_deserializeOpListComponents) ID() string { +func (*awsRestjson1_deserializeOpGetForm) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpListComponents) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpGetForm) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -1340,9 +1598,9 @@ func (m *awsRestjson1_deserializeOpListComponents) HandleDeserialize(ctx context } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorListComponents(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorGetForm(response, &metadata) } - output := &ListComponentsOutput{} + output := &GetFormOutput{} out.Result = output var buff [1024]byte @@ -1363,7 +1621,7 @@ func (m *awsRestjson1_deserializeOpListComponents) HandleDeserialize(ctx context return out, metadata, err } - err = awsRestjson1_deserializeOpDocumentListComponentsOutput(&output, shape) + err = awsRestjson1_deserializeDocumentForm(&output.Form, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1376,7 +1634,7 @@ func (m *awsRestjson1_deserializeOpListComponents) HandleDeserialize(ctx context return out, metadata, err } -func awsRestjson1_deserializeOpErrorListComponents(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorGetForm(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -1423,6 +1681,9 @@ func awsRestjson1_deserializeOpErrorListComponents(response *smithyhttp.Response case strings.EqualFold("InvalidParameterException", errorCode): return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) + default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -1433,7 +1694,7 @@ func awsRestjson1_deserializeOpErrorListComponents(response *smithyhttp.Response } } -func awsRestjson1_deserializeOpDocumentListComponentsOutput(v **ListComponentsOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentGetFormOutput(v **GetFormOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -1446,29 +1707,20 @@ func awsRestjson1_deserializeOpDocumentListComponentsOutput(v **ListComponentsOu return fmt.Errorf("unexpected JSON type %v", value) } - var sv *ListComponentsOutput + var sv *GetFormOutput if *v == nil { - sv = &ListComponentsOutput{} + sv = &GetFormOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "entities": - if err := awsRestjson1_deserializeDocumentComponentSummaryList(&sv.Entities, value); err != nil { + case "form": + if err := awsRestjson1_deserializeDocumentForm(&sv.Form, value); err != nil { return err } - case "nextToken": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.NextToken = ptr.String(jtv) - } - default: _, _ = key, value @@ -1478,14 +1730,14 @@ func awsRestjson1_deserializeOpDocumentListComponentsOutput(v **ListComponentsOu return nil } -type awsRestjson1_deserializeOpListThemes struct { +type awsRestjson1_deserializeOpGetMetadata struct { } -func (*awsRestjson1_deserializeOpListThemes) ID() string { +func (*awsRestjson1_deserializeOpGetMetadata) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpListThemes) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpGetMetadata) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -1499,9 +1751,9 @@ func (m *awsRestjson1_deserializeOpListThemes) HandleDeserialize(ctx context.Con } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorListThemes(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorGetMetadata(response, &metadata) } - output := &ListThemesOutput{} + output := &GetMetadataOutput{} out.Result = output var buff [1024]byte @@ -1522,7 +1774,7 @@ func (m *awsRestjson1_deserializeOpListThemes) HandleDeserialize(ctx context.Con return out, metadata, err } - err = awsRestjson1_deserializeOpDocumentListThemesOutput(&output, shape) + err = awsRestjson1_deserializeOpDocumentGetMetadataOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1535,7 +1787,7 @@ func (m *awsRestjson1_deserializeOpListThemes) HandleDeserialize(ctx context.Con return out, metadata, err } -func awsRestjson1_deserializeOpErrorListThemes(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorGetMetadata(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -1576,12 +1828,12 @@ func awsRestjson1_deserializeOpErrorListThemes(response *smithyhttp.Response, me } switch { - case strings.EqualFold("InternalServerException", errorCode): - return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) - case strings.EqualFold("InvalidParameterException", errorCode): return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + case strings.EqualFold("UnauthorizedException", errorCode): + return awsRestjson1_deserializeErrorUnauthorizedException(response, errorBody) + default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -1592,7 +1844,7 @@ func awsRestjson1_deserializeOpErrorListThemes(response *smithyhttp.Response, me } } -func awsRestjson1_deserializeOpDocumentListThemesOutput(v **ListThemesOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentGetMetadataOutput(v **GetMetadataOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -1605,29 +1857,20 @@ func awsRestjson1_deserializeOpDocumentListThemesOutput(v **ListThemesOutput, va return fmt.Errorf("unexpected JSON type %v", value) } - var sv *ListThemesOutput + var sv *GetMetadataOutput if *v == nil { - sv = &ListThemesOutput{} + sv = &GetMetadataOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "entities": - if err := awsRestjson1_deserializeDocumentThemeSummaryList(&sv.Entities, value); err != nil { + case "features": + if err := awsRestjson1_deserializeDocumentFeaturesMap(&sv.Features, value); err != nil { return err } - case "nextToken": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.NextToken = ptr.String(jtv) - } - default: _, _ = key, value @@ -1637,14 +1880,14 @@ func awsRestjson1_deserializeOpDocumentListThemesOutput(v **ListThemesOutput, va return nil } -type awsRestjson1_deserializeOpRefreshToken struct { +type awsRestjson1_deserializeOpGetTheme struct { } -func (*awsRestjson1_deserializeOpRefreshToken) ID() string { +func (*awsRestjson1_deserializeOpGetTheme) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpRefreshToken) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpGetTheme) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -1658,9 +1901,9 @@ func (m *awsRestjson1_deserializeOpRefreshToken) HandleDeserialize(ctx context.C } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorRefreshToken(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorGetTheme(response, &metadata) } - output := &RefreshTokenOutput{} + output := &GetThemeOutput{} out.Result = output var buff [1024]byte @@ -1681,7 +1924,7 @@ func (m *awsRestjson1_deserializeOpRefreshToken) HandleDeserialize(ctx context.C return out, metadata, err } - err = awsRestjson1_deserializeOpDocumentRefreshTokenOutput(&output, shape) + err = awsRestjson1_deserializeDocumentTheme(&output.Theme, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1694,7 +1937,7 @@ func (m *awsRestjson1_deserializeOpRefreshToken) HandleDeserialize(ctx context.C return out, metadata, err } -func awsRestjson1_deserializeOpErrorRefreshToken(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorGetTheme(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -1735,9 +1978,15 @@ func awsRestjson1_deserializeOpErrorRefreshToken(response *smithyhttp.Response, } switch { + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + case strings.EqualFold("InvalidParameterException", errorCode): return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) + default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -1748,7 +1997,7 @@ func awsRestjson1_deserializeOpErrorRefreshToken(response *smithyhttp.Response, } } -func awsRestjson1_deserializeOpDocumentRefreshTokenOutput(v **RefreshTokenOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentGetThemeOutput(v **GetThemeOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -1761,35 +2010,18 @@ func awsRestjson1_deserializeOpDocumentRefreshTokenOutput(v **RefreshTokenOutput return fmt.Errorf("unexpected JSON type %v", value) } - var sv *RefreshTokenOutput + var sv *GetThemeOutput if *v == nil { - sv = &RefreshTokenOutput{} + sv = &GetThemeOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "accessToken": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected SensitiveString to be of type string, got %T instead", value) - } - sv.AccessToken = ptr.String(jtv) - } - - case "expiresIn": - if value != nil { - jtv, ok := value.(json.Number) - if !ok { - return fmt.Errorf("expected Integer to be json.Number, got %T instead", value) - } - i64, err := jtv.Int64() - if err != nil { - return err - } - sv.ExpiresIn = ptr.Int32(int32(i64)) + case "theme": + if err := awsRestjson1_deserializeDocumentTheme(&sv.Theme, value); err != nil { + return err } default: @@ -1801,14 +2033,14 @@ func awsRestjson1_deserializeOpDocumentRefreshTokenOutput(v **RefreshTokenOutput return nil } -type awsRestjson1_deserializeOpUpdateComponent struct { +type awsRestjson1_deserializeOpListComponents struct { } -func (*awsRestjson1_deserializeOpUpdateComponent) ID() string { +func (*awsRestjson1_deserializeOpListComponents) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpUpdateComponent) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpListComponents) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -1822,9 +2054,9 @@ func (m *awsRestjson1_deserializeOpUpdateComponent) HandleDeserialize(ctx contex } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorUpdateComponent(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorListComponents(response, &metadata) } - output := &UpdateComponentOutput{} + output := &ListComponentsOutput{} out.Result = output var buff [1024]byte @@ -1845,7 +2077,7 @@ func (m *awsRestjson1_deserializeOpUpdateComponent) HandleDeserialize(ctx contex return out, metadata, err } - err = awsRestjson1_deserializeDocumentComponent(&output.Entity, shape) + err = awsRestjson1_deserializeOpDocumentListComponentsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1858,7 +2090,7 @@ func (m *awsRestjson1_deserializeOpUpdateComponent) HandleDeserialize(ctx contex return out, metadata, err } -func awsRestjson1_deserializeOpErrorUpdateComponent(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorListComponents(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -1905,9 +2137,6 @@ func awsRestjson1_deserializeOpErrorUpdateComponent(response *smithyhttp.Respons case strings.EqualFold("InvalidParameterException", errorCode): return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) - case strings.EqualFold("ResourceConflictException", errorCode): - return awsRestjson1_deserializeErrorResourceConflictException(response, errorBody) - default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -1918,7 +2147,7 @@ func awsRestjson1_deserializeOpErrorUpdateComponent(response *smithyhttp.Respons } } -func awsRestjson1_deserializeOpDocumentUpdateComponentOutput(v **UpdateComponentOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentListComponentsOutput(v **ListComponentsOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -1931,20 +2160,29 @@ func awsRestjson1_deserializeOpDocumentUpdateComponentOutput(v **UpdateComponent return fmt.Errorf("unexpected JSON type %v", value) } - var sv *UpdateComponentOutput + var sv *ListComponentsOutput if *v == nil { - sv = &UpdateComponentOutput{} + sv = &ListComponentsOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "entity": - if err := awsRestjson1_deserializeDocumentComponent(&sv.Entity, value); err != nil { + case "entities": + if err := awsRestjson1_deserializeDocumentComponentSummaryList(&sv.Entities, value); err != nil { return err } + case "nextToken": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.NextToken = ptr.String(jtv) + } + default: _, _ = key, value @@ -1954,14 +2192,14 @@ func awsRestjson1_deserializeOpDocumentUpdateComponentOutput(v **UpdateComponent return nil } -type awsRestjson1_deserializeOpUpdateTheme struct { +type awsRestjson1_deserializeOpListForms struct { } -func (*awsRestjson1_deserializeOpUpdateTheme) ID() string { +func (*awsRestjson1_deserializeOpListForms) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpUpdateTheme) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpListForms) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -1975,9 +2213,9 @@ func (m *awsRestjson1_deserializeOpUpdateTheme) HandleDeserialize(ctx context.Co } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorUpdateTheme(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorListForms(response, &metadata) } - output := &UpdateThemeOutput{} + output := &ListFormsOutput{} out.Result = output var buff [1024]byte @@ -1998,7 +2236,7 @@ func (m *awsRestjson1_deserializeOpUpdateTheme) HandleDeserialize(ctx context.Co return out, metadata, err } - err = awsRestjson1_deserializeDocumentTheme(&output.Entity, shape) + err = awsRestjson1_deserializeOpDocumentListFormsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -2011,7 +2249,7 @@ func (m *awsRestjson1_deserializeOpUpdateTheme) HandleDeserialize(ctx context.Co return out, metadata, err } -func awsRestjson1_deserializeOpErrorUpdateTheme(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorListForms(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -2058,9 +2296,6 @@ func awsRestjson1_deserializeOpErrorUpdateTheme(response *smithyhttp.Response, m case strings.EqualFold("InvalidParameterException", errorCode): return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) - case strings.EqualFold("ResourceConflictException", errorCode): - return awsRestjson1_deserializeErrorResourceConflictException(response, errorBody) - default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -2071,7 +2306,7 @@ func awsRestjson1_deserializeOpErrorUpdateTheme(response *smithyhttp.Response, m } } -func awsRestjson1_deserializeOpDocumentUpdateThemeOutput(v **UpdateThemeOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentListFormsOutput(v **ListFormsOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -2084,20 +2319,29 @@ func awsRestjson1_deserializeOpDocumentUpdateThemeOutput(v **UpdateThemeOutput, return fmt.Errorf("unexpected JSON type %v", value) } - var sv *UpdateThemeOutput + var sv *ListFormsOutput if *v == nil { - sv = &UpdateThemeOutput{} + sv = &ListFormsOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "entity": - if err := awsRestjson1_deserializeDocumentTheme(&sv.Entity, value); err != nil { + case "entities": + if err := awsRestjson1_deserializeDocumentFormSummaryList(&sv.Entities, value); err != nil { return err } + case "nextToken": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.NextToken = ptr.String(jtv) + } + default: _, _ = key, value @@ -2107,12 +2351,37 @@ func awsRestjson1_deserializeOpDocumentUpdateThemeOutput(v **UpdateThemeOutput, return nil } -func awsRestjson1_deserializeErrorInternalServerException(response *smithyhttp.Response, errorBody *bytes.Reader) error { - output := &types.InternalServerException{} +type awsRestjson1_deserializeOpListThemes struct { +} + +func (*awsRestjson1_deserializeOpListThemes) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpListThemes) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsRestjson1_deserializeOpErrorListThemes(response, &metadata) + } + output := &ListThemesOutput{} + out.Result = output + var buff [1024]byte ringBuffer := smithyio.NewRingBuffer(buff[:]) - body := io.TeeReader(errorBody, ringBuffer) + body := io.TeeReader(response.Body, ringBuffer) + decoder := json.NewDecoder(body) decoder.UseNumber() var shape interface{} @@ -2123,36 +2392,45 @@ func awsRestjson1_deserializeErrorInternalServerException(response *smithyhttp.R Err: fmt.Errorf("failed to decode response body, %w", err), Snapshot: snapshot.Bytes(), } - return err + return out, metadata, err } - err := awsRestjson1_deserializeDocumentInternalServerException(&output, shape) - + err = awsRestjson1_deserializeOpDocumentListThemesOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) - err = &smithy.DeserializationError{ - Err: fmt.Errorf("failed to decode response body, %w", err), + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body with invalid JSON, %w", err), Snapshot: snapshot.Bytes(), } - return err } - errorBody.Seek(0, io.SeekStart) - - return output + return out, metadata, err } -func awsRestjson1_deserializeErrorInvalidParameterException(response *smithyhttp.Response, errorBody *bytes.Reader) error { - output := &types.InvalidParameterException{} - var buff [1024]byte +func awsRestjson1_deserializeOpErrorListThemes(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte ringBuffer := smithyio.NewRingBuffer(buff[:]) body := io.TeeReader(errorBody, ringBuffer) decoder := json.NewDecoder(body) decoder.UseNumber() - var shape interface{} - if err := decoder.Decode(&shape); err != nil && err != io.EOF { + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) err = &smithy.DeserializationError{ @@ -2162,33 +2440,134 @@ func awsRestjson1_deserializeErrorInvalidParameterException(response *smithyhttp return err } - err := awsRestjson1_deserializeDocumentInvalidParameterException(&output, shape) + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } - if err != nil { - var snapshot bytes.Buffer - io.Copy(&snapshot, ringBuffer) - err = &smithy.DeserializationError{ - Err: fmt.Errorf("failed to decode response body, %w", err), - Snapshot: snapshot.Bytes(), + switch { + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("InvalidParameterException", errorCode): + return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, } - return err + return genericError + } +} - errorBody.Seek(0, io.SeekStart) +func awsRestjson1_deserializeOpDocumentListThemesOutput(v **ListThemesOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } - return output + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *ListThemesOutput + if *v == nil { + sv = &ListThemesOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "entities": + if err := awsRestjson1_deserializeDocumentThemeSummaryList(&sv.Entities, value); err != nil { + return err + } + + case "nextToken": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.NextToken = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil } -func awsRestjson1_deserializeErrorResourceConflictException(response *smithyhttp.Response, errorBody *bytes.Reader) error { - output := &types.ResourceConflictException{} +type awsRestjson1_deserializeOpPutMetadataFlag struct { +} + +func (*awsRestjson1_deserializeOpPutMetadataFlag) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpPutMetadataFlag) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsRestjson1_deserializeOpErrorPutMetadataFlag(response, &metadata) + } + output := &PutMetadataFlagOutput{} + out.Result = output + + if _, err = io.Copy(ioutil.Discard, response.Body); err != nil { + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to discard response body, %w", err), + } + } + + return out, metadata, err +} + +func awsRestjson1_deserializeOpErrorPutMetadataFlag(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + var buff [1024]byte ringBuffer := smithyio.NewRingBuffer(buff[:]) body := io.TeeReader(errorBody, ringBuffer) decoder := json.NewDecoder(body) decoder.UseNumber() - var shape interface{} - if err := decoder.Decode(&shape); err != nil && err != io.EOF { + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) err = &smithy.DeserializationError{ @@ -2198,29 +2577,62 @@ func awsRestjson1_deserializeErrorResourceConflictException(response *smithyhttp return err } - err := awsRestjson1_deserializeDocumentResourceConflictException(&output, shape) + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } - if err != nil { - var snapshot bytes.Buffer - io.Copy(&snapshot, ringBuffer) - err = &smithy.DeserializationError{ - Err: fmt.Errorf("failed to decode response body, %w", err), - Snapshot: snapshot.Bytes(), + switch { + case strings.EqualFold("InvalidParameterException", errorCode): + return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + + case strings.EqualFold("UnauthorizedException", errorCode): + return awsRestjson1_deserializeErrorUnauthorizedException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, } - return err + return genericError + } +} - errorBody.Seek(0, io.SeekStart) +type awsRestjson1_deserializeOpRefreshToken struct { +} - return output +func (*awsRestjson1_deserializeOpRefreshToken) ID() string { + return "OperationDeserializer" } -func awsRestjson1_deserializeErrorResourceNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error { - output := &types.ResourceNotFoundException{} +func (m *awsRestjson1_deserializeOpRefreshToken) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsRestjson1_deserializeOpErrorRefreshToken(response, &metadata) + } + output := &RefreshTokenOutput{} + out.Result = output + var buff [1024]byte ringBuffer := smithyio.NewRingBuffer(buff[:]) - body := io.TeeReader(errorBody, ringBuffer) + body := io.TeeReader(response.Body, ringBuffer) + decoder := json.NewDecoder(body) decoder.UseNumber() var shape interface{} @@ -2231,36 +2643,45 @@ func awsRestjson1_deserializeErrorResourceNotFoundException(response *smithyhttp Err: fmt.Errorf("failed to decode response body, %w", err), Snapshot: snapshot.Bytes(), } - return err + return out, metadata, err } - err := awsRestjson1_deserializeDocumentResourceNotFoundException(&output, shape) - + err = awsRestjson1_deserializeOpDocumentRefreshTokenOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) - err = &smithy.DeserializationError{ - Err: fmt.Errorf("failed to decode response body, %w", err), + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body with invalid JSON, %w", err), Snapshot: snapshot.Bytes(), } - return err } - errorBody.Seek(0, io.SeekStart) - - return output + return out, metadata, err } -func awsRestjson1_deserializeErrorServiceQuotaExceededException(response *smithyhttp.Response, errorBody *bytes.Reader) error { - output := &types.ServiceQuotaExceededException{} +func awsRestjson1_deserializeOpErrorRefreshToken(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + var buff [1024]byte ringBuffer := smithyio.NewRingBuffer(buff[:]) body := io.TeeReader(errorBody, ringBuffer) decoder := json.NewDecoder(body) decoder.UseNumber() - var shape interface{} - if err := decoder.Decode(&shape); err != nil && err != io.EOF { + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) err = &smithy.DeserializationError{ @@ -2270,24 +2691,1661 @@ func awsRestjson1_deserializeErrorServiceQuotaExceededException(response *smithy return err } - err := awsRestjson1_deserializeDocumentServiceQuotaExceededException(&output, shape) + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } - if err != nil { - var snapshot bytes.Buffer - io.Copy(&snapshot, ringBuffer) - err = &smithy.DeserializationError{ - Err: fmt.Errorf("failed to decode response body, %w", err), - Snapshot: snapshot.Bytes(), + switch { + case strings.EqualFold("InvalidParameterException", errorCode): + return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +func awsRestjson1_deserializeOpDocumentRefreshTokenOutput(v **RefreshTokenOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *RefreshTokenOutput + if *v == nil { + sv = &RefreshTokenOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "accessToken": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected SensitiveString to be of type string, got %T instead", value) + } + sv.AccessToken = ptr.String(jtv) + } + + case "expiresIn": + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected Integer to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + sv.ExpiresIn = ptr.Int32(int32(i64)) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +type awsRestjson1_deserializeOpUpdateComponent struct { +} + +func (*awsRestjson1_deserializeOpUpdateComponent) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpUpdateComponent) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsRestjson1_deserializeOpErrorUpdateComponent(response, &metadata) + } + output := &UpdateComponentOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsRestjson1_deserializeDocumentComponent(&output.Entity, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body with invalid JSON, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + return out, metadata, err +} + +func awsRestjson1_deserializeOpErrorUpdateComponent(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("InvalidParameterException", errorCode): + return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + + case strings.EqualFold("ResourceConflictException", errorCode): + return awsRestjson1_deserializeErrorResourceConflictException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +func awsRestjson1_deserializeOpDocumentUpdateComponentOutput(v **UpdateComponentOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *UpdateComponentOutput + if *v == nil { + sv = &UpdateComponentOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "entity": + if err := awsRestjson1_deserializeDocumentComponent(&sv.Entity, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +type awsRestjson1_deserializeOpUpdateForm struct { +} + +func (*awsRestjson1_deserializeOpUpdateForm) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpUpdateForm) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsRestjson1_deserializeOpErrorUpdateForm(response, &metadata) + } + output := &UpdateFormOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsRestjson1_deserializeDocumentForm(&output.Entity, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body with invalid JSON, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + return out, metadata, err +} + +func awsRestjson1_deserializeOpErrorUpdateForm(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("InvalidParameterException", errorCode): + return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + + case strings.EqualFold("ResourceConflictException", errorCode): + return awsRestjson1_deserializeErrorResourceConflictException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +func awsRestjson1_deserializeOpDocumentUpdateFormOutput(v **UpdateFormOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *UpdateFormOutput + if *v == nil { + sv = &UpdateFormOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "entity": + if err := awsRestjson1_deserializeDocumentForm(&sv.Entity, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +type awsRestjson1_deserializeOpUpdateTheme struct { +} + +func (*awsRestjson1_deserializeOpUpdateTheme) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpUpdateTheme) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsRestjson1_deserializeOpErrorUpdateTheme(response, &metadata) + } + output := &UpdateThemeOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsRestjson1_deserializeDocumentTheme(&output.Entity, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body with invalid JSON, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + return out, metadata, err +} + +func awsRestjson1_deserializeOpErrorUpdateTheme(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("InvalidParameterException", errorCode): + return awsRestjson1_deserializeErrorInvalidParameterException(response, errorBody) + + case strings.EqualFold("ResourceConflictException", errorCode): + return awsRestjson1_deserializeErrorResourceConflictException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +func awsRestjson1_deserializeOpDocumentUpdateThemeOutput(v **UpdateThemeOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *UpdateThemeOutput + if *v == nil { + sv = &UpdateThemeOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "entity": + if err := awsRestjson1_deserializeDocumentTheme(&sv.Entity, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeErrorInternalServerException(response *smithyhttp.Response, errorBody *bytes.Reader) error { + output := &types.InternalServerException{} + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + err := awsRestjson1_deserializeDocumentInternalServerException(&output, shape) + + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + + return output +} + +func awsRestjson1_deserializeErrorInvalidParameterException(response *smithyhttp.Response, errorBody *bytes.Reader) error { + output := &types.InvalidParameterException{} + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + err := awsRestjson1_deserializeDocumentInvalidParameterException(&output, shape) + + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + + return output +} + +func awsRestjson1_deserializeErrorResourceConflictException(response *smithyhttp.Response, errorBody *bytes.Reader) error { + output := &types.ResourceConflictException{} + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + err := awsRestjson1_deserializeDocumentResourceConflictException(&output, shape) + + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + + return output +} + +func awsRestjson1_deserializeErrorResourceNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error { + output := &types.ResourceNotFoundException{} + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + err := awsRestjson1_deserializeDocumentResourceNotFoundException(&output, shape) + + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + + return output +} + +func awsRestjson1_deserializeErrorServiceQuotaExceededException(response *smithyhttp.Response, errorBody *bytes.Reader) error { + output := &types.ServiceQuotaExceededException{} + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + err := awsRestjson1_deserializeDocumentServiceQuotaExceededException(&output, shape) + + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + + return output +} + +func awsRestjson1_deserializeErrorUnauthorizedException(response *smithyhttp.Response, errorBody *bytes.Reader) error { + output := &types.UnauthorizedException{} + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + err := awsRestjson1_deserializeDocumentUnauthorizedException(&output, shape) + + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + + return output +} + +func awsRestjson1_deserializeDocumentActionParameters(v **types.ActionParameters, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ActionParameters + if *v == nil { + sv = &types.ActionParameters{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "anchor": + if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Anchor, value); err != nil { + return err + } + + case "fields": + if err := awsRestjson1_deserializeDocumentComponentProperties(&sv.Fields, value); err != nil { + return err + } + + case "global": + if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Global, value); err != nil { + return err + } + + case "id": + if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Id, value); err != nil { + return err + } + + case "model": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Model = ptr.String(jtv) + } + + case "state": + if err := awsRestjson1_deserializeDocumentMutationActionSetStateParameter(&sv.State, value); err != nil { + return err + } + + case "target": + if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Target, value); err != nil { + return err + } + + case "type": + if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Type, value); err != nil { + return err + } + + case "url": + if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Url, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentComponent(v **types.Component, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.Component + if *v == nil { + sv = &types.Component{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "appId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.AppId = ptr.String(jtv) + } + + case "bindingProperties": + if err := awsRestjson1_deserializeDocumentComponentBindingProperties(&sv.BindingProperties, value); err != nil { + return err + } + + case "children": + if err := awsRestjson1_deserializeDocumentComponentChildList(&sv.Children, value); err != nil { + return err + } + + case "collectionProperties": + if err := awsRestjson1_deserializeDocumentComponentCollectionProperties(&sv.CollectionProperties, value); err != nil { + return err + } + + case "componentType": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ComponentType to be of type string, got %T instead", value) + } + sv.ComponentType = ptr.String(jtv) + } + + case "createdAt": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Timestamp to be of type string, got %T instead", value) + } + t, err := smithytime.ParseDateTime(jtv) + if err != nil { + return err + } + sv.CreatedAt = ptr.Time(t) + } + + case "environmentName": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.EnvironmentName = ptr.String(jtv) + } + + case "events": + if err := awsRestjson1_deserializeDocumentComponentEvents(&sv.Events, value); err != nil { + return err + } + + case "id": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Uuid to be of type string, got %T instead", value) + } + sv.Id = ptr.String(jtv) + } + + case "modifiedAt": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Timestamp to be of type string, got %T instead", value) + } + t, err := smithytime.ParseDateTime(jtv) + if err != nil { + return err + } + sv.ModifiedAt = ptr.Time(t) + } + + case "name": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ComponentName to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) + } + + case "overrides": + if err := awsRestjson1_deserializeDocumentComponentOverrides(&sv.Overrides, value); err != nil { + return err + } + + case "properties": + if err := awsRestjson1_deserializeDocumentComponentProperties(&sv.Properties, value); err != nil { + return err + } + + case "schemaVersion": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.SchemaVersion = ptr.String(jtv) + } + + case "sourceId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.SourceId = ptr.String(jtv) + } + + case "tags": + if err := awsRestjson1_deserializeDocumentTags(&sv.Tags, value); err != nil { + return err + } + + case "variants": + if err := awsRestjson1_deserializeDocumentComponentVariants(&sv.Variants, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentComponentBindingProperties(v *map[string]types.ComponentBindingPropertiesValue, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var mv map[string]types.ComponentBindingPropertiesValue + if *v == nil { + mv = map[string]types.ComponentBindingPropertiesValue{} + } else { + mv = *v + } + + for key, value := range shape { + var parsedVal types.ComponentBindingPropertiesValue + mapVar := parsedVal + destAddr := &mapVar + if err := awsRestjson1_deserializeDocumentComponentBindingPropertiesValue(&destAddr, value); err != nil { + return err + } + parsedVal = *destAddr + mv[key] = parsedVal + + } + *v = mv + return nil +} + +func awsRestjson1_deserializeDocumentComponentBindingPropertiesValue(v **types.ComponentBindingPropertiesValue, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ComponentBindingPropertiesValue + if *v == nil { + sv = &types.ComponentBindingPropertiesValue{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "bindingProperties": + if err := awsRestjson1_deserializeDocumentComponentBindingPropertiesValueProperties(&sv.BindingProperties, value); err != nil { + return err + } + + case "defaultValue": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.DefaultValue = ptr.String(jtv) + } + + case "type": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Type = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentComponentBindingPropertiesValueProperties(v **types.ComponentBindingPropertiesValueProperties, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ComponentBindingPropertiesValueProperties + if *v == nil { + sv = &types.ComponentBindingPropertiesValueProperties{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "bucket": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Bucket = ptr.String(jtv) + } + + case "defaultValue": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.DefaultValue = ptr.String(jtv) + } + + case "field": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Field = ptr.String(jtv) + } + + case "key": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Key = ptr.String(jtv) + } + + case "model": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Model = ptr.String(jtv) + } + + case "predicates": + if err := awsRestjson1_deserializeDocumentPredicateList(&sv.Predicates, value); err != nil { + return err + } + + case "slotName": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.SlotName = ptr.String(jtv) + } + + case "userAttribute": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.UserAttribute = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentComponentChild(v **types.ComponentChild, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ComponentChild + if *v == nil { + sv = &types.ComponentChild{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "children": + if err := awsRestjson1_deserializeDocumentComponentChildList(&sv.Children, value); err != nil { + return err + } + + case "componentType": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.ComponentType = ptr.String(jtv) + } + + case "events": + if err := awsRestjson1_deserializeDocumentComponentEvents(&sv.Events, value); err != nil { + return err + } + + case "name": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) + } + + case "properties": + if err := awsRestjson1_deserializeDocumentComponentProperties(&sv.Properties, value); err != nil { + return err + } + + case "sourceId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.SourceId = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentComponentChildList(v *[]types.ComponentChild, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.ComponentChild + if *v == nil { + cv = []types.ComponentChild{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.ComponentChild + destAddr := &col + if err := awsRestjson1_deserializeDocumentComponentChild(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsRestjson1_deserializeDocumentComponentCollectionProperties(v *map[string]types.ComponentDataConfiguration, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var mv map[string]types.ComponentDataConfiguration + if *v == nil { + mv = map[string]types.ComponentDataConfiguration{} + } else { + mv = *v + } + + for key, value := range shape { + var parsedVal types.ComponentDataConfiguration + mapVar := parsedVal + destAddr := &mapVar + if err := awsRestjson1_deserializeDocumentComponentDataConfiguration(&destAddr, value); err != nil { + return err + } + parsedVal = *destAddr + mv[key] = parsedVal + + } + *v = mv + return nil +} + +func awsRestjson1_deserializeDocumentComponentConditionProperty(v **types.ComponentConditionProperty, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ComponentConditionProperty + if *v == nil { + sv = &types.ComponentConditionProperty{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "else": + if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Else, value); err != nil { + return err + } + + case "field": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Field = ptr.String(jtv) + } + + case "operand": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Operand = ptr.String(jtv) + } + + case "operandType": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.OperandType = ptr.String(jtv) + } + + case "operator": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Operator = ptr.String(jtv) + } + + case "property": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Property = ptr.String(jtv) + } + + case "then": + if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Then, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentComponentDataConfiguration(v **types.ComponentDataConfiguration, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ComponentDataConfiguration + if *v == nil { + sv = &types.ComponentDataConfiguration{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "identifiers": + if err := awsRestjson1_deserializeDocumentIdentifierList(&sv.Identifiers, value); err != nil { + return err + } + + case "model": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Model = ptr.String(jtv) + } + + case "predicate": + if err := awsRestjson1_deserializeDocumentPredicate(&sv.Predicate, value); err != nil { + return err + } + + case "sort": + if err := awsRestjson1_deserializeDocumentSortPropertyList(&sv.Sort, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentComponentEvent(v **types.ComponentEvent, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ComponentEvent + if *v == nil { + sv = &types.ComponentEvent{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "action": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Action = ptr.String(jtv) + } + + case "bindingEvent": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.BindingEvent = ptr.String(jtv) + } + + case "parameters": + if err := awsRestjson1_deserializeDocumentActionParameters(&sv.Parameters, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentComponentEvents(v *map[string]types.ComponentEvent, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var mv map[string]types.ComponentEvent + if *v == nil { + mv = map[string]types.ComponentEvent{} + } else { + mv = *v + } + + for key, value := range shape { + var parsedVal types.ComponentEvent + mapVar := parsedVal + destAddr := &mapVar + if err := awsRestjson1_deserializeDocumentComponentEvent(&destAddr, value); err != nil { + return err + } + parsedVal = *destAddr + mv[key] = parsedVal + + } + *v = mv + return nil +} + +func awsRestjson1_deserializeDocumentComponentList(v *[]types.Component, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.Component + if *v == nil { + cv = []types.Component{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.Component + destAddr := &col + if err := awsRestjson1_deserializeDocumentComponent(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsRestjson1_deserializeDocumentComponentOverrides(v *map[string]map[string]string, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var mv map[string]map[string]string + if *v == nil { + mv = map[string]map[string]string{} + } else { + mv = *v + } + + for key, value := range shape { + var parsedVal map[string]string + mapVar := parsedVal + if err := awsRestjson1_deserializeDocumentComponentOverridesValue(&mapVar, value); err != nil { + return err + } + parsedVal = mapVar + mv[key] = parsedVal + + } + *v = mv + return nil +} + +func awsRestjson1_deserializeDocumentComponentOverridesValue(v *map[string]string, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var mv map[string]string + if *v == nil { + mv = map[string]string{} + } else { + mv = *v + } + + for key, value := range shape { + var parsedVal string + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + parsedVal = jtv } - return err - } - - errorBody.Seek(0, io.SeekStart) + mv[key] = parsedVal - return output + } + *v = mv + return nil } -func awsRestjson1_deserializeDocumentActionParameters(v **types.ActionParameters, value interface{}) error { +func awsRestjson1_deserializeDocumentComponentProperties(v *map[string]types.ComponentProperty, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -2300,74 +4358,29 @@ func awsRestjson1_deserializeDocumentActionParameters(v **types.ActionParameters return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ActionParameters + var mv map[string]types.ComponentProperty if *v == nil { - sv = &types.ActionParameters{} + mv = map[string]types.ComponentProperty{} } else { - sv = *v + mv = *v } for key, value := range shape { - switch key { - case "anchor": - if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Anchor, value); err != nil { - return err - } - - case "fields": - if err := awsRestjson1_deserializeDocumentComponentProperties(&sv.Fields, value); err != nil { - return err - } - - case "global": - if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Global, value); err != nil { - return err - } - - case "id": - if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Id, value); err != nil { - return err - } - - case "model": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.Model = ptr.String(jtv) - } - - case "state": - if err := awsRestjson1_deserializeDocumentMutationActionSetStateParameter(&sv.State, value); err != nil { - return err - } - - case "target": - if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Target, value); err != nil { - return err - } - - case "type": - if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Type, value); err != nil { - return err - } - - case "url": - if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Url, value); err != nil { - return err - } - - default: - _, _ = key, value - + var parsedVal types.ComponentProperty + mapVar := parsedVal + destAddr := &mapVar + if err := awsRestjson1_deserializeDocumentComponentProperty(&destAddr, value); err != nil { + return err } + parsedVal = *destAddr + mv[key] = parsedVal + } - *v = sv + *v = mv return nil } -func awsRestjson1_deserializeDocumentComponent(v **types.Component, value interface{}) error { +func awsRestjson1_deserializeDocumentComponentProperty(v **types.ComponentProperty, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -2380,142 +4393,128 @@ func awsRestjson1_deserializeDocumentComponent(v **types.Component, value interf return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.Component + var sv *types.ComponentProperty if *v == nil { - sv = &types.Component{} + sv = &types.ComponentProperty{} } else { sv = *v } for key, value := range shape { switch key { - case "appId": + case "bindingProperties": + if err := awsRestjson1_deserializeDocumentComponentPropertyBindingProperties(&sv.BindingProperties, value); err != nil { + return err + } + + case "bindings": + if err := awsRestjson1_deserializeDocumentFormBindings(&sv.Bindings, value); err != nil { + return err + } + + case "collectionBindingProperties": + if err := awsRestjson1_deserializeDocumentComponentPropertyBindingProperties(&sv.CollectionBindingProperties, value); err != nil { + return err + } + + case "componentName": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.AppId = ptr.String(jtv) + sv.ComponentName = ptr.String(jtv) } - case "bindingProperties": - if err := awsRestjson1_deserializeDocumentComponentBindingProperties(&sv.BindingProperties, value); err != nil { + case "concat": + if err := awsRestjson1_deserializeDocumentComponentPropertyList(&sv.Concat, value); err != nil { return err } - case "children": - if err := awsRestjson1_deserializeDocumentComponentChildList(&sv.Children, value); err != nil { + case "condition": + if err := awsRestjson1_deserializeDocumentComponentConditionProperty(&sv.Condition, value); err != nil { return err } - case "collectionProperties": - if err := awsRestjson1_deserializeDocumentComponentCollectionProperties(&sv.CollectionProperties, value); err != nil { - return err + case "configured": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected Boolean to be of type *bool, got %T instead", value) + } + sv.Configured = ptr.Bool(jtv) } - case "componentType": + case "defaultValue": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ComponentType to be of type string, got %T instead", value) + return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.ComponentType = ptr.String(jtv) + sv.DefaultValue = ptr.String(jtv) } - case "createdAt": + case "event": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected Timestamp to be of type string, got %T instead", value) - } - t, err := smithytime.ParseDateTime(jtv) - if err != nil { - return err + return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.CreatedAt = ptr.Time(t) + sv.Event = ptr.String(jtv) } - case "environmentName": + case "importedValue": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.EnvironmentName = ptr.String(jtv) - } - - case "events": - if err := awsRestjson1_deserializeDocumentComponentEvents(&sv.Events, value); err != nil { - return err + sv.ImportedValue = ptr.String(jtv) } - case "id": + case "model": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected Uuid to be of type string, got %T instead", value) + return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Id = ptr.String(jtv) + sv.Model = ptr.String(jtv) } - case "modifiedAt": + case "property": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected Timestamp to be of type string, got %T instead", value) - } - t, err := smithytime.ParseDateTime(jtv) - if err != nil { - return err + return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.ModifiedAt = ptr.Time(t) + sv.Property = ptr.String(jtv) } - case "name": + case "type": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ComponentName to be of type string, got %T instead", value) + return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Name = ptr.String(jtv) - } - - case "overrides": - if err := awsRestjson1_deserializeDocumentComponentOverrides(&sv.Overrides, value); err != nil { - return err - } - - case "properties": - if err := awsRestjson1_deserializeDocumentComponentProperties(&sv.Properties, value); err != nil { - return err + sv.Type = ptr.String(jtv) } - case "schemaVersion": + case "userAttribute": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.SchemaVersion = ptr.String(jtv) + sv.UserAttribute = ptr.String(jtv) } - case "sourceId": + case "value": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.SourceId = ptr.String(jtv) - } - - case "tags": - if err := awsRestjson1_deserializeDocumentTags(&sv.Tags, value); err != nil { - return err - } - - case "variants": - if err := awsRestjson1_deserializeDocumentComponentVariants(&sv.Variants, value); err != nil { - return err + sv.Value = ptr.String(jtv) } default: @@ -2527,42 +4526,7 @@ func awsRestjson1_deserializeDocumentComponent(v **types.Component, value interf return nil } -func awsRestjson1_deserializeDocumentComponentBindingProperties(v *map[string]types.ComponentBindingPropertiesValue, value interface{}) error { - if v == nil { - return fmt.Errorf("unexpected nil of type %T", v) - } - if value == nil { - return nil - } - - shape, ok := value.(map[string]interface{}) - if !ok { - return fmt.Errorf("unexpected JSON type %v", value) - } - - var mv map[string]types.ComponentBindingPropertiesValue - if *v == nil { - mv = map[string]types.ComponentBindingPropertiesValue{} - } else { - mv = *v - } - - for key, value := range shape { - var parsedVal types.ComponentBindingPropertiesValue - mapVar := parsedVal - destAddr := &mapVar - if err := awsRestjson1_deserializeDocumentComponentBindingPropertiesValue(&destAddr, value); err != nil { - return err - } - parsedVal = *destAddr - mv[key] = parsedVal - - } - *v = mv - return nil -} - -func awsRestjson1_deserializeDocumentComponentBindingPropertiesValue(v **types.ComponentBindingPropertiesValue, value interface{}) error { +func awsRestjson1_deserializeDocumentComponentPropertyBindingProperties(v **types.ComponentPropertyBindingProperties, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -2575,36 +4539,31 @@ func awsRestjson1_deserializeDocumentComponentBindingPropertiesValue(v **types.C return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ComponentBindingPropertiesValue + var sv *types.ComponentPropertyBindingProperties if *v == nil { - sv = &types.ComponentBindingPropertiesValue{} + sv = &types.ComponentPropertyBindingProperties{} } else { sv = *v } for key, value := range shape { switch key { - case "bindingProperties": - if err := awsRestjson1_deserializeDocumentComponentBindingPropertiesValueProperties(&sv.BindingProperties, value); err != nil { - return err - } - - case "defaultValue": + case "field": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.DefaultValue = ptr.String(jtv) + sv.Field = ptr.String(jtv) } - case "type": + case "property": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Type = ptr.String(jtv) + sv.Property = ptr.String(jtv) } default: @@ -2616,7 +4575,41 @@ func awsRestjson1_deserializeDocumentComponentBindingPropertiesValue(v **types.C return nil } -func awsRestjson1_deserializeDocumentComponentBindingPropertiesValueProperties(v **types.ComponentBindingPropertiesValueProperties, value interface{}) error { +func awsRestjson1_deserializeDocumentComponentPropertyList(v *[]types.ComponentProperty, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.ComponentProperty + if *v == nil { + cv = []types.ComponentProperty{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.ComponentProperty + destAddr := &col + if err := awsRestjson1_deserializeDocumentComponentProperty(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsRestjson1_deserializeDocumentComponentSummary(v **types.ComponentSummary, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -2629,72 +4622,58 @@ func awsRestjson1_deserializeDocumentComponentBindingPropertiesValueProperties(v return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ComponentBindingPropertiesValueProperties + var sv *types.ComponentSummary if *v == nil { - sv = &types.ComponentBindingPropertiesValueProperties{} + sv = &types.ComponentSummary{} } else { sv = *v } for key, value := range shape { switch key { - case "bucket": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.Bucket = ptr.String(jtv) - } - - case "defaultValue": + case "appId": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.DefaultValue = ptr.String(jtv) + sv.AppId = ptr.String(jtv) } - case "field": + case "componentType": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) + return fmt.Errorf("expected ComponentType to be of type string, got %T instead", value) } - sv.Field = ptr.String(jtv) + sv.ComponentType = ptr.String(jtv) } - case "key": + case "environmentName": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Key = ptr.String(jtv) + sv.EnvironmentName = ptr.String(jtv) } - case "model": + case "id": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) + return fmt.Errorf("expected Uuid to be of type string, got %T instead", value) } - sv.Model = ptr.String(jtv) - } - - case "predicates": - if err := awsRestjson1_deserializeDocumentPredicateList(&sv.Predicates, value); err != nil { - return err + sv.Id = ptr.String(jtv) } - case "userAttribute": + case "name": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) + return fmt.Errorf("expected ComponentName to be of type string, got %T instead", value) } - sv.UserAttribute = ptr.String(jtv) + sv.Name = ptr.String(jtv) } default: @@ -2706,7 +4685,41 @@ func awsRestjson1_deserializeDocumentComponentBindingPropertiesValueProperties(v return nil } -func awsRestjson1_deserializeDocumentComponentChild(v **types.ComponentChild, value interface{}) error { +func awsRestjson1_deserializeDocumentComponentSummaryList(v *[]types.ComponentSummary, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.ComponentSummary + if *v == nil { + cv = []types.ComponentSummary{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.ComponentSummary + destAddr := &col + if err := awsRestjson1_deserializeDocumentComponentSummary(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsRestjson1_deserializeDocumentComponentVariant(v **types.ComponentVariant, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -2719,57 +4732,25 @@ func awsRestjson1_deserializeDocumentComponentChild(v **types.ComponentChild, va return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ComponentChild + var sv *types.ComponentVariant if *v == nil { - sv = &types.ComponentChild{} + sv = &types.ComponentVariant{} } else { sv = *v } for key, value := range shape { switch key { - case "children": - if err := awsRestjson1_deserializeDocumentComponentChildList(&sv.Children, value); err != nil { - return err - } - - case "componentType": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.ComponentType = ptr.String(jtv) - } - - case "events": - if err := awsRestjson1_deserializeDocumentComponentEvents(&sv.Events, value); err != nil { + case "overrides": + if err := awsRestjson1_deserializeDocumentComponentOverrides(&sv.Overrides, value); err != nil { return err } - case "name": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.Name = ptr.String(jtv) - } - - case "properties": - if err := awsRestjson1_deserializeDocumentComponentProperties(&sv.Properties, value); err != nil { + case "variantValues": + if err := awsRestjson1_deserializeDocumentComponentVariantValues(&sv.VariantValues, value); err != nil { return err } - case "sourceId": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.SourceId = ptr.String(jtv) - } - default: _, _ = key, value @@ -2779,7 +4760,7 @@ func awsRestjson1_deserializeDocumentComponentChild(v **types.ComponentChild, va return nil } -func awsRestjson1_deserializeDocumentComponentChildList(v *[]types.ComponentChild, value interface{}) error { +func awsRestjson1_deserializeDocumentComponentVariants(v *[]types.ComponentVariant, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -2792,17 +4773,17 @@ func awsRestjson1_deserializeDocumentComponentChildList(v *[]types.ComponentChil return fmt.Errorf("unexpected JSON type %v", value) } - var cv []types.ComponentChild + var cv []types.ComponentVariant if *v == nil { - cv = []types.ComponentChild{} + cv = []types.ComponentVariant{} } else { cv = *v } for _, value := range shape { - var col types.ComponentChild + var col types.ComponentVariant destAddr := &col - if err := awsRestjson1_deserializeDocumentComponentChild(&destAddr, value); err != nil { + if err := awsRestjson1_deserializeDocumentComponentVariant(&destAddr, value); err != nil { return err } col = *destAddr @@ -2813,7 +4794,7 @@ func awsRestjson1_deserializeDocumentComponentChildList(v *[]types.ComponentChil return nil } -func awsRestjson1_deserializeDocumentComponentCollectionProperties(v *map[string]types.ComponentDataConfiguration, value interface{}) error { +func awsRestjson1_deserializeDocumentComponentVariantValues(v *map[string]string, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -2826,21 +4807,22 @@ func awsRestjson1_deserializeDocumentComponentCollectionProperties(v *map[string return fmt.Errorf("unexpected JSON type %v", value) } - var mv map[string]types.ComponentDataConfiguration + var mv map[string]string if *v == nil { - mv = map[string]types.ComponentDataConfiguration{} + mv = map[string]string{} } else { mv = *v } for key, value := range shape { - var parsedVal types.ComponentDataConfiguration - mapVar := parsedVal - destAddr := &mapVar - if err := awsRestjson1_deserializeDocumentComponentDataConfiguration(&destAddr, value); err != nil { - return err + var parsedVal string + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + parsedVal = jtv } - parsedVal = *destAddr mv[key] = parsedVal } @@ -2848,7 +4830,7 @@ func awsRestjson1_deserializeDocumentComponentCollectionProperties(v *map[string return nil } -func awsRestjson1_deserializeDocumentComponentConditionProperty(v **types.ComponentConditionProperty, value interface{}) error { +func awsRestjson1_deserializeDocumentFeaturesMap(v *map[string]string, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -2861,80 +4843,30 @@ func awsRestjson1_deserializeDocumentComponentConditionProperty(v **types.Compon return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ComponentConditionProperty + var mv map[string]string if *v == nil { - sv = &types.ComponentConditionProperty{} + mv = map[string]string{} } else { - sv = *v + mv = *v } for key, value := range shape { - switch key { - case "else": - if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Else, value); err != nil { - return err - } - - case "field": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.Field = ptr.String(jtv) - } - - case "operand": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.Operand = ptr.String(jtv) - } - - case "operandType": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.OperandType = ptr.String(jtv) - } - - case "operator": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.Operator = ptr.String(jtv) - } - - case "property": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.Property = ptr.String(jtv) - } - - case "then": - if err := awsRestjson1_deserializeDocumentComponentProperty(&sv.Then, value); err != nil { - return err + var parsedVal string + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) } - - default: - _, _ = key, value - + parsedVal = jtv } + mv[key] = parsedVal + } - *v = sv + *v = mv return nil } -func awsRestjson1_deserializeDocumentComponentDataConfiguration(v **types.ComponentDataConfiguration, value interface{}) error { +func awsRestjson1_deserializeDocumentFieldConfig(v **types.FieldConfig, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -2947,36 +4879,45 @@ func awsRestjson1_deserializeDocumentComponentDataConfiguration(v **types.Compon return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ComponentDataConfiguration + var sv *types.FieldConfig if *v == nil { - sv = &types.ComponentDataConfiguration{} + sv = &types.FieldConfig{} } else { sv = *v } for key, value := range shape { switch key { - case "identifiers": - if err := awsRestjson1_deserializeDocumentIdentifierList(&sv.Identifiers, value); err != nil { + case "excluded": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected Boolean to be of type *bool, got %T instead", value) + } + sv.Excluded = ptr.Bool(jtv) + } + + case "inputType": + if err := awsRestjson1_deserializeDocumentFieldInputConfig(&sv.InputType, value); err != nil { return err } - case "model": + case "label": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Model = ptr.String(jtv) + sv.Label = ptr.String(jtv) } - case "predicate": - if err := awsRestjson1_deserializeDocumentPredicate(&sv.Predicate, value); err != nil { + case "position": + if err := awsRestjson1_deserializeDocumentFieldPosition(&sv.Position, value); err != nil { return err } - case "sort": - if err := awsRestjson1_deserializeDocumentSortPropertyList(&sv.Sort, value); err != nil { + case "validations": + if err := awsRestjson1_deserializeDocumentValidationsList(&sv.Validations, value); err != nil { return err } @@ -2989,7 +4930,7 @@ func awsRestjson1_deserializeDocumentComponentDataConfiguration(v **types.Compon return nil } -func awsRestjson1_deserializeDocumentComponentEvent(v **types.ComponentEvent, value interface{}) error { +func awsRestjson1_deserializeDocumentFieldInputConfig(v **types.FieldInputConfig, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3002,35 +4943,209 @@ func awsRestjson1_deserializeDocumentComponentEvent(v **types.ComponentEvent, va return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ComponentEvent + var sv *types.FieldInputConfig if *v == nil { - sv = &types.ComponentEvent{} + sv = &types.FieldInputConfig{} } else { sv = *v } for key, value := range shape { switch key { - case "action": + case "defaultChecked": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected Boolean to be of type *bool, got %T instead", value) + } + sv.DefaultChecked = ptr.Bool(jtv) + } + + case "defaultCountryCode": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Action = ptr.String(jtv) + sv.DefaultCountryCode = ptr.String(jtv) } - case "bindingEvent": + case "defaultValue": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.BindingEvent = ptr.String(jtv) + sv.DefaultValue = ptr.String(jtv) } - case "parameters": - if err := awsRestjson1_deserializeDocumentActionParameters(&sv.Parameters, value); err != nil { + case "descriptiveText": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.DescriptiveText = ptr.String(jtv) + } + + case "maxValue": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.MaxValue = ptr.Float32(float32(f64)) + + case string: + var f64 float64 + switch { + case strings.EqualFold(jtv, "NaN"): + f64 = math.NaN() + + case strings.EqualFold(jtv, "Infinity"): + f64 = math.Inf(1) + + case strings.EqualFold(jtv, "-Infinity"): + f64 = math.Inf(-1) + + default: + return fmt.Errorf("unknown JSON number value: %s", jtv) + + } + sv.MaxValue = ptr.Float32(float32(f64)) + + default: + return fmt.Errorf("expected Float to be a JSON Number, got %T instead", value) + + } + } + + case "minValue": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.MinValue = ptr.Float32(float32(f64)) + + case string: + var f64 float64 + switch { + case strings.EqualFold(jtv, "NaN"): + f64 = math.NaN() + + case strings.EqualFold(jtv, "Infinity"): + f64 = math.Inf(1) + + case strings.EqualFold(jtv, "-Infinity"): + f64 = math.Inf(-1) + + default: + return fmt.Errorf("unknown JSON number value: %s", jtv) + + } + sv.MinValue = ptr.Float32(float32(f64)) + + default: + return fmt.Errorf("expected Float to be a JSON Number, got %T instead", value) + + } + } + + case "name": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) + } + + case "placeholder": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Placeholder = ptr.String(jtv) + } + + case "readOnly": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected Boolean to be of type *bool, got %T instead", value) + } + sv.ReadOnly = ptr.Bool(jtv) + } + + case "required": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected Boolean to be of type *bool, got %T instead", value) + } + sv.Required = ptr.Bool(jtv) + } + + case "step": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.Step = ptr.Float32(float32(f64)) + + case string: + var f64 float64 + switch { + case strings.EqualFold(jtv, "NaN"): + f64 = math.NaN() + + case strings.EqualFold(jtv, "Infinity"): + f64 = math.Inf(1) + + case strings.EqualFold(jtv, "-Infinity"): + f64 = math.Inf(-1) + + default: + return fmt.Errorf("unknown JSON number value: %s", jtv) + + } + sv.Step = ptr.Float32(float32(f64)) + + default: + return fmt.Errorf("expected Float to be a JSON Number, got %T instead", value) + + } + } + + case "type": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Type = ptr.String(jtv) + } + + case "value": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Value = ptr.String(jtv) + } + + case "valueMappings": + if err := awsRestjson1_deserializeDocumentValueMappings(&sv.ValueMappings, value); err != nil { return err } @@ -3043,7 +5158,7 @@ func awsRestjson1_deserializeDocumentComponentEvent(v **types.ComponentEvent, va return nil } -func awsRestjson1_deserializeDocumentComponentEvents(v *map[string]types.ComponentEvent, value interface{}) error { +func awsRestjson1_deserializeDocumentFieldPosition(v *types.FieldPosition, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3056,63 +5171,60 @@ func awsRestjson1_deserializeDocumentComponentEvents(v *map[string]types.Compone return fmt.Errorf("unexpected JSON type %v", value) } - var mv map[string]types.ComponentEvent - if *v == nil { - mv = map[string]types.ComponentEvent{} - } else { - mv = *v - } - + var uv types.FieldPosition +loop: for key, value := range shape { - var parsedVal types.ComponentEvent - mapVar := parsedVal - destAddr := &mapVar - if err := awsRestjson1_deserializeDocumentComponentEvent(&destAddr, value); err != nil { - return err + if value == nil { + continue } - parsedVal = *destAddr - mv[key] = parsedVal - - } - *v = mv - return nil -} + switch key { + case "below": + var mv string + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + mv = jtv + } + uv = &types.FieldPositionMemberBelow{Value: mv} + break loop -func awsRestjson1_deserializeDocumentComponentList(v *[]types.Component, value interface{}) error { - if v == nil { - return fmt.Errorf("unexpected nil of type %T", v) - } - if value == nil { - return nil - } + case "fixed": + var mv types.FixedPosition + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected FixedPosition to be of type string, got %T instead", value) + } + mv = types.FixedPosition(jtv) + } + uv = &types.FieldPositionMemberFixed{Value: mv} + break loop - shape, ok := value.([]interface{}) - if !ok { - return fmt.Errorf("unexpected JSON type %v", value) - } + case "rightOf": + var mv string + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + mv = jtv + } + uv = &types.FieldPositionMemberRightOf{Value: mv} + break loop - var cv []types.Component - if *v == nil { - cv = []types.Component{} - } else { - cv = *v - } + default: + uv = &types.UnknownUnionMember{Tag: key} + break loop - for _, value := range shape { - var col types.Component - destAddr := &col - if err := awsRestjson1_deserializeDocumentComponent(&destAddr, value); err != nil { - return err } - col = *destAddr - cv = append(cv, col) - } - *v = cv + *v = uv return nil } -func awsRestjson1_deserializeDocumentComponentOverrides(v *map[string]map[string]string, value interface{}) error { +func awsRestjson1_deserializeDocumentFieldsMap(v *map[string]types.FieldConfig, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3125,20 +5237,21 @@ func awsRestjson1_deserializeDocumentComponentOverrides(v *map[string]map[string return fmt.Errorf("unexpected JSON type %v", value) } - var mv map[string]map[string]string + var mv map[string]types.FieldConfig if *v == nil { - mv = map[string]map[string]string{} + mv = map[string]types.FieldConfig{} } else { mv = *v } for key, value := range shape { - var parsedVal map[string]string + var parsedVal types.FieldConfig mapVar := parsedVal - if err := awsRestjson1_deserializeDocumentComponentOverridesValue(&mapVar, value); err != nil { + destAddr := &mapVar + if err := awsRestjson1_deserializeDocumentFieldConfig(&destAddr, value); err != nil { return err } - parsedVal = mapVar + parsedVal = *destAddr mv[key] = parsedVal } @@ -3146,7 +5259,7 @@ func awsRestjson1_deserializeDocumentComponentOverrides(v *map[string]map[string return nil } -func awsRestjson1_deserializeDocumentComponentOverridesValue(v *map[string]string, value interface{}) error { +func awsRestjson1_deserializeDocumentFieldValidationConfiguration(v **types.FieldValidationConfiguration, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3159,65 +5272,53 @@ func awsRestjson1_deserializeDocumentComponentOverridesValue(v *map[string]strin return fmt.Errorf("unexpected JSON type %v", value) } - var mv map[string]string + var sv *types.FieldValidationConfiguration if *v == nil { - mv = map[string]string{} + sv = &types.FieldValidationConfiguration{} } else { - mv = *v + sv = *v } for key, value := range shape { - var parsedVal string - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) + switch key { + case "numValues": + if err := awsRestjson1_deserializeDocumentNumValues(&sv.NumValues, value); err != nil { + return err } - parsedVal = jtv - } - mv[key] = parsedVal - - } - *v = mv - return nil -} -func awsRestjson1_deserializeDocumentComponentProperties(v *map[string]types.ComponentProperty, value interface{}) error { - if v == nil { - return fmt.Errorf("unexpected nil of type %T", v) - } - if value == nil { - return nil - } + case "strValues": + if err := awsRestjson1_deserializeDocumentStrValues(&sv.StrValues, value); err != nil { + return err + } - shape, ok := value.(map[string]interface{}) - if !ok { - return fmt.Errorf("unexpected JSON type %v", value) - } + case "type": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Type = ptr.String(jtv) + } - var mv map[string]types.ComponentProperty - if *v == nil { - mv = map[string]types.ComponentProperty{} - } else { - mv = *v - } + case "validationMessage": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.ValidationMessage = ptr.String(jtv) + } - for key, value := range shape { - var parsedVal types.ComponentProperty - mapVar := parsedVal - destAddr := &mapVar - if err := awsRestjson1_deserializeDocumentComponentProperty(&destAddr, value); err != nil { - return err - } - parsedVal = *destAddr - mv[key] = parsedVal + default: + _, _ = key, value + } } - *v = mv + *v = sv return nil } -func awsRestjson1_deserializeDocumentComponentProperty(v **types.ComponentProperty, value interface{}) error { +func awsRestjson1_deserializeDocumentForm(v **types.Form, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3230,128 +5331,97 @@ func awsRestjson1_deserializeDocumentComponentProperty(v **types.ComponentProper return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ComponentProperty + var sv *types.Form if *v == nil { - sv = &types.ComponentProperty{} + sv = &types.Form{} } else { sv = *v } for key, value := range shape { switch key { - case "bindingProperties": - if err := awsRestjson1_deserializeDocumentComponentPropertyBindingProperties(&sv.BindingProperties, value); err != nil { - return err - } - - case "bindings": - if err := awsRestjson1_deserializeDocumentFormBindings(&sv.Bindings, value); err != nil { - return err - } - - case "collectionBindingProperties": - if err := awsRestjson1_deserializeDocumentComponentPropertyBindingProperties(&sv.CollectionBindingProperties, value); err != nil { - return err - } - - case "componentName": + case "appId": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.ComponentName = ptr.String(jtv) + sv.AppId = ptr.String(jtv) } - case "concat": - if err := awsRestjson1_deserializeDocumentComponentPropertyList(&sv.Concat, value); err != nil { + case "cta": + if err := awsRestjson1_deserializeDocumentFormCTA(&sv.Cta, value); err != nil { return err } - case "condition": - if err := awsRestjson1_deserializeDocumentComponentConditionProperty(&sv.Condition, value); err != nil { + case "dataType": + if err := awsRestjson1_deserializeDocumentFormDataTypeConfig(&sv.DataType, value); err != nil { return err } - case "configured": - if value != nil { - jtv, ok := value.(bool) - if !ok { - return fmt.Errorf("expected Boolean to be of type *bool, got %T instead", value) - } - sv.Configured = ptr.Bool(jtv) - } - - case "defaultValue": + case "environmentName": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.DefaultValue = ptr.String(jtv) + sv.EnvironmentName = ptr.String(jtv) } - case "event": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.Event = ptr.String(jtv) + case "fields": + if err := awsRestjson1_deserializeDocumentFieldsMap(&sv.Fields, value); err != nil { + return err } - case "importedValue": + case "formActionType": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) + return fmt.Errorf("expected FormActionType to be of type string, got %T instead", value) } - sv.ImportedValue = ptr.String(jtv) + sv.FormActionType = types.FormActionType(jtv) } - case "model": + case "id": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) + return fmt.Errorf("expected Uuid to be of type string, got %T instead", value) } - sv.Model = ptr.String(jtv) + sv.Id = ptr.String(jtv) } - case "property": + case "name": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) + return fmt.Errorf("expected FormName to be of type string, got %T instead", value) } - sv.Property = ptr.String(jtv) + sv.Name = ptr.String(jtv) } - case "type": + case "schemaVersion": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Type = ptr.String(jtv) + sv.SchemaVersion = ptr.String(jtv) } - case "userAttribute": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.UserAttribute = ptr.String(jtv) + case "sectionalElements": + if err := awsRestjson1_deserializeDocumentSectionalElementMap(&sv.SectionalElements, value); err != nil { + return err } - case "value": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.Value = ptr.String(jtv) + case "style": + if err := awsRestjson1_deserializeDocumentFormStyle(&sv.Style, value); err != nil { + return err + } + + case "tags": + if err := awsRestjson1_deserializeDocumentTags(&sv.Tags, value); err != nil { + return err } default: @@ -3363,7 +5433,7 @@ func awsRestjson1_deserializeDocumentComponentProperty(v **types.ComponentProper return nil } -func awsRestjson1_deserializeDocumentComponentPropertyBindingProperties(v **types.ComponentPropertyBindingProperties, value interface{}) error { +func awsRestjson1_deserializeDocumentFormBindingElement(v **types.FormBindingElement, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3376,22 +5446,22 @@ func awsRestjson1_deserializeDocumentComponentPropertyBindingProperties(v **type return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ComponentPropertyBindingProperties + var sv *types.FormBindingElement if *v == nil { - sv = &types.ComponentPropertyBindingProperties{} + sv = &types.FormBindingElement{} } else { sv = *v } for key, value := range shape { switch key { - case "field": + case "element": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Field = ptr.String(jtv) + sv.Element = ptr.String(jtv) } case "property": @@ -3412,7 +5482,7 @@ func awsRestjson1_deserializeDocumentComponentPropertyBindingProperties(v **type return nil } -func awsRestjson1_deserializeDocumentComponentPropertyList(v *[]types.ComponentProperty, value interface{}) error { +func awsRestjson1_deserializeDocumentFormBindings(v *map[string]types.FormBindingElement, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3420,33 +5490,34 @@ func awsRestjson1_deserializeDocumentComponentPropertyList(v *[]types.ComponentP return nil } - shape, ok := value.([]interface{}) + shape, ok := value.(map[string]interface{}) if !ok { return fmt.Errorf("unexpected JSON type %v", value) } - var cv []types.ComponentProperty + var mv map[string]types.FormBindingElement if *v == nil { - cv = []types.ComponentProperty{} + mv = map[string]types.FormBindingElement{} } else { - cv = *v + mv = *v } - for _, value := range shape { - var col types.ComponentProperty - destAddr := &col - if err := awsRestjson1_deserializeDocumentComponentProperty(&destAddr, value); err != nil { + for key, value := range shape { + var parsedVal types.FormBindingElement + mapVar := parsedVal + destAddr := &mapVar + if err := awsRestjson1_deserializeDocumentFormBindingElement(&destAddr, value); err != nil { return err } - col = *destAddr - cv = append(cv, col) + parsedVal = *destAddr + mv[key] = parsedVal } - *v = cv + *v = mv return nil } -func awsRestjson1_deserializeDocumentComponentSummary(v **types.ComponentSummary, value interface{}) error { +func awsRestjson1_deserializeDocumentFormButton(v **types.FormButton, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3459,58 +5530,180 @@ func awsRestjson1_deserializeDocumentComponentSummary(v **types.ComponentSummary return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ComponentSummary + var sv *types.FormButton if *v == nil { - sv = &types.ComponentSummary{} + sv = &types.FormButton{} } else { sv = *v } for key, value := range shape { switch key { - case "appId": + case "children": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.AppId = ptr.String(jtv) + sv.Children = ptr.String(jtv) } - case "componentType": + case "excluded": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected Boolean to be of type *bool, got %T instead", value) + } + sv.Excluded = ptr.Bool(jtv) + } + + case "position": + if err := awsRestjson1_deserializeDocumentFieldPosition(&sv.Position, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentFormCTA(v **types.FormCTA, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.FormCTA + if *v == nil { + sv = &types.FormCTA{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "cancel": + if err := awsRestjson1_deserializeDocumentFormButton(&sv.Cancel, value); err != nil { + return err + } + + case "clear": + if err := awsRestjson1_deserializeDocumentFormButton(&sv.Clear, value); err != nil { + return err + } + + case "position": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ComponentType to be of type string, got %T instead", value) + return fmt.Errorf("expected FormButtonsPosition to be of type string, got %T instead", value) } - sv.ComponentType = ptr.String(jtv) + sv.Position = types.FormButtonsPosition(jtv) } - case "environmentName": + case "submit": + if err := awsRestjson1_deserializeDocumentFormButton(&sv.Submit, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentFormDataTypeConfig(v **types.FormDataTypeConfig, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.FormDataTypeConfig + if *v == nil { + sv = &types.FormDataTypeConfig{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "dataSourceType": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) + return fmt.Errorf("expected FormDataSourceType to be of type string, got %T instead", value) } - sv.EnvironmentName = ptr.String(jtv) + sv.DataSourceType = types.FormDataSourceType(jtv) } - case "id": + case "dataTypeName": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected Uuid to be of type string, got %T instead", value) + return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Id = ptr.String(jtv) + sv.DataTypeName = ptr.String(jtv) } - case "name": + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentFormInputValueProperty(v **types.FormInputValueProperty, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.FormInputValueProperty + if *v == nil { + sv = &types.FormInputValueProperty{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "value": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ComponentName to be of type string, got %T instead", value) + return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Name = ptr.String(jtv) + sv.Value = ptr.String(jtv) } default: @@ -3522,7 +5715,7 @@ func awsRestjson1_deserializeDocumentComponentSummary(v **types.ComponentSummary return nil } -func awsRestjson1_deserializeDocumentComponentSummaryList(v *[]types.ComponentSummary, value interface{}) error { +func awsRestjson1_deserializeDocumentFormList(v *[]types.Form, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3535,17 +5728,17 @@ func awsRestjson1_deserializeDocumentComponentSummaryList(v *[]types.ComponentSu return fmt.Errorf("unexpected JSON type %v", value) } - var cv []types.ComponentSummary + var cv []types.Form if *v == nil { - cv = []types.ComponentSummary{} + cv = []types.Form{} } else { cv = *v } for _, value := range shape { - var col types.ComponentSummary + var col types.Form destAddr := &col - if err := awsRestjson1_deserializeDocumentComponentSummary(&destAddr, value); err != nil { + if err := awsRestjson1_deserializeDocumentForm(&destAddr, value); err != nil { return err } col = *destAddr @@ -3556,7 +5749,7 @@ func awsRestjson1_deserializeDocumentComponentSummaryList(v *[]types.ComponentSu return nil } -func awsRestjson1_deserializeDocumentComponentVariant(v **types.ComponentVariant, value interface{}) error { +func awsRestjson1_deserializeDocumentFormStyle(v **types.FormStyle, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3569,22 +5762,27 @@ func awsRestjson1_deserializeDocumentComponentVariant(v **types.ComponentVariant return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ComponentVariant + var sv *types.FormStyle if *v == nil { - sv = &types.ComponentVariant{} + sv = &types.FormStyle{} } else { sv = *v } for key, value := range shape { switch key { - case "overrides": - if err := awsRestjson1_deserializeDocumentComponentOverrides(&sv.Overrides, value); err != nil { + case "horizontalGap": + if err := awsRestjson1_deserializeDocumentFormStyleConfig(&sv.HorizontalGap, value); err != nil { return err } - case "variantValues": - if err := awsRestjson1_deserializeDocumentComponentVariantValues(&sv.VariantValues, value); err != nil { + case "outerPadding": + if err := awsRestjson1_deserializeDocumentFormStyleConfig(&sv.OuterPadding, value); err != nil { + return err + } + + case "verticalGap": + if err := awsRestjson1_deserializeDocumentFormStyleConfig(&sv.VerticalGap, value); err != nil { return err } @@ -3597,7 +5795,7 @@ func awsRestjson1_deserializeDocumentComponentVariant(v **types.ComponentVariant return nil } -func awsRestjson1_deserializeDocumentComponentVariants(v *[]types.ComponentVariant, value interface{}) error { +func awsRestjson1_deserializeDocumentFormStyleConfig(v *types.FormStyleConfig, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3605,69 +5803,53 @@ func awsRestjson1_deserializeDocumentComponentVariants(v *[]types.ComponentVaria return nil } - shape, ok := value.([]interface{}) + shape, ok := value.(map[string]interface{}) if !ok { return fmt.Errorf("unexpected JSON type %v", value) } - var cv []types.ComponentVariant - if *v == nil { - cv = []types.ComponentVariant{} - } else { - cv = *v - } - - for _, value := range shape { - var col types.ComponentVariant - destAddr := &col - if err := awsRestjson1_deserializeDocumentComponentVariant(&destAddr, value); err != nil { - return err + var uv types.FormStyleConfig +loop: + for key, value := range shape { + if value == nil { + continue } - col = *destAddr - cv = append(cv, col) - - } - *v = cv - return nil -} - -func awsRestjson1_deserializeDocumentComponentVariantValues(v *map[string]string, value interface{}) error { - if v == nil { - return fmt.Errorf("unexpected nil of type %T", v) - } - if value == nil { - return nil - } + switch key { + case "tokenReference": + var mv string + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + mv = jtv + } + uv = &types.FormStyleConfigMemberTokenReference{Value: mv} + break loop - shape, ok := value.(map[string]interface{}) - if !ok { - return fmt.Errorf("unexpected JSON type %v", value) - } + case "value": + var mv string + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + mv = jtv + } + uv = &types.FormStyleConfigMemberValue{Value: mv} + break loop - var mv map[string]string - if *v == nil { - mv = map[string]string{} - } else { - mv = *v - } + default: + uv = &types.UnknownUnionMember{Tag: key} + break loop - for key, value := range shape { - var parsedVal string - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - parsedVal = jtv } - mv[key] = parsedVal - } - *v = mv + *v = uv return nil } -func awsRestjson1_deserializeDocumentFormBindingElement(v **types.FormBindingElement, value interface{}) error { +func awsRestjson1_deserializeDocumentFormSummary(v **types.FormSummary, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3680,31 +5862,63 @@ func awsRestjson1_deserializeDocumentFormBindingElement(v **types.FormBindingEle return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.FormBindingElement + var sv *types.FormSummary if *v == nil { - sv = &types.FormBindingElement{} + sv = &types.FormSummary{} } else { sv = *v } for key, value := range shape { switch key { - case "element": + case "appId": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Element = ptr.String(jtv) + sv.AppId = ptr.String(jtv) } - case "property": + case "dataType": + if err := awsRestjson1_deserializeDocumentFormDataTypeConfig(&sv.DataType, value); err != nil { + return err + } + + case "environmentName": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Property = ptr.String(jtv) + sv.EnvironmentName = ptr.String(jtv) + } + + case "formActionType": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected FormActionType to be of type string, got %T instead", value) + } + sv.FormActionType = types.FormActionType(jtv) + } + + case "id": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Uuid to be of type string, got %T instead", value) + } + sv.Id = ptr.String(jtv) + } + + case "name": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected FormName to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) } default: @@ -3716,7 +5930,7 @@ func awsRestjson1_deserializeDocumentFormBindingElement(v **types.FormBindingEle return nil } -func awsRestjson1_deserializeDocumentFormBindings(v *map[string]types.FormBindingElement, value interface{}) error { +func awsRestjson1_deserializeDocumentFormSummaryList(v *[]types.FormSummary, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3724,30 +5938,29 @@ func awsRestjson1_deserializeDocumentFormBindings(v *map[string]types.FormBindin return nil } - shape, ok := value.(map[string]interface{}) + shape, ok := value.([]interface{}) if !ok { return fmt.Errorf("unexpected JSON type %v", value) } - var mv map[string]types.FormBindingElement + var cv []types.FormSummary if *v == nil { - mv = map[string]types.FormBindingElement{} + cv = []types.FormSummary{} } else { - mv = *v + cv = *v } - for key, value := range shape { - var parsedVal types.FormBindingElement - mapVar := parsedVal - destAddr := &mapVar - if err := awsRestjson1_deserializeDocumentFormBindingElement(&destAddr, value); err != nil { + for _, value := range shape { + var col types.FormSummary + destAddr := &col + if err := awsRestjson1_deserializeDocumentFormSummary(&destAddr, value); err != nil { return err } - parsedVal = *destAddr - mv[key] = parsedVal + col = *destAddr + cv = append(cv, col) } - *v = mv + *v = cv return nil } @@ -3921,6 +6134,46 @@ func awsRestjson1_deserializeDocumentMutationActionSetStateParameter(v **types.M return nil } +func awsRestjson1_deserializeDocumentNumValues(v *[]int32, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []int32 + if *v == nil { + cv = []int32{} + } else { + cv = *v + } + + for _, value := range shape { + var col int32 + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected Integer to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + col = int32(i64) + } + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsRestjson1_deserializeDocumentPredicate(v **types.Predicate, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -4038,20 +6291,136 @@ func awsRestjson1_deserializeDocumentResourceConflictException(v **types.Resourc var sv *types.ResourceConflictException if *v == nil { - sv = &types.ResourceConflictException{} + sv = &types.ResourceConflictException{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "message": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Message = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentResourceNotFoundException(v **types.ResourceNotFoundException, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ResourceNotFoundException + if *v == nil { + sv = &types.ResourceNotFoundException{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "message": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Message = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentSectionalElement(v **types.SectionalElement, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.SectionalElement + if *v == nil { + sv = &types.SectionalElement{} } else { sv = *v } for key, value := range shape { switch key { - case "message": + case "level": + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected Integer to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + sv.Level = ptr.Int32(int32(i64)) + } + + case "orientation": if value != nil { jtv, ok := value.(string) if !ok { return fmt.Errorf("expected String to be of type string, got %T instead", value) } - sv.Message = ptr.String(jtv) + sv.Orientation = ptr.String(jtv) + } + + case "position": + if err := awsRestjson1_deserializeDocumentFieldPosition(&sv.Position, value); err != nil { + return err + } + + case "text": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Text = ptr.String(jtv) + } + + case "type": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Type = ptr.String(jtv) } default: @@ -4063,7 +6432,7 @@ func awsRestjson1_deserializeDocumentResourceConflictException(v **types.Resourc return nil } -func awsRestjson1_deserializeDocumentResourceNotFoundException(v **types.ResourceNotFoundException, value interface{}) error { +func awsRestjson1_deserializeDocumentSectionalElementMap(v *map[string]types.SectionalElement, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -4076,30 +6445,25 @@ func awsRestjson1_deserializeDocumentResourceNotFoundException(v **types.Resourc return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ResourceNotFoundException + var mv map[string]types.SectionalElement if *v == nil { - sv = &types.ResourceNotFoundException{} + mv = map[string]types.SectionalElement{} } else { - sv = *v + mv = *v } for key, value := range shape { - switch key { - case "message": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected String to be of type string, got %T instead", value) - } - sv.Message = ptr.String(jtv) - } - - default: - _, _ = key, value - + var parsedVal types.SectionalElement + mapVar := parsedVal + destAddr := &mapVar + if err := awsRestjson1_deserializeDocumentSectionalElement(&destAddr, value); err != nil { + return err } + parsedVal = *destAddr + mv[key] = parsedVal + } - *v = sv + *v = mv return nil } @@ -4226,6 +6590,42 @@ func awsRestjson1_deserializeDocumentSortPropertyList(v *[]types.SortProperty, v return nil } +func awsRestjson1_deserializeDocumentStrValues(v *[]string, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []string + if *v == nil { + cv = []string{} + } else { + cv = *v + } + + for _, value := range shape { + var col string + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + col = jtv + } + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsRestjson1_deserializeDocumentTags(v *map[string]string, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -4628,3 +7028,188 @@ func awsRestjson1_deserializeDocumentThemeValuesList(v *[]types.ThemeValues, val *v = cv return nil } + +func awsRestjson1_deserializeDocumentUnauthorizedException(v **types.UnauthorizedException, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.UnauthorizedException + if *v == nil { + sv = &types.UnauthorizedException{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "message": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Message = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentValidationsList(v *[]types.FieldValidationConfiguration, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.FieldValidationConfiguration + if *v == nil { + cv = []types.FieldValidationConfiguration{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.FieldValidationConfiguration + destAddr := &col + if err := awsRestjson1_deserializeDocumentFieldValidationConfiguration(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsRestjson1_deserializeDocumentValueMapping(v **types.ValueMapping, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ValueMapping + if *v == nil { + sv = &types.ValueMapping{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "displayValue": + if err := awsRestjson1_deserializeDocumentFormInputValueProperty(&sv.DisplayValue, value); err != nil { + return err + } + + case "value": + if err := awsRestjson1_deserializeDocumentFormInputValueProperty(&sv.Value, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentValueMappingList(v *[]types.ValueMapping, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.ValueMapping + if *v == nil { + cv = []types.ValueMapping{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.ValueMapping + destAddr := &col + if err := awsRestjson1_deserializeDocumentValueMapping(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsRestjson1_deserializeDocumentValueMappings(v **types.ValueMappings, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ValueMappings + if *v == nil { + sv = &types.ValueMappings{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "values": + if err := awsRestjson1_deserializeDocumentValueMappingList(&sv.Values, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} diff --git a/service/amplifyuibuilder/generated.json b/service/amplifyuibuilder/generated.json index d4fa29d4ac4..ff1f0543379 100644 --- a/service/amplifyuibuilder/generated.json +++ b/service/amplifyuibuilder/generated.json @@ -9,18 +9,26 @@ "api_client.go", "api_client_test.go", "api_op_CreateComponent.go", + "api_op_CreateForm.go", "api_op_CreateTheme.go", "api_op_DeleteComponent.go", + "api_op_DeleteForm.go", "api_op_DeleteTheme.go", "api_op_ExchangeCodeForToken.go", "api_op_ExportComponents.go", + "api_op_ExportForms.go", "api_op_ExportThemes.go", "api_op_GetComponent.go", + "api_op_GetForm.go", + "api_op_GetMetadata.go", "api_op_GetTheme.go", "api_op_ListComponents.go", + "api_op_ListForms.go", "api_op_ListThemes.go", + "api_op_PutMetadataFlag.go", "api_op_RefreshToken.go", "api_op_UpdateComponent.go", + "api_op_UpdateForm.go", "api_op_UpdateTheme.go", "deserializers.go", "doc.go", @@ -33,6 +41,7 @@ "types/enums.go", "types/errors.go", "types/types.go", + "types/types_exported_test.go", "validators.go" ], "go": "1.15", diff --git a/service/amplifyuibuilder/serializers.go b/service/amplifyuibuilder/serializers.go index e8410640574..fffec025306 100644 --- a/service/amplifyuibuilder/serializers.go +++ b/service/amplifyuibuilder/serializers.go @@ -12,6 +12,7 @@ import ( smithyjson "github.com/aws/smithy-go/encoding/json" "github.com/aws/smithy-go/middleware" smithyhttp "github.com/aws/smithy-go/transport/http" + "math" ) type awsRestjson1_serializeOpCreateComponent struct { @@ -109,6 +110,101 @@ func awsRestjson1_serializeOpHttpBindingsCreateComponentInput(v *CreateComponent return nil } +type awsRestjson1_serializeOpCreateForm struct { +} + +func (*awsRestjson1_serializeOpCreateForm) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpCreateForm) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*CreateFormInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/forms") + request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) + request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) + request.Method = "POST" + restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if err := awsRestjson1_serializeOpHttpBindingsCreateFormInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if !restEncoder.HasHeader("Content-Type") { + ctx = smithyhttp.SetIsContentTypeDefaultValue(ctx, true) + restEncoder.SetHeader("Content-Type").String("application/json") + } + + if input.FormToCreate != nil { + jsonEncoder := smithyjson.NewEncoder() + if err := awsRestjson1_serializeDocumentCreateFormData(input.FormToCreate, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + payload := bytes.NewReader(jsonEncoder.Bytes()) + if request, err = request.SetStream(payload); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + } else { + jsonEncoder := smithyjson.NewEncoder() + jsonEncoder.Value.Object().Close() + payload := bytes.NewReader(jsonEncoder.Bytes()) + if request, err = request.SetStream(payload); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + } + + if request.Request, err = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsCreateFormInput(v *CreateFormInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + if v.AppId == nil || len(*v.AppId) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member appId must not be empty")} + } + if v.AppId != nil { + if err := encoder.SetURI("appId").String(*v.AppId); err != nil { + return err + } + } + + if v.ClientToken != nil { + encoder.SetQuery("clientToken").String(*v.ClientToken) + } + + if v.EnvironmentName == nil || len(*v.EnvironmentName) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member environmentName must not be empty")} + } + if v.EnvironmentName != nil { + if err := encoder.SetURI("environmentName").String(*v.EnvironmentName); err != nil { + return err + } + } + + return nil +} + type awsRestjson1_serializeOpCreateTheme struct { } @@ -280,6 +376,82 @@ func awsRestjson1_serializeOpHttpBindingsDeleteComponentInput(v *DeleteComponent return nil } +type awsRestjson1_serializeOpDeleteForm struct { +} + +func (*awsRestjson1_serializeOpDeleteForm) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpDeleteForm) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*DeleteFormInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/forms/{id}") + request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) + request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) + request.Method = "DELETE" + restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if err := awsRestjson1_serializeOpHttpBindingsDeleteFormInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsDeleteFormInput(v *DeleteFormInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + if v.AppId == nil || len(*v.AppId) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member appId must not be empty")} + } + if v.AppId != nil { + if err := encoder.SetURI("appId").String(*v.AppId); err != nil { + return err + } + } + + if v.EnvironmentName == nil || len(*v.EnvironmentName) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member environmentName must not be empty")} + } + if v.EnvironmentName != nil { + if err := encoder.SetURI("environmentName").String(*v.EnvironmentName); err != nil { + return err + } + } + + if v.Id == nil || len(*v.Id) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member id must not be empty")} + } + if v.Id != nil { + if err := encoder.SetURI("id").String(*v.Id); err != nil { + return err + } + } + + return nil +} + type awsRestjson1_serializeOpDeleteTheme struct { } @@ -509,14 +681,14 @@ func awsRestjson1_serializeOpHttpBindingsExportComponentsInput(v *ExportComponen return nil } -type awsRestjson1_serializeOpExportThemes struct { +type awsRestjson1_serializeOpExportForms struct { } -func (*awsRestjson1_serializeOpExportThemes) ID() string { +func (*awsRestjson1_serializeOpExportForms) ID() string { return "OperationSerializer" } -func (m *awsRestjson1_serializeOpExportThemes) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsRestjson1_serializeOpExportForms) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -524,13 +696,13 @@ func (m *awsRestjson1_serializeOpExportThemes) HandleSerialize(ctx context.Conte return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*ExportThemesInput) + input, ok := in.Parameters.(*ExportFormsInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} } - opPath, opQuery := httpbinding.SplitURI("/export/app/{appId}/environment/{environmentName}/themes") + opPath, opQuery := httpbinding.SplitURI("/export/app/{appId}/environment/{environmentName}/forms") request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) request.Method = "GET" @@ -539,7 +711,7 @@ func (m *awsRestjson1_serializeOpExportThemes) HandleSerialize(ctx context.Conte return out, metadata, &smithy.SerializationError{Err: err} } - if err := awsRestjson1_serializeOpHttpBindingsExportThemesInput(input, restEncoder); err != nil { + if err := awsRestjson1_serializeOpHttpBindingsExportFormsInput(input, restEncoder); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -550,7 +722,7 @@ func (m *awsRestjson1_serializeOpExportThemes) HandleSerialize(ctx context.Conte return next.HandleSerialize(ctx, in) } -func awsRestjson1_serializeOpHttpBindingsExportThemesInput(v *ExportThemesInput, encoder *httpbinding.Encoder) error { +func awsRestjson1_serializeOpHttpBindingsExportFormsInput(v *ExportFormsInput, encoder *httpbinding.Encoder) error { if v == nil { return fmt.Errorf("unsupported serialization of nil %T", v) } @@ -580,14 +752,14 @@ func awsRestjson1_serializeOpHttpBindingsExportThemesInput(v *ExportThemesInput, return nil } -type awsRestjson1_serializeOpGetComponent struct { +type awsRestjson1_serializeOpExportThemes struct { } -func (*awsRestjson1_serializeOpGetComponent) ID() string { +func (*awsRestjson1_serializeOpExportThemes) ID() string { return "OperationSerializer" } -func (m *awsRestjson1_serializeOpGetComponent) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsRestjson1_serializeOpExportThemes) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -595,13 +767,13 @@ func (m *awsRestjson1_serializeOpGetComponent) HandleSerialize(ctx context.Conte return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*GetComponentInput) + input, ok := in.Parameters.(*ExportThemesInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} } - opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/components/{id}") + opPath, opQuery := httpbinding.SplitURI("/export/app/{appId}/environment/{environmentName}/themes") request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) request.Method = "GET" @@ -610,7 +782,7 @@ func (m *awsRestjson1_serializeOpGetComponent) HandleSerialize(ctx context.Conte return out, metadata, &smithy.SerializationError{Err: err} } - if err := awsRestjson1_serializeOpHttpBindingsGetComponentInput(input, restEncoder); err != nil { + if err := awsRestjson1_serializeOpHttpBindingsExportThemesInput(input, restEncoder); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -621,7 +793,7 @@ func (m *awsRestjson1_serializeOpGetComponent) HandleSerialize(ctx context.Conte return next.HandleSerialize(ctx, in) } -func awsRestjson1_serializeOpHttpBindingsGetComponentInput(v *GetComponentInput, encoder *httpbinding.Encoder) error { +func awsRestjson1_serializeOpHttpBindingsExportThemesInput(v *ExportThemesInput, encoder *httpbinding.Encoder) error { if v == nil { return fmt.Errorf("unsupported serialization of nil %T", v) } @@ -644,26 +816,21 @@ func awsRestjson1_serializeOpHttpBindingsGetComponentInput(v *GetComponentInput, } } - if v.Id == nil || len(*v.Id) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member id must not be empty")} - } - if v.Id != nil { - if err := encoder.SetURI("id").String(*v.Id); err != nil { - return err - } + if v.NextToken != nil { + encoder.SetQuery("nextToken").String(*v.NextToken) } return nil } -type awsRestjson1_serializeOpGetTheme struct { +type awsRestjson1_serializeOpGetComponent struct { } -func (*awsRestjson1_serializeOpGetTheme) ID() string { +func (*awsRestjson1_serializeOpGetComponent) ID() string { return "OperationSerializer" } -func (m *awsRestjson1_serializeOpGetTheme) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsRestjson1_serializeOpGetComponent) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -671,13 +838,13 @@ func (m *awsRestjson1_serializeOpGetTheme) HandleSerialize(ctx context.Context, return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*GetThemeInput) + input, ok := in.Parameters.(*GetComponentInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} } - opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/themes/{id}") + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/components/{id}") request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) request.Method = "GET" @@ -686,7 +853,7 @@ func (m *awsRestjson1_serializeOpGetTheme) HandleSerialize(ctx context.Context, return out, metadata, &smithy.SerializationError{Err: err} } - if err := awsRestjson1_serializeOpHttpBindingsGetThemeInput(input, restEncoder); err != nil { + if err := awsRestjson1_serializeOpHttpBindingsGetComponentInput(input, restEncoder); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -697,7 +864,7 @@ func (m *awsRestjson1_serializeOpGetTheme) HandleSerialize(ctx context.Context, return next.HandleSerialize(ctx, in) } -func awsRestjson1_serializeOpHttpBindingsGetThemeInput(v *GetThemeInput, encoder *httpbinding.Encoder) error { +func awsRestjson1_serializeOpHttpBindingsGetComponentInput(v *GetComponentInput, encoder *httpbinding.Encoder) error { if v == nil { return fmt.Errorf("unsupported serialization of nil %T", v) } @@ -732,14 +899,14 @@ func awsRestjson1_serializeOpHttpBindingsGetThemeInput(v *GetThemeInput, encoder return nil } -type awsRestjson1_serializeOpListComponents struct { +type awsRestjson1_serializeOpGetForm struct { } -func (*awsRestjson1_serializeOpListComponents) ID() string { +func (*awsRestjson1_serializeOpGetForm) ID() string { return "OperationSerializer" } -func (m *awsRestjson1_serializeOpListComponents) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsRestjson1_serializeOpGetForm) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -747,13 +914,13 @@ func (m *awsRestjson1_serializeOpListComponents) HandleSerialize(ctx context.Con return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*ListComponentsInput) + input, ok := in.Parameters.(*GetFormInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} } - opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/components") + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/forms/{id}") request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) request.Method = "GET" @@ -762,7 +929,7 @@ func (m *awsRestjson1_serializeOpListComponents) HandleSerialize(ctx context.Con return out, metadata, &smithy.SerializationError{Err: err} } - if err := awsRestjson1_serializeOpHttpBindingsListComponentsInput(input, restEncoder); err != nil { + if err := awsRestjson1_serializeOpHttpBindingsGetFormInput(input, restEncoder); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -773,7 +940,7 @@ func (m *awsRestjson1_serializeOpListComponents) HandleSerialize(ctx context.Con return next.HandleSerialize(ctx, in) } -func awsRestjson1_serializeOpHttpBindingsListComponentsInput(v *ListComponentsInput, encoder *httpbinding.Encoder) error { +func awsRestjson1_serializeOpHttpBindingsGetFormInput(v *GetFormInput, encoder *httpbinding.Encoder) error { if v == nil { return fmt.Errorf("unsupported serialization of nil %T", v) } @@ -796,25 +963,26 @@ func awsRestjson1_serializeOpHttpBindingsListComponentsInput(v *ListComponentsIn } } - if v.MaxResults != 0 { - encoder.SetQuery("maxResults").Integer(v.MaxResults) + if v.Id == nil || len(*v.Id) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member id must not be empty")} } - - if v.NextToken != nil { - encoder.SetQuery("nextToken").String(*v.NextToken) + if v.Id != nil { + if err := encoder.SetURI("id").String(*v.Id); err != nil { + return err + } } return nil } -type awsRestjson1_serializeOpListThemes struct { +type awsRestjson1_serializeOpGetMetadata struct { } -func (*awsRestjson1_serializeOpListThemes) ID() string { +func (*awsRestjson1_serializeOpGetMetadata) ID() string { return "OperationSerializer" } -func (m *awsRestjson1_serializeOpListThemes) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsRestjson1_serializeOpGetMetadata) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -822,13 +990,13 @@ func (m *awsRestjson1_serializeOpListThemes) HandleSerialize(ctx context.Context return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*ListThemesInput) + input, ok := in.Parameters.(*GetMetadataInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} } - opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/themes") + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/metadata") request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) request.Method = "GET" @@ -837,7 +1005,7 @@ func (m *awsRestjson1_serializeOpListThemes) HandleSerialize(ctx context.Context return out, metadata, &smithy.SerializationError{Err: err} } - if err := awsRestjson1_serializeOpHttpBindingsListThemesInput(input, restEncoder); err != nil { + if err := awsRestjson1_serializeOpHttpBindingsGetMetadataInput(input, restEncoder); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -848,7 +1016,7 @@ func (m *awsRestjson1_serializeOpListThemes) HandleSerialize(ctx context.Context return next.HandleSerialize(ctx, in) } -func awsRestjson1_serializeOpHttpBindingsListThemesInput(v *ListThemesInput, encoder *httpbinding.Encoder) error { +func awsRestjson1_serializeOpHttpBindingsGetMetadataInput(v *GetMetadataInput, encoder *httpbinding.Encoder) error { if v == nil { return fmt.Errorf("unsupported serialization of nil %T", v) } @@ -871,25 +1039,17 @@ func awsRestjson1_serializeOpHttpBindingsListThemesInput(v *ListThemesInput, enc } } - if v.MaxResults != 0 { - encoder.SetQuery("maxResults").Integer(v.MaxResults) - } - - if v.NextToken != nil { - encoder.SetQuery("nextToken").String(*v.NextToken) - } - return nil } -type awsRestjson1_serializeOpRefreshToken struct { +type awsRestjson1_serializeOpGetTheme struct { } -func (*awsRestjson1_serializeOpRefreshToken) ID() string { +func (*awsRestjson1_serializeOpGetTheme) ID() string { return "OperationSerializer" } -func (m *awsRestjson1_serializeOpRefreshToken) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsRestjson1_serializeOpGetTheme) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -897,47 +1057,99 @@ func (m *awsRestjson1_serializeOpRefreshToken) HandleSerialize(ctx context.Conte return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*RefreshTokenInput) + input, ok := in.Parameters.(*GetThemeInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} } - opPath, opQuery := httpbinding.SplitURI("/tokens/{provider}/refresh") + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/themes/{id}") request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) - request.Method = "POST" + request.Method = "GET" restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) if err != nil { return out, metadata, &smithy.SerializationError{Err: err} } - if err := awsRestjson1_serializeOpHttpBindingsRefreshTokenInput(input, restEncoder); err != nil { + if err := awsRestjson1_serializeOpHttpBindingsGetThemeInput(input, restEncoder); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } - if !restEncoder.HasHeader("Content-Type") { - ctx = smithyhttp.SetIsContentTypeDefaultValue(ctx, true) - restEncoder.SetHeader("Content-Type").String("application/json") + if request.Request, err = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} } + in.Request = request - if input.RefreshTokenBody != nil { - jsonEncoder := smithyjson.NewEncoder() - if err := awsRestjson1_serializeDocumentRefreshTokenRequestBody(input.RefreshTokenBody, jsonEncoder.Value); err != nil { - return out, metadata, &smithy.SerializationError{Err: err} + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsGetThemeInput(v *GetThemeInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + if v.AppId == nil || len(*v.AppId) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member appId must not be empty")} + } + if v.AppId != nil { + if err := encoder.SetURI("appId").String(*v.AppId); err != nil { + return err } - payload := bytes.NewReader(jsonEncoder.Bytes()) - if request, err = request.SetStream(payload); err != nil { - return out, metadata, &smithy.SerializationError{Err: err} + } + + if v.EnvironmentName == nil || len(*v.EnvironmentName) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member environmentName must not be empty")} + } + if v.EnvironmentName != nil { + if err := encoder.SetURI("environmentName").String(*v.EnvironmentName); err != nil { + return err } - } else { - jsonEncoder := smithyjson.NewEncoder() - jsonEncoder.Value.Object().Close() - payload := bytes.NewReader(jsonEncoder.Bytes()) - if request, err = request.SetStream(payload); err != nil { - return out, metadata, &smithy.SerializationError{Err: err} + } + + if v.Id == nil || len(*v.Id) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member id must not be empty")} + } + if v.Id != nil { + if err := encoder.SetURI("id").String(*v.Id); err != nil { + return err } + } + + return nil +} + +type awsRestjson1_serializeOpListComponents struct { +} + +func (*awsRestjson1_serializeOpListComponents) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpListComponents) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*ListComponentsInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/components") + request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) + request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) + request.Method = "GET" + restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + if err := awsRestjson1_serializeOpHttpBindingsListComponentsInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} } if request.Request, err = restEncoder.Encode(request.Request); err != nil { @@ -947,31 +1159,48 @@ func (m *awsRestjson1_serializeOpRefreshToken) HandleSerialize(ctx context.Conte return next.HandleSerialize(ctx, in) } -func awsRestjson1_serializeOpHttpBindingsRefreshTokenInput(v *RefreshTokenInput, encoder *httpbinding.Encoder) error { +func awsRestjson1_serializeOpHttpBindingsListComponentsInput(v *ListComponentsInput, encoder *httpbinding.Encoder) error { if v == nil { return fmt.Errorf("unsupported serialization of nil %T", v) } - if len(v.Provider) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member provider must not be empty")} + if v.AppId == nil || len(*v.AppId) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member appId must not be empty")} } - if len(v.Provider) > 0 { - if err := encoder.SetURI("provider").String(string(v.Provider)); err != nil { + if v.AppId != nil { + if err := encoder.SetURI("appId").String(*v.AppId); err != nil { + return err + } + } + + if v.EnvironmentName == nil || len(*v.EnvironmentName) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member environmentName must not be empty")} + } + if v.EnvironmentName != nil { + if err := encoder.SetURI("environmentName").String(*v.EnvironmentName); err != nil { return err } } + if v.MaxResults != 0 { + encoder.SetQuery("maxResults").Integer(v.MaxResults) + } + + if v.NextToken != nil { + encoder.SetQuery("nextToken").String(*v.NextToken) + } + return nil } -type awsRestjson1_serializeOpUpdateComponent struct { +type awsRestjson1_serializeOpListForms struct { } -func (*awsRestjson1_serializeOpUpdateComponent) ID() string { +func (*awsRestjson1_serializeOpListForms) ID() string { return "OperationSerializer" } -func (m *awsRestjson1_serializeOpUpdateComponent) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsRestjson1_serializeOpListForms) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -979,47 +1208,98 @@ func (m *awsRestjson1_serializeOpUpdateComponent) HandleSerialize(ctx context.Co return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*UpdateComponentInput) + input, ok := in.Parameters.(*ListFormsInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} } - opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/components/{id}") + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/forms") request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) - request.Method = "PATCH" + request.Method = "GET" restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) if err != nil { return out, metadata, &smithy.SerializationError{Err: err} } - if err := awsRestjson1_serializeOpHttpBindingsUpdateComponentInput(input, restEncoder); err != nil { + if err := awsRestjson1_serializeOpHttpBindingsListFormsInput(input, restEncoder); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } - if !restEncoder.HasHeader("Content-Type") { - ctx = smithyhttp.SetIsContentTypeDefaultValue(ctx, true) - restEncoder.SetHeader("Content-Type").String("application/json") + if request.Request, err = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} } + in.Request = request - if input.UpdatedComponent != nil { - jsonEncoder := smithyjson.NewEncoder() - if err := awsRestjson1_serializeDocumentUpdateComponentData(input.UpdatedComponent, jsonEncoder.Value); err != nil { - return out, metadata, &smithy.SerializationError{Err: err} - } - payload := bytes.NewReader(jsonEncoder.Bytes()) - if request, err = request.SetStream(payload); err != nil { - return out, metadata, &smithy.SerializationError{Err: err} + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsListFormsInput(v *ListFormsInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + if v.AppId == nil || len(*v.AppId) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member appId must not be empty")} + } + if v.AppId != nil { + if err := encoder.SetURI("appId").String(*v.AppId); err != nil { + return err } - } else { - jsonEncoder := smithyjson.NewEncoder() - jsonEncoder.Value.Object().Close() - payload := bytes.NewReader(jsonEncoder.Bytes()) - if request, err = request.SetStream(payload); err != nil { - return out, metadata, &smithy.SerializationError{Err: err} + } + + if v.EnvironmentName == nil || len(*v.EnvironmentName) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member environmentName must not be empty")} + } + if v.EnvironmentName != nil { + if err := encoder.SetURI("environmentName").String(*v.EnvironmentName); err != nil { + return err } + } + + if v.MaxResults != 0 { + encoder.SetQuery("maxResults").Integer(v.MaxResults) + } + + if v.NextToken != nil { + encoder.SetQuery("nextToken").String(*v.NextToken) + } + + return nil +} + +type awsRestjson1_serializeOpListThemes struct { +} + +func (*awsRestjson1_serializeOpListThemes) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpListThemes) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + input, ok := in.Parameters.(*ListThemesInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/themes") + request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) + request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) + request.Method = "GET" + restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if err := awsRestjson1_serializeOpHttpBindingsListThemesInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} } if request.Request, err = restEncoder.Encode(request.Request); err != nil { @@ -1029,7 +1309,7 @@ func (m *awsRestjson1_serializeOpUpdateComponent) HandleSerialize(ctx context.Co return next.HandleSerialize(ctx, in) } -func awsRestjson1_serializeOpHttpBindingsUpdateComponentInput(v *UpdateComponentInput, encoder *httpbinding.Encoder) error { +func awsRestjson1_serializeOpHttpBindingsListThemesInput(v *ListThemesInput, encoder *httpbinding.Encoder) error { if v == nil { return fmt.Errorf("unsupported serialization of nil %T", v) } @@ -1043,10 +1323,6 @@ func awsRestjson1_serializeOpHttpBindingsUpdateComponentInput(v *UpdateComponent } } - if v.ClientToken != nil { - encoder.SetQuery("clientToken").String(*v.ClientToken) - } - if v.EnvironmentName == nil || len(*v.EnvironmentName) == 0 { return &smithy.SerializationError{Err: fmt.Errorf("input member environmentName must not be empty")} } @@ -1056,26 +1332,25 @@ func awsRestjson1_serializeOpHttpBindingsUpdateComponentInput(v *UpdateComponent } } - if v.Id == nil || len(*v.Id) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member id must not be empty")} + if v.MaxResults != 0 { + encoder.SetQuery("maxResults").Integer(v.MaxResults) } - if v.Id != nil { - if err := encoder.SetURI("id").String(*v.Id); err != nil { - return err - } + + if v.NextToken != nil { + encoder.SetQuery("nextToken").String(*v.NextToken) } return nil } -type awsRestjson1_serializeOpUpdateTheme struct { +type awsRestjson1_serializeOpPutMetadataFlag struct { } -func (*awsRestjson1_serializeOpUpdateTheme) ID() string { +func (*awsRestjson1_serializeOpPutMetadataFlag) ID() string { return "OperationSerializer" } -func (m *awsRestjson1_serializeOpUpdateTheme) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsRestjson1_serializeOpPutMetadataFlag) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -1083,22 +1358,22 @@ func (m *awsRestjson1_serializeOpUpdateTheme) HandleSerialize(ctx context.Contex return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*UpdateThemeInput) + input, ok := in.Parameters.(*PutMetadataFlagInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} } - opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/themes/{id}") + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/metadata/features/{featureName}") request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) - request.Method = "PATCH" + request.Method = "PUT" restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) if err != nil { return out, metadata, &smithy.SerializationError{Err: err} } - if err := awsRestjson1_serializeOpHttpBindingsUpdateThemeInput(input, restEncoder); err != nil { + if err := awsRestjson1_serializeOpHttpBindingsPutMetadataFlagInput(input, restEncoder); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1107,9 +1382,9 @@ func (m *awsRestjson1_serializeOpUpdateTheme) HandleSerialize(ctx context.Contex restEncoder.SetHeader("Content-Type").String("application/json") } - if input.UpdatedTheme != nil { + if input.Body != nil { jsonEncoder := smithyjson.NewEncoder() - if err := awsRestjson1_serializeDocumentUpdateThemeData(input.UpdatedTheme, jsonEncoder.Value); err != nil { + if err := awsRestjson1_serializeDocumentPutMetadataFlagBody(input.Body, jsonEncoder.Value); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } payload := bytes.NewReader(jsonEncoder.Bytes()) @@ -1133,7 +1408,7 @@ func (m *awsRestjson1_serializeOpUpdateTheme) HandleSerialize(ctx context.Contex return next.HandleSerialize(ctx, in) } -func awsRestjson1_serializeOpHttpBindingsUpdateThemeInput(v *UpdateThemeInput, encoder *httpbinding.Encoder) error { +func awsRestjson1_serializeOpHttpBindingsPutMetadataFlagInput(v *PutMetadataFlagInput, encoder *httpbinding.Encoder) error { if v == nil { return fmt.Errorf("unsupported serialization of nil %T", v) } @@ -1147,10 +1422,6 @@ func awsRestjson1_serializeOpHttpBindingsUpdateThemeInput(v *UpdateThemeInput, e } } - if v.ClientToken != nil { - encoder.SetQuery("clientToken").String(*v.ClientToken) - } - if v.EnvironmentName == nil || len(*v.EnvironmentName) == 0 { return &smithy.SerializationError{Err: fmt.Errorf("input member environmentName must not be empty")} } @@ -1160,11 +1431,11 @@ func awsRestjson1_serializeOpHttpBindingsUpdateThemeInput(v *UpdateThemeInput, e } } - if v.Id == nil || len(*v.Id) == 0 { - return &smithy.SerializationError{Err: fmt.Errorf("input member id must not be empty")} + if v.FeatureName == nil || len(*v.FeatureName) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member featureName must not be empty")} } - if v.Id != nil { - if err := encoder.SetURI("id").String(*v.Id); err != nil { + if v.FeatureName != nil { + if err := encoder.SetURI("featureName").String(*v.FeatureName); err != nil { return err } } @@ -1172,34 +1443,678 @@ func awsRestjson1_serializeOpHttpBindingsUpdateThemeInput(v *UpdateThemeInput, e return nil } -func awsRestjson1_serializeDocumentActionParameters(v *types.ActionParameters, value smithyjson.Value) error { - object := value.Object() - defer object.Close() +type awsRestjson1_serializeOpRefreshToken struct { +} - if v.Anchor != nil { - ok := object.Key("anchor") - if err := awsRestjson1_serializeDocumentComponentProperty(v.Anchor, ok); err != nil { - return err - } - } +func (*awsRestjson1_serializeOpRefreshToken) ID() string { + return "OperationSerializer" +} - if v.Fields != nil { - ok := object.Key("fields") - if err := awsRestjson1_serializeDocumentComponentProperties(v.Fields, ok); err != nil { - return err - } +func (m *awsRestjson1_serializeOpRefreshToken) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - if v.Global != nil { - ok := object.Key("global") - if err := awsRestjson1_serializeDocumentComponentProperty(v.Global, ok); err != nil { + input, ok := in.Parameters.(*RefreshTokenInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/tokens/{provider}/refresh") + request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) + request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) + request.Method = "POST" + restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if err := awsRestjson1_serializeOpHttpBindingsRefreshTokenInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if !restEncoder.HasHeader("Content-Type") { + ctx = smithyhttp.SetIsContentTypeDefaultValue(ctx, true) + restEncoder.SetHeader("Content-Type").String("application/json") + } + + if input.RefreshTokenBody != nil { + jsonEncoder := smithyjson.NewEncoder() + if err := awsRestjson1_serializeDocumentRefreshTokenRequestBody(input.RefreshTokenBody, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + payload := bytes.NewReader(jsonEncoder.Bytes()) + if request, err = request.SetStream(payload); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + } else { + jsonEncoder := smithyjson.NewEncoder() + jsonEncoder.Value.Object().Close() + payload := bytes.NewReader(jsonEncoder.Bytes()) + if request, err = request.SetStream(payload); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + } + + if request.Request, err = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsRefreshTokenInput(v *RefreshTokenInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + if len(v.Provider) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member provider must not be empty")} + } + if len(v.Provider) > 0 { + if err := encoder.SetURI("provider").String(string(v.Provider)); err != nil { + return err + } + } + + return nil +} + +type awsRestjson1_serializeOpUpdateComponent struct { +} + +func (*awsRestjson1_serializeOpUpdateComponent) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpUpdateComponent) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*UpdateComponentInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/components/{id}") + request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) + request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) + request.Method = "PATCH" + restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if err := awsRestjson1_serializeOpHttpBindingsUpdateComponentInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if !restEncoder.HasHeader("Content-Type") { + ctx = smithyhttp.SetIsContentTypeDefaultValue(ctx, true) + restEncoder.SetHeader("Content-Type").String("application/json") + } + + if input.UpdatedComponent != nil { + jsonEncoder := smithyjson.NewEncoder() + if err := awsRestjson1_serializeDocumentUpdateComponentData(input.UpdatedComponent, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + payload := bytes.NewReader(jsonEncoder.Bytes()) + if request, err = request.SetStream(payload); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + } else { + jsonEncoder := smithyjson.NewEncoder() + jsonEncoder.Value.Object().Close() + payload := bytes.NewReader(jsonEncoder.Bytes()) + if request, err = request.SetStream(payload); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + } + + if request.Request, err = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsUpdateComponentInput(v *UpdateComponentInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + if v.AppId == nil || len(*v.AppId) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member appId must not be empty")} + } + if v.AppId != nil { + if err := encoder.SetURI("appId").String(*v.AppId); err != nil { + return err + } + } + + if v.ClientToken != nil { + encoder.SetQuery("clientToken").String(*v.ClientToken) + } + + if v.EnvironmentName == nil || len(*v.EnvironmentName) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member environmentName must not be empty")} + } + if v.EnvironmentName != nil { + if err := encoder.SetURI("environmentName").String(*v.EnvironmentName); err != nil { + return err + } + } + + if v.Id == nil || len(*v.Id) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member id must not be empty")} + } + if v.Id != nil { + if err := encoder.SetURI("id").String(*v.Id); err != nil { + return err + } + } + + return nil +} + +type awsRestjson1_serializeOpUpdateForm struct { +} + +func (*awsRestjson1_serializeOpUpdateForm) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpUpdateForm) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*UpdateFormInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/forms/{id}") + request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) + request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) + request.Method = "PATCH" + restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if err := awsRestjson1_serializeOpHttpBindingsUpdateFormInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if !restEncoder.HasHeader("Content-Type") { + ctx = smithyhttp.SetIsContentTypeDefaultValue(ctx, true) + restEncoder.SetHeader("Content-Type").String("application/json") + } + + if input.UpdatedForm != nil { + jsonEncoder := smithyjson.NewEncoder() + if err := awsRestjson1_serializeDocumentUpdateFormData(input.UpdatedForm, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + payload := bytes.NewReader(jsonEncoder.Bytes()) + if request, err = request.SetStream(payload); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + } else { + jsonEncoder := smithyjson.NewEncoder() + jsonEncoder.Value.Object().Close() + payload := bytes.NewReader(jsonEncoder.Bytes()) + if request, err = request.SetStream(payload); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + } + + if request.Request, err = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsUpdateFormInput(v *UpdateFormInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + if v.AppId == nil || len(*v.AppId) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member appId must not be empty")} + } + if v.AppId != nil { + if err := encoder.SetURI("appId").String(*v.AppId); err != nil { + return err + } + } + + if v.ClientToken != nil { + encoder.SetQuery("clientToken").String(*v.ClientToken) + } + + if v.EnvironmentName == nil || len(*v.EnvironmentName) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member environmentName must not be empty")} + } + if v.EnvironmentName != nil { + if err := encoder.SetURI("environmentName").String(*v.EnvironmentName); err != nil { + return err + } + } + + if v.Id == nil || len(*v.Id) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member id must not be empty")} + } + if v.Id != nil { + if err := encoder.SetURI("id").String(*v.Id); err != nil { + return err + } + } + + return nil +} + +type awsRestjson1_serializeOpUpdateTheme struct { +} + +func (*awsRestjson1_serializeOpUpdateTheme) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpUpdateTheme) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*UpdateThemeInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/app/{appId}/environment/{environmentName}/themes/{id}") + request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) + request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) + request.Method = "PATCH" + restEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if err := awsRestjson1_serializeOpHttpBindingsUpdateThemeInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if !restEncoder.HasHeader("Content-Type") { + ctx = smithyhttp.SetIsContentTypeDefaultValue(ctx, true) + restEncoder.SetHeader("Content-Type").String("application/json") + } + + if input.UpdatedTheme != nil { + jsonEncoder := smithyjson.NewEncoder() + if err := awsRestjson1_serializeDocumentUpdateThemeData(input.UpdatedTheme, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + payload := bytes.NewReader(jsonEncoder.Bytes()) + if request, err = request.SetStream(payload); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + } else { + jsonEncoder := smithyjson.NewEncoder() + jsonEncoder.Value.Object().Close() + payload := bytes.NewReader(jsonEncoder.Bytes()) + if request, err = request.SetStream(payload); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + } + + if request.Request, err = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsUpdateThemeInput(v *UpdateThemeInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + if v.AppId == nil || len(*v.AppId) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member appId must not be empty")} + } + if v.AppId != nil { + if err := encoder.SetURI("appId").String(*v.AppId); err != nil { + return err + } + } + + if v.ClientToken != nil { + encoder.SetQuery("clientToken").String(*v.ClientToken) + } + + if v.EnvironmentName == nil || len(*v.EnvironmentName) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member environmentName must not be empty")} + } + if v.EnvironmentName != nil { + if err := encoder.SetURI("environmentName").String(*v.EnvironmentName); err != nil { + return err + } + } + + if v.Id == nil || len(*v.Id) == 0 { + return &smithy.SerializationError{Err: fmt.Errorf("input member id must not be empty")} + } + if v.Id != nil { + if err := encoder.SetURI("id").String(*v.Id); err != nil { + return err + } + } + + return nil +} + +func awsRestjson1_serializeDocumentActionParameters(v *types.ActionParameters, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Anchor != nil { + ok := object.Key("anchor") + if err := awsRestjson1_serializeDocumentComponentProperty(v.Anchor, ok); err != nil { + return err + } + } + + if v.Fields != nil { + ok := object.Key("fields") + if err := awsRestjson1_serializeDocumentComponentProperties(v.Fields, ok); err != nil { + return err + } + } + + if v.Global != nil { + ok := object.Key("global") + if err := awsRestjson1_serializeDocumentComponentProperty(v.Global, ok); err != nil { + return err + } + } + + if v.Id != nil { + ok := object.Key("id") + if err := awsRestjson1_serializeDocumentComponentProperty(v.Id, ok); err != nil { + return err + } + } + + if v.Model != nil { + ok := object.Key("model") + ok.String(*v.Model) + } + + if v.State != nil { + ok := object.Key("state") + if err := awsRestjson1_serializeDocumentMutationActionSetStateParameter(v.State, ok); err != nil { + return err + } + } + + if v.Target != nil { + ok := object.Key("target") + if err := awsRestjson1_serializeDocumentComponentProperty(v.Target, ok); err != nil { + return err + } + } + + if v.Type != nil { + ok := object.Key("type") + if err := awsRestjson1_serializeDocumentComponentProperty(v.Type, ok); err != nil { + return err + } + } + + if v.Url != nil { + ok := object.Key("url") + if err := awsRestjson1_serializeDocumentComponentProperty(v.Url, ok); err != nil { + return err + } + } + + return nil +} + +func awsRestjson1_serializeDocumentComponentBindingProperties(v map[string]types.ComponentBindingPropertiesValue, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + for key := range v { + om := object.Key(key) + mapVar := v[key] + if err := awsRestjson1_serializeDocumentComponentBindingPropertiesValue(&mapVar, om); err != nil { + return err + } + } + return nil +} + +func awsRestjson1_serializeDocumentComponentBindingPropertiesValue(v *types.ComponentBindingPropertiesValue, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.BindingProperties != nil { + ok := object.Key("bindingProperties") + if err := awsRestjson1_serializeDocumentComponentBindingPropertiesValueProperties(v.BindingProperties, ok); err != nil { return err } } - if v.Id != nil { - ok := object.Key("id") - if err := awsRestjson1_serializeDocumentComponentProperty(v.Id, ok); err != nil { + if v.DefaultValue != nil { + ok := object.Key("defaultValue") + ok.String(*v.DefaultValue) + } + + if v.Type != nil { + ok := object.Key("type") + ok.String(*v.Type) + } + + return nil +} + +func awsRestjson1_serializeDocumentComponentBindingPropertiesValueProperties(v *types.ComponentBindingPropertiesValueProperties, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Bucket != nil { + ok := object.Key("bucket") + ok.String(*v.Bucket) + } + + if v.DefaultValue != nil { + ok := object.Key("defaultValue") + ok.String(*v.DefaultValue) + } + + if v.Field != nil { + ok := object.Key("field") + ok.String(*v.Field) + } + + if v.Key != nil { + ok := object.Key("key") + ok.String(*v.Key) + } + + if v.Model != nil { + ok := object.Key("model") + ok.String(*v.Model) + } + + if v.Predicates != nil { + ok := object.Key("predicates") + if err := awsRestjson1_serializeDocumentPredicateList(v.Predicates, ok); err != nil { + return err + } + } + + if v.SlotName != nil { + ok := object.Key("slotName") + ok.String(*v.SlotName) + } + + if v.UserAttribute != nil { + ok := object.Key("userAttribute") + ok.String(*v.UserAttribute) + } + + return nil +} + +func awsRestjson1_serializeDocumentComponentChild(v *types.ComponentChild, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Children != nil { + ok := object.Key("children") + if err := awsRestjson1_serializeDocumentComponentChildList(v.Children, ok); err != nil { + return err + } + } + + if v.ComponentType != nil { + ok := object.Key("componentType") + ok.String(*v.ComponentType) + } + + if v.Events != nil { + ok := object.Key("events") + if err := awsRestjson1_serializeDocumentComponentEvents(v.Events, ok); err != nil { + return err + } + } + + if v.Name != nil { + ok := object.Key("name") + ok.String(*v.Name) + } + + if v.Properties != nil { + ok := object.Key("properties") + if err := awsRestjson1_serializeDocumentComponentProperties(v.Properties, ok); err != nil { + return err + } + } + + if v.SourceId != nil { + ok := object.Key("sourceId") + ok.String(*v.SourceId) + } + + return nil +} + +func awsRestjson1_serializeDocumentComponentChildList(v []types.ComponentChild, value smithyjson.Value) error { + array := value.Array() + defer array.Close() + + for i := range v { + av := array.Value() + if err := awsRestjson1_serializeDocumentComponentChild(&v[i], av); err != nil { + return err + } + } + return nil +} + +func awsRestjson1_serializeDocumentComponentCollectionProperties(v map[string]types.ComponentDataConfiguration, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + for key := range v { + om := object.Key(key) + mapVar := v[key] + if err := awsRestjson1_serializeDocumentComponentDataConfiguration(&mapVar, om); err != nil { + return err + } + } + return nil +} + +func awsRestjson1_serializeDocumentComponentConditionProperty(v *types.ComponentConditionProperty, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Else != nil { + ok := object.Key("else") + if err := awsRestjson1_serializeDocumentComponentProperty(v.Else, ok); err != nil { + return err + } + } + + if v.Field != nil { + ok := object.Key("field") + ok.String(*v.Field) + } + + if v.Operand != nil { + ok := object.Key("operand") + ok.String(*v.Operand) + } + + if v.OperandType != nil { + ok := object.Key("operandType") + ok.String(*v.OperandType) + } + + if v.Operator != nil { + ok := object.Key("operator") + ok.String(*v.Operator) + } + + if v.Property != nil { + ok := object.Key("property") + ok.String(*v.Property) + } + + if v.Then != nil { + ok := object.Key("then") + if err := awsRestjson1_serializeDocumentComponentProperty(v.Then, ok); err != nil { + return err + } + } + + return nil +} + +func awsRestjson1_serializeDocumentComponentDataConfiguration(v *types.ComponentDataConfiguration, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Identifiers != nil { + ok := object.Key("identifiers") + if err := awsRestjson1_serializeDocumentIdentifierList(v.Identifiers, ok); err != nil { return err } } @@ -1209,123 +2124,280 @@ func awsRestjson1_serializeDocumentActionParameters(v *types.ActionParameters, v ok.String(*v.Model) } - if v.State != nil { - ok := object.Key("state") - if err := awsRestjson1_serializeDocumentMutationActionSetStateParameter(v.State, ok); err != nil { + if v.Predicate != nil { + ok := object.Key("predicate") + if err := awsRestjson1_serializeDocumentPredicate(v.Predicate, ok); err != nil { return err } } - if v.Target != nil { - ok := object.Key("target") - if err := awsRestjson1_serializeDocumentComponentProperty(v.Target, ok); err != nil { + if v.Sort != nil { + ok := object.Key("sort") + if err := awsRestjson1_serializeDocumentSortPropertyList(v.Sort, ok); err != nil { return err } } - if v.Type != nil { - ok := object.Key("type") - if err := awsRestjson1_serializeDocumentComponentProperty(v.Type, ok); err != nil { + return nil +} + +func awsRestjson1_serializeDocumentComponentEvent(v *types.ComponentEvent, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Action != nil { + ok := object.Key("action") + ok.String(*v.Action) + } + + if v.BindingEvent != nil { + ok := object.Key("bindingEvent") + ok.String(*v.BindingEvent) + } + + if v.Parameters != nil { + ok := object.Key("parameters") + if err := awsRestjson1_serializeDocumentActionParameters(v.Parameters, ok); err != nil { return err } } - if v.Url != nil { - ok := object.Key("url") - if err := awsRestjson1_serializeDocumentComponentProperty(v.Url, ok); err != nil { + return nil +} + +func awsRestjson1_serializeDocumentComponentEvents(v map[string]types.ComponentEvent, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + for key := range v { + om := object.Key(key) + mapVar := v[key] + if err := awsRestjson1_serializeDocumentComponentEvent(&mapVar, om); err != nil { + return err + } + } + return nil +} + +func awsRestjson1_serializeDocumentComponentOverrides(v map[string]map[string]string, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + for key := range v { + om := object.Key(key) + if vv := v[key]; vv == nil { + continue + } + if err := awsRestjson1_serializeDocumentComponentOverridesValue(v[key], om); err != nil { return err } } + return nil +} + +func awsRestjson1_serializeDocumentComponentOverridesValue(v map[string]string, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + for key := range v { + om := object.Key(key) + om.String(v[key]) + } return nil } -func awsRestjson1_serializeDocumentComponentBindingProperties(v map[string]types.ComponentBindingPropertiesValue, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentComponentProperties(v map[string]types.ComponentProperty, value smithyjson.Value) error { object := value.Object() defer object.Close() for key := range v { om := object.Key(key) mapVar := v[key] - if err := awsRestjson1_serializeDocumentComponentBindingPropertiesValue(&mapVar, om); err != nil { + if err := awsRestjson1_serializeDocumentComponentProperty(&mapVar, om); err != nil { return err } } return nil } -func awsRestjson1_serializeDocumentComponentBindingPropertiesValue(v *types.ComponentBindingPropertiesValue, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentComponentProperty(v *types.ComponentProperty, value smithyjson.Value) error { object := value.Object() defer object.Close() if v.BindingProperties != nil { ok := object.Key("bindingProperties") - if err := awsRestjson1_serializeDocumentComponentBindingPropertiesValueProperties(v.BindingProperties, ok); err != nil { + if err := awsRestjson1_serializeDocumentComponentPropertyBindingProperties(v.BindingProperties, ok); err != nil { + return err + } + } + + if v.Bindings != nil { + ok := object.Key("bindings") + if err := awsRestjson1_serializeDocumentFormBindings(v.Bindings, ok); err != nil { + return err + } + } + + if v.CollectionBindingProperties != nil { + ok := object.Key("collectionBindingProperties") + if err := awsRestjson1_serializeDocumentComponentPropertyBindingProperties(v.CollectionBindingProperties, ok); err != nil { + return err + } + } + + if v.ComponentName != nil { + ok := object.Key("componentName") + ok.String(*v.ComponentName) + } + + if v.Concat != nil { + ok := object.Key("concat") + if err := awsRestjson1_serializeDocumentComponentPropertyList(v.Concat, ok); err != nil { + return err + } + } + + if v.Condition != nil { + ok := object.Key("condition") + if err := awsRestjson1_serializeDocumentComponentConditionProperty(v.Condition, ok); err != nil { return err } } + if v.Configured != nil { + ok := object.Key("configured") + ok.Boolean(*v.Configured) + } + if v.DefaultValue != nil { ok := object.Key("defaultValue") ok.String(*v.DefaultValue) } + if v.Event != nil { + ok := object.Key("event") + ok.String(*v.Event) + } + + if v.ImportedValue != nil { + ok := object.Key("importedValue") + ok.String(*v.ImportedValue) + } + + if v.Model != nil { + ok := object.Key("model") + ok.String(*v.Model) + } + + if v.Property != nil { + ok := object.Key("property") + ok.String(*v.Property) + } + if v.Type != nil { ok := object.Key("type") ok.String(*v.Type) } + if v.UserAttribute != nil { + ok := object.Key("userAttribute") + ok.String(*v.UserAttribute) + } + + if v.Value != nil { + ok := object.Key("value") + ok.String(*v.Value) + } + return nil } -func awsRestjson1_serializeDocumentComponentBindingPropertiesValueProperties(v *types.ComponentBindingPropertiesValueProperties, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentComponentPropertyBindingProperties(v *types.ComponentPropertyBindingProperties, value smithyjson.Value) error { object := value.Object() defer object.Close() - if v.Bucket != nil { - ok := object.Key("bucket") - ok.String(*v.Bucket) - } - - if v.DefaultValue != nil { - ok := object.Key("defaultValue") - ok.String(*v.DefaultValue) - } - if v.Field != nil { ok := object.Key("field") ok.String(*v.Field) } - if v.Key != nil { - ok := object.Key("key") - ok.String(*v.Key) + if v.Property != nil { + ok := object.Key("property") + ok.String(*v.Property) } - if v.Model != nil { - ok := object.Key("model") - ok.String(*v.Model) + return nil +} + +func awsRestjson1_serializeDocumentComponentPropertyList(v []types.ComponentProperty, value smithyjson.Value) error { + array := value.Array() + defer array.Close() + + for i := range v { + av := array.Value() + if err := awsRestjson1_serializeDocumentComponentProperty(&v[i], av); err != nil { + return err + } } + return nil +} - if v.Predicates != nil { - ok := object.Key("predicates") - if err := awsRestjson1_serializeDocumentPredicateList(v.Predicates, ok); err != nil { +func awsRestjson1_serializeDocumentComponentVariant(v *types.ComponentVariant, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Overrides != nil { + ok := object.Key("overrides") + if err := awsRestjson1_serializeDocumentComponentOverrides(v.Overrides, ok); err != nil { return err } } - if v.UserAttribute != nil { - ok := object.Key("userAttribute") - ok.String(*v.UserAttribute) + if v.VariantValues != nil { + ok := object.Key("variantValues") + if err := awsRestjson1_serializeDocumentComponentVariantValues(v.VariantValues, ok); err != nil { + return err + } } return nil } -func awsRestjson1_serializeDocumentComponentChild(v *types.ComponentChild, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentComponentVariants(v []types.ComponentVariant, value smithyjson.Value) error { + array := value.Array() + defer array.Close() + + for i := range v { + av := array.Value() + if err := awsRestjson1_serializeDocumentComponentVariant(&v[i], av); err != nil { + return err + } + } + return nil +} + +func awsRestjson1_serializeDocumentComponentVariantValues(v map[string]string, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + for key := range v { + om := object.Key(key) + om.String(v[key]) + } + return nil +} + +func awsRestjson1_serializeDocumentCreateComponentData(v *types.CreateComponentData, value smithyjson.Value) error { object := value.Object() defer object.Close() + if v.BindingProperties != nil { + ok := object.Key("bindingProperties") + if err := awsRestjson1_serializeDocumentComponentBindingProperties(v.BindingProperties, ok); err != nil { + return err + } + } + if v.Children != nil { ok := object.Key("children") if err := awsRestjson1_serializeDocumentComponentChildList(v.Children, ok); err != nil { @@ -1333,6 +2405,13 @@ func awsRestjson1_serializeDocumentComponentChild(v *types.ComponentChild, value } } + if v.CollectionProperties != nil { + ok := object.Key("collectionProperties") + if err := awsRestjson1_serializeDocumentComponentCollectionProperties(v.CollectionProperties, ok); err != nil { + return err + } + } + if v.ComponentType != nil { ok := object.Key("componentType") ok.String(*v.ComponentType) @@ -1350,6 +2429,13 @@ func awsRestjson1_serializeDocumentComponentChild(v *types.ComponentChild, value ok.String(*v.Name) } + if v.Overrides != nil { + ok := object.Key("overrides") + if err := awsRestjson1_serializeDocumentComponentOverrides(v.Overrides, ok); err != nil { + return err + } + } + if v.Properties != nil { ok := object.Key("properties") if err := awsRestjson1_serializeDocumentComponentProperties(v.Properties, ok); err != nil { @@ -1357,80 +2443,90 @@ func awsRestjson1_serializeDocumentComponentChild(v *types.ComponentChild, value } } + if v.SchemaVersion != nil { + ok := object.Key("schemaVersion") + ok.String(*v.SchemaVersion) + } + if v.SourceId != nil { ok := object.Key("sourceId") ok.String(*v.SourceId) } - return nil -} - -func awsRestjson1_serializeDocumentComponentChildList(v []types.ComponentChild, value smithyjson.Value) error { - array := value.Array() - defer array.Close() + if v.Tags != nil { + ok := object.Key("tags") + if err := awsRestjson1_serializeDocumentTags(v.Tags, ok); err != nil { + return err + } + } - for i := range v { - av := array.Value() - if err := awsRestjson1_serializeDocumentComponentChild(&v[i], av); err != nil { + if v.Variants != nil { + ok := object.Key("variants") + if err := awsRestjson1_serializeDocumentComponentVariants(v.Variants, ok); err != nil { return err } } + return nil } -func awsRestjson1_serializeDocumentComponentCollectionProperties(v map[string]types.ComponentDataConfiguration, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentCreateFormData(v *types.CreateFormData, value smithyjson.Value) error { object := value.Object() defer object.Close() - for key := range v { - om := object.Key(key) - mapVar := v[key] - if err := awsRestjson1_serializeDocumentComponentDataConfiguration(&mapVar, om); err != nil { + if v.Cta != nil { + ok := object.Key("cta") + if err := awsRestjson1_serializeDocumentFormCTA(v.Cta, ok); err != nil { return err } } - return nil -} -func awsRestjson1_serializeDocumentComponentConditionProperty(v *types.ComponentConditionProperty, value smithyjson.Value) error { - object := value.Object() - defer object.Close() + if v.DataType != nil { + ok := object.Key("dataType") + if err := awsRestjson1_serializeDocumentFormDataTypeConfig(v.DataType, ok); err != nil { + return err + } + } - if v.Else != nil { - ok := object.Key("else") - if err := awsRestjson1_serializeDocumentComponentProperty(v.Else, ok); err != nil { + if v.Fields != nil { + ok := object.Key("fields") + if err := awsRestjson1_serializeDocumentFieldsMap(v.Fields, ok); err != nil { return err } } - if v.Field != nil { - ok := object.Key("field") - ok.String(*v.Field) + if len(v.FormActionType) > 0 { + ok := object.Key("formActionType") + ok.String(string(v.FormActionType)) } - if v.Operand != nil { - ok := object.Key("operand") - ok.String(*v.Operand) + if v.Name != nil { + ok := object.Key("name") + ok.String(*v.Name) } - if v.OperandType != nil { - ok := object.Key("operandType") - ok.String(*v.OperandType) + if v.SchemaVersion != nil { + ok := object.Key("schemaVersion") + ok.String(*v.SchemaVersion) } - if v.Operator != nil { - ok := object.Key("operator") - ok.String(*v.Operator) + if v.SectionalElements != nil { + ok := object.Key("sectionalElements") + if err := awsRestjson1_serializeDocumentSectionalElementMap(v.SectionalElements, ok); err != nil { + return err + } } - if v.Property != nil { - ok := object.Key("property") - ok.String(*v.Property) + if v.Style != nil { + ok := object.Key("style") + if err := awsRestjson1_serializeDocumentFormStyle(v.Style, ok); err != nil { + return err + } } - if v.Then != nil { - ok := object.Key("then") - if err := awsRestjson1_serializeDocumentComponentProperty(v.Then, ok); err != nil { + if v.Tags != nil { + ok := object.Key("tags") + if err := awsRestjson1_serializeDocumentTags(v.Tags, ok); err != nil { return err } } @@ -1438,32 +2534,32 @@ func awsRestjson1_serializeDocumentComponentConditionProperty(v *types.Component return nil } -func awsRestjson1_serializeDocumentComponentDataConfiguration(v *types.ComponentDataConfiguration, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentCreateThemeData(v *types.CreateThemeData, value smithyjson.Value) error { object := value.Object() defer object.Close() - if v.Identifiers != nil { - ok := object.Key("identifiers") - if err := awsRestjson1_serializeDocumentIdentifierList(v.Identifiers, ok); err != nil { - return err - } + if v.Name != nil { + ok := object.Key("name") + ok.String(*v.Name) } - if v.Model != nil { - ok := object.Key("model") - ok.String(*v.Model) + if v.Overrides != nil { + ok := object.Key("overrides") + if err := awsRestjson1_serializeDocumentThemeValuesList(v.Overrides, ok); err != nil { + return err + } } - if v.Predicate != nil { - ok := object.Key("predicate") - if err := awsRestjson1_serializeDocumentPredicate(v.Predicate, ok); err != nil { + if v.Tags != nil { + ok := object.Key("tags") + if err := awsRestjson1_serializeDocumentTags(v.Tags, ok); err != nil { return err } } - if v.Sort != nil { - ok := object.Key("sort") - if err := awsRestjson1_serializeDocumentSortPropertyList(v.Sort, ok); err != nil { + if v.Values != nil { + ok := object.Key("values") + if err := awsRestjson1_serializeDocumentThemeValuesList(v.Values, ok); err != nil { return err } } @@ -1471,157 +2567,157 @@ func awsRestjson1_serializeDocumentComponentDataConfiguration(v *types.Component return nil } -func awsRestjson1_serializeDocumentComponentEvent(v *types.ComponentEvent, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentExchangeCodeForTokenRequestBody(v *types.ExchangeCodeForTokenRequestBody, value smithyjson.Value) error { object := value.Object() defer object.Close() - if v.Action != nil { - ok := object.Key("action") - ok.String(*v.Action) - } - - if v.BindingEvent != nil { - ok := object.Key("bindingEvent") - ok.String(*v.BindingEvent) + if v.Code != nil { + ok := object.Key("code") + ok.String(*v.Code) } - if v.Parameters != nil { - ok := object.Key("parameters") - if err := awsRestjson1_serializeDocumentActionParameters(v.Parameters, ok); err != nil { - return err - } + if v.RedirectUri != nil { + ok := object.Key("redirectUri") + ok.String(*v.RedirectUri) } return nil } -func awsRestjson1_serializeDocumentComponentEvents(v map[string]types.ComponentEvent, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentFieldConfig(v *types.FieldConfig, value smithyjson.Value) error { object := value.Object() defer object.Close() - for key := range v { - om := object.Key(key) - mapVar := v[key] - if err := awsRestjson1_serializeDocumentComponentEvent(&mapVar, om); err != nil { - return err - } + if v.Excluded != nil { + ok := object.Key("excluded") + ok.Boolean(*v.Excluded) } - return nil -} - -func awsRestjson1_serializeDocumentComponentOverrides(v map[string]map[string]string, value smithyjson.Value) error { - object := value.Object() - defer object.Close() - for key := range v { - om := object.Key(key) - if vv := v[key]; vv == nil { - continue - } - if err := awsRestjson1_serializeDocumentComponentOverridesValue(v[key], om); err != nil { + if v.InputType != nil { + ok := object.Key("inputType") + if err := awsRestjson1_serializeDocumentFieldInputConfig(v.InputType, ok); err != nil { return err } } - return nil -} - -func awsRestjson1_serializeDocumentComponentOverridesValue(v map[string]string, value smithyjson.Value) error { - object := value.Object() - defer object.Close() - for key := range v { - om := object.Key(key) - om.String(v[key]) + if v.Label != nil { + ok := object.Key("label") + ok.String(*v.Label) } - return nil -} -func awsRestjson1_serializeDocumentComponentProperties(v map[string]types.ComponentProperty, value smithyjson.Value) error { - object := value.Object() - defer object.Close() + if v.Position != nil { + ok := object.Key("position") + if err := awsRestjson1_serializeDocumentFieldPosition(v.Position, ok); err != nil { + return err + } + } - for key := range v { - om := object.Key(key) - mapVar := v[key] - if err := awsRestjson1_serializeDocumentComponentProperty(&mapVar, om); err != nil { + if v.Validations != nil { + ok := object.Key("validations") + if err := awsRestjson1_serializeDocumentValidationsList(v.Validations, ok); err != nil { return err } } + return nil } -func awsRestjson1_serializeDocumentComponentProperty(v *types.ComponentProperty, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentFieldInputConfig(v *types.FieldInputConfig, value smithyjson.Value) error { object := value.Object() defer object.Close() - if v.BindingProperties != nil { - ok := object.Key("bindingProperties") - if err := awsRestjson1_serializeDocumentComponentPropertyBindingProperties(v.BindingProperties, ok); err != nil { - return err - } + if v.DefaultChecked != nil { + ok := object.Key("defaultChecked") + ok.Boolean(*v.DefaultChecked) } - if v.Bindings != nil { - ok := object.Key("bindings") - if err := awsRestjson1_serializeDocumentFormBindings(v.Bindings, ok); err != nil { - return err - } + if v.DefaultCountryCode != nil { + ok := object.Key("defaultCountryCode") + ok.String(*v.DefaultCountryCode) } - if v.CollectionBindingProperties != nil { - ok := object.Key("collectionBindingProperties") - if err := awsRestjson1_serializeDocumentComponentPropertyBindingProperties(v.CollectionBindingProperties, ok); err != nil { - return err - } + if v.DefaultValue != nil { + ok := object.Key("defaultValue") + ok.String(*v.DefaultValue) } - if v.ComponentName != nil { - ok := object.Key("componentName") - ok.String(*v.ComponentName) + if v.DescriptiveText != nil { + ok := object.Key("descriptiveText") + ok.String(*v.DescriptiveText) } - if v.Concat != nil { - ok := object.Key("concat") - if err := awsRestjson1_serializeDocumentComponentPropertyList(v.Concat, ok); err != nil { - return err + if v.MaxValue != nil { + ok := object.Key("maxValue") + switch { + case math.IsNaN(float64(*v.MaxValue)): + ok.String("NaN") + + case math.IsInf(float64(*v.MaxValue), 1): + ok.String("Infinity") + + case math.IsInf(float64(*v.MaxValue), -1): + ok.String("-Infinity") + + default: + ok.Float(*v.MaxValue) + } } - if v.Condition != nil { - ok := object.Key("condition") - if err := awsRestjson1_serializeDocumentComponentConditionProperty(v.Condition, ok); err != nil { - return err + if v.MinValue != nil { + ok := object.Key("minValue") + switch { + case math.IsNaN(float64(*v.MinValue)): + ok.String("NaN") + + case math.IsInf(float64(*v.MinValue), 1): + ok.String("Infinity") + + case math.IsInf(float64(*v.MinValue), -1): + ok.String("-Infinity") + + default: + ok.Float(*v.MinValue) + } } - if v.Configured != nil { - ok := object.Key("configured") - ok.Boolean(*v.Configured) + if v.Name != nil { + ok := object.Key("name") + ok.String(*v.Name) } - if v.DefaultValue != nil { - ok := object.Key("defaultValue") - ok.String(*v.DefaultValue) + if v.Placeholder != nil { + ok := object.Key("placeholder") + ok.String(*v.Placeholder) } - if v.Event != nil { - ok := object.Key("event") - ok.String(*v.Event) + if v.ReadOnly != nil { + ok := object.Key("readOnly") + ok.Boolean(*v.ReadOnly) } - if v.ImportedValue != nil { - ok := object.Key("importedValue") - ok.String(*v.ImportedValue) + if v.Required != nil { + ok := object.Key("required") + ok.Boolean(*v.Required) } - if v.Model != nil { - ok := object.Key("model") - ok.String(*v.Model) - } + if v.Step != nil { + ok := object.Key("step") + switch { + case math.IsNaN(float64(*v.Step)): + ok.String("NaN") - if v.Property != nil { - ok := object.Key("property") - ok.String(*v.Property) + case math.IsInf(float64(*v.Step), 1): + ok.String("Infinity") + + case math.IsInf(float64(*v.Step), -1): + ok.String("-Infinity") + + default: + ok.Float(*v.Step) + + } } if v.Type != nil { @@ -1629,170 +2725,138 @@ func awsRestjson1_serializeDocumentComponentProperty(v *types.ComponentProperty, ok.String(*v.Type) } - if v.UserAttribute != nil { - ok := object.Key("userAttribute") - ok.String(*v.UserAttribute) - } - if v.Value != nil { ok := object.Key("value") ok.String(*v.Value) } - return nil -} - -func awsRestjson1_serializeDocumentComponentPropertyBindingProperties(v *types.ComponentPropertyBindingProperties, value smithyjson.Value) error { - object := value.Object() - defer object.Close() - - if v.Field != nil { - ok := object.Key("field") - ok.String(*v.Field) - } - - if v.Property != nil { - ok := object.Key("property") - ok.String(*v.Property) - } - - return nil -} - -func awsRestjson1_serializeDocumentComponentPropertyList(v []types.ComponentProperty, value smithyjson.Value) error { - array := value.Array() - defer array.Close() - - for i := range v { - av := array.Value() - if err := awsRestjson1_serializeDocumentComponentProperty(&v[i], av); err != nil { + if v.ValueMappings != nil { + ok := object.Key("valueMappings") + if err := awsRestjson1_serializeDocumentValueMappings(v.ValueMappings, ok); err != nil { return err } } + return nil } -func awsRestjson1_serializeDocumentComponentVariant(v *types.ComponentVariant, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentFieldPosition(v types.FieldPosition, value smithyjson.Value) error { object := value.Object() defer object.Close() - if v.Overrides != nil { - ok := object.Key("overrides") - if err := awsRestjson1_serializeDocumentComponentOverrides(v.Overrides, ok); err != nil { - return err - } - } + switch uv := v.(type) { + case *types.FieldPositionMemberBelow: + av := object.Key("below") + av.String(uv.Value) - if v.VariantValues != nil { - ok := object.Key("variantValues") - if err := awsRestjson1_serializeDocumentComponentVariantValues(v.VariantValues, ok); err != nil { - return err - } - } + case *types.FieldPositionMemberFixed: + av := object.Key("fixed") + av.String(string(uv.Value)) - return nil -} + case *types.FieldPositionMemberRightOf: + av := object.Key("rightOf") + av.String(uv.Value) -func awsRestjson1_serializeDocumentComponentVariants(v []types.ComponentVariant, value smithyjson.Value) error { - array := value.Array() - defer array.Close() + default: + return fmt.Errorf("attempted to serialize unknown member type %T for union %T", uv, v) - for i := range v { - av := array.Value() - if err := awsRestjson1_serializeDocumentComponentVariant(&v[i], av); err != nil { - return err - } } return nil } -func awsRestjson1_serializeDocumentComponentVariantValues(v map[string]string, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentFieldsMap(v map[string]types.FieldConfig, value smithyjson.Value) error { object := value.Object() defer object.Close() for key := range v { om := object.Key(key) - om.String(v[key]) + mapVar := v[key] + if err := awsRestjson1_serializeDocumentFieldConfig(&mapVar, om); err != nil { + return err + } } return nil } -func awsRestjson1_serializeDocumentCreateComponentData(v *types.CreateComponentData, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentFieldValidationConfiguration(v *types.FieldValidationConfiguration, value smithyjson.Value) error { object := value.Object() defer object.Close() - if v.BindingProperties != nil { - ok := object.Key("bindingProperties") - if err := awsRestjson1_serializeDocumentComponentBindingProperties(v.BindingProperties, ok); err != nil { + if v.NumValues != nil { + ok := object.Key("numValues") + if err := awsRestjson1_serializeDocumentNumValues(v.NumValues, ok); err != nil { return err } } - if v.Children != nil { - ok := object.Key("children") - if err := awsRestjson1_serializeDocumentComponentChildList(v.Children, ok); err != nil { + if v.StrValues != nil { + ok := object.Key("strValues") + if err := awsRestjson1_serializeDocumentStrValues(v.StrValues, ok); err != nil { return err } } - if v.CollectionProperties != nil { - ok := object.Key("collectionProperties") - if err := awsRestjson1_serializeDocumentComponentCollectionProperties(v.CollectionProperties, ok); err != nil { - return err - } + if v.Type != nil { + ok := object.Key("type") + ok.String(*v.Type) } - if v.ComponentType != nil { - ok := object.Key("componentType") - ok.String(*v.ComponentType) + if v.ValidationMessage != nil { + ok := object.Key("validationMessage") + ok.String(*v.ValidationMessage) } - if v.Events != nil { - ok := object.Key("events") - if err := awsRestjson1_serializeDocumentComponentEvents(v.Events, ok); err != nil { - return err - } + return nil +} + +func awsRestjson1_serializeDocumentFormBindingElement(v *types.FormBindingElement, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Element != nil { + ok := object.Key("element") + ok.String(*v.Element) } - if v.Name != nil { - ok := object.Key("name") - ok.String(*v.Name) + if v.Property != nil { + ok := object.Key("property") + ok.String(*v.Property) } - if v.Overrides != nil { - ok := object.Key("overrides") - if err := awsRestjson1_serializeDocumentComponentOverrides(v.Overrides, ok); err != nil { - return err - } - } + return nil +} - if v.Properties != nil { - ok := object.Key("properties") - if err := awsRestjson1_serializeDocumentComponentProperties(v.Properties, ok); err != nil { +func awsRestjson1_serializeDocumentFormBindings(v map[string]types.FormBindingElement, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + for key := range v { + om := object.Key(key) + mapVar := v[key] + if err := awsRestjson1_serializeDocumentFormBindingElement(&mapVar, om); err != nil { return err } } + return nil +} - if v.SchemaVersion != nil { - ok := object.Key("schemaVersion") - ok.String(*v.SchemaVersion) - } +func awsRestjson1_serializeDocumentFormButton(v *types.FormButton, value smithyjson.Value) error { + object := value.Object() + defer object.Close() - if v.SourceId != nil { - ok := object.Key("sourceId") - ok.String(*v.SourceId) + if v.Children != nil { + ok := object.Key("children") + ok.String(*v.Children) } - if v.Tags != nil { - ok := object.Key("tags") - if err := awsRestjson1_serializeDocumentTags(v.Tags, ok); err != nil { - return err - } + if v.Excluded != nil { + ok := object.Key("excluded") + ok.Boolean(*v.Excluded) } - if v.Variants != nil { - ok := object.Key("variants") - if err := awsRestjson1_serializeDocumentComponentVariants(v.Variants, ok); err != nil { + if v.Position != nil { + ok := object.Key("position") + if err := awsRestjson1_serializeDocumentFieldPosition(v.Position, ok); err != nil { return err } } @@ -1800,32 +2864,32 @@ func awsRestjson1_serializeDocumentCreateComponentData(v *types.CreateComponentD return nil } -func awsRestjson1_serializeDocumentCreateThemeData(v *types.CreateThemeData, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentFormCTA(v *types.FormCTA, value smithyjson.Value) error { object := value.Object() defer object.Close() - if v.Name != nil { - ok := object.Key("name") - ok.String(*v.Name) - } - - if v.Overrides != nil { - ok := object.Key("overrides") - if err := awsRestjson1_serializeDocumentThemeValuesList(v.Overrides, ok); err != nil { + if v.Cancel != nil { + ok := object.Key("cancel") + if err := awsRestjson1_serializeDocumentFormButton(v.Cancel, ok); err != nil { return err } } - if v.Tags != nil { - ok := object.Key("tags") - if err := awsRestjson1_serializeDocumentTags(v.Tags, ok); err != nil { + if v.Clear != nil { + ok := object.Key("clear") + if err := awsRestjson1_serializeDocumentFormButton(v.Clear, ok); err != nil { return err } } - if v.Values != nil { - ok := object.Key("values") - if err := awsRestjson1_serializeDocumentThemeValuesList(v.Values, ok); err != nil { + if len(v.Position) > 0 { + ok := object.Key("position") + ok.String(string(v.Position)) + } + + if v.Submit != nil { + ok := object.Key("submit") + if err := awsRestjson1_serializeDocumentFormButton(v.Submit, ok); err != nil { return err } } @@ -1833,51 +2897,80 @@ func awsRestjson1_serializeDocumentCreateThemeData(v *types.CreateThemeData, val return nil } -func awsRestjson1_serializeDocumentExchangeCodeForTokenRequestBody(v *types.ExchangeCodeForTokenRequestBody, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentFormDataTypeConfig(v *types.FormDataTypeConfig, value smithyjson.Value) error { object := value.Object() defer object.Close() - if v.Code != nil { - ok := object.Key("code") - ok.String(*v.Code) + if len(v.DataSourceType) > 0 { + ok := object.Key("dataSourceType") + ok.String(string(v.DataSourceType)) } - if v.RedirectUri != nil { - ok := object.Key("redirectUri") - ok.String(*v.RedirectUri) + if v.DataTypeName != nil { + ok := object.Key("dataTypeName") + ok.String(*v.DataTypeName) } return nil } -func awsRestjson1_serializeDocumentFormBindingElement(v *types.FormBindingElement, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentFormInputValueProperty(v *types.FormInputValueProperty, value smithyjson.Value) error { object := value.Object() defer object.Close() - if v.Element != nil { - ok := object.Key("element") - ok.String(*v.Element) - } - - if v.Property != nil { - ok := object.Key("property") - ok.String(*v.Property) + if v.Value != nil { + ok := object.Key("value") + ok.String(*v.Value) } return nil } -func awsRestjson1_serializeDocumentFormBindings(v map[string]types.FormBindingElement, value smithyjson.Value) error { +func awsRestjson1_serializeDocumentFormStyle(v *types.FormStyle, value smithyjson.Value) error { object := value.Object() defer object.Close() - for key := range v { - om := object.Key(key) - mapVar := v[key] - if err := awsRestjson1_serializeDocumentFormBindingElement(&mapVar, om); err != nil { + if v.HorizontalGap != nil { + ok := object.Key("horizontalGap") + if err := awsRestjson1_serializeDocumentFormStyleConfig(v.HorizontalGap, ok); err != nil { + return err + } + } + + if v.OuterPadding != nil { + ok := object.Key("outerPadding") + if err := awsRestjson1_serializeDocumentFormStyleConfig(v.OuterPadding, ok); err != nil { + return err + } + } + + if v.VerticalGap != nil { + ok := object.Key("verticalGap") + if err := awsRestjson1_serializeDocumentFormStyleConfig(v.VerticalGap, ok); err != nil { return err } } + + return nil +} + +func awsRestjson1_serializeDocumentFormStyleConfig(v types.FormStyleConfig, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + switch uv := v.(type) { + case *types.FormStyleConfigMemberTokenReference: + av := object.Key("tokenReference") + av.String(uv.Value) + + case *types.FormStyleConfigMemberValue: + av := object.Key("value") + av.String(uv.Value) + + default: + return fmt.Errorf("attempted to serialize unknown member type %T for union %T", uv, v) + + } return nil } @@ -1916,6 +3009,17 @@ func awsRestjson1_serializeDocumentMutationActionSetStateParameter(v *types.Muta return nil } +func awsRestjson1_serializeDocumentNumValues(v []int32, value smithyjson.Value) error { + array := value.Array() + defer array.Close() + + for i := range v { + av := array.Value() + av.Integer(v[i]) + } + return nil +} + func awsRestjson1_serializeDocumentPredicate(v *types.Predicate, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -1965,6 +3069,18 @@ func awsRestjson1_serializeDocumentPredicateList(v []types.Predicate, value smit return nil } +func awsRestjson1_serializeDocumentPutMetadataFlagBody(v *types.PutMetadataFlagBody, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.NewValue != nil { + ok := object.Key("newValue") + ok.String(*v.NewValue) + } + + return nil +} + func awsRestjson1_serializeDocumentRefreshTokenRequestBody(v *types.RefreshTokenRequestBody, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -1977,6 +3093,54 @@ func awsRestjson1_serializeDocumentRefreshTokenRequestBody(v *types.RefreshToken return nil } +func awsRestjson1_serializeDocumentSectionalElement(v *types.SectionalElement, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Level != nil { + ok := object.Key("level") + ok.Integer(*v.Level) + } + + if v.Orientation != nil { + ok := object.Key("orientation") + ok.String(*v.Orientation) + } + + if v.Position != nil { + ok := object.Key("position") + if err := awsRestjson1_serializeDocumentFieldPosition(v.Position, ok); err != nil { + return err + } + } + + if v.Text != nil { + ok := object.Key("text") + ok.String(*v.Text) + } + + if v.Type != nil { + ok := object.Key("type") + ok.String(*v.Type) + } + + return nil +} + +func awsRestjson1_serializeDocumentSectionalElementMap(v map[string]types.SectionalElement, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + for key := range v { + om := object.Key(key) + mapVar := v[key] + if err := awsRestjson1_serializeDocumentSectionalElement(&mapVar, om); err != nil { + return err + } + } + return nil +} + func awsRestjson1_serializeDocumentSortProperty(v *types.SortProperty, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -2007,6 +3171,17 @@ func awsRestjson1_serializeDocumentSortPropertyList(v []types.SortProperty, valu return nil } +func awsRestjson1_serializeDocumentStrValues(v []string, value smithyjson.Value) error { + array := value.Array() + defer array.Close() + + for i := range v { + av := array.Value() + av.String(v[i]) + } + return nil +} + func awsRestjson1_serializeDocumentTags(v map[string]string, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -2150,6 +3325,63 @@ func awsRestjson1_serializeDocumentUpdateComponentData(v *types.UpdateComponentD return nil } +func awsRestjson1_serializeDocumentUpdateFormData(v *types.UpdateFormData, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Cta != nil { + ok := object.Key("cta") + if err := awsRestjson1_serializeDocumentFormCTA(v.Cta, ok); err != nil { + return err + } + } + + if v.DataType != nil { + ok := object.Key("dataType") + if err := awsRestjson1_serializeDocumentFormDataTypeConfig(v.DataType, ok); err != nil { + return err + } + } + + if v.Fields != nil { + ok := object.Key("fields") + if err := awsRestjson1_serializeDocumentFieldsMap(v.Fields, ok); err != nil { + return err + } + } + + if len(v.FormActionType) > 0 { + ok := object.Key("formActionType") + ok.String(string(v.FormActionType)) + } + + if v.Name != nil { + ok := object.Key("name") + ok.String(*v.Name) + } + + if v.SchemaVersion != nil { + ok := object.Key("schemaVersion") + ok.String(*v.SchemaVersion) + } + + if v.SectionalElements != nil { + ok := object.Key("sectionalElements") + if err := awsRestjson1_serializeDocumentSectionalElementMap(v.SectionalElements, ok); err != nil { + return err + } + } + + if v.Style != nil { + ok := object.Key("style") + if err := awsRestjson1_serializeDocumentFormStyle(v.Style, ok); err != nil { + return err + } + } + + return nil +} + func awsRestjson1_serializeDocumentUpdateThemeData(v *types.UpdateThemeData, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -2180,3 +3412,64 @@ func awsRestjson1_serializeDocumentUpdateThemeData(v *types.UpdateThemeData, val return nil } + +func awsRestjson1_serializeDocumentValidationsList(v []types.FieldValidationConfiguration, value smithyjson.Value) error { + array := value.Array() + defer array.Close() + + for i := range v { + av := array.Value() + if err := awsRestjson1_serializeDocumentFieldValidationConfiguration(&v[i], av); err != nil { + return err + } + } + return nil +} + +func awsRestjson1_serializeDocumentValueMapping(v *types.ValueMapping, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.DisplayValue != nil { + ok := object.Key("displayValue") + if err := awsRestjson1_serializeDocumentFormInputValueProperty(v.DisplayValue, ok); err != nil { + return err + } + } + + if v.Value != nil { + ok := object.Key("value") + if err := awsRestjson1_serializeDocumentFormInputValueProperty(v.Value, ok); err != nil { + return err + } + } + + return nil +} + +func awsRestjson1_serializeDocumentValueMappingList(v []types.ValueMapping, value smithyjson.Value) error { + array := value.Array() + defer array.Close() + + for i := range v { + av := array.Value() + if err := awsRestjson1_serializeDocumentValueMapping(&v[i], av); err != nil { + return err + } + } + return nil +} + +func awsRestjson1_serializeDocumentValueMappings(v *types.ValueMappings, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Values != nil { + ok := object.Key("values") + if err := awsRestjson1_serializeDocumentValueMappingList(v.Values, ok); err != nil { + return err + } + } + + return nil +} diff --git a/service/amplifyuibuilder/types/enums.go b/service/amplifyuibuilder/types/enums.go index 0519e86cd02..2093fbe34b8 100644 --- a/service/amplifyuibuilder/types/enums.go +++ b/service/amplifyuibuilder/types/enums.go @@ -2,6 +2,80 @@ package types +type FixedPosition string + +// Enum values for FixedPosition +const ( + FixedPositionFirst FixedPosition = "first" +) + +// Values returns all known values for FixedPosition. Note that this can be +// expanded in the future, and so it is only as up to date as the client. The +// ordering of this slice is not guaranteed to be stable across updates. +func (FixedPosition) Values() []FixedPosition { + return []FixedPosition{ + "first", + } +} + +type FormActionType string + +// Enum values for FormActionType +const ( + FormActionTypeCreate FormActionType = "create" + FormActionTypeUpdate FormActionType = "update" +) + +// Values returns all known values for FormActionType. Note that this can be +// expanded in the future, and so it is only as up to date as the client. The +// ordering of this slice is not guaranteed to be stable across updates. +func (FormActionType) Values() []FormActionType { + return []FormActionType{ + "create", + "update", + } +} + +type FormButtonsPosition string + +// Enum values for FormButtonsPosition +const ( + FormButtonsPositionTop FormButtonsPosition = "top" + FormButtonsPositionBottom FormButtonsPosition = "bottom" + FormButtonsPositionTopAndBottom FormButtonsPosition = "top_and_bottom" +) + +// Values returns all known values for FormButtonsPosition. Note that this can be +// expanded in the future, and so it is only as up to date as the client. The +// ordering of this slice is not guaranteed to be stable across updates. +func (FormButtonsPosition) Values() []FormButtonsPosition { + return []FormButtonsPosition{ + "top", + "bottom", + "top_and_bottom", + } +} + +type FormDataSourceType string + +// Enum values for FormDataSourceType +const ( + // Will use a provided Amplify DataStore enabled API + FormDataSourceTypeDatastore FormDataSourceType = "DataStore" + // Will use passed in hooks to use when creating a form from scratch + FormDataSourceTypeCustom FormDataSourceType = "Custom" +) + +// Values returns all known values for FormDataSourceType. Note that this can be +// expanded in the future, and so it is only as up to date as the client. The +// ordering of this slice is not guaranteed to be stable across updates. +func (FormDataSourceType) Values() []FormDataSourceType { + return []FormDataSourceType{ + "DataStore", + "Custom", + } +} + type SortDirection string // Values returns all known values for SortDirection. Note that this can be diff --git a/service/amplifyuibuilder/types/errors.go b/service/amplifyuibuilder/types/errors.go index 00924b77fa7..05998bc6ec0 100644 --- a/service/amplifyuibuilder/types/errors.go +++ b/service/amplifyuibuilder/types/errors.go @@ -103,3 +103,22 @@ func (e *ServiceQuotaExceededException) ErrorMessage() string { } func (e *ServiceQuotaExceededException) ErrorCode() string { return "ServiceQuotaExceededException" } func (e *ServiceQuotaExceededException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient } + +// You don't have permission to perform this operation. +type UnauthorizedException struct { + Message *string + + noSmithyDocumentSerde +} + +func (e *UnauthorizedException) Error() string { + return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage()) +} +func (e *UnauthorizedException) ErrorMessage() string { + if e.Message == nil { + return "" + } + return *e.Message +} +func (e *UnauthorizedException) ErrorCode() string { return "UnauthorizedException" } +func (e *UnauthorizedException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient } diff --git a/service/amplifyuibuilder/types/types.go b/service/amplifyuibuilder/types/types.go index a3149cf77cb..dc54f661e22 100644 --- a/service/amplifyuibuilder/types/types.go +++ b/service/amplifyuibuilder/types/types.go @@ -181,6 +181,9 @@ type ComponentBindingPropertiesValueProperties struct { // A list of predicates for binding a component's properties to data. Predicates []Predicate + // The name of a component slot. + SlotName *string + // An authenticated user attribute. UserAttribute *string @@ -468,6 +471,54 @@ type CreateComponentData struct { noSmithyDocumentSerde } +// Represents all of the information that is required to create a form. +type CreateFormData struct { + + // The type of data source to use to create the form. + // + // This member is required. + DataType *FormDataTypeConfig + + // The configuration information for the form's fields. + // + // This member is required. + Fields map[string]FieldConfig + + // Specifies whether to perform a create or update action on the form. + // + // This member is required. + FormActionType FormActionType + + // The name of the form. + // + // This member is required. + Name *string + + // The schema version of the form. + // + // This member is required. + SchemaVersion *string + + // The configuration information for the visual helper elements for the form. These + // elements are not associated with any data. + // + // This member is required. + SectionalElements map[string]SectionalElement + + // The configuration for the form's style. + // + // This member is required. + Style *FormStyle + + // The FormCTA object that stores the call to action configuration for the form. + Cta *FormCTA + + // One or more key-value pairs to use when tagging the form data. + Tags map[string]string + + noSmithyDocumentSerde +} + // Represents all of the information that is required to create a theme. type CreateThemeData struct { @@ -507,6 +558,200 @@ type ExchangeCodeForTokenRequestBody struct { noSmithyDocumentSerde } +// Describes the configuration information for a field in a table. +type FieldConfig struct { + + // Specifies whether to hide a field. + Excluded *bool + + // Describes the configuration for the default input value to display for a field. + InputType *FieldInputConfig + + // The label for the field. + Label *string + + // Specifies the field position. + Position FieldPosition + + // The validations to perform on the value in the field. + Validations []FieldValidationConfiguration + + noSmithyDocumentSerde +} + +// Describes the configuration for the default input values to display for a field. +type FieldInputConfig struct { + + // The input type for the field. + // + // This member is required. + Type *string + + // Specifies whether a field has a default value. + DefaultChecked *bool + + // The default country code for a phone number. + DefaultCountryCode *string + + // The default value for the field. + DefaultValue *string + + // The text to display to describe the field. + DescriptiveText *string + + // The maximum value to display for the field. + MaxValue *float32 + + // The minimum value to display for the field. + MinValue *float32 + + // The name of the field. + Name *string + + // The text to display as a placeholder for the field. + Placeholder *string + + // Specifies a read only field. + ReadOnly *bool + + // Specifies a field that requires input. + Required *bool + + // The stepping increment for a numeric value in a field. + Step *float32 + + // The value for the field. + Value *string + + // The information to use to customize the input fields with data at runtime. + ValueMappings *ValueMappings + + noSmithyDocumentSerde +} + +// Describes the field position. +// +// The following types satisfy this interface: +// +// FieldPositionMemberBelow +// FieldPositionMemberFixed +// FieldPositionMemberRightOf +type FieldPosition interface { + isFieldPosition() +} + +// The field position is below the field specified by the string. +type FieldPositionMemberBelow struct { + Value string + + noSmithyDocumentSerde +} + +func (*FieldPositionMemberBelow) isFieldPosition() {} + +// The field position is fixed and doesn't change in relation to other fields. +type FieldPositionMemberFixed struct { + Value FixedPosition + + noSmithyDocumentSerde +} + +func (*FieldPositionMemberFixed) isFieldPosition() {} + +// The field position is to the right of the field specified by the string. +type FieldPositionMemberRightOf struct { + Value string + + noSmithyDocumentSerde +} + +func (*FieldPositionMemberRightOf) isFieldPosition() {} + +// Describes the validation configuration for a field. +type FieldValidationConfiguration struct { + + // The validation to perform on an object type. + // + // This member is required. + Type *string + + // The validation to perform on a number value. + NumValues []int32 + + // The validation to perform on a string value. + StrValues []string + + // The validation message to display. + ValidationMessage *string + + noSmithyDocumentSerde +} + +// Contains the configuration settings for a Form user interface (UI) element for +// an Amplify app. A form is a component you can add to your project by specifying +// a data source as the default configuration for the form. +type Form struct { + + // The unique ID of the Amplify app associated with the form. + // + // This member is required. + AppId *string + + // The type of data source to use to create the form. + // + // This member is required. + DataType *FormDataTypeConfig + + // The name of the backend environment that is a part of the Amplify app. + // + // This member is required. + EnvironmentName *string + + // Stores the information about the form's fields. + // + // This member is required. + Fields map[string]FieldConfig + + // The operation to perform on the specified form. + // + // This member is required. + FormActionType FormActionType + + // The unique ID of the form. + // + // This member is required. + Id *string + + // The name of the form. + // + // This member is required. + Name *string + + // The schema version of the form when it was imported. + // + // This member is required. + SchemaVersion *string + + // Stores the visual helper elements for the form that are not associated with any + // data. + // + // This member is required. + SectionalElements map[string]SectionalElement + + // Stores the configuration for the form's style. + // + // This member is required. + Style *FormStyle + + // Stores the call to action configuration for the form. + Cta *FormCTA + + // One or more key-value pairs to use when tagging the form. + Tags map[string]string + + noSmithyDocumentSerde +} + // Describes how to bind a component property to form data. type FormBindingElement struct { @@ -523,6 +768,146 @@ type FormBindingElement struct { noSmithyDocumentSerde } +// Describes the configuration for a button UI element that is a part of a form. +type FormButton struct { + + // Describes the button's properties. + Children *string + + // Specifies whether the button is visible on the form. + Excluded *bool + + // The position of the button. + Position FieldPosition + + noSmithyDocumentSerde +} + +// Describes the call to action button configuration for the form.. +type FormCTA struct { + + // Displays a cancel button. + Cancel *FormButton + + // Displays a clear button. + Clear *FormButton + + // The position of the button. + Position FormButtonsPosition + + // Displays a submit button. + Submit *FormButton + + noSmithyDocumentSerde +} + +// Describes the data type configuration for the data source associated with a +// form. +type FormDataTypeConfig struct { + + // The data source type, either an Amplify DataStore model or a custom data type. + // + // This member is required. + DataSourceType FormDataSourceType + + // The unique name of the data type you are using as the data source for the form. + // + // This member is required. + DataTypeName *string + + noSmithyDocumentSerde +} + +// Describes the configuration for an input field on a form. Use +// FormInputValueProperty to specify the values to render or bind by default. +type FormInputValueProperty struct { + + // The value to assign to the input field. + Value *string + + noSmithyDocumentSerde +} + +// Describes the configuration for the form's style. +type FormStyle struct { + + // The spacing for the horizontal gap. + HorizontalGap FormStyleConfig + + // The size of the outer padding for the form. + OuterPadding FormStyleConfig + + // The spacing for the vertical gap. + VerticalGap FormStyleConfig + + noSmithyDocumentSerde +} + +// Describes the configuration settings for the form's style properties. +// +// The following types satisfy this interface: +// +// FormStyleConfigMemberTokenReference +// FormStyleConfigMemberValue +type FormStyleConfig interface { + isFormStyleConfig() +} + +// A reference to a design token to use to bind the form's style properties to an +// existing theme. +type FormStyleConfigMemberTokenReference struct { + Value string + + noSmithyDocumentSerde +} + +func (*FormStyleConfigMemberTokenReference) isFormStyleConfig() {} + +// The value of the style setting. +type FormStyleConfigMemberValue struct { + Value string + + noSmithyDocumentSerde +} + +func (*FormStyleConfigMemberValue) isFormStyleConfig() {} + +// Describes the basic information about a form. +type FormSummary struct { + + // The unique ID for the app associated with the form summary. + // + // This member is required. + AppId *string + + // The form's data source type. + // + // This member is required. + DataType *FormDataTypeConfig + + // The name of the backend environment that is part of the Amplify app. + // + // This member is required. + EnvironmentName *string + + // The type of operation to perform on the form. + // + // This member is required. + FormActionType FormActionType + + // The ID of the form. + // + // This member is required. + Id *string + + // The name of the form. + // + // This member is required. + Name *string + + noSmithyDocumentSerde +} + // Represents the state configuration when an action modifies a property of another // element within the same component. type MutationActionSetStateParameter struct { @@ -567,6 +952,17 @@ type Predicate struct { noSmithyDocumentSerde } +// Stores the metadata information about a feature on a form or view. +type PutMetadataFlagBody struct { + + // The new information to store. + // + // This member is required. + NewValue *string + + noSmithyDocumentSerde +} + // Describes a refresh token. type RefreshTokenRequestBody struct { @@ -579,6 +975,33 @@ type RefreshTokenRequestBody struct { noSmithyDocumentSerde } +// Stores the configuration information for a visual helper element for a form. A +// sectional element can be a header, a text block, or a divider. These elements +// are static and not associated with any data. +type SectionalElement struct { + + // The type of sectional element. Valid values are Heading, Text, and Divider. + // + // This member is required. + Type *string + + // Specifies the size of the font for a Heading sectional element. Valid values are + // 1 | 2 | 3 | 4 | 5 | 6. + Level *int32 + + // Specifies the orientation for a Divider sectional element. Valid values are + // horizontal or vertical. + Orientation *string + + // Specifies the position of the text in a field for a Text sectional element. + Position FieldPosition + + // The text for a Text sectional element. + Text *string + + noSmithyDocumentSerde +} + // Describes how to sort the data that you bind to a component. type SortProperty struct { @@ -737,6 +1160,37 @@ type UpdateComponentData struct { noSmithyDocumentSerde } +// Updates and saves all of the information about a form, based on form ID. +type UpdateFormData struct { + + // The FormCTA object that stores the call to action configuration for the form. + Cta *FormCTA + + // The type of data source to use to create the form. + DataType *FormDataTypeConfig + + // The configuration information for the form's fields. + Fields map[string]FieldConfig + + // Specifies whether to perform a create or update action on the form. + FormActionType FormActionType + + // The name of the form. + Name *string + + // The schema version of the form. + SchemaVersion *string + + // The configuration information for the visual helper elements for the form. These + // elements are not associated with any data. + SectionalElements map[string]SectionalElement + + // The configuration for the form's style. + Style *FormStyle + + noSmithyDocumentSerde +} + // Saves the data binding information for a theme. type UpdateThemeData struct { @@ -757,4 +1211,42 @@ type UpdateThemeData struct { noSmithyDocumentSerde } +// Associates a complex object with a display value. Use ValueMapping to store how +// to represent complex objects when they are displayed. +type ValueMapping struct { + + // The complex object. + // + // This member is required. + Value *FormInputValueProperty + + // The value to display for the complex object. + DisplayValue *FormInputValueProperty + + noSmithyDocumentSerde +} + +// Represents the data binding configuration for a value map. +type ValueMappings struct { + + // The value and display value pairs. + // + // This member is required. + Values []ValueMapping + + noSmithyDocumentSerde +} + type noSmithyDocumentSerde = smithydocument.NoSerde + +// UnknownUnionMember is returned when a union member is returned over the wire, +// but has an unknown tag. +type UnknownUnionMember struct { + Tag string + Value []byte + + noSmithyDocumentSerde +} + +func (*UnknownUnionMember) isFieldPosition() {} +func (*UnknownUnionMember) isFormStyleConfig() {} diff --git a/service/amplifyuibuilder/types/types_exported_test.go b/service/amplifyuibuilder/types/types_exported_test.go new file mode 100644 index 00000000000..bafbd130dc1 --- /dev/null +++ b/service/amplifyuibuilder/types/types_exported_test.go @@ -0,0 +1,54 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package types_test + +import ( + "fmt" + "github.com/aws/aws-sdk-go-v2/service/amplifyuibuilder/types" +) + +func ExampleFieldPosition_outputUsage() { + var union types.FieldPosition + // type switches can be used to check the union value + switch v := union.(type) { + case *types.FieldPositionMemberBelow: + _ = v.Value // Value is string + + case *types.FieldPositionMemberFixed: + _ = v.Value // Value is types.FixedPosition + + case *types.FieldPositionMemberRightOf: + _ = v.Value // Value is string + + case *types.UnknownUnionMember: + fmt.Println("unknown tag:", v.Tag) + + default: + fmt.Println("union is nil or unknown type") + + } +} + +var _ *string +var _ types.FixedPosition + +func ExampleFormStyleConfig_outputUsage() { + var union types.FormStyleConfig + // type switches can be used to check the union value + switch v := union.(type) { + case *types.FormStyleConfigMemberTokenReference: + _ = v.Value // Value is string + + case *types.FormStyleConfigMemberValue: + _ = v.Value // Value is string + + case *types.UnknownUnionMember: + fmt.Println("unknown tag:", v.Tag) + + default: + fmt.Println("union is nil or unknown type") + + } +} + +var _ *string diff --git a/service/amplifyuibuilder/validators.go b/service/amplifyuibuilder/validators.go index 8d67d39834c..1e6b0cd2a28 100644 --- a/service/amplifyuibuilder/validators.go +++ b/service/amplifyuibuilder/validators.go @@ -30,6 +30,26 @@ func (m *validateOpCreateComponent) HandleInitialize(ctx context.Context, in mid return next.HandleInitialize(ctx, in) } +type validateOpCreateForm struct { +} + +func (*validateOpCreateForm) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpCreateForm) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*CreateFormInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpCreateFormInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpCreateTheme struct { } @@ -70,6 +90,26 @@ func (m *validateOpDeleteComponent) HandleInitialize(ctx context.Context, in mid return next.HandleInitialize(ctx, in) } +type validateOpDeleteForm struct { +} + +func (*validateOpDeleteForm) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDeleteForm) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DeleteFormInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDeleteFormInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpDeleteTheme struct { } @@ -130,6 +170,26 @@ func (m *validateOpExportComponents) HandleInitialize(ctx context.Context, in mi return next.HandleInitialize(ctx, in) } +type validateOpExportForms struct { +} + +func (*validateOpExportForms) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpExportForms) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*ExportFormsInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpExportFormsInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpExportThemes struct { } @@ -170,6 +230,46 @@ func (m *validateOpGetComponent) HandleInitialize(ctx context.Context, in middle return next.HandleInitialize(ctx, in) } +type validateOpGetForm struct { +} + +func (*validateOpGetForm) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpGetForm) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*GetFormInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpGetFormInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + +type validateOpGetMetadata struct { +} + +func (*validateOpGetMetadata) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpGetMetadata) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*GetMetadataInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpGetMetadataInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpGetTheme struct { } @@ -210,6 +310,26 @@ func (m *validateOpListComponents) HandleInitialize(ctx context.Context, in midd return next.HandleInitialize(ctx, in) } +type validateOpListForms struct { +} + +func (*validateOpListForms) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpListForms) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*ListFormsInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpListFormsInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpListThemes struct { } @@ -230,6 +350,26 @@ func (m *validateOpListThemes) HandleInitialize(ctx context.Context, in middlewa return next.HandleInitialize(ctx, in) } +type validateOpPutMetadataFlag struct { +} + +func (*validateOpPutMetadataFlag) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpPutMetadataFlag) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*PutMetadataFlagInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpPutMetadataFlagInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpRefreshToken struct { } @@ -270,6 +410,26 @@ func (m *validateOpUpdateComponent) HandleInitialize(ctx context.Context, in mid return next.HandleInitialize(ctx, in) } +type validateOpUpdateForm struct { +} + +func (*validateOpUpdateForm) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpUpdateForm) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*UpdateFormInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpUpdateFormInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpUpdateTheme struct { } @@ -294,6 +454,10 @@ func addOpCreateComponentValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpCreateComponent{}, middleware.After) } +func addOpCreateFormValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpCreateForm{}, middleware.After) +} + func addOpCreateThemeValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpCreateTheme{}, middleware.After) } @@ -302,6 +466,10 @@ func addOpDeleteComponentValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDeleteComponent{}, middleware.After) } +func addOpDeleteFormValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDeleteForm{}, middleware.After) +} + func addOpDeleteThemeValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDeleteTheme{}, middleware.After) } @@ -314,6 +482,10 @@ func addOpExportComponentsValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpExportComponents{}, middleware.After) } +func addOpExportFormsValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpExportForms{}, middleware.After) +} + func addOpExportThemesValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpExportThemes{}, middleware.After) } @@ -322,6 +494,14 @@ func addOpGetComponentValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpGetComponent{}, middleware.After) } +func addOpGetFormValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpGetForm{}, middleware.After) +} + +func addOpGetMetadataValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpGetMetadata{}, middleware.After) +} + func addOpGetThemeValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpGetTheme{}, middleware.After) } @@ -330,10 +510,18 @@ func addOpListComponentsValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpListComponents{}, middleware.After) } +func addOpListFormsValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpListForms{}, middleware.After) +} + func addOpListThemesValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpListThemes{}, middleware.After) } +func addOpPutMetadataFlagValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpPutMetadataFlag{}, middleware.After) +} + func addOpRefreshTokenValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpRefreshToken{}, middleware.After) } @@ -342,6 +530,10 @@ func addOpUpdateComponentValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpUpdateComponent{}, middleware.After) } +func addOpUpdateFormValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpUpdateForm{}, middleware.After) +} + func addOpUpdateThemeValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpUpdateTheme{}, middleware.After) } @@ -681,6 +873,51 @@ func validateCreateComponentData(v *types.CreateComponentData) error { } } +func validateCreateFormData(v *types.CreateFormData) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "CreateFormData"} + if v.Name == nil { + invalidParams.Add(smithy.NewErrParamRequired("Name")) + } + if v.DataType == nil { + invalidParams.Add(smithy.NewErrParamRequired("DataType")) + } else if v.DataType != nil { + if err := validateFormDataTypeConfig(v.DataType); err != nil { + invalidParams.AddNested("DataType", err.(smithy.InvalidParamsError)) + } + } + if len(v.FormActionType) == 0 { + invalidParams.Add(smithy.NewErrParamRequired("FormActionType")) + } + if v.Fields == nil { + invalidParams.Add(smithy.NewErrParamRequired("Fields")) + } else if v.Fields != nil { + if err := validateFieldsMap(v.Fields); err != nil { + invalidParams.AddNested("Fields", err.(smithy.InvalidParamsError)) + } + } + if v.Style == nil { + invalidParams.Add(smithy.NewErrParamRequired("Style")) + } + if v.SectionalElements == nil { + invalidParams.Add(smithy.NewErrParamRequired("SectionalElements")) + } else if v.SectionalElements != nil { + if err := validateSectionalElementMap(v.SectionalElements); err != nil { + invalidParams.AddNested("SectionalElements", err.(smithy.InvalidParamsError)) + } + } + if v.SchemaVersion == nil { + invalidParams.Add(smithy.NewErrParamRequired("SchemaVersion")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateCreateThemeData(v *types.CreateThemeData) error { if v == nil { return nil @@ -717,6 +954,81 @@ func validateExchangeCodeForTokenRequestBody(v *types.ExchangeCodeForTokenReques } } +func validateFieldConfig(v *types.FieldConfig) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "FieldConfig"} + if v.InputType != nil { + if err := validateFieldInputConfig(v.InputType); err != nil { + invalidParams.AddNested("InputType", err.(smithy.InvalidParamsError)) + } + } + if v.Validations != nil { + if err := validateValidationsList(v.Validations); err != nil { + invalidParams.AddNested("Validations", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateFieldInputConfig(v *types.FieldInputConfig) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "FieldInputConfig"} + if v.Type == nil { + invalidParams.Add(smithy.NewErrParamRequired("Type")) + } + if v.ValueMappings != nil { + if err := validateValueMappings(v.ValueMappings); err != nil { + invalidParams.AddNested("ValueMappings", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateFieldsMap(v map[string]types.FieldConfig) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "FieldsMap"} + for key := range v { + value := v[key] + if err := validateFieldConfig(&value); err != nil { + invalidParams.AddNested(fmt.Sprintf("[%q]", key), err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateFieldValidationConfiguration(v *types.FieldValidationConfiguration) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "FieldValidationConfiguration"} + if v.Type == nil { + invalidParams.Add(smithy.NewErrParamRequired("Type")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateFormBindingElement(v *types.FormBindingElement) error { if v == nil { return nil @@ -753,6 +1065,24 @@ func validateFormBindings(v map[string]types.FormBindingElement) error { } } +func validateFormDataTypeConfig(v *types.FormDataTypeConfig) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "FormDataTypeConfig"} + if len(v.DataSourceType) == 0 { + invalidParams.Add(smithy.NewErrParamRequired("DataSourceType")) + } + if v.DataTypeName == nil { + invalidParams.Add(smithy.NewErrParamRequired("DataTypeName")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateMutationActionSetStateParameter(v *types.MutationActionSetStateParameter) error { if v == nil { return nil @@ -778,6 +1108,21 @@ func validateMutationActionSetStateParameter(v *types.MutationActionSetStatePara } } +func validatePutMetadataFlagBody(v *types.PutMetadataFlagBody) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "PutMetadataFlagBody"} + if v.NewValue == nil { + invalidParams.Add(smithy.NewErrParamRequired("NewValue")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateRefreshTokenRequestBody(v *types.RefreshTokenRequestBody) error { if v == nil { return nil @@ -793,6 +1138,39 @@ func validateRefreshTokenRequestBody(v *types.RefreshTokenRequestBody) error { } } +func validateSectionalElement(v *types.SectionalElement) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "SectionalElement"} + if v.Type == nil { + invalidParams.Add(smithy.NewErrParamRequired("Type")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateSectionalElementMap(v map[string]types.SectionalElement) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "SectionalElementMap"} + for key := range v { + value := v[key] + if err := validateSectionalElement(&value); err != nil { + invalidParams.AddNested(fmt.Sprintf("[%q]", key), err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateSortProperty(v *types.SortProperty) error { if v == nil { return nil @@ -860,6 +1238,33 @@ func validateUpdateComponentData(v *types.UpdateComponentData) error { } } +func validateUpdateFormData(v *types.UpdateFormData) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "UpdateFormData"} + if v.DataType != nil { + if err := validateFormDataTypeConfig(v.DataType); err != nil { + invalidParams.AddNested("DataType", err.(smithy.InvalidParamsError)) + } + } + if v.Fields != nil { + if err := validateFieldsMap(v.Fields); err != nil { + invalidParams.AddNested("Fields", err.(smithy.InvalidParamsError)) + } + } + if v.SectionalElements != nil { + if err := validateSectionalElementMap(v.SectionalElements); err != nil { + invalidParams.AddNested("SectionalElements", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateUpdateThemeData(v *types.UpdateThemeData) error { if v == nil { return nil @@ -875,6 +1280,74 @@ func validateUpdateThemeData(v *types.UpdateThemeData) error { } } +func validateValidationsList(v []types.FieldValidationConfiguration) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ValidationsList"} + for i := range v { + if err := validateFieldValidationConfiguration(&v[i]); err != nil { + invalidParams.AddNested(fmt.Sprintf("[%d]", i), err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateValueMapping(v *types.ValueMapping) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ValueMapping"} + if v.Value == nil { + invalidParams.Add(smithy.NewErrParamRequired("Value")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateValueMappingList(v []types.ValueMapping) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ValueMappingList"} + for i := range v { + if err := validateValueMapping(&v[i]); err != nil { + invalidParams.AddNested(fmt.Sprintf("[%d]", i), err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateValueMappings(v *types.ValueMappings) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ValueMappings"} + if v.Values == nil { + invalidParams.Add(smithy.NewErrParamRequired("Values")) + } else if v.Values != nil { + if err := validateValueMappingList(v.Values); err != nil { + invalidParams.AddNested("Values", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpCreateComponentInput(v *CreateComponentInput) error { if v == nil { return nil @@ -900,6 +1373,31 @@ func validateOpCreateComponentInput(v *CreateComponentInput) error { } } +func validateOpCreateFormInput(v *CreateFormInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "CreateFormInput"} + if v.AppId == nil { + invalidParams.Add(smithy.NewErrParamRequired("AppId")) + } + if v.EnvironmentName == nil { + invalidParams.Add(smithy.NewErrParamRequired("EnvironmentName")) + } + if v.FormToCreate == nil { + invalidParams.Add(smithy.NewErrParamRequired("FormToCreate")) + } else if v.FormToCreate != nil { + if err := validateCreateFormData(v.FormToCreate); err != nil { + invalidParams.AddNested("FormToCreate", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpCreateThemeInput(v *CreateThemeInput) error { if v == nil { return nil @@ -946,6 +1444,27 @@ func validateOpDeleteComponentInput(v *DeleteComponentInput) error { } } +func validateOpDeleteFormInput(v *DeleteFormInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DeleteFormInput"} + if v.AppId == nil { + invalidParams.Add(smithy.NewErrParamRequired("AppId")) + } + if v.EnvironmentName == nil { + invalidParams.Add(smithy.NewErrParamRequired("EnvironmentName")) + } + if v.Id == nil { + invalidParams.Add(smithy.NewErrParamRequired("Id")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpDeleteThemeInput(v *DeleteThemeInput) error { if v == nil { return nil @@ -1007,6 +1526,24 @@ func validateOpExportComponentsInput(v *ExportComponentsInput) error { } } +func validateOpExportFormsInput(v *ExportFormsInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ExportFormsInput"} + if v.AppId == nil { + invalidParams.Add(smithy.NewErrParamRequired("AppId")) + } + if v.EnvironmentName == nil { + invalidParams.Add(smithy.NewErrParamRequired("EnvironmentName")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpExportThemesInput(v *ExportThemesInput) error { if v == nil { return nil @@ -1046,6 +1583,45 @@ func validateOpGetComponentInput(v *GetComponentInput) error { } } +func validateOpGetFormInput(v *GetFormInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "GetFormInput"} + if v.AppId == nil { + invalidParams.Add(smithy.NewErrParamRequired("AppId")) + } + if v.EnvironmentName == nil { + invalidParams.Add(smithy.NewErrParamRequired("EnvironmentName")) + } + if v.Id == nil { + invalidParams.Add(smithy.NewErrParamRequired("Id")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateOpGetMetadataInput(v *GetMetadataInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "GetMetadataInput"} + if v.AppId == nil { + invalidParams.Add(smithy.NewErrParamRequired("AppId")) + } + if v.EnvironmentName == nil { + invalidParams.Add(smithy.NewErrParamRequired("EnvironmentName")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpGetThemeInput(v *GetThemeInput) error { if v == nil { return nil @@ -1085,6 +1661,24 @@ func validateOpListComponentsInput(v *ListComponentsInput) error { } } +func validateOpListFormsInput(v *ListFormsInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ListFormsInput"} + if v.AppId == nil { + invalidParams.Add(smithy.NewErrParamRequired("AppId")) + } + if v.EnvironmentName == nil { + invalidParams.Add(smithy.NewErrParamRequired("EnvironmentName")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpListThemesInput(v *ListThemesInput) error { if v == nil { return nil @@ -1103,6 +1697,34 @@ func validateOpListThemesInput(v *ListThemesInput) error { } } +func validateOpPutMetadataFlagInput(v *PutMetadataFlagInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "PutMetadataFlagInput"} + if v.AppId == nil { + invalidParams.Add(smithy.NewErrParamRequired("AppId")) + } + if v.EnvironmentName == nil { + invalidParams.Add(smithy.NewErrParamRequired("EnvironmentName")) + } + if v.FeatureName == nil { + invalidParams.Add(smithy.NewErrParamRequired("FeatureName")) + } + if v.Body == nil { + invalidParams.Add(smithy.NewErrParamRequired("Body")) + } else if v.Body != nil { + if err := validatePutMetadataFlagBody(v.Body); err != nil { + invalidParams.AddNested("Body", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpRefreshTokenInput(v *RefreshTokenInput) error { if v == nil { return nil @@ -1153,6 +1775,34 @@ func validateOpUpdateComponentInput(v *UpdateComponentInput) error { } } +func validateOpUpdateFormInput(v *UpdateFormInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "UpdateFormInput"} + if v.AppId == nil { + invalidParams.Add(smithy.NewErrParamRequired("AppId")) + } + if v.EnvironmentName == nil { + invalidParams.Add(smithy.NewErrParamRequired("EnvironmentName")) + } + if v.Id == nil { + invalidParams.Add(smithy.NewErrParamRequired("Id")) + } + if v.UpdatedForm == nil { + invalidParams.Add(smithy.NewErrParamRequired("UpdatedForm")) + } else if v.UpdatedForm != nil { + if err := validateUpdateFormData(v.UpdatedForm); err != nil { + invalidParams.AddNested("UpdatedForm", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpUpdateThemeInput(v *UpdateThemeInput) error { if v == nil { return nil diff --git a/service/cloudtrail/api_op_CreateEventDataStore.go b/service/cloudtrail/api_op_CreateEventDataStore.go index dcabfb935f7..adcd1541597 100644 --- a/service/cloudtrail/api_op_CreateEventDataStore.go +++ b/service/cloudtrail/api_op_CreateEventDataStore.go @@ -51,7 +51,7 @@ type CreateEventDataStoreInput struct { OrganizationEnabled *bool // The retention period of the event data store, in days. You can set a retention - // period of up to 2555 days, the equivalent of seven years. + // period of up to 2557 days, the equivalent of seven years. RetentionPeriod *int32 // A list of tags. diff --git a/service/cloudtrail/api_op_GetChannel.go b/service/cloudtrail/api_op_GetChannel.go new file mode 100644 index 00000000000..a2a8cdb87e8 --- /dev/null +++ b/service/cloudtrail/api_op_GetChannel.go @@ -0,0 +1,141 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package cloudtrail + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/cloudtrail/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Returns the specified CloudTrail service-linked channel. Amazon Web Services +// services create service-linked channels to view CloudTrail events. +func (c *Client) GetChannel(ctx context.Context, params *GetChannelInput, optFns ...func(*Options)) (*GetChannelOutput, error) { + if params == nil { + params = &GetChannelInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "GetChannel", params, optFns, c.addOperationGetChannelMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*GetChannelOutput) + out.ResultMetadata = metadata + return out, nil +} + +type GetChannelInput struct { + + // The Amazon Resource Name (ARN) of the CloudTrail service-linked channel. + // + // This member is required. + Channel *string + + noSmithyDocumentSerde +} + +type GetChannelOutput struct { + + // The ARN of the CloudTrail service-linked channel. + ChannelArn *string + + // The Amazon Web Services service that created the CloudTrail service-linked + // channel. + Destinations []types.Destination + + // The name of the CloudTrail service-linked channel. For service-linked channels, + // the value is aws-service-channel/service-name/custom-suffix where service-name + // represents the name of the Amazon Web Services service that created the channel + // and custom-suffix represents the suffix generated by the Amazon Web Services + // service. + Name *string + + // The trail or event data store for the CloudTrail service-linked channel. + Source *string + + // Provides information about the advanced event selectors configured for the + // service-linked channel, and whether the service-linked channel applies to all + // regions or one region. + SourceConfig *types.SourceConfig + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationGetChannelMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson11_serializeOpGetChannel{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpGetChannel{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpGetChannelValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetChannel(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opGetChannel(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "cloudtrail", + OperationName: "GetChannel", + } +} diff --git a/service/cloudtrail/api_op_ListChannels.go b/service/cloudtrail/api_op_ListChannels.go new file mode 100644 index 00000000000..c75a12ce3af --- /dev/null +++ b/service/cloudtrail/api_op_ListChannels.go @@ -0,0 +1,212 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package cloudtrail + +import ( + "context" + "fmt" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/cloudtrail/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Returns all CloudTrail channels. +func (c *Client) ListChannels(ctx context.Context, params *ListChannelsInput, optFns ...func(*Options)) (*ListChannelsOutput, error) { + if params == nil { + params = &ListChannelsInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "ListChannels", params, optFns, c.addOperationListChannelsMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*ListChannelsOutput) + out.ResultMetadata = metadata + return out, nil +} + +type ListChannelsInput struct { + + // The maximum number of CloudTrail channels to display on a single page. + MaxResults *int32 + + // A token you can use to get the next page of results. + NextToken *string + + noSmithyDocumentSerde +} + +type ListChannelsOutput struct { + + // The list of CloudTrail channels. + Channels []types.Channel + + // A token used to get the next page of results. + NextToken *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationListChannelsMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson11_serializeOpListChannels{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpListChannels{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opListChannels(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +// ListChannelsAPIClient is a client that implements the ListChannels operation. +type ListChannelsAPIClient interface { + ListChannels(context.Context, *ListChannelsInput, ...func(*Options)) (*ListChannelsOutput, error) +} + +var _ ListChannelsAPIClient = (*Client)(nil) + +// ListChannelsPaginatorOptions is the paginator options for ListChannels +type ListChannelsPaginatorOptions struct { + // The maximum number of CloudTrail channels to display on a single page. + Limit int32 + + // Set to true if pagination should stop if the service returns a pagination token + // that matches the most recent token provided to the service. + StopOnDuplicateToken bool +} + +// ListChannelsPaginator is a paginator for ListChannels +type ListChannelsPaginator struct { + options ListChannelsPaginatorOptions + client ListChannelsAPIClient + params *ListChannelsInput + nextToken *string + firstPage bool +} + +// NewListChannelsPaginator returns a new ListChannelsPaginator +func NewListChannelsPaginator(client ListChannelsAPIClient, params *ListChannelsInput, optFns ...func(*ListChannelsPaginatorOptions)) *ListChannelsPaginator { + if params == nil { + params = &ListChannelsInput{} + } + + options := ListChannelsPaginatorOptions{} + if params.MaxResults != nil { + options.Limit = *params.MaxResults + } + + for _, fn := range optFns { + fn(&options) + } + + return &ListChannelsPaginator{ + options: options, + client: client, + params: params, + firstPage: true, + nextToken: params.NextToken, + } +} + +// HasMorePages returns a boolean indicating whether more pages are available +func (p *ListChannelsPaginator) HasMorePages() bool { + return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0) +} + +// NextPage retrieves the next ListChannels page. +func (p *ListChannelsPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ListChannelsOutput, error) { + if !p.HasMorePages() { + return nil, fmt.Errorf("no more pages available") + } + + params := *p.params + params.NextToken = p.nextToken + + var limit *int32 + if p.options.Limit > 0 { + limit = &p.options.Limit + } + params.MaxResults = limit + + result, err := p.client.ListChannels(ctx, ¶ms, optFns...) + if err != nil { + return nil, err + } + p.firstPage = false + + prevToken := p.nextToken + p.nextToken = result.NextToken + + if p.options.StopOnDuplicateToken && + prevToken != nil && + p.nextToken != nil && + *prevToken == *p.nextToken { + p.nextToken = nil + } + + return result, nil +} + +func newServiceMetadataMiddleware_opListChannels(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "cloudtrail", + OperationName: "ListChannels", + } +} diff --git a/service/cloudtrail/api_op_ListTrails.go b/service/cloudtrail/api_op_ListTrails.go index 03592b0082a..007cfedbf66 100644 --- a/service/cloudtrail/api_op_ListTrails.go +++ b/service/cloudtrail/api_op_ListTrails.go @@ -31,7 +31,7 @@ func (c *Client) ListTrails(ctx context.Context, params *ListTrailsInput, optFns type ListTrailsInput struct { // The token to use to get the next page of results after a previous API call. This - // token must be passed in with the same parameters that were specified in the the + // token must be passed in with the same parameters that were specified in the // original call. For example, if the original call specified an AttributeKey of // 'Username' with a value of 'root', the call with NextToken should include those // same parameters. diff --git a/service/cloudtrail/api_op_LookupEvents.go b/service/cloudtrail/api_op_LookupEvents.go index a48112c1fef..0d0adeef677 100644 --- a/service/cloudtrail/api_op_LookupEvents.go +++ b/service/cloudtrail/api_op_LookupEvents.go @@ -90,7 +90,7 @@ type LookupEventsInput struct { MaxResults *int32 // The token to use to get the next page of results after a previous API call. This - // token must be passed in with the same parameters that were specified in the the + // token must be passed in with the same parameters that were specified in the // original call. For example, if the original call specified an AttributeKey of // 'Username' with a value of 'root', the call with NextToken should include those // same parameters. diff --git a/service/cloudtrail/api_op_UpdateEventDataStore.go b/service/cloudtrail/api_op_UpdateEventDataStore.go index 8bd16f62ac8..79be40d1ce9 100644 --- a/service/cloudtrail/api_op_UpdateEventDataStore.go +++ b/service/cloudtrail/api_op_UpdateEventDataStore.go @@ -15,7 +15,7 @@ import ( // Updates an event data store. The required EventDataStore value is an ARN or the // ID portion of the ARN. Other parameters are optional, but at least one optional // parameter must be specified, or CloudTrail throws an error. RetentionPeriod is -// in days, and valid values are integers between 90 and 2555. By default, +// in days, and valid values are integers between 90 and 2557. By default, // TerminationProtection is enabled. AdvancedEventSelectors includes or excludes // management and data events in your event data store; for more information about // AdvancedEventSelectors, see PutEventSelectorsRequest$AdvancedEventSelectors. diff --git a/service/cloudtrail/deserializers.go b/service/cloudtrail/deserializers.go index c5aa1b2b502..c7b76364dec 100644 --- a/service/cloudtrail/deserializers.go +++ b/service/cloudtrail/deserializers.go @@ -1148,6 +1148,126 @@ func awsAwsjson11_deserializeOpErrorDescribeTrails(response *smithyhttp.Response } } +type awsAwsjson11_deserializeOpGetChannel struct { +} + +func (*awsAwsjson11_deserializeOpGetChannel) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson11_deserializeOpGetChannel) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsAwsjson11_deserializeOpErrorGetChannel(response, &metadata) + } + output := &GetChannelOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsAwsjson11_deserializeOpDocumentGetChannelOutput(&output, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsAwsjson11_deserializeOpErrorGetChannel(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("ChannelARNInvalidException", errorCode): + return awsAwsjson11_deserializeErrorChannelARNInvalidException(response, errorBody) + + case strings.EqualFold("ChannelNotFoundException", errorCode): + return awsAwsjson11_deserializeErrorChannelNotFoundException(response, errorBody) + + case strings.EqualFold("OperationNotPermittedException", errorCode): + return awsAwsjson11_deserializeErrorOperationNotPermittedException(response, errorBody) + + case strings.EqualFold("UnsupportedOperationException", errorCode): + return awsAwsjson11_deserializeErrorUnsupportedOperationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + type awsAwsjson11_deserializeOpGetEventDataStore struct { } @@ -1889,6 +2009,123 @@ func awsAwsjson11_deserializeOpErrorGetTrailStatus(response *smithyhttp.Response } } +type awsAwsjson11_deserializeOpListChannels struct { +} + +func (*awsAwsjson11_deserializeOpListChannels) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson11_deserializeOpListChannels) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsAwsjson11_deserializeOpErrorListChannels(response, &metadata) + } + output := &ListChannelsOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsAwsjson11_deserializeOpDocumentListChannelsOutput(&output, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsAwsjson11_deserializeOpErrorListChannels(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InvalidNextTokenException", errorCode): + return awsAwsjson11_deserializeErrorInvalidNextTokenException(response, errorBody) + + case strings.EqualFold("OperationNotPermittedException", errorCode): + return awsAwsjson11_deserializeErrorOperationNotPermittedException(response, errorBody) + + case strings.EqualFold("UnsupportedOperationException", errorCode): + return awsAwsjson11_deserializeErrorUnsupportedOperationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + type awsAwsjson11_deserializeOpListEventDataStores struct { } @@ -3923,6 +4160,76 @@ func awsAwsjson11_deserializeOpErrorUpdateTrail(response *smithyhttp.Response, m } } +func awsAwsjson11_deserializeErrorChannelARNInvalidException(response *smithyhttp.Response, errorBody *bytes.Reader) error { + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + output := &types.ChannelARNInvalidException{} + err := awsAwsjson11_deserializeDocumentChannelARNInvalidException(&output, shape) + + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + return output +} + +func awsAwsjson11_deserializeErrorChannelNotFoundException(response *smithyhttp.Response, errorBody *bytes.Reader) error { + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + output := &types.ChannelNotFoundException{} + err := awsAwsjson11_deserializeDocumentChannelNotFoundException(&output, shape) + + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + return output +} + func awsAwsjson11_deserializeErrorCloudTrailAccessNotEnabledException(response *smithyhttp.Response, errorBody *bytes.Reader) error { var buff [1024]byte ringBuffer := smithyio.NewRingBuffer(buff[:]) @@ -6028,11 +6335,204 @@ func awsAwsjson11_deserializeDocumentAdvancedEventSelectors(v *[]types.AdvancedE cv = append(cv, col) } - *v = cv + *v = cv + return nil +} + +func awsAwsjson11_deserializeDocumentAdvancedFieldSelector(v **types.AdvancedFieldSelector, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.AdvancedFieldSelector + if *v == nil { + sv = &types.AdvancedFieldSelector{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "EndsWith": + if err := awsAwsjson11_deserializeDocumentOperator(&sv.EndsWith, value); err != nil { + return err + } + + case "Equals": + if err := awsAwsjson11_deserializeDocumentOperator(&sv.Equals, value); err != nil { + return err + } + + case "Field": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected SelectorField to be of type string, got %T instead", value) + } + sv.Field = ptr.String(jtv) + } + + case "NotEndsWith": + if err := awsAwsjson11_deserializeDocumentOperator(&sv.NotEndsWith, value); err != nil { + return err + } + + case "NotEquals": + if err := awsAwsjson11_deserializeDocumentOperator(&sv.NotEquals, value); err != nil { + return err + } + + case "NotStartsWith": + if err := awsAwsjson11_deserializeDocumentOperator(&sv.NotStartsWith, value); err != nil { + return err + } + + case "StartsWith": + if err := awsAwsjson11_deserializeDocumentOperator(&sv.StartsWith, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson11_deserializeDocumentAdvancedFieldSelectors(v *[]types.AdvancedFieldSelector, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.AdvancedFieldSelector + if *v == nil { + cv = []types.AdvancedFieldSelector{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.AdvancedFieldSelector + destAddr := &col + if err := awsAwsjson11_deserializeDocumentAdvancedFieldSelector(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsAwsjson11_deserializeDocumentChannel(v **types.Channel, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.Channel + if *v == nil { + sv = &types.Channel{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "ChannelArn": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ChannelArn to be of type string, got %T instead", value) + } + sv.ChannelArn = ptr.String(jtv) + } + + case "Name": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ChannelName to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson11_deserializeDocumentChannelARNInvalidException(v **types.ChannelARNInvalidException, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ChannelARNInvalidException + if *v == nil { + sv = &types.ChannelARNInvalidException{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "Message": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ErrorMessage to be of type string, got %T instead", value) + } + sv.Message = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv return nil } -func awsAwsjson11_deserializeDocumentAdvancedFieldSelector(v **types.AdvancedFieldSelector, value interface{}) error { +func awsAwsjson11_deserializeDocumentChannelNotFoundException(v **types.ChannelNotFoundException, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -6045,52 +6545,22 @@ func awsAwsjson11_deserializeDocumentAdvancedFieldSelector(v **types.AdvancedFie return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.AdvancedFieldSelector + var sv *types.ChannelNotFoundException if *v == nil { - sv = &types.AdvancedFieldSelector{} + sv = &types.ChannelNotFoundException{} } else { sv = *v } for key, value := range shape { switch key { - case "EndsWith": - if err := awsAwsjson11_deserializeDocumentOperator(&sv.EndsWith, value); err != nil { - return err - } - - case "Equals": - if err := awsAwsjson11_deserializeDocumentOperator(&sv.Equals, value); err != nil { - return err - } - - case "Field": + case "Message": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected SelectorField to be of type string, got %T instead", value) + return fmt.Errorf("expected ErrorMessage to be of type string, got %T instead", value) } - sv.Field = ptr.String(jtv) - } - - case "NotEndsWith": - if err := awsAwsjson11_deserializeDocumentOperator(&sv.NotEndsWith, value); err != nil { - return err - } - - case "NotEquals": - if err := awsAwsjson11_deserializeDocumentOperator(&sv.NotEquals, value); err != nil { - return err - } - - case "NotStartsWith": - if err := awsAwsjson11_deserializeDocumentOperator(&sv.NotStartsWith, value); err != nil { - return err - } - - case "StartsWith": - if err := awsAwsjson11_deserializeDocumentOperator(&sv.StartsWith, value); err != nil { - return err + sv.Message = ptr.String(jtv) } default: @@ -6102,7 +6572,7 @@ func awsAwsjson11_deserializeDocumentAdvancedFieldSelector(v **types.AdvancedFie return nil } -func awsAwsjson11_deserializeDocumentAdvancedFieldSelectors(v *[]types.AdvancedFieldSelector, value interface{}) error { +func awsAwsjson11_deserializeDocumentChannels(v *[]types.Channel, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -6115,17 +6585,17 @@ func awsAwsjson11_deserializeDocumentAdvancedFieldSelectors(v *[]types.AdvancedF return fmt.Errorf("unexpected JSON type %v", value) } - var cv []types.AdvancedFieldSelector + var cv []types.Channel if *v == nil { - cv = []types.AdvancedFieldSelector{} + cv = []types.Channel{} } else { cv = *v } for _, value := range shape { - var col types.AdvancedFieldSelector + var col types.Channel destAddr := &col - if err := awsAwsjson11_deserializeDocumentAdvancedFieldSelector(&destAddr, value); err != nil { + if err := awsAwsjson11_deserializeDocumentChannel(&destAddr, value); err != nil { return err } col = *destAddr @@ -6451,6 +6921,89 @@ func awsAwsjson11_deserializeDocumentDataResourceValues(v *[]string, value inter return nil } +func awsAwsjson11_deserializeDocumentDestination(v **types.Destination, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.Destination + if *v == nil { + sv = &types.Destination{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "Location": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Location to be of type string, got %T instead", value) + } + sv.Location = ptr.String(jtv) + } + + case "Type": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected DestinationType to be of type string, got %T instead", value) + } + sv.Type = types.DestinationType(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson11_deserializeDocumentDestinations(v *[]types.Destination, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.Destination + if *v == nil { + cv = []types.Destination{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.Destination + destAddr := &col + if err := awsAwsjson11_deserializeDocumentDestination(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsAwsjson11_deserializeDocumentEvent(v **types.Event, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -9577,6 +10130,51 @@ func awsAwsjson11_deserializeDocumentS3BucketDoesNotExistException(v **types.S3B return nil } +func awsAwsjson11_deserializeDocumentSourceConfig(v **types.SourceConfig, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.SourceConfig + if *v == nil { + sv = &types.SourceConfig{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "AdvancedEventSelectors": + if err := awsAwsjson11_deserializeDocumentAdvancedEventSelectors(&sv.AdvancedEventSelectors, value); err != nil { + return err + } + + case "ApplyToAllRegions": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected Boolean to be of type *bool, got %T instead", value) + } + sv.ApplyToAllRegions = ptr.Bool(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson11_deserializeDocumentTag(v **types.Tag, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -10699,6 +11297,74 @@ func awsAwsjson11_deserializeOpDocumentDescribeTrailsOutput(v **DescribeTrailsOu return nil } +func awsAwsjson11_deserializeOpDocumentGetChannelOutput(v **GetChannelOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *GetChannelOutput + if *v == nil { + sv = &GetChannelOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "ChannelArn": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ChannelArn to be of type string, got %T instead", value) + } + sv.ChannelArn = ptr.String(jtv) + } + + case "Destinations": + if err := awsAwsjson11_deserializeDocumentDestinations(&sv.Destinations, value); err != nil { + return err + } + + case "Name": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ChannelName to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) + } + + case "Source": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Source to be of type string, got %T instead", value) + } + sv.Source = ptr.String(jtv) + } + + case "SourceConfig": + if err := awsAwsjson11_deserializeDocumentSourceConfig(&sv.SourceConfig, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson11_deserializeOpDocumentGetEventDataStoreOutput(v **GetEventDataStoreOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -11259,6 +11925,51 @@ func awsAwsjson11_deserializeOpDocumentGetTrailStatusOutput(v **GetTrailStatusOu return nil } +func awsAwsjson11_deserializeOpDocumentListChannelsOutput(v **ListChannelsOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *ListChannelsOutput + if *v == nil { + sv = &ListChannelsOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "Channels": + if err := awsAwsjson11_deserializeDocumentChannels(&sv.Channels, value); err != nil { + return err + } + + case "NextToken": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected PaginationToken to be of type string, got %T instead", value) + } + sv.NextToken = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson11_deserializeOpDocumentListEventDataStoresOutput(v **ListEventDataStoresOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/cloudtrail/generated.json b/service/cloudtrail/generated.json index 5d278d63bb4..7626c965c30 100644 --- a/service/cloudtrail/generated.json +++ b/service/cloudtrail/generated.json @@ -16,12 +16,14 @@ "api_op_DeleteTrail.go", "api_op_DescribeQuery.go", "api_op_DescribeTrails.go", + "api_op_GetChannel.go", "api_op_GetEventDataStore.go", "api_op_GetEventSelectors.go", "api_op_GetInsightSelectors.go", "api_op_GetQueryResults.go", "api_op_GetTrail.go", "api_op_GetTrailStatus.go", + "api_op_ListChannels.go", "api_op_ListEventDataStores.go", "api_op_ListPublicKeys.go", "api_op_ListQueries.go", diff --git a/service/cloudtrail/serializers.go b/service/cloudtrail/serializers.go index 286061a486e..d3f1a24dc06 100644 --- a/service/cloudtrail/serializers.go +++ b/service/cloudtrail/serializers.go @@ -456,6 +456,61 @@ func (m *awsAwsjson11_serializeOpDescribeTrails) HandleSerialize(ctx context.Con return next.HandleSerialize(ctx, in) } +type awsAwsjson11_serializeOpGetChannel struct { +} + +func (*awsAwsjson11_serializeOpGetChannel) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson11_serializeOpGetChannel) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*GetChannelInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1") + httpBindingEncoder.SetHeader("X-Amz-Target").String("CloudTrail_20131101.GetChannel") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson11_serializeOpDocumentGetChannelInput(input, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsAwsjson11_serializeOpGetEventDataStore struct { } @@ -786,6 +841,61 @@ func (m *awsAwsjson11_serializeOpGetTrailStatus) HandleSerialize(ctx context.Con return next.HandleSerialize(ctx, in) } +type awsAwsjson11_serializeOpListChannels struct { +} + +func (*awsAwsjson11_serializeOpListChannels) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson11_serializeOpListChannels) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*ListChannelsInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1") + httpBindingEncoder.SetHeader("X-Amz-Target").String("CloudTrail_20131101.ListChannels") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson11_serializeOpDocumentListChannelsInput(input, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsAwsjson11_serializeOpListEventDataStores struct { } @@ -2136,6 +2246,18 @@ func awsAwsjson11_serializeOpDocumentDescribeTrailsInput(v *DescribeTrailsInput, return nil } +func awsAwsjson11_serializeOpDocumentGetChannelInput(v *GetChannelInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Channel != nil { + ok := object.Key("Channel") + ok.String(*v.Channel) + } + + return nil +} + func awsAwsjson11_serializeOpDocumentGetEventDataStoreInput(v *GetEventDataStoreInput, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -2223,6 +2345,23 @@ func awsAwsjson11_serializeOpDocumentGetTrailStatusInput(v *GetTrailStatusInput, return nil } +func awsAwsjson11_serializeOpDocumentListChannelsInput(v *ListChannelsInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.MaxResults != nil { + ok := object.Key("MaxResults") + ok.Integer(*v.MaxResults) + } + + if v.NextToken != nil { + ok := object.Key("NextToken") + ok.String(*v.NextToken) + } + + return nil +} + func awsAwsjson11_serializeOpDocumentListEventDataStoresInput(v *ListEventDataStoresInput, value smithyjson.Value) error { object := value.Object() defer object.Close() diff --git a/service/cloudtrail/types/enums.go b/service/cloudtrail/types/enums.go index 8828959997f..6a91b7d8659 100644 --- a/service/cloudtrail/types/enums.go +++ b/service/cloudtrail/types/enums.go @@ -2,6 +2,24 @@ package types +type DestinationType string + +// Enum values for DestinationType +const ( + DestinationTypeEventDataStore DestinationType = "EVENT_DATA_STORE" + DestinationTypeAwsService DestinationType = "AWS_SERVICE" +) + +// Values returns all known values for DestinationType. Note that this can be +// expanded in the future, and so it is only as up to date as the client. The +// ordering of this slice is not guaranteed to be stable across updates. +func (DestinationType) Values() []DestinationType { + return []DestinationType{ + "EVENT_DATA_STORE", + "AWS_SERVICE", + } +} + type EventCategory string // Enum values for EventCategory diff --git a/service/cloudtrail/types/errors.go b/service/cloudtrail/types/errors.go index 10f975ef479..50d3e64a63f 100644 --- a/service/cloudtrail/types/errors.go +++ b/service/cloudtrail/types/errors.go @@ -7,6 +7,45 @@ import ( smithy "github.com/aws/smithy-go" ) +// The specified channel ARN is not valid or does not map to a channel in your +// account. +type ChannelARNInvalidException struct { + Message *string + + noSmithyDocumentSerde +} + +func (e *ChannelARNInvalidException) Error() string { + return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage()) +} +func (e *ChannelARNInvalidException) ErrorMessage() string { + if e.Message == nil { + return "" + } + return *e.Message +} +func (e *ChannelARNInvalidException) ErrorCode() string { return "ChannelARNInvalidException" } +func (e *ChannelARNInvalidException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient } + +// The specified channel was not found. +type ChannelNotFoundException struct { + Message *string + + noSmithyDocumentSerde +} + +func (e *ChannelNotFoundException) Error() string { + return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage()) +} +func (e *ChannelNotFoundException) ErrorMessage() string { + if e.Message == nil { + return "" + } + return *e.Message +} +func (e *ChannelNotFoundException) ErrorCode() string { return "ChannelNotFoundException" } +func (e *ChannelNotFoundException) ErrorFault() smithy.ErrorFault { return smithy.FaultClient } + // This exception is thrown when trusted access has not been enabled between // CloudTrail and Organizations. For more information, see Enabling Trusted Access // with Other Amazon Web Services Services diff --git a/service/cloudtrail/types/types.go b/service/cloudtrail/types/types.go index 9fc20b6a22e..7853db61b22 100644 --- a/service/cloudtrail/types/types.go +++ b/service/cloudtrail/types/types.go @@ -52,8 +52,8 @@ type AdvancedFieldSelector struct { // // * readOnly - Optional. Can be set // to Equals a value of true or false. If you do not add this field, CloudTrail - // logs both both read and write events. A value of true logs only read events. A - // value of false logs only write events. + // logs both read and write events. A value of true logs only read events. A value + // of false logs only write events. // // * eventSource - For filtering management // events only. This can be set only to NotEqualskms.amazonaws.com. @@ -205,6 +205,21 @@ type AdvancedFieldSelector struct { noSmithyDocumentSerde } +// Contains information about a returned CloudTrail channel. +type Channel struct { + + // The Amazon Resource Name (ARN) of the channel. + ChannelArn *string + + // The name of the CloudTrail channel. For service-linked channels, the name is + // aws-service-channel/service-name/custom-suffix where service-name represents the + // name of the Amazon Web Services service that created the channel and + // custom-suffix represents the suffix created by the Amazon Web Services service. + Name *string + + noSmithyDocumentSerde +} + // The Amazon S3 buckets, Lambda functions, or Amazon DynamoDB tables that you // specify in your event selectors for your trail to log data events. Data events // provide information about the resource operations performed on or within a @@ -328,6 +343,23 @@ type DataResource struct { noSmithyDocumentSerde } +// Contains information about the service where CloudTrail delivers events. +type Destination struct { + + // The location of the service. For service-linked channels, this is the name of + // the Amazon Web Services service. + // + // This member is required. + Location *string + + // The type of service. For service-linked channels, the value is AWS_SERVICE. + // + // This member is required. + Type DestinationType + + noSmithyDocumentSerde +} + // Contains information about an event that was returned by a lookup request. The // result includes a representation of a CloudTrail event. type Event struct { @@ -367,7 +399,7 @@ type Event struct { // A storage lake of event data against which you can run complex SQL-based // queries. An event data store can include events that you have logged on your -// account from the last 90 to 2555 days (about three months to up to seven years). +// account from the last 90 to 2557 days (about three months to up to seven years). // To select events for an event data store, use advanced event selectors // (https://docs.aws.amazon.com/awscloudtrail/latest/userguide/logging-data-events-with-cloudtrail.html#creating-data-event-selectors-advanced). type EventDataStore struct { @@ -615,6 +647,19 @@ type ResourceTag struct { noSmithyDocumentSerde } +// Contains configuration information about the service-linked channel. +type SourceConfig struct { + + // The advanced event selectors configured for the service-linked channel. + AdvancedEventSelectors []AdvancedEventSelector + + // Specifies whether the service-linked channel applies to one region or all + // regions. + ApplyToAllRegions *bool + + noSmithyDocumentSerde +} + // A custom key-value pair associated with a resource such as a CloudTrail trail. type Tag struct { diff --git a/service/cloudtrail/validators.go b/service/cloudtrail/validators.go index 0e2addcc8db..a2d9b940490 100644 --- a/service/cloudtrail/validators.go +++ b/service/cloudtrail/validators.go @@ -150,6 +150,26 @@ func (m *validateOpDescribeQuery) HandleInitialize(ctx context.Context, in middl return next.HandleInitialize(ctx, in) } +type validateOpGetChannel struct { +} + +func (*validateOpGetChannel) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpGetChannel) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*GetChannelInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpGetChannelInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpGetEventDataStore struct { } @@ -538,6 +558,10 @@ func addOpDescribeQueryValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDescribeQuery{}, middleware.After) } +func addOpGetChannelValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpGetChannel{}, middleware.After) +} + func addOpGetEventDataStoreValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpGetEventDataStore{}, middleware.After) } @@ -881,6 +905,21 @@ func validateOpDescribeQueryInput(v *DescribeQueryInput) error { } } +func validateOpGetChannelInput(v *GetChannelInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "GetChannelInput"} + if v.Channel == nil { + invalidParams.Add(smithy.NewErrParamRequired("Channel")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpGetEventDataStoreInput(v *GetEventDataStoreInput) error { if v == nil { return nil diff --git a/service/customerprofiles/api_op_AddProfileKey.go b/service/customerprofiles/api_op_AddProfileKey.go index 007d43aee86..b4d6c707017 100644 --- a/service/customerprofiles/api_op_AddProfileKey.go +++ b/service/customerprofiles/api_op_AddProfileKey.go @@ -10,10 +10,9 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Associates a new key value with a specific profile, such as a Contact Trace -// Record (CTR) ContactId. A profile object can have a single unique key and any -// number of additional keys that can be used to identify the profile that it -// belongs to. +// Associates a new key value with a specific profile, such as a Contact Record +// ContactId. A profile object can have a single unique key and any number of +// additional keys that can be used to identify the profile that it belongs to. func (c *Client) AddProfileKey(ctx context.Context, params *AddProfileKeyInput, optFns ...func(*Options)) (*AddProfileKeyOutput, error) { if params == nil { params = &AddProfileKeyInput{} diff --git a/service/customerprofiles/api_op_GetIntegration.go b/service/customerprofiles/api_op_GetIntegration.go index 1aae63fd4dc..f285fa10e5b 100644 --- a/service/customerprofiles/api_op_GetIntegration.go +++ b/service/customerprofiles/api_op_GetIntegration.go @@ -64,6 +64,11 @@ type GetIntegrationOutput struct { // This member is required. Uri *string + // Boolean to indicate if the Flow associated with the Integration is created via + // Appflow console or with ObjectTypeName equals _unstructured via API/CLI in + // flowDefinition + IsUnstructured *bool + // The name of the profile object type. ObjectTypeName *string diff --git a/service/customerprofiles/api_op_PutIntegration.go b/service/customerprofiles/api_op_PutIntegration.go index efbfbcabc47..cd76b35bfd2 100644 --- a/service/customerprofiles/api_op_PutIntegration.go +++ b/service/customerprofiles/api_op_PutIntegration.go @@ -14,7 +14,10 @@ import ( // Adds an integration between the service and a third-party service, which // includes Amazon AppFlow and Amazon Connect. An integration can belong to only -// one domain. +// one domain. To add or remove tags on an existing Integration, see TagResource +// (https://docs.aws.amazon.com/customerprofiles/latest/APIReference/API_TagResource.html)/ +// UntagResource +// (https://docs.aws.amazon.com/customerprofiles/latest/APIReference/API_UntagResource.html). func (c *Client) PutIntegration(ctx context.Context, params *PutIntegrationInput, optFns ...func(*Options)) (*PutIntegrationOutput, error) { if params == nil { params = &PutIntegrationInput{} @@ -82,6 +85,11 @@ type PutIntegrationOutput struct { // This member is required. Uri *string + // Boolean to indicate if the Flow associated with the Integration is created via + // Appflow console or with ObjectTypeName equals _unstructured via API/CLI in + // flowDefinition + IsUnstructured *bool + // The name of the profile object type. ObjectTypeName *string diff --git a/service/customerprofiles/api_op_PutProfileObject.go b/service/customerprofiles/api_op_PutProfileObject.go index 021e1abc5d9..6dd12b6920e 100644 --- a/service/customerprofiles/api_op_PutProfileObject.go +++ b/service/customerprofiles/api_op_PutProfileObject.go @@ -11,15 +11,14 @@ import ( ) // Adds additional objects to customer profiles of a given ObjectType. When adding -// a specific profile object, like a Contact Trace Record (CTR), an inferred -// profile can get created if it is not mapped to an existing profile. The -// resulting profile will only have a phone number populated in the standard -// ProfileObject. Any additional CTRs with the same phone number will be mapped to -// the same inferred profile. When a ProfileObject is created and if a -// ProfileObjectType already exists for the ProfileObject, it will provide data to -// a standard profile depending on the ProfileObjectType definition. -// PutProfileObject needs an ObjectType, which can be created using -// PutProfileObjectType. +// a specific profile object, like a Contact Record, an inferred profile can get +// created if it is not mapped to an existing profile. The resulting profile will +// only have a phone number populated in the standard ProfileObject. Any additional +// Contact Records with the same phone number will be mapped to the same inferred +// profile. When a ProfileObject is created and if a ProfileObjectType already +// exists for the ProfileObject, it will provide data to a standard profile +// depending on the ProfileObjectType definition. PutProfileObject needs an +// ObjectType, which can be created using PutProfileObjectType. func (c *Client) PutProfileObject(ctx context.Context, params *PutProfileObjectInput, optFns ...func(*Options)) (*PutProfileObjectOutput, error) { if params == nil { params = &PutProfileObjectInput{} diff --git a/service/customerprofiles/api_op_PutProfileObjectType.go b/service/customerprofiles/api_op_PutProfileObjectType.go index 9108e773bad..90a63670ae8 100644 --- a/service/customerprofiles/api_op_PutProfileObjectType.go +++ b/service/customerprofiles/api_op_PutProfileObjectType.go @@ -12,7 +12,10 @@ import ( "time" ) -// Defines a ProfileObjectType. +// Defines a ProfileObjectType. To add or remove tags on an existing ObjectType, +// see TagResource +// (https://docs.aws.amazon.com/customerprofiles/latest/APIReference/API_TagResource.html)/UntagResource +// (https://docs.aws.amazon.com/customerprofiles/latest/APIReference/API_UntagResource.html). func (c *Client) PutProfileObjectType(ctx context.Context, params *PutProfileObjectTypeInput, optFns ...func(*Options)) (*PutProfileObjectTypeOutput, error) { if params == nil { params = &PutProfileObjectTypeInput{} diff --git a/service/customerprofiles/api_op_UpdateDomain.go b/service/customerprofiles/api_op_UpdateDomain.go index e590b19a300..a15e008df28 100644 --- a/service/customerprofiles/api_op_UpdateDomain.go +++ b/service/customerprofiles/api_op_UpdateDomain.go @@ -21,7 +21,10 @@ import ( // set Matching to true. To prevent cross-service impersonation when you call this // API, see Cross-service confused deputy prevention // (https://docs.aws.amazon.com/connect/latest/adminguide/cross-service-confused-deputy-prevention.html) -// for sample policies that you should apply. +// for sample policies that you should apply. To add or remove tags on an existing +// Domain, see TagResource +// (https://docs.aws.amazon.com/customerprofiles/latest/APIReference/API_TagResource.html)/UntagResource +// (https://docs.aws.amazon.com/customerprofiles/latest/APIReference/API_UntagResource.html). func (c *Client) UpdateDomain(ctx context.Context, params *UpdateDomainInput, optFns ...func(*Options)) (*UpdateDomainOutput, error) { if params == nil { params = &UpdateDomainInput{} diff --git a/service/customerprofiles/deserializers.go b/service/customerprofiles/deserializers.go index 4406e1436c6..dc397ac8c32 100644 --- a/service/customerprofiles/deserializers.go +++ b/service/customerprofiles/deserializers.go @@ -2714,6 +2714,15 @@ func awsRestjson1_deserializeOpDocumentGetIntegrationOutput(v **GetIntegrationOu sv.DomainName = ptr.String(jtv) } + case "IsUnstructured": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected optionalBoolean to be of type *bool, got %T instead", value) + } + sv.IsUnstructured = ptr.Bool(jtv) + } + case "LastUpdatedAt": if value != nil { switch jtv := value.(type) { @@ -5695,6 +5704,15 @@ func awsRestjson1_deserializeOpDocumentPutIntegrationOutput(v **PutIntegrationOu sv.DomainName = ptr.String(jtv) } + case "IsUnstructured": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected optionalBoolean to be of type *bool, got %T instead", value) + } + sv.IsUnstructured = ptr.Bool(jtv) + } + case "LastUpdatedAt": if value != nil { switch jtv := value.(type) { @@ -8522,6 +8540,15 @@ func awsRestjson1_deserializeDocumentListIntegrationItem(v **types.ListIntegrati sv.DomainName = ptr.String(jtv) } + case "IsUnstructured": + if value != nil { + jtv, ok := value.(bool) + if !ok { + return fmt.Errorf("expected optionalBoolean to be of type *bool, got %T instead", value) + } + sv.IsUnstructured = ptr.Bool(jtv) + } + case "LastUpdatedAt": if value != nil { switch jtv := value.(type) { diff --git a/service/customerprofiles/types/types.go b/service/customerprofiles/types/types.go index 6ad4b57db51..510aea9bc10 100644 --- a/service/customerprofiles/types/types.go +++ b/service/customerprofiles/types/types.go @@ -561,6 +561,11 @@ type ListIntegrationItem struct { // This member is required. Uri *string + // Boolean to indicate if the Flow associated with the Integration is created via + // Appflow console or with ObjectTypeName equals _unstructured via API/CLI in + // flowDefinition + IsUnstructured *bool + // The name of the profile object type. ObjectTypeName *string diff --git a/service/dataexchange/api_op_CreateDataSet.go b/service/dataexchange/api_op_CreateDataSet.go index 0c9d76f3a2f..ebaae186db6 100644 --- a/service/dataexchange/api_op_CreateDataSet.go +++ b/service/dataexchange/api_op_CreateDataSet.go @@ -28,7 +28,6 @@ func (c *Client) CreateDataSet(ctx context.Context, params *CreateDataSetInput, return out, nil } -// The request body for CreateDataSet. type CreateDataSetInput struct { // The type of asset that is added to a data set. diff --git a/service/dataexchange/api_op_CreateEventAction.go b/service/dataexchange/api_op_CreateEventAction.go index 275650d99bd..d8450c56c55 100644 --- a/service/dataexchange/api_op_CreateEventAction.go +++ b/service/dataexchange/api_op_CreateEventAction.go @@ -28,7 +28,6 @@ func (c *Client) CreateEventAction(ctx context.Context, params *CreateEventActio return out, nil } -// The request body for CreateEventAction. type CreateEventActionInput struct { // What occurs after a certain event. diff --git a/service/dataexchange/api_op_CreateJob.go b/service/dataexchange/api_op_CreateJob.go index c5b06419e4a..75593a26f30 100644 --- a/service/dataexchange/api_op_CreateJob.go +++ b/service/dataexchange/api_op_CreateJob.go @@ -28,7 +28,6 @@ func (c *Client) CreateJob(ctx context.Context, params *CreateJobInput, optFns . return out, nil } -// The request body for CreateJob. type CreateJobInput struct { // The details for the CreateJob request. diff --git a/service/dataexchange/api_op_CreateRevision.go b/service/dataexchange/api_op_CreateRevision.go index 4ae6ac3c567..8f13ca3325a 100644 --- a/service/dataexchange/api_op_CreateRevision.go +++ b/service/dataexchange/api_op_CreateRevision.go @@ -27,7 +27,6 @@ func (c *Client) CreateRevision(ctx context.Context, params *CreateRevisionInput return out, nil } -// The request body for CreateRevision. type CreateRevisionInput struct { // The unique identifier for a data set. diff --git a/service/dataexchange/api_op_RevokeRevision.go b/service/dataexchange/api_op_RevokeRevision.go index 9a9c738405a..b87401fc9d7 100644 --- a/service/dataexchange/api_op_RevokeRevision.go +++ b/service/dataexchange/api_op_RevokeRevision.go @@ -27,7 +27,6 @@ func (c *Client) RevokeRevision(ctx context.Context, params *RevokeRevisionInput return out, nil } -// The request body for RevokeRevision. type RevokeRevisionInput struct { // The unique identifier for a data set. diff --git a/service/dataexchange/api_op_SendApiAsset.go b/service/dataexchange/api_op_SendApiAsset.go index 93e5868dc21..ee5a8ce73b0 100644 --- a/service/dataexchange/api_op_SendApiAsset.go +++ b/service/dataexchange/api_op_SendApiAsset.go @@ -28,7 +28,6 @@ func (c *Client) SendApiAsset(ctx context.Context, params *SendApiAssetInput, op return out, nil } -// The request body for SendApiAsset. type SendApiAssetInput struct { // Asset ID value for the API request. @@ -54,7 +53,7 @@ type SendApiAssetInput struct { Method *string // URI path value for the API request. Alternatively, you can set the URI path - // directly by invoking /v1/{pathValue} + // directly by invoking /v1/{pathValue}. Path *string // Attach query string parameters to the end of the URI (for example, diff --git a/service/dataexchange/api_op_TagResource.go b/service/dataexchange/api_op_TagResource.go index 02574face30..7b41b27d033 100644 --- a/service/dataexchange/api_op_TagResource.go +++ b/service/dataexchange/api_op_TagResource.go @@ -26,7 +26,6 @@ func (c *Client) TagResource(ctx context.Context, params *TagResourceInput, optF return out, nil } -// The request body for TagResource. type TagResourceInput struct { // An Amazon Resource Name (ARN) that uniquely identifies an AWS resource. diff --git a/service/dataexchange/api_op_UpdateAsset.go b/service/dataexchange/api_op_UpdateAsset.go index 8b2aa602631..b1762d4d0a8 100644 --- a/service/dataexchange/api_op_UpdateAsset.go +++ b/service/dataexchange/api_op_UpdateAsset.go @@ -28,7 +28,6 @@ func (c *Client) UpdateAsset(ctx context.Context, params *UpdateAssetInput, optF return out, nil } -// The request body for UpdateAsset. type UpdateAssetInput struct { // The unique identifier for an asset. diff --git a/service/dataexchange/api_op_UpdateDataSet.go b/service/dataexchange/api_op_UpdateDataSet.go index 0e55a982048..7242364ca34 100644 --- a/service/dataexchange/api_op_UpdateDataSet.go +++ b/service/dataexchange/api_op_UpdateDataSet.go @@ -28,7 +28,6 @@ func (c *Client) UpdateDataSet(ctx context.Context, params *UpdateDataSetInput, return out, nil } -// The request body for UpdateDataSet. type UpdateDataSetInput struct { // The unique identifier for a data set. diff --git a/service/dataexchange/api_op_UpdateEventAction.go b/service/dataexchange/api_op_UpdateEventAction.go index da67d4b2446..00a22f05522 100644 --- a/service/dataexchange/api_op_UpdateEventAction.go +++ b/service/dataexchange/api_op_UpdateEventAction.go @@ -28,7 +28,6 @@ func (c *Client) UpdateEventAction(ctx context.Context, params *UpdateEventActio return out, nil } -// The request body for UpdateEventAction. type UpdateEventActionInput struct { // The unique identifier for the event action. diff --git a/service/dataexchange/api_op_UpdateRevision.go b/service/dataexchange/api_op_UpdateRevision.go index 1d5c11370cf..28a86cd46cf 100644 --- a/service/dataexchange/api_op_UpdateRevision.go +++ b/service/dataexchange/api_op_UpdateRevision.go @@ -27,7 +27,6 @@ func (c *Client) UpdateRevision(ctx context.Context, params *UpdateRevisionInput return out, nil } -// The request body for UpdateRevision. type UpdateRevisionInput struct { // The unique identifier for a data set. diff --git a/service/dataexchange/doc.go b/service/dataexchange/doc.go index 0292bef2386..56ce202c6cd 100644 --- a/service/dataexchange/doc.go +++ b/service/dataexchange/doc.go @@ -5,14 +5,14 @@ // // AWS Data Exchange is a service that makes it easy for AWS customers to exchange // data in the cloud. You can use the AWS Data Exchange APIs to create, update, -// manage, and access file-based data set in the AWS Cloud.As a subscriber, you can -// view and access the data sets that you have an entitlement to through a +// manage, and access file-based data set in the AWS Cloud. As a subscriber, you +// can view and access the data sets that you have an entitlement to through a // subscription. You can use the APIS to download or copy your entitled data sets // to Amazon S3 for use across a variety of AWS analytics and machine learning -// services.As a provider, you can create and manage your data sets that you would +// services. As a provider, you can create and manage your data sets that you would // like to publish to a product. Being able to package and provide your data sets // into products requires a few steps to determine eligibility. For more -// information, visit the AWS Data Exchange User Guide.A data set is a collection +// information, visit the AWS Data Exchange User Guide. A data set is a collection // of data that can be changed or updated over time. Data sets can be updated using // revisions, which represent a new version or incremental change to a data set. A // revision contains one or more assets. An asset in AWS Data Exchange is a piece diff --git a/service/dataexchange/types/types.go b/service/dataexchange/types/types.go index 68759867266..3a1954ffa9e 100644 --- a/service/dataexchange/types/types.go +++ b/service/dataexchange/types/types.go @@ -450,7 +450,7 @@ type ExportRevisionsToS3ResponseDetails struct { // Encryption configuration of the export job. Includes the encryption type in // addition to the AWS KMS key. The KMS key is only necessary if you chose the KMS -// encryption. type. +// encryption type. type ExportServerSideEncryption struct { // The type of server side encryption used for encrypting the objects in Amazon S3. @@ -851,16 +851,16 @@ type RequestDetails struct { // Details about the export to Amazon S3 request. ExportRevisionsToS3 *ExportRevisionsToS3RequestDetails - // Information about the import asset from API Gateway API request. + // Details about the import from signed URL request. ImportAssetFromApiGatewayApi *ImportAssetFromApiGatewayApiRequestDetails - // Details about the import from signed URL request. + // Details about the import from Amazon S3 request. ImportAssetFromSignedUrl *ImportAssetFromSignedUrlRequestDetails // Details from an import from Amazon Redshift datashare request. ImportAssetsFromRedshiftDataShares *ImportAssetsFromRedshiftDataSharesRequestDetails - // Details about the import from Amazon S3 request. + // Information about the import asset from API Gateway API request. ImportAssetsFromS3 *ImportAssetsFromS3RequestDetails noSmithyDocumentSerde diff --git a/service/drs/deserializers.go b/service/drs/deserializers.go index 4a494986d25..efb466aec5b 100644 --- a/service/drs/deserializers.go +++ b/service/drs/deserializers.go @@ -6168,7 +6168,7 @@ func awsRestjson1_deserializeDocumentDataReplicationInfo(v **types.DataReplicati if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ISO8601DatetimeString to be of type string, got %T instead", value) + return fmt.Errorf("expected ISO8601DurationString to be of type string, got %T instead", value) } sv.LagDuration = ptr.String(jtv) } @@ -7136,7 +7136,7 @@ func awsRestjson1_deserializeDocumentLifeCycle(v **types.LifeCycle, value interf if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ISO8601DatetimeString to be of type string, got %T instead", value) + return fmt.Errorf("expected ISO8601DurationString to be of type string, got %T instead", value) } sv.ElapsedReplicationDuration = ptr.String(jtv) } diff --git a/service/ec2/api_op_AttachClassicLinkVpc.go b/service/ec2/api_op_AttachClassicLinkVpc.go index c3045857db3..904151f47bc 100644 --- a/service/ec2/api_op_AttachClassicLinkVpc.go +++ b/service/ec2/api_op_AttachClassicLinkVpc.go @@ -10,10 +10,10 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. Links an EC2-Classic instance to a +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. Links an EC2-Classic instance to a // ClassicLink-enabled VPC through one or more of the VPC's security groups. You // cannot link an EC2-Classic instance to more than one VPC at a time. You can only // link an instance that's in the running state. An instance is automatically diff --git a/service/ec2/api_op_CreateCoipCidr.go b/service/ec2/api_op_CreateCoipCidr.go new file mode 100644 index 00000000000..5f14ab657f2 --- /dev/null +++ b/service/ec2/api_op_CreateCoipCidr.go @@ -0,0 +1,132 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package ec2 + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/ec2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Creates a range of customer-owned IP addresses. +func (c *Client) CreateCoipCidr(ctx context.Context, params *CreateCoipCidrInput, optFns ...func(*Options)) (*CreateCoipCidrOutput, error) { + if params == nil { + params = &CreateCoipCidrInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "CreateCoipCidr", params, optFns, c.addOperationCreateCoipCidrMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*CreateCoipCidrOutput) + out.ResultMetadata = metadata + return out, nil +} + +type CreateCoipCidrInput struct { + + // A customer-owned IP address range to create. + // + // This member is required. + Cidr *string + + // The ID of the address pool. + // + // This member is required. + CoipPoolId *string + + // Checks whether you have the required permissions for the action, without + // actually making the request, and provides an error response. If you have the + // required permissions, the error response is DryRunOperation. Otherwise, it is + // UnauthorizedOperation. + DryRun *bool + + noSmithyDocumentSerde +} + +type CreateCoipCidrOutput struct { + + // Information about a range of customer-owned IP addresses. + CoipCidr *types.CoipCidr + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationCreateCoipCidrMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsEc2query_serializeOpCreateCoipCidr{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsEc2query_deserializeOpCreateCoipCidr{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpCreateCoipCidrValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreateCoipCidr(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opCreateCoipCidr(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "ec2", + OperationName: "CreateCoipCidr", + } +} diff --git a/service/ec2/api_op_CreateCoipPool.go b/service/ec2/api_op_CreateCoipPool.go new file mode 100644 index 00000000000..1281ab14883 --- /dev/null +++ b/service/ec2/api_op_CreateCoipPool.go @@ -0,0 +1,130 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package ec2 + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/ec2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Creates a pool of customer-owned IP (CoIP) addresses. +func (c *Client) CreateCoipPool(ctx context.Context, params *CreateCoipPoolInput, optFns ...func(*Options)) (*CreateCoipPoolOutput, error) { + if params == nil { + params = &CreateCoipPoolInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "CreateCoipPool", params, optFns, c.addOperationCreateCoipPoolMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*CreateCoipPoolOutput) + out.ResultMetadata = metadata + return out, nil +} + +type CreateCoipPoolInput struct { + + // The ID of the local gateway route table. + // + // This member is required. + LocalGatewayRouteTableId *string + + // Checks whether you have the required permissions for the action, without + // actually making the request, and provides an error response. If you have the + // required permissions, the error response is DryRunOperation. Otherwise, it is + // UnauthorizedOperation. + DryRun *bool + + // The tags to assign to the CoIP address pool. + TagSpecifications []types.TagSpecification + + noSmithyDocumentSerde +} + +type CreateCoipPoolOutput struct { + + // Describes a customer-owned address pool. + CoipPool *types.CoipPool + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationCreateCoipPoolMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsEc2query_serializeOpCreateCoipPool{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsEc2query_deserializeOpCreateCoipPool{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpCreateCoipPoolValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreateCoipPool(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opCreateCoipPool(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "ec2", + OperationName: "CreateCoipPool", + } +} diff --git a/service/ec2/api_op_CreateDefaultVpc.go b/service/ec2/api_op_CreateDefaultVpc.go index e0274d07700..371118e505b 100644 --- a/service/ec2/api_op_CreateDefaultVpc.go +++ b/service/ec2/api_op_CreateDefaultVpc.go @@ -22,9 +22,9 @@ import ( // default VPC in a Region that supports EC2-Classic. If you want a default VPC in // a Region that supports EC2-Classic, see "I really want a default VPC for my // existing EC2 account. Is that possible?" in the Default VPCs FAQ -// (http://aws.amazon.com/vpc/faqs/#Default_VPCs). We are retiring EC2-Classic on -// August 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For -// more information, see Migrate from EC2-Classic to a VPC +// (http://aws.amazon.com/vpc/faqs/#Default_VPCs). We are retiring EC2-Classic. We +// recommend that you migrate from EC2-Classic to a VPC. For more information, see +// Migrate from EC2-Classic to a VPC // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the // Amazon Elastic Compute Cloud User Guide. func (c *Client) CreateDefaultVpc(ctx context.Context, params *CreateDefaultVpcInput, optFns ...func(*Options)) (*CreateDefaultVpcOutput, error) { diff --git a/service/ec2/api_op_CreateFlowLogs.go b/service/ec2/api_op_CreateFlowLogs.go index 3a0df139738..385b76c29f8 100644 --- a/service/ec2/api_op_CreateFlowLogs.go +++ b/service/ec2/api_op_CreateFlowLogs.go @@ -42,14 +42,13 @@ func (c *Client) CreateFlowLogs(ctx context.Context, params *CreateFlowLogsInput type CreateFlowLogsInput struct { - // The ID of the subnet, network interface, or VPC for which you want to create a - // flow log. Constraints: Maximum of 1000 resources + // The IDs of the resources to monitor. For example, if the resource type is VPC, + // specify the IDs of the VPCs. Constraints: Maximum of 1000 resources // // This member is required. ResourceIds []string - // The type of resource for which to create the flow log. For example, if you - // specified a VPC ID for the ResourceId property, specify VPC for this property. + // The type of resource to monitor. // // This member is required. ResourceType types.FlowLogsResourceType @@ -59,9 +58,13 @@ type CreateFlowLogsInput struct { // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Run_Instance_Idempotency.html). ClientToken *string - // The ARN for the IAM role that permits Amazon EC2 to publish flow logs to a - // CloudWatch Logs log group in your account. If you specify LogDestinationType as - // s3, do not specify DeliverLogsPermissionArn or LogGroupName. + // The ARN of the IAM role that allows Amazon EC2 to publish flow logs across + // accounts. + DeliverCrossAccountRole *string + + // The ARN of the IAM role that allows Amazon EC2 to publish flow logs to a + // CloudWatch Logs log group in your account. This parameter is required if the + // destination type is cloud-watch-logs and unsupported otherwise. DeliverLogsPermissionArn *string // The destination options. @@ -73,41 +76,40 @@ type CreateFlowLogsInput struct { // UnauthorizedOperation. DryRun *bool - // The destination to which the flow log data is to be published. Flow log data can - // be published to a CloudWatch Logs log group or an Amazon S3 bucket. The value - // specified for this parameter depends on the value specified for - // LogDestinationType. If LogDestinationType is not specified or cloud-watch-logs, - // specify the Amazon Resource Name (ARN) of the CloudWatch Logs log group. For - // example, to publish to a log group called my-logs, specify - // arn:aws:logs:us-east-1:123456789012:log-group:my-logs. Alternatively, use - // LogGroupName instead. If LogDestinationType is s3, specify the ARN of the Amazon - // S3 bucket. You can also specify a subfolder in the bucket. To specify a - // subfolder in the bucket, use the following ARN format: - // bucket_ARN/subfolder_name/. For example, to specify a subfolder named my-logs in - // a bucket named my-bucket, use the following ARN: - // arn:aws:s3:::my-bucket/my-logs/. You cannot use AWSLogs as a subfolder name. - // This is a reserved term. + // The destination for the flow log data. The meaning of this parameter depends on + // the destination type. + // + // * If the destination type is cloud-watch-logs, specify + // the ARN of a CloudWatch Logs log group. For example: + // arn:aws:logs:region:account_id:log-group:my_group Alternatively, use the + // LogGroupName parameter. + // + // * If the destination type is s3, specify the ARN of an + // S3 bucket. For example: arn:aws:s3:::my_bucket/my_subfolder/ The subfolder is + // optional. Note that you can't use AWSLogs as a subfolder name. + // + // * If the + // destination type is kinesis-data-firehose, specify the ARN of a Kinesis Data + // Firehose delivery stream. For example: + // arn:aws:firehose:region:account_id:deliverystream:my_stream LogDestination *string - // The type of destination to which the flow log data is to be published. Flow log - // data can be published to CloudWatch Logs or Amazon S3. To publish flow log data - // to CloudWatch Logs, specify cloud-watch-logs. To publish flow log data to Amazon - // S3, specify s3. If you specify LogDestinationType as s3, do not specify - // DeliverLogsPermissionArn or LogGroupName. Default: cloud-watch-logs + // The type of destination for the flow log data. Default: cloud-watch-logs LogDestinationType types.LogDestinationType - // The fields to include in the flow log record, in the order in which they should - // appear. For a list of available fields, see Flow log records + // The fields to include in the flow log record. List the fields in the order in + // which they should appear. For more information about the available fields, see + // Flow log records // (https://docs.aws.amazon.com/vpc/latest/userguide/flow-logs.html#flow-log-records). // If you omit this parameter, the flow log is created using the default format. If - // you specify this parameter, you must specify at least one field. Specify the + // you specify this parameter, you must include at least one field. Specify the // fields using the ${field-id} format, separated by spaces. For the CLI, surround // this parameter value with single quotes on Linux or double quotes on Windows. LogFormat *string // The name of a new or existing CloudWatch Logs log group where Amazon EC2 - // publishes your flow logs. If you specify LogDestinationType as s3, do not - // specify DeliverLogsPermissionArn or LogGroupName. + // publishes your flow logs. This parameter is valid only if the destination type + // is cloud-watch-logs. LogGroupName *string // The maximum interval of time during which a flow of packets is captured and @@ -122,8 +124,8 @@ type CreateFlowLogsInput struct { // The tags to apply to the flow logs. TagSpecifications []types.TagSpecification - // The type of traffic to log. You can log traffic that the resource accepts or - // rejects, or all traffic. + // The type of traffic to monitor (accepted traffic, rejected traffic, or all + // traffic). TrafficType types.TrafficType noSmithyDocumentSerde diff --git a/service/ec2/api_op_CreateLocalGatewayRoute.go b/service/ec2/api_op_CreateLocalGatewayRoute.go index 4cf0da0e46c..a8ead5b991d 100644 --- a/service/ec2/api_op_CreateLocalGatewayRoute.go +++ b/service/ec2/api_op_CreateLocalGatewayRoute.go @@ -11,7 +11,13 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Creates a static route for the specified local gateway route table. +// Creates a static route for the specified local gateway route table. You must +// specify one of the following targets: +// +// * LocalGatewayVirtualInterfaceGroupId +// +// * +// NetworkInterfaceId func (c *Client) CreateLocalGatewayRoute(ctx context.Context, params *CreateLocalGatewayRouteInput, optFns ...func(*Options)) (*CreateLocalGatewayRouteOutput, error) { if params == nil { params = &CreateLocalGatewayRouteInput{} @@ -40,17 +46,18 @@ type CreateLocalGatewayRouteInput struct { // This member is required. LocalGatewayRouteTableId *string - // The ID of the virtual interface group. - // - // This member is required. - LocalGatewayVirtualInterfaceGroupId *string - // Checks whether you have the required permissions for the action, without // actually making the request, and provides an error response. If you have the // required permissions, the error response is DryRunOperation. Otherwise, it is // UnauthorizedOperation. DryRun *bool + // The ID of the virtual interface group. + LocalGatewayVirtualInterfaceGroupId *string + + // The ID of the network interface. + NetworkInterfaceId *string + noSmithyDocumentSerde } diff --git a/service/ec2/api_op_CreateLocalGatewayRouteTable.go b/service/ec2/api_op_CreateLocalGatewayRouteTable.go new file mode 100644 index 00000000000..cdcc20dfb2f --- /dev/null +++ b/service/ec2/api_op_CreateLocalGatewayRouteTable.go @@ -0,0 +1,133 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package ec2 + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/ec2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Creates a local gateway route table. +func (c *Client) CreateLocalGatewayRouteTable(ctx context.Context, params *CreateLocalGatewayRouteTableInput, optFns ...func(*Options)) (*CreateLocalGatewayRouteTableOutput, error) { + if params == nil { + params = &CreateLocalGatewayRouteTableInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "CreateLocalGatewayRouteTable", params, optFns, c.addOperationCreateLocalGatewayRouteTableMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*CreateLocalGatewayRouteTableOutput) + out.ResultMetadata = metadata + return out, nil +} + +type CreateLocalGatewayRouteTableInput struct { + + // The ID of the local gateway. + // + // This member is required. + LocalGatewayId *string + + // Checks whether you have the required permissions for the action, without + // actually making the request, and provides an error response. If you have the + // required permissions, the error response is DryRunOperation. Otherwise, it is + // UnauthorizedOperation. + DryRun *bool + + // The mode of the local gateway route table. + Mode types.LocalGatewayRouteTableMode + + // The tags assigned to the local gateway route table. + TagSpecifications []types.TagSpecification + + noSmithyDocumentSerde +} + +type CreateLocalGatewayRouteTableOutput struct { + + // Describes a local gateway route table. + LocalGatewayRouteTable *types.LocalGatewayRouteTable + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationCreateLocalGatewayRouteTableMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsEc2query_serializeOpCreateLocalGatewayRouteTable{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsEc2query_deserializeOpCreateLocalGatewayRouteTable{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpCreateLocalGatewayRouteTableValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreateLocalGatewayRouteTable(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opCreateLocalGatewayRouteTable(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "ec2", + OperationName: "CreateLocalGatewayRouteTable", + } +} diff --git a/service/ec2/api_op_CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation.go b/service/ec2/api_op_CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation.go new file mode 100644 index 00000000000..760313dd02e --- /dev/null +++ b/service/ec2/api_op_CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation.go @@ -0,0 +1,137 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package ec2 + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/ec2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Creates a local gateway route table virtual interface group association. +func (c *Client) CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation(ctx context.Context, params *CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput, optFns ...func(*Options)) (*CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput, error) { + if params == nil { + params = &CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation", params, optFns, c.addOperationCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput) + out.ResultMetadata = metadata + return out, nil +} + +type CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput struct { + + // The ID of the local gateway route table. + // + // This member is required. + LocalGatewayRouteTableId *string + + // The ID of the local gateway route table virtual interface group association. + // + // This member is required. + LocalGatewayVirtualInterfaceGroupId *string + + // Checks whether you have the required permissions for the action, without + // actually making the request, and provides an error response. If you have the + // required permissions, the error response is DryRunOperation. Otherwise, it is + // UnauthorizedOperation. + DryRun *bool + + // The tags assigned to the local gateway route table virtual interface group + // association. + TagSpecifications []types.TagSpecification + + noSmithyDocumentSerde +} + +type CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput struct { + + // Describes an association between a local gateway route table and a virtual + // interface group. + LocalGatewayRouteTableVirtualInterfaceGroupAssociation *types.LocalGatewayRouteTableVirtualInterfaceGroupAssociation + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsEc2query_serializeOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsEc2query_deserializeOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "ec2", + OperationName: "CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation", + } +} diff --git a/service/ec2/api_op_DeleteCoipCidr.go b/service/ec2/api_op_DeleteCoipCidr.go new file mode 100644 index 00000000000..a220270edf6 --- /dev/null +++ b/service/ec2/api_op_DeleteCoipCidr.go @@ -0,0 +1,132 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package ec2 + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/ec2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Deletes a range of customer-owned IP addresses. +func (c *Client) DeleteCoipCidr(ctx context.Context, params *DeleteCoipCidrInput, optFns ...func(*Options)) (*DeleteCoipCidrOutput, error) { + if params == nil { + params = &DeleteCoipCidrInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DeleteCoipCidr", params, optFns, c.addOperationDeleteCoipCidrMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DeleteCoipCidrOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DeleteCoipCidrInput struct { + + // A customer-owned IP address range that you want to delete. + // + // This member is required. + Cidr *string + + // The ID of the customer-owned address pool. + // + // This member is required. + CoipPoolId *string + + // Checks whether you have the required permissions for the action, without + // actually making the request, and provides an error response. If you have the + // required permissions, the error response is DryRunOperation. Otherwise, it is + // UnauthorizedOperation. + DryRun *bool + + noSmithyDocumentSerde +} + +type DeleteCoipCidrOutput struct { + + // Information about a range of customer-owned IP addresses. + CoipCidr *types.CoipCidr + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDeleteCoipCidrMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsEc2query_serializeOpDeleteCoipCidr{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsEc2query_deserializeOpDeleteCoipCidr{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpDeleteCoipCidrValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteCoipCidr(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opDeleteCoipCidr(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "ec2", + OperationName: "DeleteCoipCidr", + } +} diff --git a/service/ec2/api_op_DeleteCoipPool.go b/service/ec2/api_op_DeleteCoipPool.go new file mode 100644 index 00000000000..6814586819a --- /dev/null +++ b/service/ec2/api_op_DeleteCoipPool.go @@ -0,0 +1,127 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package ec2 + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/ec2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Deletes a pool of customer-owned IP (CoIP) addresses. +func (c *Client) DeleteCoipPool(ctx context.Context, params *DeleteCoipPoolInput, optFns ...func(*Options)) (*DeleteCoipPoolOutput, error) { + if params == nil { + params = &DeleteCoipPoolInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DeleteCoipPool", params, optFns, c.addOperationDeleteCoipPoolMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DeleteCoipPoolOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DeleteCoipPoolInput struct { + + // The ID of the CoIP pool that you want to delete. + // + // This member is required. + CoipPoolId *string + + // Checks whether you have the required permissions for the action, without + // actually making the request, and provides an error response. If you have the + // required permissions, the error response is DryRunOperation. Otherwise, it is + // UnauthorizedOperation. + DryRun *bool + + noSmithyDocumentSerde +} + +type DeleteCoipPoolOutput struct { + + // Describes a customer-owned address pool. + CoipPool *types.CoipPool + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDeleteCoipPoolMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsEc2query_serializeOpDeleteCoipPool{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsEc2query_deserializeOpDeleteCoipPool{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpDeleteCoipPoolValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteCoipPool(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opDeleteCoipPool(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "ec2", + OperationName: "DeleteCoipPool", + } +} diff --git a/service/ec2/api_op_DeleteLocalGatewayRouteTable.go b/service/ec2/api_op_DeleteLocalGatewayRouteTable.go new file mode 100644 index 00000000000..10f6c4ddab0 --- /dev/null +++ b/service/ec2/api_op_DeleteLocalGatewayRouteTable.go @@ -0,0 +1,127 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package ec2 + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/ec2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Deletes a local gateway route table. +func (c *Client) DeleteLocalGatewayRouteTable(ctx context.Context, params *DeleteLocalGatewayRouteTableInput, optFns ...func(*Options)) (*DeleteLocalGatewayRouteTableOutput, error) { + if params == nil { + params = &DeleteLocalGatewayRouteTableInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DeleteLocalGatewayRouteTable", params, optFns, c.addOperationDeleteLocalGatewayRouteTableMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DeleteLocalGatewayRouteTableOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DeleteLocalGatewayRouteTableInput struct { + + // The ID of the local gateway route table. + // + // This member is required. + LocalGatewayRouteTableId *string + + // Checks whether you have the required permissions for the action, without + // actually making the request, and provides an error response. If you have the + // required permissions, the error response is DryRunOperation. Otherwise, it is + // UnauthorizedOperation. + DryRun *bool + + noSmithyDocumentSerde +} + +type DeleteLocalGatewayRouteTableOutput struct { + + // Describes a local gateway route table. + LocalGatewayRouteTable *types.LocalGatewayRouteTable + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDeleteLocalGatewayRouteTableMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsEc2query_serializeOpDeleteLocalGatewayRouteTable{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsEc2query_deserializeOpDeleteLocalGatewayRouteTable{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpDeleteLocalGatewayRouteTableValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteLocalGatewayRouteTable(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opDeleteLocalGatewayRouteTable(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "ec2", + OperationName: "DeleteLocalGatewayRouteTable", + } +} diff --git a/service/ec2/api_op_DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation.go b/service/ec2/api_op_DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation.go new file mode 100644 index 00000000000..e62185835f9 --- /dev/null +++ b/service/ec2/api_op_DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation.go @@ -0,0 +1,128 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package ec2 + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/ec2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Deletes a local gateway route table virtual interface group association. +func (c *Client) DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation(ctx context.Context, params *DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput, optFns ...func(*Options)) (*DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput, error) { + if params == nil { + params = &DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation", params, optFns, c.addOperationDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput struct { + + // The ID of the local gateway route table virtual interface group association. + // + // This member is required. + LocalGatewayRouteTableVirtualInterfaceGroupAssociationId *string + + // Checks whether you have the required permissions for the action, without + // actually making the request, and provides an error response. If you have the + // required permissions, the error response is DryRunOperation. Otherwise, it is + // UnauthorizedOperation. + DryRun *bool + + noSmithyDocumentSerde +} + +type DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput struct { + + // Describes an association between a local gateway route table and a virtual + // interface group. + LocalGatewayRouteTableVirtualInterfaceGroupAssociation *types.LocalGatewayRouteTableVirtualInterfaceGroupAssociation + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsEc2query_serializeOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsEc2query_deserializeOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "ec2", + OperationName: "DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation", + } +} diff --git a/service/ec2/api_op_DescribeClassicLinkInstances.go b/service/ec2/api_op_DescribeClassicLinkInstances.go index a81655c9f37..f63277eea51 100644 --- a/service/ec2/api_op_DescribeClassicLinkInstances.go +++ b/service/ec2/api_op_DescribeClassicLinkInstances.go @@ -15,11 +15,10 @@ import ( // Describes one or more of your linked EC2-Classic instances. This request only // returns information about EC2-Classic instances linked to a VPC through // ClassicLink. You cannot use this request to return information about other -// instances. We are retiring EC2-Classic on August 15, 2022. We recommend that you -// migrate from EC2-Classic to a VPC. For more information, see Migrate from -// EC2-Classic to a VPC -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the -// Amazon Elastic Compute Cloud User Guide. +// instances. We are retiring EC2-Classic. We recommend that you migrate from +// EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a +// VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in +// the Amazon Elastic Compute Cloud User Guide. func (c *Client) DescribeClassicLinkInstances(ctx context.Context, params *DescribeClassicLinkInstancesInput, optFns ...func(*Options)) (*DescribeClassicLinkInstancesOutput, error) { if params == nil { params = &DescribeClassicLinkInstancesInput{} diff --git a/service/ec2/api_op_DescribeFlowLogs.go b/service/ec2/api_op_DescribeFlowLogs.go index 23fd214f91e..0587e644402 100644 --- a/service/ec2/api_op_DescribeFlowLogs.go +++ b/service/ec2/api_op_DescribeFlowLogs.go @@ -12,9 +12,9 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Describes one or more flow logs. To view the information in your flow logs (the -// log streams for the network interfaces), you must use the CloudWatch Logs -// console or the CloudWatch Logs API. +// Describes one or more flow logs. To view the published flow log records, you +// must view the log destination. For example, the CloudWatch Logs log group, the +// Amazon S3 bucket, or the Kinesis Data Firehose delivery stream. func (c *Client) DescribeFlowLogs(ctx context.Context, params *DescribeFlowLogsInput, optFns ...func(*Options)) (*DescribeFlowLogsOutput, error) { if params == nil { params = &DescribeFlowLogsInput{} @@ -43,29 +43,29 @@ type DescribeFlowLogsInput struct { // * deliver-log-status - The status of the logs delivery // (SUCCESS | FAILED). // - // * log-destination-type - The type of destination to which - // the flow log publishes data. Possible destination types include cloud-watch-logs - // and s3. + // * log-destination-type - The type of destination for the + // flow log data (cloud-watch-logs | s3 | kinesis-data-firehose). // - // * flow-log-id - The ID of the flow log. + // * flow-log-id - + // The ID of the flow log. // - // * log-group-name - The name of - // the log group. + // * log-group-name - The name of the log group. // - // * resource-id - The ID of the VPC, subnet, or network - // interface. + // * + // resource-id - The ID of the VPC, subnet, or network interface. // - // * traffic-type - The type of traffic (ACCEPT | REJECT | ALL). + // * traffic-type - + // The type of traffic (ACCEPT | REJECT | ALL). // - // * - // tag: - The key/value combination of a tag assigned to the resource. Use the tag - // key in the filter name and the tag value as the filter value. For example, to - // find all resources that have a tag with the key Owner and the value TeamA, - // specify tag:Owner for the filter name and TeamA for the filter value. + // * tag: - The key/value combination + // of a tag assigned to the resource. Use the tag key in the filter name and the + // tag value as the filter value. For example, to find all resources that have a + // tag with the key Owner and the value TeamA, specify tag:Owner for the filter + // name and TeamA for the filter value. // - // * tag-key - // - The key of a tag assigned to the resource. Use this filter to find all - // resources assigned a tag with a specific key, regardless of the tag value. + // * tag-key - The key of a tag assigned to + // the resource. Use this filter to find all resources assigned a tag with a + // specific key, regardless of the tag value. Filter []types.Filter // One or more flow log IDs. Constraint: Maximum of 1000 flow log IDs. diff --git a/service/ec2/api_op_DescribeVpcClassicLink.go b/service/ec2/api_op_DescribeVpcClassicLink.go index bdb53791b15..bb736f7654a 100644 --- a/service/ec2/api_op_DescribeVpcClassicLink.go +++ b/service/ec2/api_op_DescribeVpcClassicLink.go @@ -12,8 +12,8 @@ import ( ) // Describes the ClassicLink status of one or more VPCs. We are retiring -// EC2-Classic on August 15, 2022. We recommend that you migrate from EC2-Classic -// to a VPC. For more information, see Migrate from EC2-Classic to a VPC +// EC2-Classic. We recommend that you migrate from EC2-Classic to a VPC. For more +// information, see Migrate from EC2-Classic to a VPC // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the // Amazon Elastic Compute Cloud User Guide. func (c *Client) DescribeVpcClassicLink(ctx context.Context, params *DescribeVpcClassicLinkInput, optFns ...func(*Options)) (*DescribeVpcClassicLinkOutput, error) { diff --git a/service/ec2/api_op_DescribeVpcClassicLinkDnsSupport.go b/service/ec2/api_op_DescribeVpcClassicLinkDnsSupport.go index defd1e7aaa2..d974dc9ee22 100644 --- a/service/ec2/api_op_DescribeVpcClassicLinkDnsSupport.go +++ b/service/ec2/api_op_DescribeVpcClassicLinkDnsSupport.go @@ -12,15 +12,15 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. Describes the ClassicLink DNS -// support status of one or more VPCs. If enabled, the DNS hostname of a linked -// EC2-Classic instance resolves to its private IP address when addressed from an -// instance in the VPC to which it's linked. Similarly, the DNS hostname of an -// instance in a VPC resolves to its private IP address when addressed from a -// linked EC2-Classic instance. For more information, see ClassicLink +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. Describes the ClassicLink DNS support +// status of one or more VPCs. If enabled, the DNS hostname of a linked EC2-Classic +// instance resolves to its private IP address when addressed from an instance in +// the VPC to which it's linked. Similarly, the DNS hostname of an instance in a +// VPC resolves to its private IP address when addressed from a linked EC2-Classic +// instance. For more information, see ClassicLink // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) in // the Amazon Elastic Compute Cloud User Guide. func (c *Client) DescribeVpcClassicLinkDnsSupport(ctx context.Context, params *DescribeVpcClassicLinkDnsSupportInput, optFns ...func(*Options)) (*DescribeVpcClassicLinkDnsSupportOutput, error) { diff --git a/service/ec2/api_op_DetachClassicLinkVpc.go b/service/ec2/api_op_DetachClassicLinkVpc.go index dd3dab3b885..63d6cb60a8e 100644 --- a/service/ec2/api_op_DetachClassicLinkVpc.go +++ b/service/ec2/api_op_DetachClassicLinkVpc.go @@ -10,13 +10,13 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. Unlinks (detaches) a linked -// EC2-Classic instance from a VPC. After the instance has been unlinked, the VPC -// security groups are no longer associated with it. An instance is automatically -// unlinked from a VPC when it's stopped. +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. Unlinks (detaches) a linked EC2-Classic +// instance from a VPC. After the instance has been unlinked, the VPC security +// groups are no longer associated with it. An instance is automatically unlinked +// from a VPC when it's stopped. func (c *Client) DetachClassicLinkVpc(ctx context.Context, params *DetachClassicLinkVpcInput, optFns ...func(*Options)) (*DetachClassicLinkVpcOutput, error) { if params == nil { params = &DetachClassicLinkVpcInput{} diff --git a/service/ec2/api_op_DisableVpcClassicLink.go b/service/ec2/api_op_DisableVpcClassicLink.go index 663b7d0edd2..665350d7ce7 100644 --- a/service/ec2/api_op_DisableVpcClassicLink.go +++ b/service/ec2/api_op_DisableVpcClassicLink.go @@ -11,9 +11,9 @@ import ( ) // Disables ClassicLink for a VPC. You cannot disable ClassicLink for a VPC that -// has EC2-Classic instances linked to it. We are retiring EC2-Classic on August -// 15, 2022. We recommend that you migrate from EC2-Classic to a VPC. For more -// information, see Migrate from EC2-Classic to a VPC +// has EC2-Classic instances linked to it. We are retiring EC2-Classic. We +// recommend that you migrate from EC2-Classic to a VPC. For more information, see +// Migrate from EC2-Classic to a VPC // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the // Amazon Elastic Compute Cloud User Guide. func (c *Client) DisableVpcClassicLink(ctx context.Context, params *DisableVpcClassicLinkInput, optFns ...func(*Options)) (*DisableVpcClassicLinkOutput, error) { diff --git a/service/ec2/api_op_DisableVpcClassicLinkDnsSupport.go b/service/ec2/api_op_DisableVpcClassicLinkDnsSupport.go index 0b88f4595b4..30307c51c5e 100644 --- a/service/ec2/api_op_DisableVpcClassicLinkDnsSupport.go +++ b/service/ec2/api_op_DisableVpcClassicLinkDnsSupport.go @@ -15,11 +15,10 @@ import ( // instances in the VPC to which it's linked. For more information, see ClassicLink // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) in // the Amazon Elastic Compute Cloud User Guide. You must specify a VPC ID in the -// request. We are retiring EC2-Classic on August 15, 2022. We recommend that you -// migrate from EC2-Classic to a VPC. For more information, see Migrate from -// EC2-Classic to a VPC -// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the -// Amazon Elastic Compute Cloud User Guide. +// request. We are retiring EC2-Classic. We recommend that you migrate from +// EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to a +// VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in +// the Amazon Elastic Compute Cloud User Guide. func (c *Client) DisableVpcClassicLinkDnsSupport(ctx context.Context, params *DisableVpcClassicLinkDnsSupportInput, optFns ...func(*Options)) (*DisableVpcClassicLinkDnsSupportOutput, error) { if params == nil { params = &DisableVpcClassicLinkDnsSupportInput{} diff --git a/service/ec2/api_op_EnableVpcClassicLink.go b/service/ec2/api_op_EnableVpcClassicLink.go index fa678b936e6..c64b631213e 100644 --- a/service/ec2/api_op_EnableVpcClassicLink.go +++ b/service/ec2/api_op_EnableVpcClassicLink.go @@ -10,11 +10,11 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. Enables a VPC for ClassicLink. You -// can then link EC2-Classic instances to your ClassicLink-enabled VPC to allow +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. Enables a VPC for ClassicLink. You can +// then link EC2-Classic instances to your ClassicLink-enabled VPC to allow // communication over private IP addresses. You cannot enable your VPC for // ClassicLink if any of your VPC route tables have existing routes for address // ranges within the 10.0.0.0/8 IP address range, excluding local routes for VPCs diff --git a/service/ec2/api_op_EnableVpcClassicLinkDnsSupport.go b/service/ec2/api_op_EnableVpcClassicLinkDnsSupport.go index 067c1dbb6ef..c9746bb20fb 100644 --- a/service/ec2/api_op_EnableVpcClassicLinkDnsSupport.go +++ b/service/ec2/api_op_EnableVpcClassicLinkDnsSupport.go @@ -10,15 +10,15 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. Enables a VPC to support DNS -// hostname resolution for ClassicLink. If enabled, the DNS hostname of a linked -// EC2-Classic instance resolves to its private IP address when addressed from an -// instance in the VPC to which it's linked. Similarly, the DNS hostname of an -// instance in a VPC resolves to its private IP address when addressed from a -// linked EC2-Classic instance. For more information, see ClassicLink +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. Enables a VPC to support DNS hostname +// resolution for ClassicLink. If enabled, the DNS hostname of a linked EC2-Classic +// instance resolves to its private IP address when addressed from an instance in +// the VPC to which it's linked. Similarly, the DNS hostname of an instance in a +// VPC resolves to its private IP address when addressed from a linked EC2-Classic +// instance. For more information, see ClassicLink // (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-classiclink.html) in // the Amazon Elastic Compute Cloud User Guide. You must specify a VPC ID in the // request. diff --git a/service/ec2/api_op_ModifyLocalGatewayRoute.go b/service/ec2/api_op_ModifyLocalGatewayRoute.go new file mode 100644 index 00000000000..19054b7af68 --- /dev/null +++ b/service/ec2/api_op_ModifyLocalGatewayRoute.go @@ -0,0 +1,139 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package ec2 + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/ec2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Modifies the specified local gateway route. +func (c *Client) ModifyLocalGatewayRoute(ctx context.Context, params *ModifyLocalGatewayRouteInput, optFns ...func(*Options)) (*ModifyLocalGatewayRouteOutput, error) { + if params == nil { + params = &ModifyLocalGatewayRouteInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "ModifyLocalGatewayRoute", params, optFns, c.addOperationModifyLocalGatewayRouteMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*ModifyLocalGatewayRouteOutput) + out.ResultMetadata = metadata + return out, nil +} + +type ModifyLocalGatewayRouteInput struct { + + // The CIDR block used for destination matches. The value that you provide must + // match the CIDR of an existing route in the table. + // + // This member is required. + DestinationCidrBlock *string + + // The ID of the local gateway route table. + // + // This member is required. + LocalGatewayRouteTableId *string + + // Checks whether you have the required permissions for the action, without + // actually making the request, and provides an error response. If you have the + // required permissions, the error response is DryRunOperation. Otherwise, it is + // UnauthorizedOperation. + DryRun *bool + + // The ID of the virtual interface group. + LocalGatewayVirtualInterfaceGroupId *string + + // The ID of the network interface. + NetworkInterfaceId *string + + noSmithyDocumentSerde +} + +type ModifyLocalGatewayRouteOutput struct { + + // Describes a route for a local gateway route table. + Route *types.LocalGatewayRoute + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationModifyLocalGatewayRouteMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsEc2query_serializeOpModifyLocalGatewayRoute{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsEc2query_deserializeOpModifyLocalGatewayRoute{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpModifyLocalGatewayRouteValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opModifyLocalGatewayRoute(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opModifyLocalGatewayRoute(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "ec2", + OperationName: "ModifyLocalGatewayRoute", + } +} diff --git a/service/ec2/api_op_ModifyVpcPeeringConnectionOptions.go b/service/ec2/api_op_ModifyVpcPeeringConnectionOptions.go index ef49007b09b..1032cce53cc 100644 --- a/service/ec2/api_op_ModifyVpcPeeringConnectionOptions.go +++ b/service/ec2/api_op_ModifyVpcPeeringConnectionOptions.go @@ -11,10 +11,10 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. Modifies the VPC peering connection +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. Modifies the VPC peering connection // options on one side of a VPC peering connection. You can do the following: // // * diff --git a/service/ec2/deserializers.go b/service/ec2/deserializers.go index 89beecdf08a..bbc2d27ebb9 100644 --- a/service/ec2/deserializers.go +++ b/service/ec2/deserializers.go @@ -4755,14 +4755,14 @@ func awsEc2query_deserializeOpErrorCreateClientVpnRoute(response *smithyhttp.Res } } -type awsEc2query_deserializeOpCreateCustomerGateway struct { +type awsEc2query_deserializeOpCreateCoipCidr struct { } -func (*awsEc2query_deserializeOpCreateCustomerGateway) ID() string { +func (*awsEc2query_deserializeOpCreateCoipCidr) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateCustomerGateway) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateCoipCidr) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -4776,9 +4776,9 @@ func (m *awsEc2query_deserializeOpCreateCustomerGateway) HandleDeserialize(ctx c } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateCustomerGateway(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateCoipCidr(response, &metadata) } - output := &CreateCustomerGatewayOutput{} + output := &CreateCoipCidrOutput{} out.Result = output var buff [1024]byte @@ -4799,7 +4799,7 @@ func (m *awsEc2query_deserializeOpCreateCustomerGateway) HandleDeserialize(ctx c } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateCustomerGatewayOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateCoipCidrOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -4813,7 +4813,7 @@ func (m *awsEc2query_deserializeOpCreateCustomerGateway) HandleDeserialize(ctx c return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateCustomerGateway(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateCoipCidr(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -4846,14 +4846,14 @@ func awsEc2query_deserializeOpErrorCreateCustomerGateway(response *smithyhttp.Re } } -type awsEc2query_deserializeOpCreateDefaultSubnet struct { +type awsEc2query_deserializeOpCreateCoipPool struct { } -func (*awsEc2query_deserializeOpCreateDefaultSubnet) ID() string { +func (*awsEc2query_deserializeOpCreateCoipPool) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateDefaultSubnet) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateCoipPool) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -4867,9 +4867,9 @@ func (m *awsEc2query_deserializeOpCreateDefaultSubnet) HandleDeserialize(ctx con } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateDefaultSubnet(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateCoipPool(response, &metadata) } - output := &CreateDefaultSubnetOutput{} + output := &CreateCoipPoolOutput{} out.Result = output var buff [1024]byte @@ -4890,7 +4890,7 @@ func (m *awsEc2query_deserializeOpCreateDefaultSubnet) HandleDeserialize(ctx con } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateDefaultSubnetOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateCoipPoolOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -4904,7 +4904,7 @@ func (m *awsEc2query_deserializeOpCreateDefaultSubnet) HandleDeserialize(ctx con return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateDefaultSubnet(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateCoipPool(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -4937,14 +4937,14 @@ func awsEc2query_deserializeOpErrorCreateDefaultSubnet(response *smithyhttp.Resp } } -type awsEc2query_deserializeOpCreateDefaultVpc struct { +type awsEc2query_deserializeOpCreateCustomerGateway struct { } -func (*awsEc2query_deserializeOpCreateDefaultVpc) ID() string { +func (*awsEc2query_deserializeOpCreateCustomerGateway) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateDefaultVpc) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateCustomerGateway) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -4958,9 +4958,9 @@ func (m *awsEc2query_deserializeOpCreateDefaultVpc) HandleDeserialize(ctx contex } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateDefaultVpc(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateCustomerGateway(response, &metadata) } - output := &CreateDefaultVpcOutput{} + output := &CreateCustomerGatewayOutput{} out.Result = output var buff [1024]byte @@ -4981,7 +4981,7 @@ func (m *awsEc2query_deserializeOpCreateDefaultVpc) HandleDeserialize(ctx contex } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateDefaultVpcOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateCustomerGatewayOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -4995,7 +4995,7 @@ func (m *awsEc2query_deserializeOpCreateDefaultVpc) HandleDeserialize(ctx contex return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateDefaultVpc(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateCustomerGateway(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5028,14 +5028,14 @@ func awsEc2query_deserializeOpErrorCreateDefaultVpc(response *smithyhttp.Respons } } -type awsEc2query_deserializeOpCreateDhcpOptions struct { +type awsEc2query_deserializeOpCreateDefaultSubnet struct { } -func (*awsEc2query_deserializeOpCreateDhcpOptions) ID() string { +func (*awsEc2query_deserializeOpCreateDefaultSubnet) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateDhcpOptions) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateDefaultSubnet) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5049,9 +5049,9 @@ func (m *awsEc2query_deserializeOpCreateDhcpOptions) HandleDeserialize(ctx conte } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateDhcpOptions(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateDefaultSubnet(response, &metadata) } - output := &CreateDhcpOptionsOutput{} + output := &CreateDefaultSubnetOutput{} out.Result = output var buff [1024]byte @@ -5072,7 +5072,7 @@ func (m *awsEc2query_deserializeOpCreateDhcpOptions) HandleDeserialize(ctx conte } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateDhcpOptionsOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateDefaultSubnetOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5086,7 +5086,7 @@ func (m *awsEc2query_deserializeOpCreateDhcpOptions) HandleDeserialize(ctx conte return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateDhcpOptions(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateDefaultSubnet(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5119,14 +5119,14 @@ func awsEc2query_deserializeOpErrorCreateDhcpOptions(response *smithyhttp.Respon } } -type awsEc2query_deserializeOpCreateEgressOnlyInternetGateway struct { +type awsEc2query_deserializeOpCreateDefaultVpc struct { } -func (*awsEc2query_deserializeOpCreateEgressOnlyInternetGateway) ID() string { +func (*awsEc2query_deserializeOpCreateDefaultVpc) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateEgressOnlyInternetGateway) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateDefaultVpc) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5140,9 +5140,9 @@ func (m *awsEc2query_deserializeOpCreateEgressOnlyInternetGateway) HandleDeseria } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateEgressOnlyInternetGateway(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateDefaultVpc(response, &metadata) } - output := &CreateEgressOnlyInternetGatewayOutput{} + output := &CreateDefaultVpcOutput{} out.Result = output var buff [1024]byte @@ -5163,7 +5163,7 @@ func (m *awsEc2query_deserializeOpCreateEgressOnlyInternetGateway) HandleDeseria } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateEgressOnlyInternetGatewayOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateDefaultVpcOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5177,7 +5177,7 @@ func (m *awsEc2query_deserializeOpCreateEgressOnlyInternetGateway) HandleDeseria return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateEgressOnlyInternetGateway(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateDefaultVpc(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5210,14 +5210,14 @@ func awsEc2query_deserializeOpErrorCreateEgressOnlyInternetGateway(response *smi } } -type awsEc2query_deserializeOpCreateFleet struct { +type awsEc2query_deserializeOpCreateDhcpOptions struct { } -func (*awsEc2query_deserializeOpCreateFleet) ID() string { +func (*awsEc2query_deserializeOpCreateDhcpOptions) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateFleet) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateDhcpOptions) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5231,9 +5231,9 @@ func (m *awsEc2query_deserializeOpCreateFleet) HandleDeserialize(ctx context.Con } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateFleet(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateDhcpOptions(response, &metadata) } - output := &CreateFleetOutput{} + output := &CreateDhcpOptionsOutput{} out.Result = output var buff [1024]byte @@ -5254,7 +5254,7 @@ func (m *awsEc2query_deserializeOpCreateFleet) HandleDeserialize(ctx context.Con } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateFleetOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateDhcpOptionsOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5268,7 +5268,7 @@ func (m *awsEc2query_deserializeOpCreateFleet) HandleDeserialize(ctx context.Con return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateFleet(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateDhcpOptions(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5301,14 +5301,14 @@ func awsEc2query_deserializeOpErrorCreateFleet(response *smithyhttp.Response, me } } -type awsEc2query_deserializeOpCreateFlowLogs struct { +type awsEc2query_deserializeOpCreateEgressOnlyInternetGateway struct { } -func (*awsEc2query_deserializeOpCreateFlowLogs) ID() string { +func (*awsEc2query_deserializeOpCreateEgressOnlyInternetGateway) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateFlowLogs) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateEgressOnlyInternetGateway) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5322,9 +5322,9 @@ func (m *awsEc2query_deserializeOpCreateFlowLogs) HandleDeserialize(ctx context. } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateFlowLogs(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateEgressOnlyInternetGateway(response, &metadata) } - output := &CreateFlowLogsOutput{} + output := &CreateEgressOnlyInternetGatewayOutput{} out.Result = output var buff [1024]byte @@ -5345,7 +5345,7 @@ func (m *awsEc2query_deserializeOpCreateFlowLogs) HandleDeserialize(ctx context. } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateFlowLogsOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateEgressOnlyInternetGatewayOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5359,7 +5359,7 @@ func (m *awsEc2query_deserializeOpCreateFlowLogs) HandleDeserialize(ctx context. return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateFlowLogs(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateEgressOnlyInternetGateway(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5392,14 +5392,14 @@ func awsEc2query_deserializeOpErrorCreateFlowLogs(response *smithyhttp.Response, } } -type awsEc2query_deserializeOpCreateFpgaImage struct { +type awsEc2query_deserializeOpCreateFleet struct { } -func (*awsEc2query_deserializeOpCreateFpgaImage) ID() string { +func (*awsEc2query_deserializeOpCreateFleet) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateFpgaImage) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateFleet) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5413,9 +5413,9 @@ func (m *awsEc2query_deserializeOpCreateFpgaImage) HandleDeserialize(ctx context } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateFpgaImage(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateFleet(response, &metadata) } - output := &CreateFpgaImageOutput{} + output := &CreateFleetOutput{} out.Result = output var buff [1024]byte @@ -5436,7 +5436,7 @@ func (m *awsEc2query_deserializeOpCreateFpgaImage) HandleDeserialize(ctx context } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateFpgaImageOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateFleetOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5450,7 +5450,7 @@ func (m *awsEc2query_deserializeOpCreateFpgaImage) HandleDeserialize(ctx context return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateFpgaImage(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateFleet(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5483,14 +5483,14 @@ func awsEc2query_deserializeOpErrorCreateFpgaImage(response *smithyhttp.Response } } -type awsEc2query_deserializeOpCreateImage struct { +type awsEc2query_deserializeOpCreateFlowLogs struct { } -func (*awsEc2query_deserializeOpCreateImage) ID() string { +func (*awsEc2query_deserializeOpCreateFlowLogs) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateImage) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateFlowLogs) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5504,9 +5504,9 @@ func (m *awsEc2query_deserializeOpCreateImage) HandleDeserialize(ctx context.Con } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateImage(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateFlowLogs(response, &metadata) } - output := &CreateImageOutput{} + output := &CreateFlowLogsOutput{} out.Result = output var buff [1024]byte @@ -5527,7 +5527,7 @@ func (m *awsEc2query_deserializeOpCreateImage) HandleDeserialize(ctx context.Con } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateImageOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateFlowLogsOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5541,7 +5541,7 @@ func (m *awsEc2query_deserializeOpCreateImage) HandleDeserialize(ctx context.Con return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateImage(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateFlowLogs(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5574,14 +5574,14 @@ func awsEc2query_deserializeOpErrorCreateImage(response *smithyhttp.Response, me } } -type awsEc2query_deserializeOpCreateInstanceEventWindow struct { +type awsEc2query_deserializeOpCreateFpgaImage struct { } -func (*awsEc2query_deserializeOpCreateInstanceEventWindow) ID() string { +func (*awsEc2query_deserializeOpCreateFpgaImage) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateInstanceEventWindow) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateFpgaImage) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5595,9 +5595,9 @@ func (m *awsEc2query_deserializeOpCreateInstanceEventWindow) HandleDeserialize(c } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateInstanceEventWindow(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateFpgaImage(response, &metadata) } - output := &CreateInstanceEventWindowOutput{} + output := &CreateFpgaImageOutput{} out.Result = output var buff [1024]byte @@ -5618,7 +5618,7 @@ func (m *awsEc2query_deserializeOpCreateInstanceEventWindow) HandleDeserialize(c } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateInstanceEventWindowOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateFpgaImageOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5632,7 +5632,7 @@ func (m *awsEc2query_deserializeOpCreateInstanceEventWindow) HandleDeserialize(c return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateInstanceEventWindow(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateFpgaImage(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5665,14 +5665,14 @@ func awsEc2query_deserializeOpErrorCreateInstanceEventWindow(response *smithyhtt } } -type awsEc2query_deserializeOpCreateInstanceExportTask struct { +type awsEc2query_deserializeOpCreateImage struct { } -func (*awsEc2query_deserializeOpCreateInstanceExportTask) ID() string { +func (*awsEc2query_deserializeOpCreateImage) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateInstanceExportTask) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateImage) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5686,9 +5686,9 @@ func (m *awsEc2query_deserializeOpCreateInstanceExportTask) HandleDeserialize(ct } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateInstanceExportTask(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateImage(response, &metadata) } - output := &CreateInstanceExportTaskOutput{} + output := &CreateImageOutput{} out.Result = output var buff [1024]byte @@ -5709,7 +5709,7 @@ func (m *awsEc2query_deserializeOpCreateInstanceExportTask) HandleDeserialize(ct } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateInstanceExportTaskOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateImageOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5723,7 +5723,7 @@ func (m *awsEc2query_deserializeOpCreateInstanceExportTask) HandleDeserialize(ct return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateInstanceExportTask(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateImage(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5756,14 +5756,14 @@ func awsEc2query_deserializeOpErrorCreateInstanceExportTask(response *smithyhttp } } -type awsEc2query_deserializeOpCreateInternetGateway struct { +type awsEc2query_deserializeOpCreateInstanceEventWindow struct { } -func (*awsEc2query_deserializeOpCreateInternetGateway) ID() string { +func (*awsEc2query_deserializeOpCreateInstanceEventWindow) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateInternetGateway) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateInstanceEventWindow) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5777,9 +5777,9 @@ func (m *awsEc2query_deserializeOpCreateInternetGateway) HandleDeserialize(ctx c } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateInternetGateway(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateInstanceEventWindow(response, &metadata) } - output := &CreateInternetGatewayOutput{} + output := &CreateInstanceEventWindowOutput{} out.Result = output var buff [1024]byte @@ -5800,7 +5800,7 @@ func (m *awsEc2query_deserializeOpCreateInternetGateway) HandleDeserialize(ctx c } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateInternetGatewayOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateInstanceEventWindowOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5814,7 +5814,7 @@ func (m *awsEc2query_deserializeOpCreateInternetGateway) HandleDeserialize(ctx c return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateInternetGateway(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateInstanceEventWindow(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5847,14 +5847,14 @@ func awsEc2query_deserializeOpErrorCreateInternetGateway(response *smithyhttp.Re } } -type awsEc2query_deserializeOpCreateIpam struct { +type awsEc2query_deserializeOpCreateInstanceExportTask struct { } -func (*awsEc2query_deserializeOpCreateIpam) ID() string { +func (*awsEc2query_deserializeOpCreateInstanceExportTask) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateIpam) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateInstanceExportTask) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5868,9 +5868,9 @@ func (m *awsEc2query_deserializeOpCreateIpam) HandleDeserialize(ctx context.Cont } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateIpam(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateInstanceExportTask(response, &metadata) } - output := &CreateIpamOutput{} + output := &CreateInstanceExportTaskOutput{} out.Result = output var buff [1024]byte @@ -5891,7 +5891,7 @@ func (m *awsEc2query_deserializeOpCreateIpam) HandleDeserialize(ctx context.Cont } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateIpamOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateInstanceExportTaskOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5905,7 +5905,7 @@ func (m *awsEc2query_deserializeOpCreateIpam) HandleDeserialize(ctx context.Cont return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateIpam(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateInstanceExportTask(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5938,14 +5938,14 @@ func awsEc2query_deserializeOpErrorCreateIpam(response *smithyhttp.Response, met } } -type awsEc2query_deserializeOpCreateIpamPool struct { +type awsEc2query_deserializeOpCreateInternetGateway struct { } -func (*awsEc2query_deserializeOpCreateIpamPool) ID() string { +func (*awsEc2query_deserializeOpCreateInternetGateway) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateIpamPool) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateInternetGateway) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5959,9 +5959,9 @@ func (m *awsEc2query_deserializeOpCreateIpamPool) HandleDeserialize(ctx context. } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateIpamPool(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateInternetGateway(response, &metadata) } - output := &CreateIpamPoolOutput{} + output := &CreateInternetGatewayOutput{} out.Result = output var buff [1024]byte @@ -5982,7 +5982,7 @@ func (m *awsEc2query_deserializeOpCreateIpamPool) HandleDeserialize(ctx context. } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateIpamPoolOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateInternetGatewayOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5996,7 +5996,7 @@ func (m *awsEc2query_deserializeOpCreateIpamPool) HandleDeserialize(ctx context. return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateIpamPool(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateInternetGateway(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -6029,14 +6029,14 @@ func awsEc2query_deserializeOpErrorCreateIpamPool(response *smithyhttp.Response, } } -type awsEc2query_deserializeOpCreateIpamScope struct { +type awsEc2query_deserializeOpCreateIpam struct { } -func (*awsEc2query_deserializeOpCreateIpamScope) ID() string { +func (*awsEc2query_deserializeOpCreateIpam) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateIpamScope) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateIpam) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -6050,9 +6050,9 @@ func (m *awsEc2query_deserializeOpCreateIpamScope) HandleDeserialize(ctx context } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateIpamScope(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateIpam(response, &metadata) } - output := &CreateIpamScopeOutput{} + output := &CreateIpamOutput{} out.Result = output var buff [1024]byte @@ -6073,7 +6073,7 @@ func (m *awsEc2query_deserializeOpCreateIpamScope) HandleDeserialize(ctx context } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateIpamScopeOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateIpamOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -6087,7 +6087,7 @@ func (m *awsEc2query_deserializeOpCreateIpamScope) HandleDeserialize(ctx context return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateIpamScope(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateIpam(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -6120,14 +6120,14 @@ func awsEc2query_deserializeOpErrorCreateIpamScope(response *smithyhttp.Response } } -type awsEc2query_deserializeOpCreateKeyPair struct { +type awsEc2query_deserializeOpCreateIpamPool struct { } -func (*awsEc2query_deserializeOpCreateKeyPair) ID() string { +func (*awsEc2query_deserializeOpCreateIpamPool) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateKeyPair) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateIpamPool) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -6141,9 +6141,9 @@ func (m *awsEc2query_deserializeOpCreateKeyPair) HandleDeserialize(ctx context.C } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateKeyPair(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateIpamPool(response, &metadata) } - output := &CreateKeyPairOutput{} + output := &CreateIpamPoolOutput{} out.Result = output var buff [1024]byte @@ -6164,7 +6164,7 @@ func (m *awsEc2query_deserializeOpCreateKeyPair) HandleDeserialize(ctx context.C } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateKeyPairOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateIpamPoolOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -6178,7 +6178,7 @@ func (m *awsEc2query_deserializeOpCreateKeyPair) HandleDeserialize(ctx context.C return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateKeyPair(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateIpamPool(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -6211,14 +6211,14 @@ func awsEc2query_deserializeOpErrorCreateKeyPair(response *smithyhttp.Response, } } -type awsEc2query_deserializeOpCreateLaunchTemplate struct { +type awsEc2query_deserializeOpCreateIpamScope struct { } -func (*awsEc2query_deserializeOpCreateLaunchTemplate) ID() string { +func (*awsEc2query_deserializeOpCreateIpamScope) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateLaunchTemplate) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateIpamScope) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -6232,9 +6232,9 @@ func (m *awsEc2query_deserializeOpCreateLaunchTemplate) HandleDeserialize(ctx co } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateLaunchTemplate(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateIpamScope(response, &metadata) } - output := &CreateLaunchTemplateOutput{} + output := &CreateIpamScopeOutput{} out.Result = output var buff [1024]byte @@ -6255,7 +6255,7 @@ func (m *awsEc2query_deserializeOpCreateLaunchTemplate) HandleDeserialize(ctx co } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateLaunchTemplateOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateIpamScopeOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -6269,7 +6269,7 @@ func (m *awsEc2query_deserializeOpCreateLaunchTemplate) HandleDeserialize(ctx co return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateLaunchTemplate(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateIpamScope(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -6302,14 +6302,14 @@ func awsEc2query_deserializeOpErrorCreateLaunchTemplate(response *smithyhttp.Res } } -type awsEc2query_deserializeOpCreateLaunchTemplateVersion struct { +type awsEc2query_deserializeOpCreateKeyPair struct { } -func (*awsEc2query_deserializeOpCreateLaunchTemplateVersion) ID() string { +func (*awsEc2query_deserializeOpCreateKeyPair) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateLaunchTemplateVersion) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateKeyPair) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -6323,9 +6323,9 @@ func (m *awsEc2query_deserializeOpCreateLaunchTemplateVersion) HandleDeserialize } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateLaunchTemplateVersion(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateKeyPair(response, &metadata) } - output := &CreateLaunchTemplateVersionOutput{} + output := &CreateKeyPairOutput{} out.Result = output var buff [1024]byte @@ -6346,7 +6346,7 @@ func (m *awsEc2query_deserializeOpCreateLaunchTemplateVersion) HandleDeserialize } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateLaunchTemplateVersionOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateKeyPairOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -6360,7 +6360,7 @@ func (m *awsEc2query_deserializeOpCreateLaunchTemplateVersion) HandleDeserialize return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateLaunchTemplateVersion(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateKeyPair(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -6393,14 +6393,14 @@ func awsEc2query_deserializeOpErrorCreateLaunchTemplateVersion(response *smithyh } } -type awsEc2query_deserializeOpCreateLocalGatewayRoute struct { +type awsEc2query_deserializeOpCreateLaunchTemplate struct { } -func (*awsEc2query_deserializeOpCreateLocalGatewayRoute) ID() string { +func (*awsEc2query_deserializeOpCreateLaunchTemplate) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateLocalGatewayRoute) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateLaunchTemplate) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -6414,9 +6414,9 @@ func (m *awsEc2query_deserializeOpCreateLocalGatewayRoute) HandleDeserialize(ctx } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateLocalGatewayRoute(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateLaunchTemplate(response, &metadata) } - output := &CreateLocalGatewayRouteOutput{} + output := &CreateLaunchTemplateOutput{} out.Result = output var buff [1024]byte @@ -6437,7 +6437,7 @@ func (m *awsEc2query_deserializeOpCreateLocalGatewayRoute) HandleDeserialize(ctx } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentCreateLocalGatewayRouteOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentCreateLaunchTemplateOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -6451,7 +6451,7 @@ func (m *awsEc2query_deserializeOpCreateLocalGatewayRoute) HandleDeserialize(ctx return out, metadata, err } -func awsEc2query_deserializeOpErrorCreateLocalGatewayRoute(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorCreateLaunchTemplate(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -6484,14 +6484,14 @@ func awsEc2query_deserializeOpErrorCreateLocalGatewayRoute(response *smithyhttp. } } -type awsEc2query_deserializeOpCreateLocalGatewayRouteTableVpcAssociation struct { +type awsEc2query_deserializeOpCreateLaunchTemplateVersion struct { } -func (*awsEc2query_deserializeOpCreateLocalGatewayRouteTableVpcAssociation) ID() string { +func (*awsEc2query_deserializeOpCreateLaunchTemplateVersion) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpCreateLocalGatewayRouteTableVpcAssociation) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpCreateLaunchTemplateVersion) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -6505,9 +6505,373 @@ func (m *awsEc2query_deserializeOpCreateLocalGatewayRouteTableVpcAssociation) Ha } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorCreateLocalGatewayRouteTableVpcAssociation(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorCreateLaunchTemplateVersion(response, &metadata) } - output := &CreateLocalGatewayRouteTableVpcAssociationOutput{} + output := &CreateLaunchTemplateVersionOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + body := io.TeeReader(response.Body, ringBuffer) + rootDecoder := xml.NewDecoder(body) + t, err := smithyxml.FetchRootElement(rootDecoder) + if err == io.EOF { + return out, metadata, nil + } + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) + err = awsEc2query_deserializeOpDocumentCreateLaunchTemplateVersionOutput(&output, decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsEc2query_deserializeOpErrorCreateLaunchTemplateVersion(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := ec2query.GetErrorResponseComponents(errorBody) + if err != nil { + return err + } + awsmiddleware.SetRequestIDMetadata(metadata, errorComponents.RequestID) + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsEc2query_deserializeOpCreateLocalGatewayRoute struct { +} + +func (*awsEc2query_deserializeOpCreateLocalGatewayRoute) ID() string { + return "OperationDeserializer" +} + +func (m *awsEc2query_deserializeOpCreateLocalGatewayRoute) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsEc2query_deserializeOpErrorCreateLocalGatewayRoute(response, &metadata) + } + output := &CreateLocalGatewayRouteOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + body := io.TeeReader(response.Body, ringBuffer) + rootDecoder := xml.NewDecoder(body) + t, err := smithyxml.FetchRootElement(rootDecoder) + if err == io.EOF { + return out, metadata, nil + } + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) + err = awsEc2query_deserializeOpDocumentCreateLocalGatewayRouteOutput(&output, decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsEc2query_deserializeOpErrorCreateLocalGatewayRoute(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := ec2query.GetErrorResponseComponents(errorBody) + if err != nil { + return err + } + awsmiddleware.SetRequestIDMetadata(metadata, errorComponents.RequestID) + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsEc2query_deserializeOpCreateLocalGatewayRouteTable struct { +} + +func (*awsEc2query_deserializeOpCreateLocalGatewayRouteTable) ID() string { + return "OperationDeserializer" +} + +func (m *awsEc2query_deserializeOpCreateLocalGatewayRouteTable) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsEc2query_deserializeOpErrorCreateLocalGatewayRouteTable(response, &metadata) + } + output := &CreateLocalGatewayRouteTableOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + body := io.TeeReader(response.Body, ringBuffer) + rootDecoder := xml.NewDecoder(body) + t, err := smithyxml.FetchRootElement(rootDecoder) + if err == io.EOF { + return out, metadata, nil + } + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) + err = awsEc2query_deserializeOpDocumentCreateLocalGatewayRouteTableOutput(&output, decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsEc2query_deserializeOpErrorCreateLocalGatewayRouteTable(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := ec2query.GetErrorResponseComponents(errorBody) + if err != nil { + return err + } + awsmiddleware.SetRequestIDMetadata(metadata, errorComponents.RequestID) + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsEc2query_deserializeOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation struct { +} + +func (*awsEc2query_deserializeOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation) ID() string { + return "OperationDeserializer" +} + +func (m *awsEc2query_deserializeOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsEc2query_deserializeOpErrorCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation(response, &metadata) + } + output := &CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + body := io.TeeReader(response.Body, ringBuffer) + rootDecoder := xml.NewDecoder(body) + t, err := smithyxml.FetchRootElement(rootDecoder) + if err == io.EOF { + return out, metadata, nil + } + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) + err = awsEc2query_deserializeOpDocumentCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput(&output, decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsEc2query_deserializeOpErrorCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := ec2query.GetErrorResponseComponents(errorBody) + if err != nil { + return err + } + awsmiddleware.SetRequestIDMetadata(metadata, errorComponents.RequestID) + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsEc2query_deserializeOpCreateLocalGatewayRouteTableVpcAssociation struct { +} + +func (*awsEc2query_deserializeOpCreateLocalGatewayRouteTableVpcAssociation) ID() string { + return "OperationDeserializer" +} + +func (m *awsEc2query_deserializeOpCreateLocalGatewayRouteTableVpcAssociation) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsEc2query_deserializeOpErrorCreateLocalGatewayRouteTableVpcAssociation(response, &metadata) + } + output := &CreateLocalGatewayRouteTableVpcAssociationOutput{} out.Result = output var buff [1024]byte @@ -11056,6 +11420,188 @@ func awsEc2query_deserializeOpErrorDeleteClientVpnRoute(response *smithyhttp.Res } } +type awsEc2query_deserializeOpDeleteCoipCidr struct { +} + +func (*awsEc2query_deserializeOpDeleteCoipCidr) ID() string { + return "OperationDeserializer" +} + +func (m *awsEc2query_deserializeOpDeleteCoipCidr) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsEc2query_deserializeOpErrorDeleteCoipCidr(response, &metadata) + } + output := &DeleteCoipCidrOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + body := io.TeeReader(response.Body, ringBuffer) + rootDecoder := xml.NewDecoder(body) + t, err := smithyxml.FetchRootElement(rootDecoder) + if err == io.EOF { + return out, metadata, nil + } + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) + err = awsEc2query_deserializeOpDocumentDeleteCoipCidrOutput(&output, decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsEc2query_deserializeOpErrorDeleteCoipCidr(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := ec2query.GetErrorResponseComponents(errorBody) + if err != nil { + return err + } + awsmiddleware.SetRequestIDMetadata(metadata, errorComponents.RequestID) + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsEc2query_deserializeOpDeleteCoipPool struct { +} + +func (*awsEc2query_deserializeOpDeleteCoipPool) ID() string { + return "OperationDeserializer" +} + +func (m *awsEc2query_deserializeOpDeleteCoipPool) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsEc2query_deserializeOpErrorDeleteCoipPool(response, &metadata) + } + output := &DeleteCoipPoolOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + body := io.TeeReader(response.Body, ringBuffer) + rootDecoder := xml.NewDecoder(body) + t, err := smithyxml.FetchRootElement(rootDecoder) + if err == io.EOF { + return out, metadata, nil + } + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) + err = awsEc2query_deserializeOpDocumentDeleteCoipPoolOutput(&output, decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsEc2query_deserializeOpErrorDeleteCoipPool(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := ec2query.GetErrorResponseComponents(errorBody) + if err != nil { + return err + } + awsmiddleware.SetRequestIDMetadata(metadata, errorComponents.RequestID) + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + type awsEc2query_deserializeOpDeleteCustomerGateway struct { } @@ -12329,6 +12875,188 @@ func awsEc2query_deserializeOpErrorDeleteLocalGatewayRoute(response *smithyhttp. } } +type awsEc2query_deserializeOpDeleteLocalGatewayRouteTable struct { +} + +func (*awsEc2query_deserializeOpDeleteLocalGatewayRouteTable) ID() string { + return "OperationDeserializer" +} + +func (m *awsEc2query_deserializeOpDeleteLocalGatewayRouteTable) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsEc2query_deserializeOpErrorDeleteLocalGatewayRouteTable(response, &metadata) + } + output := &DeleteLocalGatewayRouteTableOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + body := io.TeeReader(response.Body, ringBuffer) + rootDecoder := xml.NewDecoder(body) + t, err := smithyxml.FetchRootElement(rootDecoder) + if err == io.EOF { + return out, metadata, nil + } + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) + err = awsEc2query_deserializeOpDocumentDeleteLocalGatewayRouteTableOutput(&output, decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsEc2query_deserializeOpErrorDeleteLocalGatewayRouteTable(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := ec2query.GetErrorResponseComponents(errorBody) + if err != nil { + return err + } + awsmiddleware.SetRequestIDMetadata(metadata, errorComponents.RequestID) + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsEc2query_deserializeOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation struct { +} + +func (*awsEc2query_deserializeOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation) ID() string { + return "OperationDeserializer" +} + +func (m *awsEc2query_deserializeOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsEc2query_deserializeOpErrorDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation(response, &metadata) + } + output := &DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + body := io.TeeReader(response.Body, ringBuffer) + rootDecoder := xml.NewDecoder(body) + t, err := smithyxml.FetchRootElement(rootDecoder) + if err == io.EOF { + return out, metadata, nil + } + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) + err = awsEc2query_deserializeOpDocumentDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput(&output, decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsEc2query_deserializeOpErrorDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := ec2query.GetErrorResponseComponents(errorBody) + if err != nil { + return err + } + awsmiddleware.SetRequestIDMetadata(metadata, errorComponents.RequestID) + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + type awsEc2query_deserializeOpDeleteLocalGatewayRouteTableVpcAssociation struct { } @@ -38689,14 +39417,105 @@ func awsEc2query_deserializeOpErrorModifyIpam(response *smithyhttp.Response, met } } -type awsEc2query_deserializeOpModifyIpamPool struct { +type awsEc2query_deserializeOpModifyIpamPool struct { +} + +func (*awsEc2query_deserializeOpModifyIpamPool) ID() string { + return "OperationDeserializer" +} + +func (m *awsEc2query_deserializeOpModifyIpamPool) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsEc2query_deserializeOpErrorModifyIpamPool(response, &metadata) + } + output := &ModifyIpamPoolOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + body := io.TeeReader(response.Body, ringBuffer) + rootDecoder := xml.NewDecoder(body) + t, err := smithyxml.FetchRootElement(rootDecoder) + if err == io.EOF { + return out, metadata, nil + } + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) + err = awsEc2query_deserializeOpDocumentModifyIpamPoolOutput(&output, decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsEc2query_deserializeOpErrorModifyIpamPool(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := ec2query.GetErrorResponseComponents(errorBody) + if err != nil { + return err + } + awsmiddleware.SetRequestIDMetadata(metadata, errorComponents.RequestID) + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsEc2query_deserializeOpModifyIpamResourceCidr struct { } -func (*awsEc2query_deserializeOpModifyIpamPool) ID() string { +func (*awsEc2query_deserializeOpModifyIpamResourceCidr) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpModifyIpamPool) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpModifyIpamResourceCidr) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -38710,9 +39529,9 @@ func (m *awsEc2query_deserializeOpModifyIpamPool) HandleDeserialize(ctx context. } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorModifyIpamPool(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorModifyIpamResourceCidr(response, &metadata) } - output := &ModifyIpamPoolOutput{} + output := &ModifyIpamResourceCidrOutput{} out.Result = output var buff [1024]byte @@ -38733,7 +39552,7 @@ func (m *awsEc2query_deserializeOpModifyIpamPool) HandleDeserialize(ctx context. } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentModifyIpamPoolOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentModifyIpamResourceCidrOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -38747,7 +39566,7 @@ func (m *awsEc2query_deserializeOpModifyIpamPool) HandleDeserialize(ctx context. return out, metadata, err } -func awsEc2query_deserializeOpErrorModifyIpamPool(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorModifyIpamResourceCidr(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -38780,14 +39599,14 @@ func awsEc2query_deserializeOpErrorModifyIpamPool(response *smithyhttp.Response, } } -type awsEc2query_deserializeOpModifyIpamResourceCidr struct { +type awsEc2query_deserializeOpModifyIpamScope struct { } -func (*awsEc2query_deserializeOpModifyIpamResourceCidr) ID() string { +func (*awsEc2query_deserializeOpModifyIpamScope) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpModifyIpamResourceCidr) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpModifyIpamScope) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -38801,9 +39620,9 @@ func (m *awsEc2query_deserializeOpModifyIpamResourceCidr) HandleDeserialize(ctx } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorModifyIpamResourceCidr(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorModifyIpamScope(response, &metadata) } - output := &ModifyIpamResourceCidrOutput{} + output := &ModifyIpamScopeOutput{} out.Result = output var buff [1024]byte @@ -38824,7 +39643,7 @@ func (m *awsEc2query_deserializeOpModifyIpamResourceCidr) HandleDeserialize(ctx } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentModifyIpamResourceCidrOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentModifyIpamScopeOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -38838,7 +39657,7 @@ func (m *awsEc2query_deserializeOpModifyIpamResourceCidr) HandleDeserialize(ctx return out, metadata, err } -func awsEc2query_deserializeOpErrorModifyIpamResourceCidr(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorModifyIpamScope(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -38871,14 +39690,14 @@ func awsEc2query_deserializeOpErrorModifyIpamResourceCidr(response *smithyhttp.R } } -type awsEc2query_deserializeOpModifyIpamScope struct { +type awsEc2query_deserializeOpModifyLaunchTemplate struct { } -func (*awsEc2query_deserializeOpModifyIpamScope) ID() string { +func (*awsEc2query_deserializeOpModifyLaunchTemplate) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpModifyIpamScope) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpModifyLaunchTemplate) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -38892,9 +39711,9 @@ func (m *awsEc2query_deserializeOpModifyIpamScope) HandleDeserialize(ctx context } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorModifyIpamScope(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorModifyLaunchTemplate(response, &metadata) } - output := &ModifyIpamScopeOutput{} + output := &ModifyLaunchTemplateOutput{} out.Result = output var buff [1024]byte @@ -38915,7 +39734,7 @@ func (m *awsEc2query_deserializeOpModifyIpamScope) HandleDeserialize(ctx context } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentModifyIpamScopeOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentModifyLaunchTemplateOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -38929,7 +39748,7 @@ func (m *awsEc2query_deserializeOpModifyIpamScope) HandleDeserialize(ctx context return out, metadata, err } -func awsEc2query_deserializeOpErrorModifyIpamScope(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorModifyLaunchTemplate(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -38962,14 +39781,14 @@ func awsEc2query_deserializeOpErrorModifyIpamScope(response *smithyhttp.Response } } -type awsEc2query_deserializeOpModifyLaunchTemplate struct { +type awsEc2query_deserializeOpModifyLocalGatewayRoute struct { } -func (*awsEc2query_deserializeOpModifyLaunchTemplate) ID() string { +func (*awsEc2query_deserializeOpModifyLocalGatewayRoute) ID() string { return "OperationDeserializer" } -func (m *awsEc2query_deserializeOpModifyLaunchTemplate) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsEc2query_deserializeOpModifyLocalGatewayRoute) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -38983,9 +39802,9 @@ func (m *awsEc2query_deserializeOpModifyLaunchTemplate) HandleDeserialize(ctx co } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsEc2query_deserializeOpErrorModifyLaunchTemplate(response, &metadata) + return out, metadata, awsEc2query_deserializeOpErrorModifyLocalGatewayRoute(response, &metadata) } - output := &ModifyLaunchTemplateOutput{} + output := &ModifyLocalGatewayRouteOutput{} out.Result = output var buff [1024]byte @@ -39006,7 +39825,7 @@ func (m *awsEc2query_deserializeOpModifyLaunchTemplate) HandleDeserialize(ctx co } decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) - err = awsEc2query_deserializeOpDocumentModifyLaunchTemplateOutput(&output, decoder) + err = awsEc2query_deserializeOpDocumentModifyLocalGatewayRouteOutput(&output, decoder) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -39020,7 +39839,7 @@ func (m *awsEc2query_deserializeOpModifyLaunchTemplate) HandleDeserialize(ctx co return out, metadata, err } -func awsEc2query_deserializeOpErrorModifyLaunchTemplate(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsEc2query_deserializeOpErrorModifyLocalGatewayRoute(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -56054,6 +56873,81 @@ func awsEc2query_deserializeDocumentCoipAddressUsageSetUnwrapped(v *[]types.Coip *v = sv return nil } +func awsEc2query_deserializeDocumentCoipCidr(v **types.CoipCidr, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *types.CoipCidr + if *v == nil { + sv = &types.CoipCidr{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("cidr", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.Cidr = ptr.String(xtv) + } + + case strings.EqualFold("coipPoolId", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.CoipPoolId = ptr.String(xtv) + } + + case strings.EqualFold("localGatewayRouteTableId", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.LocalGatewayRouteTableId = ptr.String(xtv) + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + func awsEc2query_deserializeDocumentCoipPool(v **types.CoipPool, decoder smithyxml.NodeDecoder) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -65579,6 +66473,19 @@ func awsEc2query_deserializeDocumentFlowLog(v **types.FlowLog, decoder smithyxml sv.CreationTime = ptr.Time(t) } + case strings.EqualFold("deliverCrossAccountRole", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.DeliverCrossAccountRole = ptr.String(xtv) + } + case strings.EqualFold("deliverLogsErrorMessage", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -84576,6 +85483,19 @@ func awsEc2query_deserializeDocumentLocalGatewayRoute(v **types.LocalGatewayRout originalDecoder := decoder decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) switch { + case strings.EqualFold("coipPoolId", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.CoipPoolId = ptr.String(xtv) + } + case strings.EqualFold("destinationCidrBlock", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -84628,6 +85548,19 @@ func awsEc2query_deserializeDocumentLocalGatewayRoute(v **types.LocalGatewayRout sv.LocalGatewayVirtualInterfaceGroupId = ptr.String(xtv) } + case strings.EqualFold("networkInterfaceId", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.NetworkInterfaceId = ptr.String(xtv) + } + case strings.EqualFold("ownerId", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -84654,6 +85587,19 @@ func awsEc2query_deserializeDocumentLocalGatewayRoute(v **types.LocalGatewayRout sv.State = types.LocalGatewayRouteState(xtv) } + case strings.EqualFold("subnetId", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.SubnetId = ptr.String(xtv) + } + case strings.EqualFold("type", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -84810,6 +85756,19 @@ func awsEc2query_deserializeDocumentLocalGatewayRouteTable(v **types.LocalGatewa sv.LocalGatewayRouteTableId = ptr.String(xtv) } + case strings.EqualFold("mode", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.Mode = types.LocalGatewayRouteTableMode(xtv) + } + case strings.EqualFold("outpostArn", t.Name.Local): val, err := decoder.Value() if err != nil { @@ -84849,6 +85808,12 @@ func awsEc2query_deserializeDocumentLocalGatewayRouteTable(v **types.LocalGatewa sv.State = ptr.String(xtv) } + case strings.EqualFold("stateReason", t.Name.Local): + nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) + if err := awsEc2query_deserializeDocumentStateReason(&sv.StateReason, nodeDecoder); err != nil { + return err + } + case strings.EqualFold("tagSet", t.Name.Local): nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) if err := awsEc2query_deserializeDocumentTagList(&sv.Tags, nodeDecoder); err != nil { @@ -123551,6 +124516,90 @@ func awsEc2query_deserializeOpDocumentCreateClientVpnRouteOutput(v **CreateClien return nil } +func awsEc2query_deserializeOpDocumentCreateCoipCidrOutput(v **CreateCoipCidrOutput, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *CreateCoipCidrOutput + if *v == nil { + sv = &CreateCoipCidrOutput{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("coipCidr", t.Name.Local): + nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) + if err := awsEc2query_deserializeDocumentCoipCidr(&sv.CoipCidr, nodeDecoder); err != nil { + return err + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + +func awsEc2query_deserializeOpDocumentCreateCoipPoolOutput(v **CreateCoipPoolOutput, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *CreateCoipPoolOutput + if *v == nil { + sv = &CreateCoipPoolOutput{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("coipPool", t.Name.Local): + nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) + if err := awsEc2query_deserializeDocumentCoipPool(&sv.CoipPool, nodeDecoder); err != nil { + return err + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + func awsEc2query_deserializeOpDocumentCreateCustomerGatewayOutput(v **CreateCustomerGatewayOutput, decoder smithyxml.NodeDecoder) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -124491,6 +125540,90 @@ func awsEc2query_deserializeOpDocumentCreateLocalGatewayRouteOutput(v **CreateLo return nil } +func awsEc2query_deserializeOpDocumentCreateLocalGatewayRouteTableOutput(v **CreateLocalGatewayRouteTableOutput, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *CreateLocalGatewayRouteTableOutput + if *v == nil { + sv = &CreateLocalGatewayRouteTableOutput{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("localGatewayRouteTable", t.Name.Local): + nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) + if err := awsEc2query_deserializeDocumentLocalGatewayRouteTable(&sv.LocalGatewayRouteTable, nodeDecoder); err != nil { + return err + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + +func awsEc2query_deserializeOpDocumentCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput(v **CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput + if *v == nil { + sv = &CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("localGatewayRouteTableVirtualInterfaceGroupAssociation", t.Name.Local): + nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) + if err := awsEc2query_deserializeDocumentLocalGatewayRouteTableVirtualInterfaceGroupAssociation(&sv.LocalGatewayRouteTableVirtualInterfaceGroupAssociation, nodeDecoder); err != nil { + return err + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + func awsEc2query_deserializeOpDocumentCreateLocalGatewayRouteTableVpcAssociationOutput(v **CreateLocalGatewayRouteTableVpcAssociationOutput, decoder smithyxml.NodeDecoder) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -127110,6 +128243,90 @@ func awsEc2query_deserializeOpDocumentDeleteClientVpnRouteOutput(v **DeleteClien return nil } +func awsEc2query_deserializeOpDocumentDeleteCoipCidrOutput(v **DeleteCoipCidrOutput, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *DeleteCoipCidrOutput + if *v == nil { + sv = &DeleteCoipCidrOutput{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("coipCidr", t.Name.Local): + nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) + if err := awsEc2query_deserializeDocumentCoipCidr(&sv.CoipCidr, nodeDecoder); err != nil { + return err + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + +func awsEc2query_deserializeOpDocumentDeleteCoipPoolOutput(v **DeleteCoipPoolOutput, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *DeleteCoipPoolOutput + if *v == nil { + sv = &DeleteCoipPoolOutput{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("coipPool", t.Name.Local): + nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) + if err := awsEc2query_deserializeDocumentCoipPool(&sv.CoipPool, nodeDecoder); err != nil { + return err + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + func awsEc2query_deserializeOpDocumentDeleteEgressOnlyInternetGatewayOutput(v **DeleteEgressOnlyInternetGatewayOutput, decoder smithyxml.NodeDecoder) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -127604,6 +128821,90 @@ func awsEc2query_deserializeOpDocumentDeleteLocalGatewayRouteOutput(v **DeleteLo return nil } +func awsEc2query_deserializeOpDocumentDeleteLocalGatewayRouteTableOutput(v **DeleteLocalGatewayRouteTableOutput, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *DeleteLocalGatewayRouteTableOutput + if *v == nil { + sv = &DeleteLocalGatewayRouteTableOutput{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("localGatewayRouteTable", t.Name.Local): + nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) + if err := awsEc2query_deserializeDocumentLocalGatewayRouteTable(&sv.LocalGatewayRouteTable, nodeDecoder); err != nil { + return err + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + +func awsEc2query_deserializeOpDocumentDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput(v **DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput + if *v == nil { + sv = &DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationOutput{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("localGatewayRouteTableVirtualInterfaceGroupAssociation", t.Name.Local): + nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) + if err := awsEc2query_deserializeDocumentLocalGatewayRouteTableVirtualInterfaceGroupAssociation(&sv.LocalGatewayRouteTableVirtualInterfaceGroupAssociation, nodeDecoder); err != nil { + return err + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + func awsEc2query_deserializeOpDocumentDeleteLocalGatewayRouteTableVpcAssociationOutput(v **DeleteLocalGatewayRouteTableVpcAssociationOutput, decoder smithyxml.NodeDecoder) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -142675,6 +143976,48 @@ func awsEc2query_deserializeOpDocumentModifyLaunchTemplateOutput(v **ModifyLaunc return nil } +func awsEc2query_deserializeOpDocumentModifyLocalGatewayRouteOutput(v **ModifyLocalGatewayRouteOutput, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *ModifyLocalGatewayRouteOutput + if *v == nil { + sv = &ModifyLocalGatewayRouteOutput{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("route", t.Name.Local): + nodeDecoder := smithyxml.WrapNodeDecoder(decoder.Decoder, t) + if err := awsEc2query_deserializeDocumentLocalGatewayRoute(&sv.Route, nodeDecoder); err != nil { + return err + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + func awsEc2query_deserializeOpDocumentModifyManagedPrefixListOutput(v **ModifyManagedPrefixListOutput, decoder smithyxml.NodeDecoder) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/ec2/generated.json b/service/ec2/generated.json index 007342578f8..8d4efd4182f 100644 --- a/service/ec2/generated.json +++ b/service/ec2/generated.json @@ -64,6 +64,8 @@ "api_op_CreateCarrierGateway.go", "api_op_CreateClientVpnEndpoint.go", "api_op_CreateClientVpnRoute.go", + "api_op_CreateCoipCidr.go", + "api_op_CreateCoipPool.go", "api_op_CreateCustomerGateway.go", "api_op_CreateDefaultSubnet.go", "api_op_CreateDefaultVpc.go", @@ -83,6 +85,8 @@ "api_op_CreateLaunchTemplate.go", "api_op_CreateLaunchTemplateVersion.go", "api_op_CreateLocalGatewayRoute.go", + "api_op_CreateLocalGatewayRouteTable.go", + "api_op_CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation.go", "api_op_CreateLocalGatewayRouteTableVpcAssociation.go", "api_op_CreateManagedPrefixList.go", "api_op_CreateNatGateway.go", @@ -134,6 +138,8 @@ "api_op_DeleteCarrierGateway.go", "api_op_DeleteClientVpnEndpoint.go", "api_op_DeleteClientVpnRoute.go", + "api_op_DeleteCoipCidr.go", + "api_op_DeleteCoipPool.go", "api_op_DeleteCustomerGateway.go", "api_op_DeleteDhcpOptions.go", "api_op_DeleteEgressOnlyInternetGateway.go", @@ -149,6 +155,8 @@ "api_op_DeleteLaunchTemplate.go", "api_op_DeleteLaunchTemplateVersions.go", "api_op_DeleteLocalGatewayRoute.go", + "api_op_DeleteLocalGatewayRouteTable.go", + "api_op_DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation.go", "api_op_DeleteLocalGatewayRouteTableVpcAssociation.go", "api_op_DeleteManagedPrefixList.go", "api_op_DeleteNatGateway.go", @@ -450,6 +458,7 @@ "api_op_ModifyIpamResourceCidr.go", "api_op_ModifyIpamScope.go", "api_op_ModifyLaunchTemplate.go", + "api_op_ModifyLocalGatewayRoute.go", "api_op_ModifyManagedPrefixList.go", "api_op_ModifyNetworkInterfaceAttribute.go", "api_op_ModifyPrivateDnsNameOptions.go", diff --git a/service/ec2/serializers.go b/service/ec2/serializers.go index f2c2b4ef607..afba197085a 100644 --- a/service/ec2/serializers.go +++ b/service/ec2/serializers.go @@ -3409,6 +3409,134 @@ func (m *awsEc2query_serializeOpCreateClientVpnRoute) HandleSerialize(ctx contex return next.HandleSerialize(ctx, in) } +type awsEc2query_serializeOpCreateCoipCidr struct { +} + +func (*awsEc2query_serializeOpCreateCoipCidr) ID() string { + return "OperationSerializer" +} + +func (m *awsEc2query_serializeOpCreateCoipCidr) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*CreateCoipCidrInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("CreateCoipCidr") + body.Key("Version").String("2016-11-15") + + if err := awsEc2query_serializeOpDocumentCreateCoipCidrInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + +type awsEc2query_serializeOpCreateCoipPool struct { +} + +func (*awsEc2query_serializeOpCreateCoipPool) ID() string { + return "OperationSerializer" +} + +func (m *awsEc2query_serializeOpCreateCoipPool) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*CreateCoipPoolInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("CreateCoipPool") + body.Key("Version").String("2016-11-15") + + if err := awsEc2query_serializeOpDocumentCreateCoipPoolInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsEc2query_serializeOpCreateCustomerGateway struct { } @@ -4625,6 +4753,134 @@ func (m *awsEc2query_serializeOpCreateLocalGatewayRoute) HandleSerialize(ctx con return next.HandleSerialize(ctx, in) } +type awsEc2query_serializeOpCreateLocalGatewayRouteTable struct { +} + +func (*awsEc2query_serializeOpCreateLocalGatewayRouteTable) ID() string { + return "OperationSerializer" +} + +func (m *awsEc2query_serializeOpCreateLocalGatewayRouteTable) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*CreateLocalGatewayRouteTableInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("CreateLocalGatewayRouteTable") + body.Key("Version").String("2016-11-15") + + if err := awsEc2query_serializeOpDocumentCreateLocalGatewayRouteTableInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + +type awsEc2query_serializeOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation struct { +} + +func (*awsEc2query_serializeOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation) ID() string { + return "OperationSerializer" +} + +func (m *awsEc2query_serializeOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation") + body.Key("Version").String("2016-11-15") + + if err := awsEc2query_serializeOpDocumentCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsEc2query_serializeOpCreateLocalGatewayRouteTableVpcAssociation struct { } @@ -7889,6 +8145,134 @@ func (m *awsEc2query_serializeOpDeleteClientVpnRoute) HandleSerialize(ctx contex return next.HandleSerialize(ctx, in) } +type awsEc2query_serializeOpDeleteCoipCidr struct { +} + +func (*awsEc2query_serializeOpDeleteCoipCidr) ID() string { + return "OperationSerializer" +} + +func (m *awsEc2query_serializeOpDeleteCoipCidr) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*DeleteCoipCidrInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("DeleteCoipCidr") + body.Key("Version").String("2016-11-15") + + if err := awsEc2query_serializeOpDocumentDeleteCoipCidrInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + +type awsEc2query_serializeOpDeleteCoipPool struct { +} + +func (*awsEc2query_serializeOpDeleteCoipPool) ID() string { + return "OperationSerializer" +} + +func (m *awsEc2query_serializeOpDeleteCoipPool) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*DeleteCoipPoolInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("DeleteCoipPool") + body.Key("Version").String("2016-11-15") + + if err := awsEc2query_serializeOpDocumentDeleteCoipPoolInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsEc2query_serializeOpDeleteCustomerGateway struct { } @@ -8761,10 +9145,138 @@ func (m *awsEc2query_serializeOpDeleteLaunchTemplateVersions) HandleSerialize(ct bodyWriter := bytes.NewBuffer(nil) bodyEncoder := query.NewEncoder(bodyWriter) body := bodyEncoder.Object() - body.Key("Action").String("DeleteLaunchTemplateVersions") + body.Key("Action").String("DeleteLaunchTemplateVersions") + body.Key("Version").String("2016-11-15") + + if err := awsEc2query_serializeOpDocumentDeleteLaunchTemplateVersionsInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + +type awsEc2query_serializeOpDeleteLocalGatewayRoute struct { +} + +func (*awsEc2query_serializeOpDeleteLocalGatewayRoute) ID() string { + return "OperationSerializer" +} + +func (m *awsEc2query_serializeOpDeleteLocalGatewayRoute) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*DeleteLocalGatewayRouteInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("DeleteLocalGatewayRoute") + body.Key("Version").String("2016-11-15") + + if err := awsEc2query_serializeOpDocumentDeleteLocalGatewayRouteInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + +type awsEc2query_serializeOpDeleteLocalGatewayRouteTable struct { +} + +func (*awsEc2query_serializeOpDeleteLocalGatewayRouteTable) ID() string { + return "OperationSerializer" +} + +func (m *awsEc2query_serializeOpDeleteLocalGatewayRouteTable) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*DeleteLocalGatewayRouteTableInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("DeleteLocalGatewayRouteTable") body.Key("Version").String("2016-11-15") - if err := awsEc2query_serializeOpDocumentDeleteLaunchTemplateVersionsInput(input, bodyEncoder.Value); err != nil { + if err := awsEc2query_serializeOpDocumentDeleteLocalGatewayRouteTableInput(input, bodyEncoder.Value); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -8785,14 +9297,14 @@ func (m *awsEc2query_serializeOpDeleteLaunchTemplateVersions) HandleSerialize(ct return next.HandleSerialize(ctx, in) } -type awsEc2query_serializeOpDeleteLocalGatewayRoute struct { +type awsEc2query_serializeOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation struct { } -func (*awsEc2query_serializeOpDeleteLocalGatewayRoute) ID() string { +func (*awsEc2query_serializeOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation) ID() string { return "OperationSerializer" } -func (m *awsEc2query_serializeOpDeleteLocalGatewayRoute) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsEc2query_serializeOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -8800,7 +9312,7 @@ func (m *awsEc2query_serializeOpDeleteLocalGatewayRoute) HandleSerialize(ctx con return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*DeleteLocalGatewayRouteInput) + input, ok := in.Parameters.(*DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} @@ -8825,10 +9337,10 @@ func (m *awsEc2query_serializeOpDeleteLocalGatewayRoute) HandleSerialize(ctx con bodyWriter := bytes.NewBuffer(nil) bodyEncoder := query.NewEncoder(bodyWriter) body := bodyEncoder.Object() - body.Key("Action").String("DeleteLocalGatewayRoute") + body.Key("Action").String("DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation") body.Key("Version").String("2016-11-15") - if err := awsEc2query_serializeOpDocumentDeleteLocalGatewayRouteInput(input, bodyEncoder.Value); err != nil { + if err := awsEc2query_serializeOpDocumentDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput(input, bodyEncoder.Value); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -28113,6 +28625,70 @@ func (m *awsEc2query_serializeOpModifyLaunchTemplate) HandleSerialize(ctx contex return next.HandleSerialize(ctx, in) } +type awsEc2query_serializeOpModifyLocalGatewayRoute struct { +} + +func (*awsEc2query_serializeOpModifyLocalGatewayRoute) ID() string { + return "OperationSerializer" +} + +func (m *awsEc2query_serializeOpModifyLocalGatewayRoute) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*ModifyLocalGatewayRouteInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("ModifyLocalGatewayRoute") + body.Key("Version").String("2016-11-15") + + if err := awsEc2query_serializeOpDocumentModifyLocalGatewayRouteInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsEc2query_serializeOpModifyManagedPrefixList struct { } @@ -44727,6 +45303,52 @@ func awsEc2query_serializeOpDocumentCreateClientVpnRouteInput(v *CreateClientVpn return nil } +func awsEc2query_serializeOpDocumentCreateCoipCidrInput(v *CreateCoipCidrInput, value query.Value) error { + object := value.Object() + _ = object + + if v.Cidr != nil { + objectKey := object.Key("Cidr") + objectKey.String(*v.Cidr) + } + + if v.CoipPoolId != nil { + objectKey := object.Key("CoipPoolId") + objectKey.String(*v.CoipPoolId) + } + + if v.DryRun != nil { + objectKey := object.Key("DryRun") + objectKey.Boolean(*v.DryRun) + } + + return nil +} + +func awsEc2query_serializeOpDocumentCreateCoipPoolInput(v *CreateCoipPoolInput, value query.Value) error { + object := value.Object() + _ = object + + if v.DryRun != nil { + objectKey := object.Key("DryRun") + objectKey.Boolean(*v.DryRun) + } + + if v.LocalGatewayRouteTableId != nil { + objectKey := object.Key("LocalGatewayRouteTableId") + objectKey.String(*v.LocalGatewayRouteTableId) + } + + if v.TagSpecifications != nil { + objectKey := object.FlatKey("TagSpecification") + if err := awsEc2query_serializeDocumentTagSpecificationList(v.TagSpecifications, objectKey); err != nil { + return err + } + } + + return nil +} + func awsEc2query_serializeOpDocumentCreateCustomerGatewayInput(v *CreateCustomerGatewayInput, value query.Value) error { object := value.Object() _ = object @@ -44961,6 +45583,11 @@ func awsEc2query_serializeOpDocumentCreateFlowLogsInput(v *CreateFlowLogsInput, objectKey.String(*v.ClientToken) } + if v.DeliverCrossAccountRole != nil { + objectKey := object.Key("DeliverCrossAccountRole") + objectKey.String(*v.DeliverCrossAccountRole) + } + if v.DeliverLogsPermissionArn != nil { objectKey := object.Key("DeliverLogsPermissionArn") objectKey.String(*v.DeliverLogsPermissionArn) @@ -45514,6 +46141,69 @@ func awsEc2query_serializeOpDocumentCreateLocalGatewayRouteInput(v *CreateLocalG objectKey.String(*v.LocalGatewayVirtualInterfaceGroupId) } + if v.NetworkInterfaceId != nil { + objectKey := object.Key("NetworkInterfaceId") + objectKey.String(*v.NetworkInterfaceId) + } + + return nil +} + +func awsEc2query_serializeOpDocumentCreateLocalGatewayRouteTableInput(v *CreateLocalGatewayRouteTableInput, value query.Value) error { + object := value.Object() + _ = object + + if v.DryRun != nil { + objectKey := object.Key("DryRun") + objectKey.Boolean(*v.DryRun) + } + + if v.LocalGatewayId != nil { + objectKey := object.Key("LocalGatewayId") + objectKey.String(*v.LocalGatewayId) + } + + if len(v.Mode) > 0 { + objectKey := object.Key("Mode") + objectKey.String(string(v.Mode)) + } + + if v.TagSpecifications != nil { + objectKey := object.FlatKey("TagSpecification") + if err := awsEc2query_serializeDocumentTagSpecificationList(v.TagSpecifications, objectKey); err != nil { + return err + } + } + + return nil +} + +func awsEc2query_serializeOpDocumentCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput(v *CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput, value query.Value) error { + object := value.Object() + _ = object + + if v.DryRun != nil { + objectKey := object.Key("DryRun") + objectKey.Boolean(*v.DryRun) + } + + if v.LocalGatewayRouteTableId != nil { + objectKey := object.Key("LocalGatewayRouteTableId") + objectKey.String(*v.LocalGatewayRouteTableId) + } + + if v.LocalGatewayVirtualInterfaceGroupId != nil { + objectKey := object.Key("LocalGatewayVirtualInterfaceGroupId") + objectKey.String(*v.LocalGatewayVirtualInterfaceGroupId) + } + + if v.TagSpecifications != nil { + objectKey := object.FlatKey("TagSpecification") + if err := awsEc2query_serializeDocumentTagSpecificationList(v.TagSpecifications, objectKey); err != nil { + return err + } + } + return nil } @@ -47574,6 +48264,45 @@ func awsEc2query_serializeOpDocumentDeleteClientVpnRouteInput(v *DeleteClientVpn return nil } +func awsEc2query_serializeOpDocumentDeleteCoipCidrInput(v *DeleteCoipCidrInput, value query.Value) error { + object := value.Object() + _ = object + + if v.Cidr != nil { + objectKey := object.Key("Cidr") + objectKey.String(*v.Cidr) + } + + if v.CoipPoolId != nil { + objectKey := object.Key("CoipPoolId") + objectKey.String(*v.CoipPoolId) + } + + if v.DryRun != nil { + objectKey := object.Key("DryRun") + objectKey.Boolean(*v.DryRun) + } + + return nil +} + +func awsEc2query_serializeOpDocumentDeleteCoipPoolInput(v *DeleteCoipPoolInput, value query.Value) error { + object := value.Object() + _ = object + + if v.CoipPoolId != nil { + objectKey := object.Key("CoipPoolId") + objectKey.String(*v.CoipPoolId) + } + + if v.DryRun != nil { + objectKey := object.Key("DryRun") + objectKey.Boolean(*v.DryRun) + } + + return nil +} + func awsEc2query_serializeOpDocumentDeleteCustomerGatewayInput(v *DeleteCustomerGatewayInput, value query.Value) error { object := value.Object() _ = object @@ -47875,6 +48604,40 @@ func awsEc2query_serializeOpDocumentDeleteLocalGatewayRouteInput(v *DeleteLocalG return nil } +func awsEc2query_serializeOpDocumentDeleteLocalGatewayRouteTableInput(v *DeleteLocalGatewayRouteTableInput, value query.Value) error { + object := value.Object() + _ = object + + if v.DryRun != nil { + objectKey := object.Key("DryRun") + objectKey.Boolean(*v.DryRun) + } + + if v.LocalGatewayRouteTableId != nil { + objectKey := object.Key("LocalGatewayRouteTableId") + objectKey.String(*v.LocalGatewayRouteTableId) + } + + return nil +} + +func awsEc2query_serializeOpDocumentDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput(v *DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput, value query.Value) error { + object := value.Object() + _ = object + + if v.DryRun != nil { + objectKey := object.Key("DryRun") + objectKey.Boolean(*v.DryRun) + } + + if v.LocalGatewayRouteTableVirtualInterfaceGroupAssociationId != nil { + objectKey := object.Key("LocalGatewayRouteTableVirtualInterfaceGroupAssociationId") + objectKey.String(*v.LocalGatewayRouteTableVirtualInterfaceGroupAssociationId) + } + + return nil +} + func awsEc2query_serializeOpDocumentDeleteLocalGatewayRouteTableVpcAssociationInput(v *DeleteLocalGatewayRouteTableVpcAssociationInput, value query.Value) error { object := value.Object() _ = object @@ -56754,6 +57517,38 @@ func awsEc2query_serializeOpDocumentModifyLaunchTemplateInput(v *ModifyLaunchTem return nil } +func awsEc2query_serializeOpDocumentModifyLocalGatewayRouteInput(v *ModifyLocalGatewayRouteInput, value query.Value) error { + object := value.Object() + _ = object + + if v.DestinationCidrBlock != nil { + objectKey := object.Key("DestinationCidrBlock") + objectKey.String(*v.DestinationCidrBlock) + } + + if v.DryRun != nil { + objectKey := object.Key("DryRun") + objectKey.Boolean(*v.DryRun) + } + + if v.LocalGatewayRouteTableId != nil { + objectKey := object.Key("LocalGatewayRouteTableId") + objectKey.String(*v.LocalGatewayRouteTableId) + } + + if v.LocalGatewayVirtualInterfaceGroupId != nil { + objectKey := object.Key("LocalGatewayVirtualInterfaceGroupId") + objectKey.String(*v.LocalGatewayVirtualInterfaceGroupId) + } + + if v.NetworkInterfaceId != nil { + objectKey := object.Key("NetworkInterfaceId") + objectKey.String(*v.NetworkInterfaceId) + } + + return nil +} + func awsEc2query_serializeOpDocumentModifyManagedPrefixListInput(v *ModifyManagedPrefixListInput, value query.Value) error { object := value.Object() _ = object diff --git a/service/ec2/types/enums.go b/service/ec2/types/enums.go index 6ac17ee738e..7129cadc03c 100644 --- a/service/ec2/types/enums.go +++ b/service/ec2/types/enums.go @@ -35,6 +35,8 @@ const ( AcceleratorNameM60 AcceleratorName = "m60" AcceleratorNameRadeonProV520 AcceleratorName = "radeon-pro-v520" AcceleratorNameVu9p AcceleratorName = "vu9p" + AcceleratorNameInferentia AcceleratorName = "inferentia" + AcceleratorNameK520 AcceleratorName = "k520" ) // Values returns all known values for AcceleratorName. Note that this can be @@ -49,6 +51,8 @@ func (AcceleratorName) Values() []AcceleratorName { "m60", "radeon-pro-v520", "vu9p", + "inferentia", + "k520", } } @@ -4430,6 +4434,24 @@ func (LocalGatewayRouteState) Values() []LocalGatewayRouteState { } } +type LocalGatewayRouteTableMode string + +// Enum values for LocalGatewayRouteTableMode +const ( + LocalGatewayRouteTableModeDirectVpcRouting LocalGatewayRouteTableMode = "direct-vpc-routing" + LocalGatewayRouteTableModeCoip LocalGatewayRouteTableMode = "coip" +) + +// Values returns all known values for LocalGatewayRouteTableMode. Note that this +// can be expanded in the future, and so it is only as up to date as the client. +// The ordering of this slice is not guaranteed to be stable across updates. +func (LocalGatewayRouteTableMode) Values() []LocalGatewayRouteTableMode { + return []LocalGatewayRouteTableMode{ + "direct-vpc-routing", + "coip", + } +} + type LocalGatewayRouteType string // Enum values for LocalGatewayRouteType @@ -4510,8 +4532,9 @@ type LogDestinationType string // Enum values for LogDestinationType const ( - LogDestinationTypeCloudWatchLogs LogDestinationType = "cloud-watch-logs" - LogDestinationTypeS3 LogDestinationType = "s3" + LogDestinationTypeCloudWatchLogs LogDestinationType = "cloud-watch-logs" + LogDestinationTypeS3 LogDestinationType = "s3" + LogDestinationTypeKinesisDataFirehose LogDestinationType = "kinesis-data-firehose" ) // Values returns all known values for LogDestinationType. Note that this can be @@ -4521,6 +4544,7 @@ func (LogDestinationType) Values() []LogDestinationType { return []LogDestinationType{ "cloud-watch-logs", "s3", + "kinesis-data-firehose", } } @@ -5342,6 +5366,7 @@ const ( ResourceTypeClientVpnEndpoint ResourceType = "client-vpn-endpoint" ResourceTypeCustomerGateway ResourceType = "customer-gateway" ResourceTypeCarrierGateway ResourceType = "carrier-gateway" + ResourceTypeCoipPool ResourceType = "coip-pool" ResourceTypeDedicatedHost ResourceType = "dedicated-host" ResourceTypeDhcpOptions ResourceType = "dhcp-options" ResourceTypeEgressOnlyInternetGateway ResourceType = "egress-only-internet-gateway" @@ -5411,6 +5436,7 @@ const ( ResourceTypeCapacityReservationFleet ResourceType = "capacity-reservation-fleet" ResourceTypeTrafficMirrorFilterRule ResourceType = "traffic-mirror-filter-rule" ResourceTypeVpcEndpointConnectionDeviceType ResourceType = "vpc-endpoint-connection-device-type" + ResourceTypeVpnConnectionDeviceType ResourceType = "vpn-connection-device-type" ) // Values returns all known values for ResourceType. Note that this can be expanded @@ -5422,6 +5448,7 @@ func (ResourceType) Values() []ResourceType { "client-vpn-endpoint", "customer-gateway", "carrier-gateway", + "coip-pool", "dedicated-host", "dhcp-options", "egress-only-internet-gateway", @@ -5491,6 +5518,7 @@ func (ResourceType) Values() []ResourceType { "capacity-reservation-fleet", "traffic-mirror-filter-rule", "vpc-endpoint-connection-device-type", + "vpn-connection-device-type", } } diff --git a/service/ec2/types/types.go b/service/ec2/types/types.go index c0720f87890..0b977b0aaf9 100644 --- a/service/ec2/types/types.go +++ b/service/ec2/types/types.go @@ -1320,10 +1320,10 @@ type ClassicLinkDnsSupport struct { noSmithyDocumentSerde } -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. Describes a linked EC2-Classic +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. Describes a linked EC2-Classic // instance. type ClassicLinkInstance struct { @@ -1793,6 +1793,21 @@ type CoipAddressUsage struct { noSmithyDocumentSerde } +// Information about a customer-owned IP address range. +type CoipCidr struct { + + // An address range in a customer-owned IP address space. + Cidr *string + + // The ID of the address pool. + CoipPoolId *string + + // The ID of the local gateway route table. + LocalGatewayRouteTableId *string + + noSmithyDocumentSerde +} + // Describes a customer-owned address pool. type CoipPool struct { @@ -4017,6 +4032,10 @@ type FlowLog struct { // The date and time the flow log was created. CreationTime *time.Time + // The ARN of the IAM role that allows the service to publish flow logs across + // accounts. + DeliverCrossAccountRole *string + // Information about the error that occurred. Rate limited indicates that // CloudWatch Logs throttling has been applied for one or more network interfaces, // or that you've reached the limit on the number of log groups that you can @@ -4025,7 +4044,7 @@ type FlowLog struct { // error indicates an internal error. DeliverLogsErrorMessage *string - // The ARN of the IAM role that posts logs to CloudWatch Logs. + // The ARN of the IAM role allows the service to publish logs to CloudWatch Logs. DeliverLogsPermissionArn *string // The status of the logs delivery (SUCCESS | FAILED). @@ -4034,22 +4053,16 @@ type FlowLog struct { // The destination options. DestinationOptions *DestinationOptionsResponse - // The flow log ID. + // The ID of the flow log. FlowLogId *string // The status of the flow log (ACTIVE). FlowLogStatus *string - // The destination to which the flow log data is published. Flow log data can be - // published to an CloudWatch Logs log group or an Amazon S3 bucket. If the flow - // log publishes to CloudWatch Logs, this element indicates the Amazon Resource - // Name (ARN) of the CloudWatch Logs log group to which the data is published. If - // the flow log publishes to Amazon S3, this element indicates the ARN of the - // Amazon S3 bucket to which the data is published. + // The Amazon Resource Name (ARN) of the destination for the flow log data. LogDestination *string - // The type of destination to which the flow log data is published. Flow log data - // can be published to CloudWatch Logs or Amazon S3. + // The type of destination for the flow log data. LogDestinationType LogDestinationType // The format of the flow log record. @@ -4066,7 +4079,7 @@ type FlowLog struct { // the specified value. Valid Values: 60 | 600 MaxAggregationInterval *int32 - // The ID of the resource on which the flow log was created. + // The ID of the resource being monitored. ResourceId *string // The tags for the flow log. @@ -8553,6 +8566,9 @@ type LocalGateway struct { // Describes a route for a local gateway route table. type LocalGatewayRoute struct { + // The ID of the customer-owned address pool. + CoipPoolId *string + // The CIDR block used for destination matches. DestinationCidrBlock *string @@ -8565,12 +8581,18 @@ type LocalGatewayRoute struct { // The ID of the virtual interface group. LocalGatewayVirtualInterfaceGroupId *string + // The ID of the network interface. + NetworkInterfaceId *string + // The ID of the Amazon Web Services account that owns the local gateway route. OwnerId *string // The state of the route. State LocalGatewayRouteState + // The ID of the subnet. + SubnetId *string + // The route type. Type LocalGatewayRouteType @@ -8589,6 +8611,9 @@ type LocalGatewayRouteTable struct { // The ID of the local gateway route table. LocalGatewayRouteTableId *string + // The mode of the local gateway route table. + Mode LocalGatewayRouteTableMode + // The Amazon Resource Name (ARN) of the Outpost. OutpostArn *string @@ -8599,6 +8624,9 @@ type LocalGatewayRouteTable struct { // The state of the local gateway route table. State *string + // Describes a state change. + StateReason *StateReason + // The tags assigned to the local gateway route table. Tags []Tag @@ -9929,11 +9957,11 @@ type PeeringAttachmentStatus struct { noSmithyDocumentSerde } -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. Describes the VPC peering -// connection options. +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. Describes the VPC peering connection +// options. type PeeringConnectionOptions struct { // If true, the public DNS hostnames of instances in the specified VPC resolve to @@ -9951,10 +9979,10 @@ type PeeringConnectionOptions struct { noSmithyDocumentSerde } -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. The VPC peering connection options. +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. The VPC peering connection options. type PeeringConnectionOptionsRequest struct { // If true, enables a local VPC to resolve public DNS hostnames to private IP @@ -15824,11 +15852,11 @@ type VpcCidrBlockState struct { noSmithyDocumentSerde } -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. Describes whether a VPC is enabled -// for ClassicLink. +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. Describes whether a VPC is enabled for +// ClassicLink. type VpcClassicLink struct { // Indicates whether the VPC is enabled for ClassicLink. @@ -15990,11 +16018,11 @@ type VpcPeeringConnection struct { noSmithyDocumentSerde } -// We are retiring EC2-Classic on August 15, 2022. We recommend that you migrate -// from EC2-Classic to a VPC. For more information, see Migrate from EC2-Classic to -// a VPC (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in -// the Amazon Elastic Compute Cloud User Guide. Describes the VPC peering -// connection options. +// We are retiring EC2-Classic. We recommend that you migrate from EC2-Classic to a +// VPC. For more information, see Migrate from EC2-Classic to a VPC +// (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/vpc-migrate.html) in the +// Amazon Elastic Compute Cloud User Guide. Describes the VPC peering connection +// options. type VpcPeeringConnectionOptionsDescription struct { // Indicates whether a local VPC can resolve public DNS hostnames to private IP diff --git a/service/ec2/validators.go b/service/ec2/validators.go index dc248e8c62a..311196c29de 100644 --- a/service/ec2/validators.go +++ b/service/ec2/validators.go @@ -910,6 +910,46 @@ func (m *validateOpCreateClientVpnRoute) HandleInitialize(ctx context.Context, i return next.HandleInitialize(ctx, in) } +type validateOpCreateCoipCidr struct { +} + +func (*validateOpCreateCoipCidr) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpCreateCoipCidr) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*CreateCoipCidrInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpCreateCoipCidrInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + +type validateOpCreateCoipPool struct { +} + +func (*validateOpCreateCoipPool) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpCreateCoipPool) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*CreateCoipPoolInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpCreateCoipPoolInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpCreateCustomerGateway struct { } @@ -1210,6 +1250,46 @@ func (m *validateOpCreateLocalGatewayRoute) HandleInitialize(ctx context.Context return next.HandleInitialize(ctx, in) } +type validateOpCreateLocalGatewayRouteTable struct { +} + +func (*validateOpCreateLocalGatewayRouteTable) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpCreateLocalGatewayRouteTable) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*CreateLocalGatewayRouteTableInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpCreateLocalGatewayRouteTableInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + +type validateOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation struct { +} + +func (*validateOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpCreateLocalGatewayRouteTableVpcAssociation struct { } @@ -2070,6 +2150,46 @@ func (m *validateOpDeleteClientVpnRoute) HandleInitialize(ctx context.Context, i return next.HandleInitialize(ctx, in) } +type validateOpDeleteCoipCidr struct { +} + +func (*validateOpDeleteCoipCidr) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDeleteCoipCidr) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DeleteCoipCidrInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDeleteCoipCidrInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + +type validateOpDeleteCoipPool struct { +} + +func (*validateOpDeleteCoipPool) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDeleteCoipPool) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DeleteCoipPoolInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDeleteCoipPoolInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpDeleteCustomerGateway struct { } @@ -2330,6 +2450,46 @@ func (m *validateOpDeleteLocalGatewayRoute) HandleInitialize(ctx context.Context return next.HandleInitialize(ctx, in) } +type validateOpDeleteLocalGatewayRouteTable struct { +} + +func (*validateOpDeleteLocalGatewayRouteTable) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDeleteLocalGatewayRouteTable) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DeleteLocalGatewayRouteTableInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDeleteLocalGatewayRouteTableInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + +type validateOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation struct { +} + +func (*validateOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpDeleteLocalGatewayRouteTableVpcAssociation struct { } @@ -5570,6 +5730,26 @@ func (m *validateOpModifyIpamScope) HandleInitialize(ctx context.Context, in mid return next.HandleInitialize(ctx, in) } +type validateOpModifyLocalGatewayRoute struct { +} + +func (*validateOpModifyLocalGatewayRoute) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpModifyLocalGatewayRoute) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*ModifyLocalGatewayRouteInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpModifyLocalGatewayRouteInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpModifyManagedPrefixList struct { } @@ -7410,6 +7590,14 @@ func addOpCreateClientVpnRouteValidationMiddleware(stack *middleware.Stack) erro return stack.Initialize.Add(&validateOpCreateClientVpnRoute{}, middleware.After) } +func addOpCreateCoipCidrValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpCreateCoipCidr{}, middleware.After) +} + +func addOpCreateCoipPoolValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpCreateCoipPool{}, middleware.After) +} + func addOpCreateCustomerGatewayValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpCreateCustomerGateway{}, middleware.After) } @@ -7470,6 +7658,14 @@ func addOpCreateLocalGatewayRouteValidationMiddleware(stack *middleware.Stack) e return stack.Initialize.Add(&validateOpCreateLocalGatewayRoute{}, middleware.After) } +func addOpCreateLocalGatewayRouteTableValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpCreateLocalGatewayRouteTable{}, middleware.After) +} + +func addOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociation{}, middleware.After) +} + func addOpCreateLocalGatewayRouteTableVpcAssociationValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpCreateLocalGatewayRouteTableVpcAssociation{}, middleware.After) } @@ -7642,6 +7838,14 @@ func addOpDeleteClientVpnRouteValidationMiddleware(stack *middleware.Stack) erro return stack.Initialize.Add(&validateOpDeleteClientVpnRoute{}, middleware.After) } +func addOpDeleteCoipCidrValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDeleteCoipCidr{}, middleware.After) +} + +func addOpDeleteCoipPoolValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDeleteCoipPool{}, middleware.After) +} + func addOpDeleteCustomerGatewayValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDeleteCustomerGateway{}, middleware.After) } @@ -7694,6 +7898,14 @@ func addOpDeleteLocalGatewayRouteValidationMiddleware(stack *middleware.Stack) e return stack.Initialize.Add(&validateOpDeleteLocalGatewayRoute{}, middleware.After) } +func addOpDeleteLocalGatewayRouteTableValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDeleteLocalGatewayRouteTable{}, middleware.After) +} + +func addOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociation{}, middleware.After) +} + func addOpDeleteLocalGatewayRouteTableVpcAssociationValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDeleteLocalGatewayRouteTableVpcAssociation{}, middleware.After) } @@ -8342,6 +8554,10 @@ func addOpModifyIpamScopeValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpModifyIpamScope{}, middleware.After) } +func addOpModifyLocalGatewayRouteValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpModifyLocalGatewayRoute{}, middleware.After) +} + func addOpModifyManagedPrefixListValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpModifyManagedPrefixList{}, middleware.After) } @@ -10182,6 +10398,39 @@ func validateOpCreateClientVpnRouteInput(v *CreateClientVpnRouteInput) error { } } +func validateOpCreateCoipCidrInput(v *CreateCoipCidrInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "CreateCoipCidrInput"} + if v.Cidr == nil { + invalidParams.Add(smithy.NewErrParamRequired("Cidr")) + } + if v.CoipPoolId == nil { + invalidParams.Add(smithy.NewErrParamRequired("CoipPoolId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateOpCreateCoipPoolInput(v *CreateCoipPoolInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "CreateCoipPoolInput"} + if v.LocalGatewayRouteTableId == nil { + invalidParams.Add(smithy.NewErrParamRequired("LocalGatewayRouteTableId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpCreateCustomerGatewayInput(v *CreateCustomerGatewayInput) error { if v == nil { return nil @@ -10443,6 +10692,36 @@ func validateOpCreateLocalGatewayRouteInput(v *CreateLocalGatewayRouteInput) err if v.LocalGatewayRouteTableId == nil { invalidParams.Add(smithy.NewErrParamRequired("LocalGatewayRouteTableId")) } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateOpCreateLocalGatewayRouteTableInput(v *CreateLocalGatewayRouteTableInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "CreateLocalGatewayRouteTableInput"} + if v.LocalGatewayId == nil { + invalidParams.Add(smithy.NewErrParamRequired("LocalGatewayId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateOpCreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput(v *CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "CreateLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput"} + if v.LocalGatewayRouteTableId == nil { + invalidParams.Add(smithy.NewErrParamRequired("LocalGatewayRouteTableId")) + } if v.LocalGatewayVirtualInterfaceGroupId == nil { invalidParams.Add(smithy.NewErrParamRequired("LocalGatewayVirtualInterfaceGroupId")) } @@ -11239,6 +11518,39 @@ func validateOpDeleteClientVpnRouteInput(v *DeleteClientVpnRouteInput) error { } } +func validateOpDeleteCoipCidrInput(v *DeleteCoipCidrInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DeleteCoipCidrInput"} + if v.Cidr == nil { + invalidParams.Add(smithy.NewErrParamRequired("Cidr")) + } + if v.CoipPoolId == nil { + invalidParams.Add(smithy.NewErrParamRequired("CoipPoolId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateOpDeleteCoipPoolInput(v *DeleteCoipPoolInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DeleteCoipPoolInput"} + if v.CoipPoolId == nil { + invalidParams.Add(smithy.NewErrParamRequired("CoipPoolId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpDeleteCustomerGatewayInput(v *DeleteCustomerGatewayInput) error { if v == nil { return nil @@ -11440,6 +11752,36 @@ func validateOpDeleteLocalGatewayRouteInput(v *DeleteLocalGatewayRouteInput) err } } +func validateOpDeleteLocalGatewayRouteTableInput(v *DeleteLocalGatewayRouteTableInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DeleteLocalGatewayRouteTableInput"} + if v.LocalGatewayRouteTableId == nil { + invalidParams.Add(smithy.NewErrParamRequired("LocalGatewayRouteTableId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateOpDeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput(v *DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DeleteLocalGatewayRouteTableVirtualInterfaceGroupAssociationInput"} + if v.LocalGatewayRouteTableVirtualInterfaceGroupAssociationId == nil { + invalidParams.Add(smithy.NewErrParamRequired("LocalGatewayRouteTableVirtualInterfaceGroupAssociationId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpDeleteLocalGatewayRouteTableVpcAssociationInput(v *DeleteLocalGatewayRouteTableVpcAssociationInput) error { if v == nil { return nil @@ -14083,6 +14425,24 @@ func validateOpModifyIpamScopeInput(v *ModifyIpamScopeInput) error { } } +func validateOpModifyLocalGatewayRouteInput(v *ModifyLocalGatewayRouteInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ModifyLocalGatewayRouteInput"} + if v.DestinationCidrBlock == nil { + invalidParams.Add(smithy.NewErrParamRequired("DestinationCidrBlock")) + } + if v.LocalGatewayRouteTableId == nil { + invalidParams.Add(smithy.NewErrParamRequired("LocalGatewayRouteTableId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpModifyManagedPrefixListInput(v *ModifyManagedPrefixListInput) error { if v == nil { return nil diff --git a/service/eks/api_op_AssociateIdentityProviderConfig.go b/service/eks/api_op_AssociateIdentityProviderConfig.go index d934a63c62c..792fb203178 100644 --- a/service/eks/api_op_AssociateIdentityProviderConfig.go +++ b/service/eks/api_op_AssociateIdentityProviderConfig.go @@ -43,8 +43,7 @@ type AssociateIdentityProviderConfigInput struct { // This member is required. ClusterName *string - // An object that represents an OpenID Connect (OIDC) identity provider - // configuration. + // An object representing an OpenID Connect (OIDC) identity provider configuration. // // This member is required. Oidc *types.OidcIdentityProviderConfigRequest diff --git a/service/eks/api_op_CreateAddon.go b/service/eks/api_op_CreateAddon.go index 833b1ad02ed..d8a68cb6f00 100644 --- a/service/eks/api_op_CreateAddon.go +++ b/service/eks/api_op_CreateAddon.go @@ -58,8 +58,26 @@ type CreateAddonInput struct { // of the request. ClientRequestToken *string - // How to resolve parameter value conflicts when migrating an existing add-on to an - // Amazon EKS add-on. + // How to resolve field value conflicts for an Amazon EKS add-on. Conflicts are + // handled based on the value you choose: + // + // * None – If the self-managed version of + // the add-on is installed on your cluster, Amazon EKS doesn't change the value. + // Creation of the add-on might fail. + // + // * Overwrite – If the self-managed version of + // the add-on is installed on your cluster and the Amazon EKS default value is + // different than the existing value, Amazon EKS changes the value to the Amazon + // EKS default value. + // + // * Preserve – Not supported. You can set this value when + // updating an add-on though. For more information, see UpdateAddon + // (https://docs.aws.amazon.com/eks/latest/APIReference/API_UpdateAddon.html). + // + // If + // you don't currently have the self-managed version of the add-on installed on + // your cluster, the Amazon EKS add-on is installed. Amazon EKS sets all values to + // default values, regardless of the option that you specify. ResolveConflicts types.ResolveConflicts // The Amazon Resource Name (ARN) of an existing IAM role to bind to the add-on's diff --git a/service/eks/api_op_CreateCluster.go b/service/eks/api_op_CreateCluster.go index fe21c0ce73d..e74dab64329 100644 --- a/service/eks/api_op_CreateCluster.go +++ b/service/eks/api_op_CreateCluster.go @@ -95,12 +95,21 @@ type CreateClusterInput struct { // CloudWatch Pricing (http://aws.amazon.com/cloudwatch/pricing/). Logging *types.Logging + // An object representing the configuration of your local Amazon EKS cluster on an + // Amazon Web Services Outpost. Before creating a local cluster on an Outpost, + // review Creating an Amazon EKS cluster on an Amazon Web Services Outpost + // (https://docs.aws.amazon.com/eks/latest/userguide/create-cluster-outpost.html) + // in the Amazon EKS User Guide. This object isn't available for creating Amazon + // EKS clusters on the Amazon Web Services cloud. + OutpostConfig *types.OutpostConfigRequest + // The metadata to apply to the cluster to assist with categorization and // organization. Each tag consists of a key and an optional value. You define both. Tags map[string]string // The desired Kubernetes version for your cluster. If you don't specify a value - // here, the latest version available in Amazon EKS is used. + // here, the default version available in Amazon EKS is used. The default version + // might not be the latest version available. Version *string noSmithyDocumentSerde diff --git a/service/eks/api_op_DescribeIdentityProviderConfig.go b/service/eks/api_op_DescribeIdentityProviderConfig.go index 178863319a1..8d358a2c2a4 100644 --- a/service/eks/api_op_DescribeIdentityProviderConfig.go +++ b/service/eks/api_op_DescribeIdentityProviderConfig.go @@ -34,7 +34,7 @@ type DescribeIdentityProviderConfigInput struct { // This member is required. ClusterName *string - // An object that represents an identity provider configuration. + // An object representing an identity provider configuration. // // This member is required. IdentityProviderConfig *types.IdentityProviderConfig diff --git a/service/eks/api_op_DisassociateIdentityProviderConfig.go b/service/eks/api_op_DisassociateIdentityProviderConfig.go index bb1dda0e1c3..394bcf9f64e 100644 --- a/service/eks/api_op_DisassociateIdentityProviderConfig.go +++ b/service/eks/api_op_DisassociateIdentityProviderConfig.go @@ -38,7 +38,7 @@ type DisassociateIdentityProviderConfigInput struct { // This member is required. ClusterName *string - // An object that represents an identity provider configuration. + // An object representing an identity provider configuration. // // This member is required. IdentityProviderConfig *types.IdentityProviderConfig diff --git a/service/eks/api_op_UpdateAddon.go b/service/eks/api_op_UpdateAddon.go index 545ed70e007..705f9b170a5 100644 --- a/service/eks/api_op_UpdateAddon.go +++ b/service/eks/api_op_UpdateAddon.go @@ -51,8 +51,19 @@ type UpdateAddonInput struct { // the request. ClientRequestToken *string - // How to resolve parameter value conflicts when applying the new version of the - // add-on to the cluster. + // How to resolve field value conflicts for an Amazon EKS add-on if you've changed + // a value from the Amazon EKS default value. Conflicts are handled based on the + // option you choose: + // + // * None – Amazon EKS doesn't change the value. The update + // might fail. + // + // * Overwrite – Amazon EKS overwrites the changed value back to the + // Amazon EKS default value. + // + // * Preserve – Amazon EKS preserves the value. If you + // choose this option, we recommend that you test any field and value changes on a + // non-production cluster before updating the add-on on your production cluster. ResolveConflicts types.ResolveConflicts // The Amazon Resource Name (ARN) of an existing IAM role to bind to the add-on's diff --git a/service/eks/deserializers.go b/service/eks/deserializers.go index 396f89afe9e..d21cbf13c97 100644 --- a/service/eks/deserializers.go +++ b/service/eks/deserializers.go @@ -6600,6 +6600,20 @@ func awsRestjson1_deserializeDocumentCluster(v **types.Cluster, value interface{ sv.Endpoint = ptr.String(jtv) } + case "health": + if err := awsRestjson1_deserializeDocumentClusterHealth(&sv.Health, value); err != nil { + return err + } + + case "id": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Id = ptr.String(jtv) + } + case "identity": if err := awsRestjson1_deserializeDocumentIdentity(&sv.Identity, value); err != nil { return err @@ -6624,6 +6638,11 @@ func awsRestjson1_deserializeDocumentCluster(v **types.Cluster, value interface{ sv.Name = ptr.String(jtv) } + case "outpostConfig": + if err := awsRestjson1_deserializeDocumentOutpostConfigResponse(&sv.OutpostConfig, value); err != nil { + return err + } + case "platformVersion": if value != nil { jtv, ok := value.(string) @@ -6679,6 +6698,130 @@ func awsRestjson1_deserializeDocumentCluster(v **types.Cluster, value interface{ return nil } +func awsRestjson1_deserializeDocumentClusterHealth(v **types.ClusterHealth, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ClusterHealth + if *v == nil { + sv = &types.ClusterHealth{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "issues": + if err := awsRestjson1_deserializeDocumentClusterIssueList(&sv.Issues, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentClusterIssue(v **types.ClusterIssue, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ClusterIssue + if *v == nil { + sv = &types.ClusterIssue{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "code": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ClusterIssueCode to be of type string, got %T instead", value) + } + sv.Code = types.ClusterIssueCode(jtv) + } + + case "message": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Message = ptr.String(jtv) + } + + case "resourceIds": + if err := awsRestjson1_deserializeDocumentStringList(&sv.ResourceIds, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentClusterIssueList(v *[]types.ClusterIssue, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.ClusterIssue + if *v == nil { + cv = []types.ClusterIssue{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.ClusterIssue + destAddr := &col + if err := awsRestjson1_deserializeDocumentClusterIssue(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsRestjson1_deserializeDocumentCompatibilities(v *[]types.Compatibility, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -8555,6 +8698,51 @@ func awsRestjson1_deserializeDocumentOidcIdentityProviderConfig(v **types.OidcId return nil } +func awsRestjson1_deserializeDocumentOutpostConfigResponse(v **types.OutpostConfigResponse, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.OutpostConfigResponse + if *v == nil { + sv = &types.OutpostConfigResponse{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "controlPlaneInstanceType": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.ControlPlaneInstanceType = ptr.String(jtv) + } + + case "outpostArns": + if err := awsRestjson1_deserializeDocumentStringList(&sv.OutpostArns, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentProvider(v **types.Provider, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/eks/serializers.go b/service/eks/serializers.go index bff8a39ada1..8bf47e31b94 100644 --- a/service/eks/serializers.go +++ b/service/eks/serializers.go @@ -396,6 +396,13 @@ func awsRestjson1_serializeOpDocumentCreateClusterInput(v *CreateClusterInput, v ok.String(*v.Name) } + if v.OutpostConfig != nil { + ok := object.Key("outpostConfig") + if err := awsRestjson1_serializeDocumentOutpostConfigRequest(v.OutpostConfig, ok); err != nil { + return err + } + } + if v.ResourcesVpcConfig != nil { ok := object.Key("resourcesVpcConfig") if err := awsRestjson1_serializeDocumentVpcConfigRequest(v.ResourcesVpcConfig, ok); err != nil { @@ -3131,6 +3138,25 @@ func awsRestjson1_serializeDocumentOidcIdentityProviderConfigRequest(v *types.Oi return nil } +func awsRestjson1_serializeDocumentOutpostConfigRequest(v *types.OutpostConfigRequest, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.ControlPlaneInstanceType != nil { + ok := object.Key("controlPlaneInstanceType") + ok.String(*v.ControlPlaneInstanceType) + } + + if v.OutpostArns != nil { + ok := object.Key("outpostArns") + if err := awsRestjson1_serializeDocumentStringList(v.OutpostArns, ok); err != nil { + return err + } + } + + return nil +} + func awsRestjson1_serializeDocumentProvider(v *types.Provider, value smithyjson.Value) error { object := value.Object() defer object.Close() diff --git a/service/eks/types/enums.go b/service/eks/types/enums.go index 62863ed2da9..d85ce058d93 100644 --- a/service/eks/types/enums.go +++ b/service/eks/types/enums.go @@ -43,6 +43,7 @@ const ( AddonStatusDeleting AddonStatus = "DELETING" AddonStatusDeleteFailed AddonStatus = "DELETE_FAILED" AddonStatusDegraded AddonStatus = "DEGRADED" + AddonStatusUpdateFailed AddonStatus = "UPDATE_FAILED" ) // Values returns all known values for AddonStatus. Note that this can be expanded @@ -57,6 +58,7 @@ func (AddonStatus) Values() []AddonStatus { "DELETING", "DELETE_FAILED", "DEGRADED", + "UPDATE_FAILED", } } @@ -108,6 +110,32 @@ func (CapacityTypes) Values() []CapacityTypes { } } +type ClusterIssueCode string + +// Enum values for ClusterIssueCode +const ( + ClusterIssueCodeAccessDenied ClusterIssueCode = "AccessDenied" + ClusterIssueCodeClusterUnreachable ClusterIssueCode = "ClusterUnreachable" + ClusterIssueCodeConfigurationConflict ClusterIssueCode = "ConfigurationConflict" + ClusterIssueCodeInternalFailure ClusterIssueCode = "InternalFailure" + ClusterIssueCodeResourceLimitExceeded ClusterIssueCode = "ResourceLimitExceeded" + ClusterIssueCodeResourceNotFound ClusterIssueCode = "ResourceNotFound" +) + +// Values returns all known values for ClusterIssueCode. Note that this can be +// expanded in the future, and so it is only as up to date as the client. The +// ordering of this slice is not guaranteed to be stable across updates. +func (ClusterIssueCode) Values() []ClusterIssueCode { + return []ClusterIssueCode{ + "AccessDenied", + "ClusterUnreachable", + "ConfigurationConflict", + "InternalFailure", + "ResourceLimitExceeded", + "ResourceNotFound", + } +} + type ClusterStatus string // Enum values for ClusterStatus @@ -386,6 +414,7 @@ type ResolveConflicts string const ( ResolveConflictsOverwrite ResolveConflicts = "OVERWRITE" ResolveConflictsNone ResolveConflicts = "NONE" + ResolveConflictsPreserve ResolveConflicts = "PRESERVE" ) // Values returns all known values for ResolveConflicts. Note that this can be @@ -395,6 +424,7 @@ func (ResolveConflicts) Values() []ResolveConflicts { return []ResolveConflicts{ "OVERWRITE", "NONE", + "PRESERVE", } } diff --git a/service/eks/types/types.go b/service/eks/types/types.go index 31c99f76c2b..85d8206d3cb 100644 --- a/service/eks/types/types.go +++ b/service/eks/types/types.go @@ -27,7 +27,7 @@ type Addon struct { // The date and time that the add-on was created. CreatedAt *time.Time - // An object that represents the health of the add-on. + // An object representing the health of the add-on. Health *AddonHealth // The date and time that the add-on was last modified. @@ -51,7 +51,7 @@ type Addon struct { // The health of the add-on. type AddonHealth struct { - // An object that represents the add-on's health issues. + // An object representing the health issues for an add-on. Issues []AddonIssue noSmithyDocumentSerde @@ -63,7 +63,7 @@ type AddonInfo struct { // The name of the add-on. AddonName *string - // An object that represents information about available add-on versions and + // An object representing information about available add-on versions and // compatible Kubernetes versions. AddonVersions []AddonVersionInfo @@ -97,7 +97,7 @@ type AddonVersionInfo struct { // The architectures that the version supports. Architecture []string - // An object that represents the compatibilities of a version. + // An object representing the compatibilities of a version. Compatibilities []Compatibility noSmithyDocumentSerde @@ -149,6 +149,16 @@ type Cluster struct { // The endpoint for your Kubernetes API server. Endpoint *string + // An object representing the health of your local Amazon EKS cluster on an Amazon + // Web Services Outpost. This object isn't available for clusters on the Amazon Web + // Services cloud. + Health *ClusterHealth + + // The ID of your local Amazon EKS cluster on an Amazon Web Services Outpost. This + // property isn't available for an Amazon EKS cluster on the Amazon Web Services + // cloud. + Id *string + // The identity provider information for the cluster. Identity *Identity @@ -161,6 +171,11 @@ type Cluster struct { // The name of the cluster. Name *string + // An object representing the configuration of your local Amazon EKS cluster on an + // Amazon Web Services Outpost. This object isn't available for clusters on the + // Amazon Web Services cloud. + OutpostConfig *OutpostConfigResponse + // The platform version of your Amazon EKS cluster. For more information, see // Platform Versions // (https://docs.aws.amazon.com/eks/latest/userguide/platform-versions.html) in the @@ -196,6 +211,35 @@ type Cluster struct { noSmithyDocumentSerde } +// An object representing the health of your local Amazon EKS cluster on an Amazon +// Web Services Outpost. You can't use this API with an Amazon EKS cluster on the +// Amazon Web Services cloud. +type ClusterHealth struct { + + // An object representing the health issues of your local Amazon EKS cluster on an + // Amazon Web Services Outpost. + Issues []ClusterIssue + + noSmithyDocumentSerde +} + +// An issue with your local Amazon EKS cluster on an Amazon Web Services Outpost. +// You can't use this API with an Amazon EKS cluster on the Amazon Web Services +// cloud. +type ClusterIssue struct { + + // The error code of the issue. + Code ClusterIssueCode + + // A description of the issue. + Message *string + + // The resource IDs that the issue relates to. + ResourceIds []string + + noSmithyDocumentSerde +} + // Compatibility information. type Compatibility struct { @@ -383,8 +427,7 @@ type IdentityProviderConfig struct { // The full description of your identity configuration. type IdentityProviderConfigResponse struct { - // An object that represents an OpenID Connect (OIDC) identity provider - // configuration. + // An object representing an OpenID Connect (OIDC) identity provider configuration. Oidc *OidcIdentityProviderConfig noSmithyDocumentSerde @@ -546,7 +589,7 @@ type KubernetesNetworkConfigResponse struct { } // An object representing a node group launch template specification. The launch -// template cannot include SubnetId +// template can't include SubnetId // (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateNetworkInterface.html), // IamInstanceProfile // (https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_IamInstanceProfile.html), @@ -562,17 +605,22 @@ type KubernetesNetworkConfigResponse struct { // in the Amazon EC2 API Reference. For more information about using launch // templates with Amazon EKS, see Launch template support // (https://docs.aws.amazon.com/eks/latest/userguide/launch-templates.html) in the -// Amazon EKS User Guide. Specify either name or id, but not both. +// Amazon EKS User Guide. You must specify either the launch template ID or the +// launch template name in the request, but not both. type LaunchTemplateSpecification struct { - // The ID of the launch template. + // The ID of the launch template. You must specify either the launch template ID or + // the launch template name in the request, but not both. Id *string - // The name of the launch template. + // The name of the launch template. You must specify either the launch template + // name or the launch template ID in the request, but not both. Name *string - // The version of the launch template to use. If no version is specified, then the - // template's default version is used. + // The launch template version number, $Latest, or $Default. If the value is + // $Latest, Amazon EKS uses the latest version of the launch template. If the value + // is $Default, Amazon EKS uses the default version of the launch template. + // Default: The default version of the launch template. Version *string noSmithyDocumentSerde @@ -793,8 +841,8 @@ type OIDC struct { noSmithyDocumentSerde } -// An object that represents the configuration for an OpenID Connect (OIDC) -// identity provider. +// An object representing the configuration for an OpenID Connect (OIDC) identity +// provider. type OidcIdentityProviderConfig struct { // This is also known as audience. The ID of the client application that makes @@ -906,6 +954,66 @@ type OidcIdentityProviderConfigRequest struct { noSmithyDocumentSerde } +// The configuration of your local Amazon EKS cluster on an Amazon Web Services +// Outpost. Before creating a cluster on an Outpost, review Creating a local Amazon +// EKS cluster on an Amazon Web Services Outpost +// (https://docs.aws.amazon.com/eks/latest/userguide/create-cluster-outpost.html) +// in the Amazon EKS User Guide. This API isn't available for Amazon EKS clusters +// on the Amazon Web Services cloud. +type OutpostConfigRequest struct { + + // The Amazon EC2 instance type that you want to use for your local Amazon EKS + // cluster on Outposts. The instance type that you specify is used for all + // Kubernetes control plane instances. The instance type can't be changed after + // cluster creation. Choose an instance type based on the number of nodes that your + // cluster will have. If your cluster will have: + // + // * 1–20 nodes, then we recommend + // specifying a large instance type. + // + // * 21–100 nodes, then we recommend specifying + // an xlarge instance type. + // + // * 101–250 nodes, then we recommend specifying a + // 2xlarge instance type. + // + // For a list of the available Amazon EC2 instance types, + // see Compute and storage in Outposts rack features + // (http://aws.amazon.com/outposts/rack/features/). The control plane is not + // automatically scaled by Amazon EKS. + // + // This member is required. + ControlPlaneInstanceType *string + + // The ARN of the Outpost that you want to use for your local Amazon EKS cluster on + // Outposts. Only a single Outpost ARN is supported. + // + // This member is required. + OutpostArns []string + + noSmithyDocumentSerde +} + +// An object representing the configuration of your local Amazon EKS cluster on an +// Amazon Web Services Outpost. This API isn't available for Amazon EKS clusters on +// the Amazon Web Services cloud. +type OutpostConfigResponse struct { + + // The Amazon EC2 instance type used for the control plane. The instance type is + // the same for all control plane instances. + // + // This member is required. + ControlPlaneInstanceType *string + + // The ARN of the Outpost that you specified for use with your local Amazon EKS + // cluster on Outposts. + // + // This member is required. + OutpostArns []string + + noSmithyDocumentSerde +} + // Identifies the Key Management Service (KMS) key used to encrypt the secrets. type Provider struct { diff --git a/service/eks/validators.go b/service/eks/validators.go index 824222ad7fd..9672e26344c 100644 --- a/service/eks/validators.go +++ b/service/eks/validators.go @@ -835,6 +835,24 @@ func validateOidcIdentityProviderConfigRequest(v *types.OidcIdentityProviderConf } } +func validateOutpostConfigRequest(v *types.OutpostConfigRequest) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "OutpostConfigRequest"} + if v.OutpostArns == nil { + invalidParams.Add(smithy.NewErrParamRequired("OutpostArns")) + } + if v.ControlPlaneInstanceType == nil { + invalidParams.Add(smithy.NewErrParamRequired("ControlPlaneInstanceType")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpAssociateEncryptionConfigInput(v *AssociateEncryptionConfigInput) error { if v == nil { return nil @@ -907,6 +925,11 @@ func validateOpCreateClusterInput(v *CreateClusterInput) error { if v.ResourcesVpcConfig == nil { invalidParams.Add(smithy.NewErrParamRequired("ResourcesVpcConfig")) } + if v.OutpostConfig != nil { + if err := validateOutpostConfigRequest(v.OutpostConfig); err != nil { + invalidParams.AddNested("OutpostConfig", err.(smithy.InvalidParamsError)) + } + } if invalidParams.Len() > 0 { return invalidParams } else { diff --git a/service/emrcontainers/api_op_CreateManagedEndpoint.go b/service/emrcontainers/api_op_CreateManagedEndpoint.go index c74d489e0a0..cb659ed0367 100644 --- a/service/emrcontainers/api_op_CreateManagedEndpoint.go +++ b/service/emrcontainers/api_op_CreateManagedEndpoint.go @@ -62,7 +62,7 @@ type CreateManagedEndpointInput struct { // This member is required. VirtualClusterId *string - // The certificate ARN provided by users for the managed endpoint. This fiedd is + // The certificate ARN provided by users for the managed endpoint. This field is // under deprecation and will be removed in future releases. // // Deprecated: Customer provided certificate-arn is deprecated and would be removed diff --git a/service/emrcontainers/deserializers.go b/service/emrcontainers/deserializers.go index 6df18ca012a..fecdc4b2e32 100644 --- a/service/emrcontainers/deserializers.go +++ b/service/emrcontainers/deserializers.go @@ -3087,6 +3087,11 @@ func awsRestjson1_deserializeDocumentJobDriver(v **types.JobDriver, value interf for key, value := range shape { switch key { + case "sparkSqlJobDriver": + if err := awsRestjson1_deserializeDocumentSparkSqlJobDriver(&sv.SparkSqlJobDriver, value); err != nil { + return err + } + case "sparkSubmitJobDriver": if err := awsRestjson1_deserializeDocumentSparkSubmitJobDriver(&sv.SparkSubmitJobDriver, value); err != nil { return err @@ -3472,6 +3477,55 @@ func awsRestjson1_deserializeDocumentSensitivePropertiesMap(v *map[string]string return nil } +func awsRestjson1_deserializeDocumentSparkSqlJobDriver(v **types.SparkSqlJobDriver, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.SparkSqlJobDriver + if *v == nil { + sv = &types.SparkSqlJobDriver{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "entryPoint": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected EntryPointPath to be of type string, got %T instead", value) + } + sv.EntryPoint = ptr.String(jtv) + } + + case "sparkSqlParameters": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected SparkSqlParameters to be of type string, got %T instead", value) + } + sv.SparkSqlParameters = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentSparkSubmitJobDriver(v **types.SparkSubmitJobDriver, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/emrcontainers/serializers.go b/service/emrcontainers/serializers.go index 32443809c5f..0dbb3b86583 100644 --- a/service/emrcontainers/serializers.go +++ b/service/emrcontainers/serializers.go @@ -1323,6 +1323,13 @@ func awsRestjson1_serializeDocumentJobDriver(v *types.JobDriver, value smithyjso object := value.Object() defer object.Close() + if v.SparkSqlJobDriver != nil { + ok := object.Key("sparkSqlJobDriver") + if err := awsRestjson1_serializeDocumentSparkSqlJobDriver(v.SparkSqlJobDriver, ok); err != nil { + return err + } + } + if v.SparkSubmitJobDriver != nil { ok := object.Key("sparkSubmitJobDriver") if err := awsRestjson1_serializeDocumentSparkSubmitJobDriver(v.SparkSubmitJobDriver, ok); err != nil { @@ -1382,6 +1389,23 @@ func awsRestjson1_serializeDocumentSensitivePropertiesMap(v map[string]string, v return nil } +func awsRestjson1_serializeDocumentSparkSqlJobDriver(v *types.SparkSqlJobDriver, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.EntryPoint != nil { + ok := object.Key("entryPoint") + ok.String(*v.EntryPoint) + } + + if v.SparkSqlParameters != nil { + ok := object.Key("sparkSqlParameters") + ok.String(*v.SparkSqlParameters) + } + + return nil +} + func awsRestjson1_serializeDocumentSparkSubmitJobDriver(v *types.SparkSubmitJobDriver, value smithyjson.Value) error { object := value.Object() defer object.Close() diff --git a/service/emrcontainers/types/types.go b/service/emrcontainers/types/types.go index fe86b036b9d..9706f23c894 100644 --- a/service/emrcontainers/types/types.go +++ b/service/emrcontainers/types/types.go @@ -183,6 +183,9 @@ type Endpoint struct { // Specify the driver that the job runs on. type JobDriver struct { + // The job driver for job type. + SparkSqlJobDriver *SparkSqlJobDriver + // The job driver parameters specified for spark submit. SparkSubmitJobDriver *SparkSubmitJobDriver @@ -271,6 +274,18 @@ type S3MonitoringConfiguration struct { noSmithyDocumentSerde } +// The job driver for job type. +type SparkSqlJobDriver struct { + + // The SQL file to be executed. + EntryPoint *string + + // The Spark parameters to be included in the Spark SQL command. + SparkSqlParameters *string + + noSmithyDocumentSerde +} + // The information about job driver for Spark submit. type SparkSubmitJobDriver struct { diff --git a/service/evidently/api_op_CreateProject.go b/service/evidently/api_op_CreateProject.go index aeb39a3a46b..81425d7097f 100644 --- a/service/evidently/api_op_CreateProject.go +++ b/service/evidently/api_op_CreateProject.go @@ -37,6 +37,20 @@ type CreateProjectInput struct { // This member is required. Name *string + // Use this parameter if the project will use client-side evaluation powered by + // AppConfig. Client-side evaluation allows your application to assign variations + // to user sessions locally instead of by calling the EvaluateFeature + // (https://docs.aws.amazon.com/cloudwatchevidently/latest/APIReference/API_EvaluateFeature.html) + // operation. This mitigates the latency and availability risks that come with an + // API call. For more information, see Client-side evaluation - powered by + // AppConfig. + // (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-Evidently-client-side-evaluation.html) + // This parameter is a structure that contains information about the AppConfig + // application and environment that will be used as for client-side evaluation. To + // create a project that uses client-side evaluation, you must have the + // evidently:ExportProjectAsConfiguration permission. + AppConfigResource *types.ProjectAppConfigResourceConfig + // A structure that contains information about where Evidently is to store // evaluation events for longer term storage, if you choose to do so. If you choose // not to store these events, Evidently deletes them after using them to produce diff --git a/service/evidently/api_op_CreateSegment.go b/service/evidently/api_op_CreateSegment.go index 83b4cbe1a63..140abaf244f 100644 --- a/service/evidently/api_op_CreateSegment.go +++ b/service/evidently/api_op_CreateSegment.go @@ -16,10 +16,10 @@ import ( // Chrome browser users, users in Europe, or Firefox browser users in Europe who // also fit other criteria that your application collects, such as age. Using a // segment in an experiment limits that experiment to evaluate only the users who -// match the segment criteria. Using one or more segments in a launch allow you to +// match the segment criteria. Using one or more segments in a launch allows you to // define different traffic splits for the different audience segments. For more // information about segment pattern syntax, see Segment rule pattern syntax -// (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-Evidently-segments-syntax.html). +// (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-Evidently-segments.html#CloudWatch-Evidently-segments-syntax.html). // The pattern that you define for a segment is matched against the value of // evaluationContext, which is passed into Evidently in the EvaluateFeature // (https://docs.aws.amazon.com/cloudwatchevidently/latest/APIReference/API_EvaluateFeature.html) @@ -48,7 +48,7 @@ type CreateSegmentInput struct { // The pattern to use for the segment. For more information about pattern syntax, // see Segment rule pattern syntax - // (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-Evidently-segments-syntax.html). + // (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-Evidently-segments.html#CloudWatch-Evidently-segments-syntax.html). // // This value conforms to the media type: application/json // diff --git a/service/evidently/api_op_GetExperimentResults.go b/service/evidently/api_op_GetExperimentResults.go index 10182f011a9..59212c1315b 100644 --- a/service/evidently/api_op_GetExperimentResults.go +++ b/service/evidently/api_op_GetExperimentResults.go @@ -14,9 +14,13 @@ import ( // Retrieves the results of a running or completed experiment. No results are // available until there have been 100 events for each variation and at least 10 -// minutes have passed since the start of the experiment. Experiment results are -// available up to 63 days after the start of the experiment. They are not -// available after that because of CloudWatch data retention policies. +// minutes have passed since the start of the experiment. To increase the +// statistical power, Evidently performs an additional offline p-value analysis at +// the end of the experiment. Offline p-value analysis can detect statistical +// significance in some cases where the anytime p-values used during the experiment +// do not find statistical significance. Experiment results are available up to 63 +// days after the start of the experiment. They are not available after that +// because of CloudWatch data retention policies. func (c *Client) GetExperimentResults(ctx context.Context, params *GetExperimentResultsInput, optFns ...func(*Options)) (*GetExperimentResultsOutput, error) { if params == nil { params = &GetExperimentResultsInput{} diff --git a/service/evidently/api_op_UpdateProject.go b/service/evidently/api_op_UpdateProject.go index f2a94de99ab..b89ebf6bf9e 100644 --- a/service/evidently/api_op_UpdateProject.go +++ b/service/evidently/api_op_UpdateProject.go @@ -42,6 +42,15 @@ type UpdateProjectInput struct { // This member is required. Project *string + // Use this parameter if the project will use client-side evaluation powered by + // AppConfig. Client-side evaluation allows your application to assign variations + // to user sessions locally instead of by calling the EvaluateFeature + // (https://docs.aws.amazon.com/cloudwatchevidently/latest/APIReference/API_EvaluateFeature.html) + // operation. This mitigates the latency and availability risks that come with an + // API call. allows you to This parameter is a structure that contains information + // about the AppConfig application that will be used for client-side evaluation. + AppConfigResource *types.ProjectAppConfigResourceConfig + // An optional description of the project. Description *string diff --git a/service/evidently/deserializers.go b/service/evidently/deserializers.go index d9de91ebd6a..6e296e48192 100644 --- a/service/evidently/deserializers.go +++ b/service/evidently/deserializers.go @@ -8038,6 +8038,11 @@ func awsRestjson1_deserializeDocumentProject(v **types.Project, value interface{ sv.ActiveLaunchCount = ptr.Int64(i64) } + case "appConfigResource": + if err := awsRestjson1_deserializeDocumentProjectAppConfigResource(&sv.AppConfigResource, value); err != nil { + return err + } + case "arn": if value != nil { jtv, ok := value.(string) @@ -8164,6 +8169,64 @@ func awsRestjson1_deserializeDocumentProject(v **types.Project, value interface{ return nil } +func awsRestjson1_deserializeDocumentProjectAppConfigResource(v **types.ProjectAppConfigResource, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ProjectAppConfigResource + if *v == nil { + sv = &types.ProjectAppConfigResource{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "applicationId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected AppConfigResourceId to be of type string, got %T instead", value) + } + sv.ApplicationId = ptr.String(jtv) + } + + case "configurationProfileId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected AppConfigResourceId to be of type string, got %T instead", value) + } + sv.ConfigurationProfileId = ptr.String(jtv) + } + + case "environmentId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected AppConfigResourceId to be of type string, got %T instead", value) + } + sv.EnvironmentId = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentProjectDataDelivery(v **types.ProjectDataDelivery, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/evidently/serializers.go b/service/evidently/serializers.go index a463a87a7d6..c1531cbfbcf 100644 --- a/service/evidently/serializers.go +++ b/service/evidently/serializers.go @@ -524,6 +524,13 @@ func awsRestjson1_serializeOpDocumentCreateProjectInput(v *CreateProjectInput, v object := value.Object() defer object.Close() + if v.AppConfigResource != nil { + ok := object.Key("appConfigResource") + if err := awsRestjson1_serializeDocumentProjectAppConfigResourceConfig(v.AppConfigResource, ok); err != nil { + return err + } + } + if v.DataDelivery != nil { ok := object.Key("dataDelivery") if err := awsRestjson1_serializeDocumentProjectDataDeliveryConfig(v.DataDelivery, ok); err != nil { @@ -3037,6 +3044,13 @@ func awsRestjson1_serializeOpDocumentUpdateProjectInput(v *UpdateProjectInput, v object := value.Object() defer object.Close() + if v.AppConfigResource != nil { + ok := object.Key("appConfigResource") + if err := awsRestjson1_serializeDocumentProjectAppConfigResourceConfig(v.AppConfigResource, ok); err != nil { + return err + } + } + if v.Description != nil { ok := object.Key("description") ok.String(*v.Description) @@ -3422,6 +3436,23 @@ func awsRestjson1_serializeDocumentOnlineAbConfig(v *types.OnlineAbConfig, value return nil } +func awsRestjson1_serializeDocumentProjectAppConfigResourceConfig(v *types.ProjectAppConfigResourceConfig, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.ApplicationId != nil { + ok := object.Key("applicationId") + ok.String(*v.ApplicationId) + } + + if v.EnvironmentId != nil { + ok := object.Key("environmentId") + ok.String(*v.EnvironmentId) + } + + return nil +} + func awsRestjson1_serializeDocumentProjectDataDeliveryConfig(v *types.ProjectDataDeliveryConfig, value smithyjson.Value) error { object := value.Object() defer object.Close() diff --git a/service/evidently/types/types.go b/service/evidently/types/types.go index 7c705e3a53f..b3aa74fd91a 100644 --- a/service/evidently/types/types.go +++ b/service/evidently/types/types.go @@ -735,6 +735,10 @@ type Project struct { // The number of ongoing launches currently in the project. ActiveLaunchCount *int64 + // This structure defines the configuration of how your application integrates with + // AppConfig to run client-side evaluation. + AppConfigResource *ProjectAppConfigResource + // A structure that contains information about where Evidently is to store // evaluation events for longer term storage. DataDelivery *ProjectDataDelivery @@ -760,6 +764,51 @@ type Project struct { noSmithyDocumentSerde } +// This is a structure that defines the configuration of how your application +// integrates with AppConfig to run client-side evaluation. +type ProjectAppConfigResource struct { + + // The ID of the AppConfig application to use for client-side evaluation. + // + // This member is required. + ApplicationId *string + + // The ID of the AppConfig profile to use for client-side evaluation. + // + // This member is required. + ConfigurationProfileId *string + + // The ID of the AppConfig environment to use for client-side evaluation. This must + // be an environment that is within the application that you specify for + // applicationId. + // + // This member is required. + EnvironmentId *string + + noSmithyDocumentSerde +} + +// Use this parameter to configure client-side evaluation for your project. +// Client-side evaluation allows your application to assign variations to user +// sessions locally instead of by calling the EvaluateFeature +// (https://docs.aws.amazon.com/cloudwatchevidently/latest/APIReference/API_EvaluateFeature.html) +// operation to assign the variations. This mitigates the latency and availability +// risks that come with an API call. ProjectAppConfigResource is a structure that +// defines the configuration of how your application integrates with AppConfig to +// run client-side evaluation. +type ProjectAppConfigResourceConfig struct { + + // The ID of the AppConfig application to use for client-side evaluation. + ApplicationId *string + + // The ID of the AppConfig environment to use for client-side evaluation. This must + // be an environment that is within the application that you specify for + // applicationId. + EnvironmentId *string + + noSmithyDocumentSerde +} + // A structure that contains information about where Evidently is to store // evaluation events for longer term storage. type ProjectDataDelivery struct { @@ -1038,7 +1087,10 @@ type Segment struct { // This member is required. Name *string - // + // The pattern that defines the attributes to use to evalute whether a user session + // will be in the segment. For more information about the pattern syntax, see + // Segment rule pattern syntax + // (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-Evidently-segments.html). // // This value conforms to the media type: application/json // diff --git a/service/fsx/types/types.go b/service/fsx/types/types.go index 212ebf22e7d..278f9d62d15 100644 --- a/service/fsx/types/types.go +++ b/service/fsx/types/types.go @@ -863,21 +863,25 @@ type CreateOntapVolumeConfiguration struct { // This member is required. StorageVirtualMachineId *string - // The security style for the volume. If a volume's security style is not - // specified, it is automatically set to the root volume's security style. Specify - // one of the following values: + // Specifies the security style for the volume. If a volume's security style is not + // specified, it is automatically set to the root volume's security style. The + // security style determines the type of permissions that FSx for ONTAP uses to + // control data access. For more information, see Volume security style + // (https://docs.aws.amazon.com/fsx/latest/ONTAPGuide/managing-volumes.html#volume-security-style) + // in the Amazon FSx for NetApp ONTAP User Guide. Specify one of the following + // values: // - // * UNIX if the file system is managed by a UNIX - // administrator, the majority of users are NFS clients, and an application - // accessing the data uses a UNIX user as the service account. + // * UNIX if the file system is managed by a UNIX administrator, the + // majority of users are NFS clients, and an application accessing the data uses a + // UNIX user as the service account. // - // * NTFS if the file - // system is managed by a Windows administrator, the majority of users are SMB - // clients, and an application accessing the data uses a Windows user as the - // service account. + // * NTFS if the file system is managed by a + // Windows administrator, the majority of users are SMB clients, and an application + // accessing the data uses a Windows user as the service account. // - // * MIXED if the file system is managed by both UNIX and Windows - // administrators and users consist of both NFS and SMB clients. + // * MIXED if the + // file system is managed by both UNIX and Windows administrators and users consist + // of both NFS and SMB clients. SecurityStyle SecurityStyle // Describes the data tiering policy for an ONTAP volume. When enabled, Amazon FSx @@ -1573,8 +1577,7 @@ type FileSystem struct { // The Domain Name System (DNS) name for the file system. DNSName *string - // A structure providing details of any failures that occurred when creating a file - // system. + // A structure providing details of any failures that occurred. FailureDetails *FileSystemFailureDetails // The system-generated, unique 17-digit ID of the file system. @@ -1723,11 +1726,10 @@ type FileSystemEndpoints struct { noSmithyDocumentSerde } -// A structure providing details of any failures that occurred when creating a file -// system. +// A structure providing details of any failures that occurred. type FileSystemFailureDetails struct { - // A message describing any failures that occurred during file system creation. + // A message describing any failures that occurred. Message *string noSmithyDocumentSerde diff --git a/service/identitystore/api_op_CreateGroupMembership.go b/service/identitystore/api_op_CreateGroupMembership.go index 76763f9ebc3..f431d55b7f4 100644 --- a/service/identitystore/api_op_CreateGroupMembership.go +++ b/service/identitystore/api_op_CreateGroupMembership.go @@ -57,7 +57,7 @@ type CreateGroupMembershipOutput struct { // This member is required. IdentityStoreId *string - // The identifier for a GroupMembership in the identity store. + // The identifier for a newly created GroupMembership in an identity store. // // This member is required. MembershipId *string diff --git a/service/identitystore/api_op_CreateUser.go b/service/identitystore/api_op_CreateUser.go index 3f8a98f5aaa..e862a68e1fb 100644 --- a/service/identitystore/api_op_CreateUser.go +++ b/service/identitystore/api_op_CreateUser.go @@ -72,9 +72,8 @@ type CreateUserInput struct { // A unique string used to identify the user. The length limit is 128 characters. // This value can consist of letters, accented characters, symbols, numbers, and - // punctuation. The characters <>;:% are excluded. This value is specified at the - // time the user is created and stored as an attribute of the user object in the - // identity store. + // punctuation. This value is specified at the time the user is created and stored + // as an attribute of the user object in the identity store. UserName *string // A string indicating the user's type. Possible values depend on each customer's diff --git a/service/identitystore/api_op_DeleteGroupMembership.go b/service/identitystore/api_op_DeleteGroupMembership.go index 05a49894c8f..a7007e0a49d 100644 --- a/service/identitystore/api_op_DeleteGroupMembership.go +++ b/service/identitystore/api_op_DeleteGroupMembership.go @@ -33,7 +33,7 @@ type DeleteGroupMembershipInput struct { // This member is required. IdentityStoreId *string - // The identifier for a GroupMembership in the identity store. + // The identifier for a GroupMembership in an identity store. // // This member is required. MembershipId *string diff --git a/service/identitystore/api_op_DescribeGroupMembership.go b/service/identitystore/api_op_DescribeGroupMembership.go index cfeff648599..6b7aefe0f27 100644 --- a/service/identitystore/api_op_DescribeGroupMembership.go +++ b/service/identitystore/api_op_DescribeGroupMembership.go @@ -11,7 +11,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Retrieves membership metadata and attributes from MembershipId in a group. +// Retrieves membership metadata and attributes from MembershipId in an identity +// store. func (c *Client) DescribeGroupMembership(ctx context.Context, params *DescribeGroupMembershipInput, optFns ...func(*Options)) (*DescribeGroupMembershipOutput, error) { if params == nil { params = &DescribeGroupMembershipInput{} @@ -34,7 +35,7 @@ type DescribeGroupMembershipInput struct { // This member is required. IdentityStoreId *string - // The identifier for a GroupMembership in the identity store. + // The identifier for a GroupMembership in an identity store. // // This member is required. MembershipId *string @@ -59,7 +60,7 @@ type DescribeGroupMembershipOutput struct { // This member is required. MemberId types.MemberId - // The identifier for a GroupMembership in the identity store. + // The identifier for a GroupMembership in an identity store. // // This member is required. MembershipId *string diff --git a/service/identitystore/api_op_DescribeUser.go b/service/identitystore/api_op_DescribeUser.go index c77bd2f5ab8..fa0a4157623 100644 --- a/service/identitystore/api_op_DescribeUser.go +++ b/service/identitystore/api_op_DescribeUser.go @@ -94,10 +94,10 @@ type DescribeUserOutput struct { // A string containing the user's title. Title *string - // The user’s username value. The length limit is 128 characters. This value can - // consist of letters, accented characters, symbols, numbers, and punctuation. The - // characters <>;:% are excluded. This value is specified at the time the user is - // created and stored as an attribute of the user object in the identity store. + // A unique string used to identify the user. The length limit is 128 characters. + // This value can consist of letters, accented characters, symbols, numbers, and + // punctuation. This value is specified at the time the user is created and stored + // as an attribute of the user object in the identity store. UserName *string // A string indicating the user's type. diff --git a/service/identitystore/api_op_GetGroupId.go b/service/identitystore/api_op_GetGroupId.go index 7f62600d085..babc7a14a5d 100644 --- a/service/identitystore/api_op_GetGroupId.go +++ b/service/identitystore/api_op_GetGroupId.go @@ -29,10 +29,10 @@ func (c *Client) GetGroupId(ctx context.Context, params *GetGroupIdInput, optFns type GetGroupIdInput struct { - // A unique identifier for the group value that is not the group's primary - // identifier. This value can be an identifier from an external identity provider - // (IdP) that is associated with the group or a unique attribute. For example, a - // unique GroupDisplayName. + // A unique identifier for an identity resource that is not the primary identifier. + // This value can be an identifier from an external identity provider (IdP) that is + // associated with the group or a unique attribute. For example, a unique + // GroupDisplayName. // // This member is required. AlternateIdentifier types.AlternateIdentifier diff --git a/service/identitystore/api_op_GetGroupMembershipId.go b/service/identitystore/api_op_GetGroupMembershipId.go index 6aa4d2166b5..43420643b16 100644 --- a/service/identitystore/api_op_GetGroupMembershipId.go +++ b/service/identitystore/api_op_GetGroupMembershipId.go @@ -11,7 +11,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Retrieves the MembershipId in a group. +// Retrieves the MembershipId in an identity store. func (c *Client) GetGroupMembershipId(ctx context.Context, params *GetGroupMembershipIdInput, optFns ...func(*Options)) (*GetGroupMembershipIdOutput, error) { if params == nil { params = &GetGroupMembershipIdInput{} @@ -56,7 +56,7 @@ type GetGroupMembershipIdOutput struct { // This member is required. IdentityStoreId *string - // The identifier for a GroupMembership in the identity store. + // The identifier for a GroupMembership in an identity store. // // This member is required. MembershipId *string diff --git a/service/identitystore/api_op_GetUserId.go b/service/identitystore/api_op_GetUserId.go index 50d6efa902d..68555b8fd74 100644 --- a/service/identitystore/api_op_GetUserId.go +++ b/service/identitystore/api_op_GetUserId.go @@ -29,7 +29,7 @@ func (c *Client) GetUserId(ctx context.Context, params *GetUserIdInput, optFns . type GetUserIdInput struct { - // Any unique attribute associated with a user that is not the UserId. + // A unique identifier for an identity resource that is not the primary identifier. // // This member is required. AlternateIdentifier types.AlternateIdentifier diff --git a/service/identitystore/api_op_IsMemberInGroups.go b/service/identitystore/api_op_IsMemberInGroups.go index 88f89224bcb..4587a8ba781 100644 --- a/service/identitystore/api_op_IsMemberInGroups.go +++ b/service/identitystore/api_op_IsMemberInGroups.go @@ -11,7 +11,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Returns if a member exists in specified groups. +// Checks the user's membership in all requested groups and returns if the member +// exists in all queried groups. func (c *Client) IsMemberInGroups(ctx context.Context, params *IsMemberInGroupsInput, optFns ...func(*Options)) (*IsMemberInGroupsOutput, error) { if params == nil { params = &IsMemberInGroupsInput{} @@ -49,7 +50,7 @@ type IsMemberInGroupsInput struct { type IsMemberInGroupsOutput struct { - // An object containing results of batch IsMemberInGroups call. + // A list containing the results of membership existence checks. // // This member is required. Results []types.GroupMembershipExistenceResult diff --git a/service/identitystore/api_op_ListGroupMemberships.go b/service/identitystore/api_op_ListGroupMemberships.go index 38a182ff286..17238ecc0e0 100644 --- a/service/identitystore/api_op_ListGroupMemberships.go +++ b/service/identitystore/api_op_ListGroupMemberships.go @@ -42,8 +42,7 @@ type ListGroupMembershipsInput struct { IdentityStoreId *string // The maximum number of results to be returned per request. This parameter is used - // in the ListUsers and ListGroups requests to specify how many results to return - // in one page. The length limit is 50 characters. + // in all List requests to specify how many results to return in one page. MaxResults *int32 // The pagination token used for the ListUsers, ListGroups and ListGroupMemberships @@ -63,11 +62,11 @@ type ListGroupMembershipsOutput struct { // This member is required. GroupMemberships []types.GroupMembership - // The pagination token used for the ListUsers, ListGroups and ListGroupMemberships - // API operations. This value is generated by the identity store service. It is - // returned in the API response if the total results are more than the size of one - // page. This token is also returned when it is used in the API request to search - // for the next page. + // The pagination token used for the ListUsers, ListGroups, and + // ListGroupMemberships API operations. This value is generated by the identity + // store service. It is returned in the API response if the total results are more + // than the size of one page. This token is also returned when it is used in the + // API request to search for the next page. NextToken *string // Metadata pertaining to the operation's result. @@ -151,8 +150,7 @@ var _ ListGroupMembershipsAPIClient = (*Client)(nil) // ListGroupMemberships type ListGroupMembershipsPaginatorOptions struct { // The maximum number of results to be returned per request. This parameter is used - // in the ListUsers and ListGroups requests to specify how many results to return - // in one page. The length limit is 50 characters. + // in all List requests to specify how many results to return in one page. Limit int32 // Set to true if pagination should stop if the service returns a pagination token diff --git a/service/identitystore/api_op_ListGroupMembershipsForMember.go b/service/identitystore/api_op_ListGroupMembershipsForMember.go index ed2afe8e984..b446a060e2a 100644 --- a/service/identitystore/api_op_ListGroupMembershipsForMember.go +++ b/service/identitystore/api_op_ListGroupMembershipsForMember.go @@ -48,11 +48,11 @@ type ListGroupMembershipsForMemberInput struct { // in one page. The length limit is 50 characters. MaxResults *int32 - // The pagination token used for the ListUsers, ListGroups and ListGroupMemberships - // API operations. This value is generated by the identity store service. It is - // returned in the API response if the total results are more than the size of one - // page. This token is also returned when it is used in the API request to search - // for the next page. + // The pagination token used for the ListUsers, ListGroups, and + // ListGroupMemberships API operations. This value is generated by the identity + // store service. It is returned in the API response if the total results are more + // than the size of one page. This token is also returned when it is used in the + // API request to search for the next page. NextToken *string noSmithyDocumentSerde @@ -65,11 +65,11 @@ type ListGroupMembershipsForMemberOutput struct { // This member is required. GroupMemberships []types.GroupMembership - // The pagination token used for the ListUsers, ListGroups and ListGroupMemberships - // API operations. This value is generated by the identity store service. It is - // returned in the API response if the total results are more than the size of one - // page. This token is also returned when it is used in the API request to search - // for the next page. + // The pagination token used for the ListUsers, ListGroups, and + // ListGroupMemberships API operations. This value is generated by the identity + // store service. It is returned in the API response if the total results are more + // than the size of one page. This token is also returned when it is used in the + // API request to search for the next page. NextToken *string // Metadata pertaining to the operation's result. diff --git a/service/identitystore/api_op_ListGroups.go b/service/identitystore/api_op_ListGroups.go index 8e94245c025..03939441d77 100644 --- a/service/identitystore/api_op_ListGroups.go +++ b/service/identitystore/api_op_ListGroups.go @@ -12,9 +12,10 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Filtering for a group by the group DisplayName attribute is deprecated. Instead, -// use the GetGroupId API action. Lists all groups in the identity store. Returns a -// paginated list of complete Group objects. +// Lists the attribute name and value of the group that you specified in the +// search. We only support DisplayName as a valid filter attribute path currently, +// and filter is required. This API returns minimum attributes, including GroupId +// and group DisplayName in the response. func (c *Client) ListGroups(ctx context.Context, params *ListGroupsInput, optFns ...func(*Options)) (*ListGroupsOutput, error) { if params == nil { params = &ListGroupsInput{} @@ -40,7 +41,8 @@ type ListGroupsInput struct { // This member is required. IdentityStoreId *string - // A list of Filter objects that is used in the ListUsers and ListGroups requests. + // A list of Filter objects, which is used in the ListUsers and ListGroups + // requests. // // Deprecated: Using filters with ListGroups API is deprecated, please use // GetGroupId API instead. diff --git a/service/identitystore/api_op_ListUsers.go b/service/identitystore/api_op_ListUsers.go index a6afb721c6c..d17c102baaf 100644 --- a/service/identitystore/api_op_ListUsers.go +++ b/service/identitystore/api_op_ListUsers.go @@ -12,9 +12,10 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Filtering for a user by the UserName attribute is deprecated. Instead, use the -// GetUserId API action. Lists all users in the identity store. Returns a paginated -// list of complete User objects. +// Lists the attribute name and value of the user that you specified in the search. +// We only support UserName as a valid filter attribute path currently, and filter +// is required. This API returns minimum attributes, including UserId and UserName +// in the response. func (c *Client) ListUsers(ctx context.Context, params *ListUsersInput, optFns ...func(*Options)) (*ListUsersOutput, error) { if params == nil { params = &ListUsersInput{} @@ -40,7 +41,8 @@ type ListUsersInput struct { // This member is required. IdentityStoreId *string - // A list of Filter objects that is used in the ListUsers and ListGroups requests. + // A list of Filter objects, which is used in the ListUsers and ListGroups + // requests. // // Deprecated: Using filters with ListUsers API is deprecated, please use // GetGroupId API instead. diff --git a/service/identitystore/doc.go b/service/identitystore/doc.go index f2c218eeda7..1f6abad1d5e 100644 --- a/service/identitystore/doc.go +++ b/service/identitystore/doc.go @@ -3,8 +3,14 @@ // Package identitystore provides the API client, operations, and parameter types // for AWS SSO Identity Store. // -// The AWS Single Sign-On (SSO) Identity Store service provides a single place to -// retrieve all of your identities (users and groups). For more information about -// AWS, see the AWS Single Sign-On User Guide +// The Identity Store service used by AWS IAM Identity Center (successor to AWS +// Single Sign-On) provides a single place to retrieve all of your identities +// (users and groups). For more information, see the IAM Identity Center User Guide // (https://docs.aws.amazon.com/singlesignon/latest/userguide/what-is.html). +// Although AWS Single Sign-On was renamed, the sso and identitystore API +// namespaces will continue to retain their original name for backward +// compatibility purposes. For more information, see IAM Identity Center rename +// (https://docs.aws.amazon.com/singlesignon/latest/userguide/what-is.html#renamed). +// This reference guide describes the identity store operations that you can call +// programatically and includes detailed information on data types and errors. package identitystore diff --git a/service/identitystore/types/types.go b/service/identitystore/types/types.go index f69d08a2681..d6817d97dfa 100644 --- a/service/identitystore/types/types.go +++ b/service/identitystore/types/types.go @@ -22,8 +22,8 @@ type Address struct { // The postal code of the address. PostalCode *string - // A boolean representing whether this is the primary address for the associated - // resource. + // A Boolean value representing whether this is the primary address for the + // associated resource. Primary bool // The region of the address. @@ -38,10 +38,10 @@ type Address struct { noSmithyDocumentSerde } -// A unique identifier for the group value that is not the group's primary -// identifier. This value can be an identifier from an external identity provider -// (IdP) that is associated with the group or a unique attribute. For example, a -// unique GroupDisplayName. +// A unique identifier for a user or group that is not the its primary identifier. +// This value can be an identifier from an external identity provider (IdP) that is +// associated with the group or a unique attribute. For example, a unique +// GroupDisplayName. // // The following types satisfy this interface: // @@ -79,7 +79,8 @@ type AttributeOperation struct { // This member is required. AttributePath *string - // The value of the attribute. + // The value of the attribute. This is a Document type. This type is not supported + // by Java V1, Go V1, and older versions of the AWS CLI. AttributeValue document.Interface noSmithyDocumentSerde @@ -88,8 +89,8 @@ type AttributeOperation struct { // The email address associated with the user. type Email struct { - // A boolean representing whether this is the primary email for the associated - // resource. + // A Boolean value representing whether this is the primary email address for the + // associated resource. Primary bool // A string representing the type of address. For example, "Work." @@ -185,7 +186,7 @@ type GroupMembership struct { // of the group. MemberId MemberId - // The identifier for a GroupMembership object in the identity store. + // The identifier for a GroupMembership object in an identity store. MembershipId *string noSmithyDocumentSerde @@ -226,7 +227,7 @@ type MemberIdMemberUserId struct { func (*MemberIdMemberUserId) isMemberId() {} -// The name of the user. +// The full name of the user. type Name struct { // The family name of the user. @@ -253,7 +254,7 @@ type Name struct { // The phone number associated with the user. type PhoneNumber struct { - // A boolean representing whether this is the primary phone number for the + // A Boolean value representing whether this is the primary phone number for the // associated resource. Primary bool @@ -276,7 +277,8 @@ type UniqueAttribute struct { // This member is required. AttributePath *string - // The value of the attribute. + // The value of the attribute. This is a Document type. This type is not supported + // by Java V1, Go V1, and older versions of the AWS CLI. // // This member is required. AttributeValue document.Interface @@ -334,13 +336,13 @@ type User struct { Timezone *string // A string containing the user's title. Possible values depend on each customer's - // specific needs, so they are left unspecified + // specific needs, so they are left unspecified. Title *string - // The user’s user name value. The length limit is 128 characters. This value can - // consist of letters, accented characters, symbols, numbers, and punctuation. The - // characters <>;:% are excluded. This value is specified at the time the user is - // created and stored as an attribute of the user object in the identity store. + // A unique string used to identify the user. The length limit is 128 characters. + // This value can consist of letters, accented characters, symbols, numbers, and + // punctuation. This value is specified at the time the user is created and stored + // as an attribute of the user object in the identity store. UserName *string // A string indicating the user's type. Possible values depend on each customer's diff --git a/service/inspector2/deserializers.go b/service/inspector2/deserializers.go index a5d88ee778a..db60fc98e23 100644 --- a/service/inspector2/deserializers.go +++ b/service/inspector2/deserializers.go @@ -7774,6 +7774,11 @@ func awsRestjson1_deserializeDocumentFilterCriteria(v **types.FilterCriteria, va return err } + case "fixAvailable": + if err := awsRestjson1_deserializeDocumentStringFilterList(&sv.FixAvailable, value); err != nil { + return err + } + case "inspectorScore": if err := awsRestjson1_deserializeDocumentNumberFilterList(&sv.InspectorScore, value); err != nil { return err @@ -7957,6 +7962,15 @@ func awsRestjson1_deserializeDocumentFinding(v **types.Finding, value interface{ } } + case "fixAvailable": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected FixAvailable to be of type string, got %T instead", value) + } + sv.FixAvailable = types.FixAvailable(jtv) + } + case "inspectorScore": if value != nil { switch jtv := value.(type) { @@ -11269,6 +11283,15 @@ func awsRestjson1_deserializeDocumentVulnerablePackage(v **types.VulnerablePacka sv.Release = ptr.String(jtv) } + case "remediation": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected VulnerablePackageRemediation to be of type string, got %T instead", value) + } + sv.Remediation = ptr.String(jtv) + } + case "sourceLayerHash": if value != nil { jtv, ok := value.(string) diff --git a/service/inspector2/serializers.go b/service/inspector2/serializers.go index 944fc5bb5ea..4e8644512ed 100644 --- a/service/inspector2/serializers.go +++ b/service/inspector2/serializers.go @@ -2941,6 +2941,13 @@ func awsRestjson1_serializeDocumentFilterCriteria(v *types.FilterCriteria, value } } + if v.FixAvailable != nil { + ok := object.Key("fixAvailable") + if err := awsRestjson1_serializeDocumentStringFilterList(v.FixAvailable, ok); err != nil { + return err + } + } + if v.InspectorScore != nil { ok := object.Key("inspectorScore") if err := awsRestjson1_serializeDocumentNumberFilterList(v.InspectorScore, ok); err != nil { diff --git a/service/inspector2/types/enums.go b/service/inspector2/types/enums.go index a1f8f5ecf6f..4e4f2d39341 100644 --- a/service/inspector2/types/enums.go +++ b/service/inspector2/types/enums.go @@ -462,6 +462,26 @@ func (FindingTypeSortBy) Values() []FindingTypeSortBy { } } +type FixAvailable string + +// Enum values for FixAvailable +const ( + FixAvailableYes FixAvailable = "YES" + FixAvailableNo FixAvailable = "NO" + FixAvailablePartial FixAvailable = "PARTIAL" +) + +// Values returns all known values for FixAvailable. Note that this can be expanded +// in the future, and so it is only as up to date as the client. The ordering of +// this slice is not guaranteed to be stable across updates. +func (FixAvailable) Values() []FixAvailable { + return []FixAvailable{ + "YES", + "NO", + "PARTIAL", + } +} + type FreeTrialInfoErrorCode string // Enum values for FreeTrialInfoErrorCode @@ -860,6 +880,8 @@ const ( ScanStatusReasonScanFrequencyScanOnPush ScanStatusReason = "SCAN_FREQUENCY_SCAN_ON_PUSH" ScanStatusReasonEc2InstanceStopped ScanStatusReason = "EC2_INSTANCE_STOPPED" ScanStatusReasonPendingDisable ScanStatusReason = "PENDING_DISABLE" + ScanStatusReasonNoInventory ScanStatusReason = "NO_INVENTORY" + ScanStatusReasonStaleInventory ScanStatusReason = "STALE_INVENTORY" ) // Values returns all known values for ScanStatusReason. Note that this can be @@ -881,6 +903,8 @@ func (ScanStatusReason) Values() []ScanStatusReason { "SCAN_FREQUENCY_SCAN_ON_PUSH", "EC2_INSTANCE_STOPPED", "PENDING_DISABLE", + "NO_INVENTORY", + "STALE_INVENTORY", } } diff --git a/service/inspector2/types/types.go b/service/inspector2/types/types.go index c15675bff61..5e29bc0df02 100644 --- a/service/inspector2/types/types.go +++ b/service/inspector2/types/types.go @@ -989,6 +989,12 @@ type FilterCriteria struct { // Details on the date and time a finding was first seen used to filter findings. FirstObservedAt []DateFilter + // Details on whether a fix is available through a version update. This value can + // be YES, NO, or PARTIAL. A PARTIAL fix means that some, but not all, of the + // packages identified in the finding have fixes available through updated + // versions. + FixAvailable []StringFilter + // The Amazon Inspector score to filter on. InspectorScore []NumberFilter @@ -1091,6 +1097,12 @@ type Finding struct { // This member is required. Type FindingType + // Details on whether a fix is available through a version update. This value can + // be YES, NO, or PARTIAL. A PARTIAL fix means that some, but not all, of the + // packages identified in the finding have fixes available through updated + // versions. + FixAvailable FixAvailable + // The Amazon Inspector score given to the finding. InspectorScore *float64 @@ -1418,11 +1430,6 @@ type PackageVulnerabilityDetails struct { // This member is required. VulnerabilityId *string - // The packages impacted by this vulnerability. - // - // This member is required. - VulnerablePackages []VulnerablePackage - // An object that contains details about the CVSS score of a finding. Cvss []CvssScore @@ -1445,6 +1452,9 @@ type PackageVulnerabilityDetails struct { // The date and time the vendor last updated this vulnerability in their database. VendorUpdatedAt *time.Time + // The packages impacted by this vulnerability. + VulnerablePackages []VulnerablePackage + noSmithyDocumentSerde } @@ -1868,6 +1878,9 @@ type VulnerablePackage struct { // The release of the vulnerable package. Release *string + // The code to run in your environment to update packages with a fix available. + Remediation *string + // The source layer hash of the vulnerable package. SourceLayerHash *string diff --git a/service/inspector2/validators.go b/service/inspector2/validators.go index 60727d1ec6e..8115b7c9f9e 100644 --- a/service/inspector2/validators.go +++ b/service/inspector2/validators.go @@ -957,6 +957,11 @@ func validateFilterCriteria(v *types.FilterCriteria) error { invalidParams.AddNested("RelatedVulnerabilities", err.(smithy.InvalidParamsError)) } } + if v.FixAvailable != nil { + if err := validateStringFilterList(v.FixAvailable); err != nil { + invalidParams.AddNested("FixAvailable", err.(smithy.InvalidParamsError)) + } + } if invalidParams.Len() > 0 { return invalidParams } else { diff --git a/service/iotsitewise/api_op_CreateAsset.go b/service/iotsitewise/api_op_CreateAsset.go index efe3f528d99..720560b09eb 100644 --- a/service/iotsitewise/api_op_CreateAsset.go +++ b/service/iotsitewise/api_op_CreateAsset.go @@ -38,7 +38,7 @@ type CreateAssetInput struct { // This member is required. AssetModelId *string - // A unique, friendly name for the asset. + // A friendly name for the asset. // // This member is required. AssetName *string diff --git a/service/iotsitewise/api_op_CreateBulkImportJob.go b/service/iotsitewise/api_op_CreateBulkImportJob.go index 83ab9d36a45..354a99c82be 100644 --- a/service/iotsitewise/api_op_CreateBulkImportJob.go +++ b/service/iotsitewise/api_op_CreateBulkImportJob.go @@ -12,10 +12,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// This API operation is in preview release for IoT SiteWise and is subject to -// change. We recommend that you use this operation only with test data, and not in -// production environments. Defines a job to ingest data to IoT SiteWise from -// Amazon S3. For more information, see Create a bulk import job (CLI) +// Defines a job to ingest data to IoT SiteWise from Amazon S3. For more +// information, see Create a bulk import job (CLI) // (https://docs.aws.amazon.com/iot-sitewise/latest/userguide/CreateBulkImportJob.html) // in the Amazon Simple Storage Service User Guide. You must enable IoT SiteWise to // export data to Amazon S3 before you create a bulk import job. For more diff --git a/service/iotsitewise/api_op_DescribeBulkImportJob.go b/service/iotsitewise/api_op_DescribeBulkImportJob.go index b0e4b1f9cff..a94e847a673 100644 --- a/service/iotsitewise/api_op_DescribeBulkImportJob.go +++ b/service/iotsitewise/api_op_DescribeBulkImportJob.go @@ -13,10 +13,8 @@ import ( "time" ) -// This API operation is in preview release for IoT SiteWise and is subject to -// change. We recommend that you use this operation only with test data, and not in -// production environments. Retrieves information about a bulk import job request. -// For more information, see Describe a bulk import job (CLI) +// Retrieves information about a bulk import job request. For more information, see +// Describe a bulk import job (CLI) // (https://docs.aws.amazon.com/iot-sitewise/latest/userguide/DescribeBulkImportJob.html) // in the Amazon Simple Storage Service User Guide. func (c *Client) DescribeBulkImportJob(ctx context.Context, params *DescribeBulkImportJobInput, optFns ...func(*Options)) (*DescribeBulkImportJobOutput, error) { diff --git a/service/iotsitewise/api_op_ListBulkImportJobs.go b/service/iotsitewise/api_op_ListBulkImportJobs.go index 478c75b690f..8fe80fb376a 100644 --- a/service/iotsitewise/api_op_ListBulkImportJobs.go +++ b/service/iotsitewise/api_op_ListBulkImportJobs.go @@ -12,12 +12,10 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// This API operation is in preview release for IoT SiteWise and is subject to -// change. We recommend that you use this operation only with test data, and not in -// production environments. Retrieves a paginated list of bulk import job requests. -// For more information, see List bulk import jobs (CLI) +// Retrieves a paginated list of bulk import job requests. For more information, +// see List bulk import jobs (CLI) // (https://docs.aws.amazon.com/iot-sitewise/latest/userguide/ListBulkImportJobs.html) -// in the Amazon Simple Storage Service User Guide. +// in the IoT SiteWise User Guide. func (c *Client) ListBulkImportJobs(ctx context.Context, params *ListBulkImportJobsInput, optFns ...func(*Options)) (*ListBulkImportJobsOutput, error) { if params == nil { params = &ListBulkImportJobsInput{} diff --git a/service/iotsitewise/api_op_UpdateAsset.go b/service/iotsitewise/api_op_UpdateAsset.go index a2fa5077ef8..b22ec9e2ffa 100644 --- a/service/iotsitewise/api_op_UpdateAsset.go +++ b/service/iotsitewise/api_op_UpdateAsset.go @@ -37,7 +37,7 @@ type UpdateAssetInput struct { // This member is required. AssetId *string - // A unique, friendly name for the asset. + // A friendly name for the asset. // // This member is required. AssetName *string diff --git a/service/iotsitewise/api_op_UpdateAssetProperty.go b/service/iotsitewise/api_op_UpdateAssetProperty.go index 3c48249a8d9..a1d83dbf601 100644 --- a/service/iotsitewise/api_op_UpdateAssetProperty.go +++ b/service/iotsitewise/api_op_UpdateAssetProperty.go @@ -67,6 +67,11 @@ type UpdateAssetPropertyInput struct { // state is set to DISABLED. PropertyNotificationState types.PropertyNotificationState + // The unit of measure (such as Newtons or RPM) of the asset property. If you don't + // specify a value for this parameter, the service uses the value of the + // assetModelProperty in the asset model. + PropertyUnit *string + noSmithyDocumentSerde } diff --git a/service/iotsitewise/serializers.go b/service/iotsitewise/serializers.go index 660cf5b8154..4a17ccfccef 100644 --- a/service/iotsitewise/serializers.go +++ b/service/iotsitewise/serializers.go @@ -4866,6 +4866,11 @@ func awsRestjson1_serializeOpDocumentUpdateAssetPropertyInput(v *UpdateAssetProp ok.String(string(v.PropertyNotificationState)) } + if v.PropertyUnit != nil { + ok := object.Key("propertyUnit") + ok.String(*v.PropertyUnit) + } + return nil } diff --git a/service/kendra/types/enums.go b/service/kendra/types/enums.go index e04c61c045b..b164886ae2f 100644 --- a/service/kendra/types/enums.go +++ b/service/kendra/types/enums.go @@ -1114,6 +1114,7 @@ const ( SharePointVersionSharepoint2013 SharePointVersion = "SHAREPOINT_2013" SharePointVersionSharepoint2016 SharePointVersion = "SHAREPOINT_2016" SharePointVersionSharepointOnline SharePointVersion = "SHAREPOINT_ONLINE" + SharePointVersionSharepoint2019 SharePointVersion = "SHAREPOINT_2019" ) // Values returns all known values for SharePointVersion. Note that this can be @@ -1124,6 +1125,7 @@ func (SharePointVersion) Values() []SharePointVersion { "SHAREPOINT_2013", "SHAREPOINT_2016", "SHAREPOINT_ONLINE", + "SHAREPOINT_2019", } } diff --git a/service/kendra/types/types.go b/service/kendra/types/types.go index 0f2627b5746..a88db44d590 100644 --- a/service/kendra/types/types.go +++ b/service/kendra/types/types.go @@ -170,45 +170,46 @@ type AlfrescoConfiguration struct { noSmithyDocumentSerde } -// Provides filtering the query results based on document attributes. When you use -// the AndAllFilters or OrAllFilters, filters you can use 2 layers under the first -// attribute filter. For example, you can use: +// Provides filtering the query results based on document attributes or metadata +// fields. When you use the AndAllFilters or OrAllFilters, filters you can use 2 +// layers under the first attribute filter. For example, you can use: // -// If you use more than 2 layers, you -// receive a ValidationException exception with the message "AttributeFilter cannot -// have a depth of more than 2." If you use more than 10 attribute filters in a -// given list for AndAllFilters or OrAllFilters, you receive a ValidationException -// with the message "AttributeFilter cannot have a length of more than 10". +// If you use +// more than 2 layers, you receive a ValidationException exception with the message +// "AttributeFilter cannot have a depth of more than 2." If you use more than 10 +// attribute filters in a given list for AndAllFilters or OrAllFilters, you receive +// a ValidationException with the message "AttributeFilter cannot have a length of +// more than 10". type AttributeFilter struct { // Performs a logical AND operation on all supplied filters. AndAllFilters []AttributeFilter - // Returns true when a document contains all of the specified document attributes. - // This filter is only applicable to StringListValue metadata. + // Returns true when a document contains all of the specified document attributes + // or metadata fields. This filter is only applicable to StringListValue metadata. ContainsAll *DocumentAttribute - // Returns true when a document contains any of the specified document attributes. - // This filter is only applicable to StringListValue metadata. + // Returns true when a document contains any of the specified document attributes + // or metadata fields. This filter is only applicable to StringListValue metadata. ContainsAny *DocumentAttribute - // Performs an equals operation on two document attributes. + // Performs an equals operation on two document attributes or metadata fields. EqualsTo *DocumentAttribute - // Performs a greater than operation on two document attributes. Use with a - // document attribute of type Date or Long. + // Performs a greater than operation on two document attributes or metadata fields. + // Use with a document attribute of type Date or Long. GreaterThan *DocumentAttribute - // Performs a greater or equals than operation on two document attributes. Use with - // a document attribute of type Date or Long. + // Performs a greater or equals than operation on two document attributes or + // metadata fields. Use with a document attribute of type Date or Long. GreaterThanOrEquals *DocumentAttribute - // Performs a less than operation on two document attributes. Use with a document - // attribute of type Date or Long. + // Performs a less than operation on two document attributes or metadata fields. + // Use with a document attribute of type Date or Long. LessThan *DocumentAttribute - // Performs a less than or equals operation on two document attributes. Use with a - // document attribute of type Date or Long. + // Performs a less than or equals operation on two document attributes or metadata + // fields. Use with a document attribute of type Date or Long. LessThanOrEquals *DocumentAttribute // Performs a logical NOT operation on all supplied filters. diff --git a/service/lexmodelsv2/api_op_CreateSlot.go b/service/lexmodelsv2/api_op_CreateSlot.go index 20add86cb77..f4576520bae 100644 --- a/service/lexmodelsv2/api_op_CreateSlot.go +++ b/service/lexmodelsv2/api_op_CreateSlot.go @@ -88,6 +88,10 @@ type CreateSlotInput struct { // determines the values that can be entered into the slot. SlotTypeId *string + // Specifications for the constituent sub slots and the expression for the + // composite slot. + SubSlotSetting *types.SubSlotSetting + noSmithyDocumentSerde } @@ -128,6 +132,10 @@ type CreateSlotOutput struct { // The unique identifier of the slot type associated with this slot. SlotTypeId *string + // Specifications for the constituent sub slots and the expression for the + // composite slot. + SubSlotSetting *types.SubSlotSetting + // The value elicitation settings specified for the slot. ValueElicitationSetting *types.SlotValueElicitationSetting diff --git a/service/lexmodelsv2/api_op_CreateSlotType.go b/service/lexmodelsv2/api_op_CreateSlotType.go index aecb8debfb5..2d6da5d2c20 100644 --- a/service/lexmodelsv2/api_op_CreateSlotType.go +++ b/service/lexmodelsv2/api_op_CreateSlotType.go @@ -56,6 +56,9 @@ type CreateSlotTypeInput struct { // This member is required. SlotTypeName *string + // Specifications for a composite slot type. + CompositeSlotTypeSetting *types.CompositeSlotTypeSetting + // A description of the slot type. Use the description to help identify the slot // type in lists. Description *string @@ -99,6 +102,9 @@ type CreateSlotTypeOutput struct { // The version of the bot associated with the slot type. BotVersion *string + // Specifications for a composite slot type. + CompositeSlotTypeSetting *types.CompositeSlotTypeSetting + // A timestamp of the date and time that the slot type was created. CreationDateTime *time.Time diff --git a/service/lexmodelsv2/api_op_DescribeSlot.go b/service/lexmodelsv2/api_op_DescribeSlot.go index 6c471623528..b8191becb5a 100644 --- a/service/lexmodelsv2/api_op_DescribeSlot.go +++ b/service/lexmodelsv2/api_op_DescribeSlot.go @@ -101,6 +101,10 @@ type DescribeSlotOutput struct { // slot. SlotTypeId *string + // Specifications for the constituent sub slots and the expression for the + // composite slot. + SubSlotSetting *types.SubSlotSetting + // Prompts that Amazon Lex uses to elicit a value for the slot. ValueElicitationSetting *types.SlotValueElicitationSetting diff --git a/service/lexmodelsv2/api_op_DescribeSlotType.go b/service/lexmodelsv2/api_op_DescribeSlotType.go index 9a2cac1faa3..96a61eb12be 100644 --- a/service/lexmodelsv2/api_op_DescribeSlotType.go +++ b/service/lexmodelsv2/api_op_DescribeSlotType.go @@ -64,6 +64,9 @@ type DescribeSlotTypeOutput struct { // The version of the bot associated with the slot type. BotVersion *string + // Specifications for a composite slot type. + CompositeSlotTypeSetting *types.CompositeSlotTypeSetting + // A timestamp of the date and time that the slot type was created. CreationDateTime *time.Time diff --git a/service/lexmodelsv2/api_op_UpdateSlot.go b/service/lexmodelsv2/api_op_UpdateSlot.go index 49bae4e8686..1aa3019b6fd 100644 --- a/service/lexmodelsv2/api_op_UpdateSlot.go +++ b/service/lexmodelsv2/api_op_UpdateSlot.go @@ -84,6 +84,10 @@ type UpdateSlotInput struct { // The unique identifier of the new slot type to associate with this slot. SlotTypeId *string + // Specifications for the constituent sub slots and the expression for the + // composite slot. + SubSlotSetting *types.SubSlotSetting + noSmithyDocumentSerde } @@ -126,6 +130,10 @@ type UpdateSlotOutput struct { // The updated identifier of the slot type that provides values for the slot. SlotTypeId *string + // Specifications for the constituent sub slots and the expression for the + // composite slot. + SubSlotSetting *types.SubSlotSetting + // The updated prompts that Amazon Lex sends to the user to elicit a response that // provides a value for the slot. ValueElicitationSetting *types.SlotValueElicitationSetting diff --git a/service/lexmodelsv2/api_op_UpdateSlotType.go b/service/lexmodelsv2/api_op_UpdateSlotType.go index 57731db0f86..15249a29f41 100644 --- a/service/lexmodelsv2/api_op_UpdateSlotType.go +++ b/service/lexmodelsv2/api_op_UpdateSlotType.go @@ -58,6 +58,9 @@ type UpdateSlotTypeInput struct { // This member is required. SlotTypeName *string + // Specifications for a composite slot type. + CompositeSlotTypeSetting *types.CompositeSlotTypeSetting + // The new description of the slot type. Description *string @@ -86,6 +89,9 @@ type UpdateSlotTypeOutput struct { // The version of the bot that contains the slot type. This is always DRAFT. BotVersion *string + // Specifications for a composite slot type. + CompositeSlotTypeSetting *types.CompositeSlotTypeSetting + // The timestamp of the date and time that the slot type was created. CreationDateTime *time.Time diff --git a/service/lexmodelsv2/deserializers.go b/service/lexmodelsv2/deserializers.go index a8322d6af41..6452f342bea 100644 --- a/service/lexmodelsv2/deserializers.go +++ b/service/lexmodelsv2/deserializers.go @@ -2289,6 +2289,11 @@ func awsRestjson1_deserializeOpDocumentCreateSlotOutput(v **CreateSlotOutput, va sv.SlotTypeId = ptr.String(jtv) } + case "subSlotSetting": + if err := awsRestjson1_deserializeDocumentSubSlotSetting(&sv.SubSlotSetting, value); err != nil { + return err + } + case "valueElicitationSetting": if err := awsRestjson1_deserializeDocumentSlotValueElicitationSetting(&sv.ValueElicitationSetting, value); err != nil { return err @@ -2469,6 +2474,11 @@ func awsRestjson1_deserializeOpDocumentCreateSlotTypeOutput(v **CreateSlotTypeOu sv.BotVersion = ptr.String(jtv) } + case "compositeSlotTypeSetting": + if err := awsRestjson1_deserializeDocumentCompositeSlotTypeSetting(&sv.CompositeSlotTypeSetting, value); err != nil { + return err + } + case "creationDateTime": if value != nil { switch jtv := value.(type) { @@ -7500,6 +7510,11 @@ func awsRestjson1_deserializeOpDocumentDescribeSlotOutput(v **DescribeSlotOutput sv.SlotTypeId = ptr.String(jtv) } + case "subSlotSetting": + if err := awsRestjson1_deserializeDocumentSubSlotSetting(&sv.SubSlotSetting, value); err != nil { + return err + } + case "valueElicitationSetting": if err := awsRestjson1_deserializeDocumentSlotValueElicitationSetting(&sv.ValueElicitationSetting, value); err != nil { return err @@ -7677,6 +7692,11 @@ func awsRestjson1_deserializeOpDocumentDescribeSlotTypeOutput(v **DescribeSlotTy sv.BotVersion = ptr.String(jtv) } + case "compositeSlotTypeSetting": + if err := awsRestjson1_deserializeDocumentCompositeSlotTypeSetting(&sv.CompositeSlotTypeSetting, value); err != nil { + return err + } + case "creationDateTime": if value != nil { switch jtv := value.(type) { @@ -13646,6 +13666,11 @@ func awsRestjson1_deserializeOpDocumentUpdateSlotOutput(v **UpdateSlotOutput, va sv.SlotTypeId = ptr.String(jtv) } + case "subSlotSetting": + if err := awsRestjson1_deserializeDocumentSubSlotSetting(&sv.SubSlotSetting, value); err != nil { + return err + } + case "valueElicitationSetting": if err := awsRestjson1_deserializeDocumentSlotValueElicitationSetting(&sv.ValueElicitationSetting, value); err != nil { return err @@ -13826,6 +13851,11 @@ func awsRestjson1_deserializeOpDocumentUpdateSlotTypeOutput(v **UpdateSlotTypeOu sv.BotVersion = ptr.String(jtv) } + case "compositeSlotTypeSetting": + if err := awsRestjson1_deserializeDocumentCompositeSlotTypeSetting(&sv.CompositeSlotTypeSetting, value); err != nil { + return err + } + case "creationDateTime": if value != nil { switch jtv := value.(type) { @@ -16263,6 +16293,42 @@ func awsRestjson1_deserializeDocumentCodeHookSpecification(v **types.CodeHookSpe return nil } +func awsRestjson1_deserializeDocumentCompositeSlotTypeSetting(v **types.CompositeSlotTypeSetting, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.CompositeSlotTypeSetting + if *v == nil { + sv = &types.CompositeSlotTypeSetting{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "subSlots": + if err := awsRestjson1_deserializeDocumentSubSlotTypeList(&sv.SubSlots, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentCondition(v **types.Condition, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -20914,6 +20980,51 @@ func awsRestjson1_deserializeDocumentSlotValueSelectionSetting(v **types.SlotVal return nil } +func awsRestjson1_deserializeDocumentSpecifications(v **types.Specifications, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.Specifications + if *v == nil { + sv = &types.Specifications{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "slotTypeId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected BuiltInOrCustomSlotTypeId to be of type string, got %T instead", value) + } + sv.SlotTypeId = ptr.String(jtv) + } + + case "valueElicitationSetting": + if err := awsRestjson1_deserializeDocumentSubSlotValueElicitationSetting(&sv.ValueElicitationSetting, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentSSMLMessage(v **types.SSMLMessage, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -21061,6 +21172,220 @@ func awsRestjson1_deserializeDocumentStringMap(v *map[string]string, value inter return nil } +func awsRestjson1_deserializeDocumentSubSlotSetting(v **types.SubSlotSetting, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.SubSlotSetting + if *v == nil { + sv = &types.SubSlotSetting{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "expression": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected SubSlotExpression to be of type string, got %T instead", value) + } + sv.Expression = ptr.String(jtv) + } + + case "slotSpecifications": + if err := awsRestjson1_deserializeDocumentSubSlotSpecificationMap(&sv.SlotSpecifications, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentSubSlotSpecificationMap(v *map[string]types.Specifications, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var mv map[string]types.Specifications + if *v == nil { + mv = map[string]types.Specifications{} + } else { + mv = *v + } + + for key, value := range shape { + var parsedVal types.Specifications + mapVar := parsedVal + destAddr := &mapVar + if err := awsRestjson1_deserializeDocumentSpecifications(&destAddr, value); err != nil { + return err + } + parsedVal = *destAddr + mv[key] = parsedVal + + } + *v = mv + return nil +} + +func awsRestjson1_deserializeDocumentSubSlotTypeComposition(v **types.SubSlotTypeComposition, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.SubSlotTypeComposition + if *v == nil { + sv = &types.SubSlotTypeComposition{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "name": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Name to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) + } + + case "slotTypeId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected BuiltInOrCustomSlotTypeId to be of type string, got %T instead", value) + } + sv.SlotTypeId = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentSubSlotTypeList(v *[]types.SubSlotTypeComposition, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.SubSlotTypeComposition + if *v == nil { + cv = []types.SubSlotTypeComposition{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.SubSlotTypeComposition + destAddr := &col + if err := awsRestjson1_deserializeDocumentSubSlotTypeComposition(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsRestjson1_deserializeDocumentSubSlotValueElicitationSetting(v **types.SubSlotValueElicitationSetting, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.SubSlotValueElicitationSetting + if *v == nil { + sv = &types.SubSlotValueElicitationSetting{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "defaultValueSpecification": + if err := awsRestjson1_deserializeDocumentSlotDefaultValueSpecification(&sv.DefaultValueSpecification, value); err != nil { + return err + } + + case "promptSpecification": + if err := awsRestjson1_deserializeDocumentPromptSpecification(&sv.PromptSpecification, value); err != nil { + return err + } + + case "sampleUtterances": + if err := awsRestjson1_deserializeDocumentSampleUtterancesList(&sv.SampleUtterances, value); err != nil { + return err + } + + case "waitAndContinueSpecification": + if err := awsRestjson1_deserializeDocumentWaitAndContinueSpecification(&sv.WaitAndContinueSpecification, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentSynonymList(v *[]types.SampleValue, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/lexmodelsv2/serializers.go b/service/lexmodelsv2/serializers.go index 8539f560d53..21f688b3bb5 100644 --- a/service/lexmodelsv2/serializers.go +++ b/service/lexmodelsv2/serializers.go @@ -1096,6 +1096,13 @@ func awsRestjson1_serializeOpDocumentCreateSlotInput(v *CreateSlotInput, value s ok.String(*v.SlotTypeId) } + if v.SubSlotSetting != nil { + ok := object.Key("subSlotSetting") + if err := awsRestjson1_serializeDocumentSubSlotSetting(v.SubSlotSetting, ok); err != nil { + return err + } + } + if v.ValueElicitationSetting != nil { ok := object.Key("valueElicitationSetting") if err := awsRestjson1_serializeDocumentSlotValueElicitationSetting(v.ValueElicitationSetting, ok); err != nil { @@ -1197,6 +1204,13 @@ func awsRestjson1_serializeOpDocumentCreateSlotTypeInput(v *CreateSlotTypeInput, object := value.Object() defer object.Close() + if v.CompositeSlotTypeSetting != nil { + ok := object.Key("compositeSlotTypeSetting") + if err := awsRestjson1_serializeDocumentCompositeSlotTypeSetting(v.CompositeSlotTypeSetting, ok); err != nil { + return err + } + } + if v.Description != nil { ok := object.Key("description") ok.String(*v.Description) @@ -6112,6 +6126,13 @@ func awsRestjson1_serializeOpDocumentUpdateSlotInput(v *UpdateSlotInput, value s ok.String(*v.SlotTypeId) } + if v.SubSlotSetting != nil { + ok := object.Key("subSlotSetting") + if err := awsRestjson1_serializeDocumentSubSlotSetting(v.SubSlotSetting, ok); err != nil { + return err + } + } + if v.ValueElicitationSetting != nil { ok := object.Key("valueElicitationSetting") if err := awsRestjson1_serializeDocumentSlotValueElicitationSetting(v.ValueElicitationSetting, ok); err != nil { @@ -6222,6 +6243,13 @@ func awsRestjson1_serializeOpDocumentUpdateSlotTypeInput(v *UpdateSlotTypeInput, object := value.Object() defer object.Close() + if v.CompositeSlotTypeSetting != nil { + ok := object.Key("compositeSlotTypeSetting") + if err := awsRestjson1_serializeDocumentCompositeSlotTypeSetting(v.CompositeSlotTypeSetting, ok); err != nil { + return err + } + } + if v.Description != nil { ok := object.Key("description") ok.String(*v.Description) @@ -6813,6 +6841,20 @@ func awsRestjson1_serializeDocumentCodeHookSpecification(v *types.CodeHookSpecif return nil } +func awsRestjson1_serializeDocumentCompositeSlotTypeSetting(v *types.CompositeSlotTypeSetting, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.SubSlots != nil { + ok := object.Key("subSlots") + if err := awsRestjson1_serializeDocumentSubSlotTypeList(v.SubSlots, ok); err != nil { + return err + } + } + + return nil +} + func awsRestjson1_serializeDocumentCondition(v *types.Condition, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -8815,6 +8857,25 @@ func awsRestjson1_serializeDocumentSlotValueSelectionSetting(v *types.SlotValueS return nil } +func awsRestjson1_serializeDocumentSpecifications(v *types.Specifications, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.SlotTypeId != nil { + ok := object.Key("slotTypeId") + ok.String(*v.SlotTypeId) + } + + if v.ValueElicitationSetting != nil { + ok := object.Key("valueElicitationSetting") + if err := awsRestjson1_serializeDocumentSubSlotValueElicitationSetting(v.ValueElicitationSetting, ok); err != nil { + return err + } + } + + return nil +} + func awsRestjson1_serializeDocumentSSMLMessage(v *types.SSMLMessage, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -8867,6 +8928,104 @@ func awsRestjson1_serializeDocumentStringMap(v map[string]string, value smithyjs return nil } +func awsRestjson1_serializeDocumentSubSlotSetting(v *types.SubSlotSetting, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Expression != nil { + ok := object.Key("expression") + ok.String(*v.Expression) + } + + if v.SlotSpecifications != nil { + ok := object.Key("slotSpecifications") + if err := awsRestjson1_serializeDocumentSubSlotSpecificationMap(v.SlotSpecifications, ok); err != nil { + return err + } + } + + return nil +} + +func awsRestjson1_serializeDocumentSubSlotSpecificationMap(v map[string]types.Specifications, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + for key := range v { + om := object.Key(key) + mapVar := v[key] + if err := awsRestjson1_serializeDocumentSpecifications(&mapVar, om); err != nil { + return err + } + } + return nil +} + +func awsRestjson1_serializeDocumentSubSlotTypeComposition(v *types.SubSlotTypeComposition, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Name != nil { + ok := object.Key("name") + ok.String(*v.Name) + } + + if v.SlotTypeId != nil { + ok := object.Key("slotTypeId") + ok.String(*v.SlotTypeId) + } + + return nil +} + +func awsRestjson1_serializeDocumentSubSlotTypeList(v []types.SubSlotTypeComposition, value smithyjson.Value) error { + array := value.Array() + defer array.Close() + + for i := range v { + av := array.Value() + if err := awsRestjson1_serializeDocumentSubSlotTypeComposition(&v[i], av); err != nil { + return err + } + } + return nil +} + +func awsRestjson1_serializeDocumentSubSlotValueElicitationSetting(v *types.SubSlotValueElicitationSetting, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.DefaultValueSpecification != nil { + ok := object.Key("defaultValueSpecification") + if err := awsRestjson1_serializeDocumentSlotDefaultValueSpecification(v.DefaultValueSpecification, ok); err != nil { + return err + } + } + + if v.PromptSpecification != nil { + ok := object.Key("promptSpecification") + if err := awsRestjson1_serializeDocumentPromptSpecification(v.PromptSpecification, ok); err != nil { + return err + } + } + + if v.SampleUtterances != nil { + ok := object.Key("sampleUtterances") + if err := awsRestjson1_serializeDocumentSampleUtterancesList(v.SampleUtterances, ok); err != nil { + return err + } + } + + if v.WaitAndContinueSpecification != nil { + ok := object.Key("waitAndContinueSpecification") + if err := awsRestjson1_serializeDocumentWaitAndContinueSpecification(v.WaitAndContinueSpecification, ok); err != nil { + return err + } + } + + return nil +} + func awsRestjson1_serializeDocumentSynonymList(v []types.SampleValue, value smithyjson.Value) error { array := value.Array() defer array.Close() diff --git a/service/lexmodelsv2/types/enums.go b/service/lexmodelsv2/types/enums.go index 2ec5903c9e0..a434e679934 100644 --- a/service/lexmodelsv2/types/enums.go +++ b/service/lexmodelsv2/types/enums.go @@ -831,6 +831,7 @@ const ( SlotTypeCategoryCustom SlotTypeCategory = "Custom" SlotTypeCategoryExtended SlotTypeCategory = "Extended" SlotTypeCategoryExternalGrammar SlotTypeCategory = "ExternalGrammar" + SlotTypeCategoryComposite SlotTypeCategory = "Composite" ) // Values returns all known values for SlotTypeCategory. Note that this can be @@ -841,6 +842,7 @@ func (SlotTypeCategory) Values() []SlotTypeCategory { "Custom", "Extended", "ExternalGrammar", + "Composite", } } @@ -904,6 +906,7 @@ type SlotValueResolutionStrategy string const ( SlotValueResolutionStrategyOriginalValue SlotValueResolutionStrategy = "OriginalValue" SlotValueResolutionStrategyTopResolution SlotValueResolutionStrategy = "TopResolution" + SlotValueResolutionStrategyConcatenation SlotValueResolutionStrategy = "Concatenation" ) // Values returns all known values for SlotValueResolutionStrategy. Note that this @@ -913,6 +916,7 @@ func (SlotValueResolutionStrategy) Values() []SlotValueResolutionStrategy { return []SlotValueResolutionStrategy{ "OriginalValue", "TopResolution", + "Concatenation", } } diff --git a/service/lexmodelsv2/types/types.go b/service/lexmodelsv2/types/types.go index 6a22c1ed8bd..1bc4faabeaf 100644 --- a/service/lexmodelsv2/types/types.go +++ b/service/lexmodelsv2/types/types.go @@ -712,6 +712,16 @@ type CodeHookSpecification struct { noSmithyDocumentSerde } +// A composite slot is a combination of two or more slots that capture multiple +// pieces of information in a single user input. +type CompositeSlotTypeSetting struct { + + // Subslots in the composite slot. + SubSlots []SubSlotTypeComposition + + noSmithyDocumentSerde +} + // Provides an expression that evaluates to true or false. type Condition struct { @@ -2292,7 +2302,8 @@ type SlotValue struct { noSmithyDocumentSerde } -// Settings that you can use for eliciting a slot value. +// Specifies the elicitation setting details for constituent sub slots of a +// composite slot. type SlotValueElicitationSetting struct { // Specifies whether the slot is required or optional. @@ -2400,6 +2411,23 @@ type SlotValueSelectionSetting struct { noSmithyDocumentSerde } +// Subslot specifications. +type Specifications struct { + + // The unique identifier assigned to the slot type. + // + // This member is required. + SlotTypeId *string + + // Specifies the elicitation setting details for constituent sub slots of a + // composite slot. + // + // This member is required. + ValueElicitationSetting *SubSlotValueElicitationSetting + + noSmithyDocumentSerde +} + // Defines a Speech Synthesis Markup Language (SSML) prompt. type SSMLMessage struct { @@ -2440,6 +2468,69 @@ type StillWaitingResponseSpecification struct { noSmithyDocumentSerde } +// Specifications for the constituent sub slots and the expression for the +// composite slot. +type SubSlotSetting struct { + + // The expression text for defining the constituent sub slots in the composite slot + // using logical AND and OR operators. + Expression *string + + // Specifications for the constituent sub slots of a composite slot. + SlotSpecifications map[string]Specifications + + noSmithyDocumentSerde +} + +// Subslot type composition. +type SubSlotTypeComposition struct { + + // Name of a constituent sub slot inside a composite slot. + // + // This member is required. + Name *string + + // The unique identifier assigned to a slot type. This refers to either a built-in + // slot type or the unique slotTypeId of a custom slot type. + // + // This member is required. + SlotTypeId *string + + noSmithyDocumentSerde +} + +// Subslot elicitation settings. DefaultValueSpecification is a list of default +// values for a constituent sub slot in a composite slot. Default values are used +// when Amazon Lex hasn't determined a value for a slot. You can specify default +// values from context variables, session attributes, and defined values. This is +// similar to DefaultValueSpecification for slots. PromptSpecification is the +// prompt that Amazon Lex uses to elicit the sub slot value from the user. This is +// similar to PromptSpecification for slots. +type SubSlotValueElicitationSetting struct { + + // Specifies a list of message groups that Amazon Lex sends to a user to elicit a + // response. + // + // This member is required. + PromptSpecification *PromptSpecification + + // Defines a list of values that Amazon Lex should use as the default value for a + // slot. + DefaultValueSpecification *SlotDefaultValueSpecification + + // If you know a specific pattern that users might respond to an Amazon Lex request + // for a sub slot value, you can provide those utterances to improve accuracy. This + // is optional. In most cases Amazon Lex is capable of understanding user + // utterances. This is similar to SampleUtterances for slots. + SampleUtterances []SampleUtterance + + // Specifies the prompts that Amazon Lex uses while a bot is waiting for customer + // input. + WaitAndContinueSpecification *WaitAndContinueSpecification + + noSmithyDocumentSerde +} + // Defines the Amazon CloudWatch Logs destination log group for conversation text // logs. type TextLogDestination struct { diff --git a/service/lexmodelsv2/validators.go b/service/lexmodelsv2/validators.go index 2a0ab628884..33824222887 100644 --- a/service/lexmodelsv2/validators.go +++ b/service/lexmodelsv2/validators.go @@ -2136,6 +2136,23 @@ func validateCodeHookSpecification(v *types.CodeHookSpecification) error { } } +func validateCompositeSlotTypeSetting(v *types.CompositeSlotTypeSetting) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "CompositeSlotTypeSetting"} + if v.SubSlots != nil { + if err := validateSubSlotTypeList(v.SubSlots); err != nil { + invalidParams.AddNested("SubSlots", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateCondition(v *types.Condition) error { if v == nil { return nil @@ -3838,6 +3855,28 @@ func validateSlotValueSelectionSetting(v *types.SlotValueSelectionSetting) error } } +func validateSpecifications(v *types.Specifications) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "Specifications"} + if v.SlotTypeId == nil { + invalidParams.Add(smithy.NewErrParamRequired("SlotTypeId")) + } + if v.ValueElicitationSetting == nil { + invalidParams.Add(smithy.NewErrParamRequired("ValueElicitationSetting")) + } else if v.ValueElicitationSetting != nil { + if err := validateSubSlotValueElicitationSetting(v.ValueElicitationSetting); err != nil { + invalidParams.AddNested("ValueElicitationSetting", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateSSMLMessage(v *types.SSMLMessage) error { if v == nil { return nil @@ -3878,6 +3917,110 @@ func validateStillWaitingResponseSpecification(v *types.StillWaitingResponseSpec } } +func validateSubSlotSetting(v *types.SubSlotSetting) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "SubSlotSetting"} + if v.SlotSpecifications != nil { + if err := validateSubSlotSpecificationMap(v.SlotSpecifications); err != nil { + invalidParams.AddNested("SlotSpecifications", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateSubSlotSpecificationMap(v map[string]types.Specifications) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "SubSlotSpecificationMap"} + for key := range v { + value := v[key] + if err := validateSpecifications(&value); err != nil { + invalidParams.AddNested(fmt.Sprintf("[%q]", key), err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateSubSlotTypeComposition(v *types.SubSlotTypeComposition) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "SubSlotTypeComposition"} + if v.Name == nil { + invalidParams.Add(smithy.NewErrParamRequired("Name")) + } + if v.SlotTypeId == nil { + invalidParams.Add(smithy.NewErrParamRequired("SlotTypeId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateSubSlotTypeList(v []types.SubSlotTypeComposition) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "SubSlotTypeList"} + for i := range v { + if err := validateSubSlotTypeComposition(&v[i]); err != nil { + invalidParams.AddNested(fmt.Sprintf("[%d]", i), err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateSubSlotValueElicitationSetting(v *types.SubSlotValueElicitationSetting) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "SubSlotValueElicitationSetting"} + if v.DefaultValueSpecification != nil { + if err := validateSlotDefaultValueSpecification(v.DefaultValueSpecification); err != nil { + invalidParams.AddNested("DefaultValueSpecification", err.(smithy.InvalidParamsError)) + } + } + if v.PromptSpecification == nil { + invalidParams.Add(smithy.NewErrParamRequired("PromptSpecification")) + } else if v.PromptSpecification != nil { + if err := validatePromptSpecification(v.PromptSpecification); err != nil { + invalidParams.AddNested("PromptSpecification", err.(smithy.InvalidParamsError)) + } + } + if v.SampleUtterances != nil { + if err := validateSampleUtterancesList(v.SampleUtterances); err != nil { + invalidParams.AddNested("SampleUtterances", err.(smithy.InvalidParamsError)) + } + } + if v.WaitAndContinueSpecification != nil { + if err := validateWaitAndContinueSpecification(v.WaitAndContinueSpecification); err != nil { + invalidParams.AddNested("WaitAndContinueSpecification", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateSynonymList(v []types.SampleValue) error { if v == nil { return nil @@ -4350,6 +4493,11 @@ func validateOpCreateSlotInput(v *CreateSlotInput) error { if v.IntentId == nil { invalidParams.Add(smithy.NewErrParamRequired("IntentId")) } + if v.SubSlotSetting != nil { + if err := validateSubSlotSetting(v.SubSlotSetting); err != nil { + invalidParams.AddNested("SubSlotSetting", err.(smithy.InvalidParamsError)) + } + } if invalidParams.Len() > 0 { return invalidParams } else { @@ -4389,6 +4537,11 @@ func validateOpCreateSlotTypeInput(v *CreateSlotTypeInput) error { invalidParams.AddNested("ExternalSourceSetting", err.(smithy.InvalidParamsError)) } } + if v.CompositeSlotTypeSetting != nil { + if err := validateCompositeSlotTypeSetting(v.CompositeSlotTypeSetting); err != nil { + invalidParams.AddNested("CompositeSlotTypeSetting", err.(smithy.InvalidParamsError)) + } + } if invalidParams.Len() > 0 { return invalidParams } else { @@ -5651,6 +5804,11 @@ func validateOpUpdateSlotInput(v *UpdateSlotInput) error { if v.IntentId == nil { invalidParams.Add(smithy.NewErrParamRequired("IntentId")) } + if v.SubSlotSetting != nil { + if err := validateSubSlotSetting(v.SubSlotSetting); err != nil { + invalidParams.AddNested("SubSlotSetting", err.(smithy.InvalidParamsError)) + } + } if invalidParams.Len() > 0 { return invalidParams } else { @@ -5693,6 +5851,11 @@ func validateOpUpdateSlotTypeInput(v *UpdateSlotTypeInput) error { invalidParams.AddNested("ExternalSourceSetting", err.(smithy.InvalidParamsError)) } } + if v.CompositeSlotTypeSetting != nil { + if err := validateCompositeSlotTypeSetting(v.CompositeSlotTypeSetting); err != nil { + invalidParams.AddNested("CompositeSlotTypeSetting", err.(smithy.InvalidParamsError)) + } + } if invalidParams.Len() > 0 { return invalidParams } else { diff --git a/service/lexruntimev2/deserializers.go b/service/lexruntimev2/deserializers.go index ff1406708df..390abda20dd 100644 --- a/service/lexruntimev2/deserializers.go +++ b/service/lexruntimev2/deserializers.go @@ -2229,6 +2229,11 @@ func awsRestjson1_deserializeDocumentDialogAction(v **types.DialogAction, value sv.SlotToElicit = ptr.String(jtv) } + case "subSlotToElicit": + if err := awsRestjson1_deserializeDocumentElicitSubSlot(&sv.SubSlotToElicit, value); err != nil { + return err + } + case "type": if value != nil { jtv, ok := value.(string) @@ -2247,6 +2252,51 @@ func awsRestjson1_deserializeDocumentDialogAction(v **types.DialogAction, value return nil } +func awsRestjson1_deserializeDocumentElicitSubSlot(v **types.ElicitSubSlot, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ElicitSubSlot + if *v == nil { + sv = &types.ElicitSubSlot{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "name": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected NonEmptyString to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) + } + + case "subSlotToElicit": + if err := awsRestjson1_deserializeDocumentElicitSubSlot(&sv.SubSlotToElicit, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentHeartbeatEvent(v **types.HeartbeatEvent, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -2819,6 +2869,11 @@ func awsRestjson1_deserializeDocumentRuntimeHintDetails(v **types.RuntimeHintDet return err } + case "subSlotHints": + if err := awsRestjson1_deserializeDocumentSlotHintsSlotMap(&sv.SubSlotHints, value); err != nil { + return err + } + default: _, _ = key, value @@ -3246,6 +3301,11 @@ func awsRestjson1_deserializeDocumentSlot(v **types.Slot, value interface{}) err sv.Shape = types.Shape(jtv) } + case "subSlots": + if err := awsRestjson1_deserializeDocumentSlots(&sv.SubSlots, value); err != nil { + return err + } + case "value": if err := awsRestjson1_deserializeDocumentValue(&sv.Value, value); err != nil { return err diff --git a/service/lexruntimev2/serializers.go b/service/lexruntimev2/serializers.go index e8acb0b3d80..ac6aefa611a 100644 --- a/service/lexruntimev2/serializers.go +++ b/service/lexruntimev2/serializers.go @@ -957,6 +957,13 @@ func awsRestjson1_serializeDocumentDialogAction(v *types.DialogAction, value smi ok.String(*v.SlotToElicit) } + if v.SubSlotToElicit != nil { + ok := object.Key("subSlotToElicit") + if err := awsRestjson1_serializeDocumentElicitSubSlot(v.SubSlotToElicit, ok); err != nil { + return err + } + } + if len(v.Type) > 0 { ok := object.Key("type") ok.String(string(v.Type)) @@ -1004,6 +1011,25 @@ func awsRestjson1_serializeDocumentDTMFInputEvent(v *types.DTMFInputEvent, value return nil } +func awsRestjson1_serializeDocumentElicitSubSlot(v *types.ElicitSubSlot, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Name != nil { + ok := object.Key("name") + ok.String(*v.Name) + } + + if v.SubSlotToElicit != nil { + ok := object.Key("subSlotToElicit") + if err := awsRestjson1_serializeDocumentElicitSubSlot(v.SubSlotToElicit, ok); err != nil { + return err + } + } + + return nil +} + func awsRestjson1_serializeDocumentImageResponseCard(v *types.ImageResponseCard, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -1127,6 +1153,13 @@ func awsRestjson1_serializeDocumentRuntimeHintDetails(v *types.RuntimeHintDetail } } + if v.SubSlotHints != nil { + ok := object.Key("subSlotHints") + if err := awsRestjson1_serializeDocumentSlotHintsSlotMap(v.SubSlotHints, ok); err != nil { + return err + } + } + return nil } @@ -1225,6 +1258,13 @@ func awsRestjson1_serializeDocumentSlot(v *types.Slot, value smithyjson.Value) e ok.String(string(v.Shape)) } + if v.SubSlots != nil { + ok := object.Key("subSlots") + if err := awsRestjson1_serializeDocumentSlots(v.SubSlots, ok); err != nil { + return err + } + } + if v.Value != nil { ok := object.Key("value") if err := awsRestjson1_serializeDocumentValue(v.Value, ok); err != nil { diff --git a/service/lexruntimev2/types/enums.go b/service/lexruntimev2/types/enums.go index ad24a2d9e58..b62dbecd1c3 100644 --- a/service/lexruntimev2/types/enums.go +++ b/service/lexruntimev2/types/enums.go @@ -180,8 +180,9 @@ type Shape string // Enum values for Shape const ( - ShapeScalar Shape = "Scalar" - ShapeList Shape = "List" + ShapeScalar Shape = "Scalar" + ShapeList Shape = "List" + ShapeComposite Shape = "Composite" ) // Values returns all known values for Shape. Note that this can be expanded in the @@ -191,6 +192,7 @@ func (Shape) Values() []Shape { return []Shape{ "Scalar", "List", + "Composite", } } diff --git a/service/lexruntimev2/types/types.go b/service/lexruntimev2/types/types.go index 9138d453642..82cb3f5620f 100644 --- a/service/lexruntimev2/types/types.go +++ b/service/lexruntimev2/types/types.go @@ -191,7 +191,12 @@ type ConfigurationEvent struct { // The state of the user's session with Amazon Lex V2. SessionState *SessionState - // A list of messages to send to the user. + // A list of messages to send to the user. If you set the welcomeMessage field, you + // must also set the DialogAction + // (https://docs.aws.amazon.com/lexv2/latest/dg/API_runtime_DialogAction.html) + // structure's type + // (https://docs.aws.amazon.com/lexv2/latest/dg/API_runtime_DialogAction.html#lexv2-Type-runtime_DialogAction-type) + // field. WelcomeMessages []Message noSmithyDocumentSerde @@ -214,7 +219,10 @@ type DialogAction struct { // * Delegate - The next action is determined by Amazon Lex // V2. // - // * ElicitSlot - The next action is to elicit a slot value from the user. + // * ElicitIntent - The next action is to elicit an intent from the user. + // + // * + // ElicitSlot - The next action is to elicit a slot value from the user. // // This member is required. Type DialogActionType @@ -235,6 +243,10 @@ type DialogAction struct { // The name of the slot that should be elicited from the user. SlotToElicit *string + // The name of the constituent sub slot of the composite slot specified in + // slotToElicit that should be elicited from the user. + SubSlotToElicit *ElicitSubSlot + noSmithyDocumentSerde } @@ -276,6 +288,21 @@ type DTMFInputEvent struct { noSmithyDocumentSerde } +// The specific constituent sub slot of the composite slot to elicit in dialog +// action. +type ElicitSubSlot struct { + + // The name of the slot that should be elicited from the user. + // + // This member is required. + Name *string + + // The field is not supported. + SubSlotToElicit *ElicitSubSlot + + noSmithyDocumentSerde +} + // Event that Amazon Lex V2 sends to indicate that the stream is still open between // the client application and Amazon Lex V2 type HeartbeatEvent struct { @@ -455,10 +482,15 @@ type RuntimeHintDetails struct { // One or more strings that Amazon Lex V2 should look for in the input to the bot. // Each phrase is given preference when deciding on slot values. - // - // This member is required. RuntimeHintValues []RuntimeHintValue + // A map of constituent sub slot names inside a composite slot in the intent and + // the phrases that should be added for each sub slot. Inside each composite slot + // hints, this structure provides a mechanism to add granular sub slot phrases. + // Only sub slot hints are supported for composite slots. The intent name, + // composite slot name and the constituent sub slot names must exist. + SubSlotHints map[string]RuntimeHintDetails + noSmithyDocumentSerde } @@ -467,15 +499,15 @@ type RuntimeHintDetails struct { // runtime hints are preferred in the resolution. You can provide hints for a // maximum of 100 intents. You can provide a maximum of 100 slots. Before you can // use runtime hints with an existing bot, you must first rebuild the bot. For more -// information, see Using hints to improve accuracy -// (https://docs.aws.amazon.com/lexv2/latest/dg/using-hints.xml). +// information, see Using runtime hints to improve recognition of slot values +// (https://docs.aws.amazon.com/lexv2/latest/dg/using-hints.html). type RuntimeHints struct { // A list of the slots in the intent that should have runtime hints added, and the // phrases that should be added for each slot. The first level of the slotHints map // is the name of the intent. The second level is the name of the slot within the // intent. For more information, see Using hints to improve accuracy - // (https://docs.aws.amazon.com/lexv2/latest/dg/using-hints.xml). The intent name + // (https://docs.aws.amazon.com/lexv2/latest/dg/using-hints.html). The intent name // and slot name must exist. SlotHints map[string]map[string]RuntimeHintDetails @@ -571,6 +603,9 @@ type Slot struct { // contains a single value. Shape Shape + // The constituent sub slots of a composite slot. + SubSlots map[string]Slot + // The current value of the slot. Value *Value diff --git a/service/lexruntimev2/validators.go b/service/lexruntimev2/validators.go index 9afe94fdcc9..bc00c2aa97e 100644 --- a/service/lexruntimev2/validators.go +++ b/service/lexruntimev2/validators.go @@ -297,6 +297,11 @@ func validateDialogAction(v *types.DialogAction) error { if len(v.Type) == 0 { invalidParams.Add(smithy.NewErrParamRequired("Type")) } + if v.SubSlotToElicit != nil { + if err := validateElicitSubSlot(v.SubSlotToElicit); err != nil { + invalidParams.AddNested("SubSlotToElicit", err.(smithy.InvalidParamsError)) + } + } if invalidParams.Len() > 0 { return invalidParams } else { @@ -319,6 +324,26 @@ func validateDTMFInputEvent(v *types.DTMFInputEvent) error { } } +func validateElicitSubSlot(v *types.ElicitSubSlot) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ElicitSubSlot"} + if v.Name == nil { + invalidParams.Add(smithy.NewErrParamRequired("Name")) + } + if v.SubSlotToElicit != nil { + if err := validateElicitSubSlot(v.SubSlotToElicit); err != nil { + invalidParams.AddNested("SubSlotToElicit", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateImageResponseCard(v *types.ImageResponseCard) error { if v == nil { return nil @@ -401,13 +426,16 @@ func validateRuntimeHintDetails(v *types.RuntimeHintDetails) error { return nil } invalidParams := smithy.InvalidParamsError{Context: "RuntimeHintDetails"} - if v.RuntimeHintValues == nil { - invalidParams.Add(smithy.NewErrParamRequired("RuntimeHintValues")) - } else if v.RuntimeHintValues != nil { + if v.RuntimeHintValues != nil { if err := validateRuntimeHintValuesList(v.RuntimeHintValues); err != nil { invalidParams.AddNested("RuntimeHintValues", err.(smithy.InvalidParamsError)) } } + if v.SubSlotHints != nil { + if err := validateSlotHintsSlotMap(v.SubSlotHints); err != nil { + invalidParams.AddNested("SubSlotHints", err.(smithy.InvalidParamsError)) + } + } if invalidParams.Len() > 0 { return invalidParams } else { @@ -511,6 +539,11 @@ func validateSlot(v *types.Slot) error { invalidParams.AddNested("Values", err.(smithy.InvalidParamsError)) } } + if v.SubSlots != nil { + if err := validateSlots(v.SubSlots); err != nil { + invalidParams.AddNested("SubSlots", err.(smithy.InvalidParamsError)) + } + } if invalidParams.Len() > 0 { return invalidParams } else { diff --git a/service/lookoutmetrics/api_op_CreateMetricSet.go b/service/lookoutmetrics/api_op_CreateMetricSet.go index 2ee795ad7d0..38887a195e1 100644 --- a/service/lookoutmetrics/api_op_CreateMetricSet.go +++ b/service/lookoutmetrics/api_op_CreateMetricSet.go @@ -49,6 +49,9 @@ type CreateMetricSetInput struct { // This member is required. MetricSource *types.MetricSource + // A list of filters that specify which data is kept for anomaly detection. + DimensionFilterList []types.MetricSetDimensionFilter + // A list of the fields you want to treat as dimensions. DimensionList []string diff --git a/service/lookoutmetrics/api_op_DescribeMetricSet.go b/service/lookoutmetrics/api_op_DescribeMetricSet.go index 52722a87a76..aba94f90b89 100644 --- a/service/lookoutmetrics/api_op_DescribeMetricSet.go +++ b/service/lookoutmetrics/api_op_DescribeMetricSet.go @@ -48,6 +48,9 @@ type DescribeMetricSetOutput struct { // The time at which the dataset was created. CreationTime *time.Time + // The dimensions and their values that were used to filter the dataset. + DimensionFilterList []types.MetricSetDimensionFilter + // A list of the dimensions chosen for analysis. DimensionList []string diff --git a/service/lookoutmetrics/api_op_UpdateMetricSet.go b/service/lookoutmetrics/api_op_UpdateMetricSet.go index ea6dfd8ebb7..2592275ec69 100644 --- a/service/lookoutmetrics/api_op_UpdateMetricSet.go +++ b/service/lookoutmetrics/api_op_UpdateMetricSet.go @@ -34,6 +34,13 @@ type UpdateMetricSetInput struct { // This member is required. MetricSetArn *string + // Describes a list of filters for choosing specific dimensions and specific + // values. Each filter consists of the dimension and one of its values that you + // want to include. When multiple dimensions or values are specified, the + // dimensions are joined with an AND operation and the values are joined with an OR + // operation. + DimensionFilterList []types.MetricSetDimensionFilter + // The dimension list. DimensionList []string diff --git a/service/lookoutmetrics/deserializers.go b/service/lookoutmetrics/deserializers.go index 59b5d40e37e..aa51b580c1e 100644 --- a/service/lookoutmetrics/deserializers.go +++ b/service/lookoutmetrics/deserializers.go @@ -1759,6 +1759,11 @@ func awsRestjson1_deserializeOpDocumentDescribeMetricSetOutput(v **DescribeMetri } } + case "DimensionFilterList": + if err := awsRestjson1_deserializeDocumentMetricSetDimensionFilterList(&sv.DimensionFilterList, value); err != nil { + return err + } + case "DimensionList": if err := awsRestjson1_deserializeDocumentDimensionList(&sv.DimensionList, value); err != nil { return err @@ -7365,6 +7370,89 @@ func awsRestjson1_deserializeDocumentFileFormatDescriptor(v **types.FileFormatDe return nil } +func awsRestjson1_deserializeDocumentFilter(v **types.Filter, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.Filter + if *v == nil { + sv = &types.Filter{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "DimensionValue": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected DimensionValue to be of type string, got %T instead", value) + } + sv.DimensionValue = ptr.String(jtv) + } + + case "FilterOperation": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected FilterOperation to be of type string, got %T instead", value) + } + sv.FilterOperation = types.FilterOperation(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentFilterList(v *[]types.Filter, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.Filter + if *v == nil { + cv = []types.Filter{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.Filter + destAddr := &col + if err := awsRestjson1_deserializeDocumentFilter(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsRestjson1_deserializeDocumentHeaderList(v *[]string, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -8123,6 +8211,85 @@ func awsRestjson1_deserializeDocumentMetricSetDataQualityMetricList(v *[]types.M return nil } +func awsRestjson1_deserializeDocumentMetricSetDimensionFilter(v **types.MetricSetDimensionFilter, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.MetricSetDimensionFilter + if *v == nil { + sv = &types.MetricSetDimensionFilter{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "FilterList": + if err := awsRestjson1_deserializeDocumentFilterList(&sv.FilterList, value); err != nil { + return err + } + + case "Name": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ColumnName to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentMetricSetDimensionFilterList(v *[]types.MetricSetDimensionFilter, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.MetricSetDimensionFilter + if *v == nil { + cv = []types.MetricSetDimensionFilter{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.MetricSetDimensionFilter + destAddr := &col + if err := awsRestjson1_deserializeDocumentMetricSetDimensionFilter(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsRestjson1_deserializeDocumentMetricSetSummary(v **types.MetricSetSummary, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/lookoutmetrics/serializers.go b/service/lookoutmetrics/serializers.go index 93ec594eaa6..4aeb4e8e676 100644 --- a/service/lookoutmetrics/serializers.go +++ b/service/lookoutmetrics/serializers.go @@ -411,6 +411,13 @@ func awsRestjson1_serializeOpDocumentCreateMetricSetInput(v *CreateMetricSetInpu ok.String(*v.AnomalyDetectorArn) } + if v.DimensionFilterList != nil { + ok := object.Key("DimensionFilterList") + if err := awsRestjson1_serializeDocumentMetricSetDimensionFilterList(v.DimensionFilterList, ok); err != nil { + return err + } + } + if v.DimensionList != nil { ok := object.Key("DimensionList") if err := awsRestjson1_serializeDocumentDimensionList(v.DimensionList, ok); err != nil { @@ -2346,6 +2353,13 @@ func awsRestjson1_serializeOpDocumentUpdateMetricSetInput(v *UpdateMetricSetInpu object := value.Object() defer object.Close() + if v.DimensionFilterList != nil { + ok := object.Key("DimensionFilterList") + if err := awsRestjson1_serializeDocumentMetricSetDimensionFilterList(v.DimensionFilterList, ok); err != nil { + return err + } + } + if v.DimensionList != nil { ok := object.Key("DimensionList") if err := awsRestjson1_serializeDocumentDimensionList(v.DimensionList, ok); err != nil { @@ -2731,6 +2745,36 @@ func awsRestjson1_serializeDocumentFileFormatDescriptor(v *types.FileFormatDescr return nil } +func awsRestjson1_serializeDocumentFilter(v *types.Filter, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.DimensionValue != nil { + ok := object.Key("DimensionValue") + ok.String(*v.DimensionValue) + } + + if len(v.FilterOperation) > 0 { + ok := object.Key("FilterOperation") + ok.String(string(v.FilterOperation)) + } + + return nil +} + +func awsRestjson1_serializeDocumentFilterList(v []types.Filter, value smithyjson.Value) error { + array := value.Array() + defer array.Close() + + for i := range v { + av := array.Value() + if err := awsRestjson1_serializeDocumentFilter(&v[i], av); err != nil { + return err + } + } + return nil +} + func awsRestjson1_serializeDocumentHeaderList(v []string, value smithyjson.Value) error { array := value.Array() defer array.Close() @@ -2833,6 +2877,38 @@ func awsRestjson1_serializeDocumentMetricNameList(v []string, value smithyjson.V return nil } +func awsRestjson1_serializeDocumentMetricSetDimensionFilter(v *types.MetricSetDimensionFilter, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.FilterList != nil { + ok := object.Key("FilterList") + if err := awsRestjson1_serializeDocumentFilterList(v.FilterList, ok); err != nil { + return err + } + } + + if v.Name != nil { + ok := object.Key("Name") + ok.String(*v.Name) + } + + return nil +} + +func awsRestjson1_serializeDocumentMetricSetDimensionFilterList(v []types.MetricSetDimensionFilter, value smithyjson.Value) error { + array := value.Array() + defer array.Close() + + for i := range v { + av := array.Value() + if err := awsRestjson1_serializeDocumentMetricSetDimensionFilter(&v[i], av); err != nil { + return err + } + } + return nil +} + func awsRestjson1_serializeDocumentMetricSource(v *types.MetricSource, value smithyjson.Value) error { object := value.Object() defer object.Close() diff --git a/service/lookoutmetrics/types/enums.go b/service/lookoutmetrics/types/enums.go index 79168c9eb59..79d0932be28 100644 --- a/service/lookoutmetrics/types/enums.go +++ b/service/lookoutmetrics/types/enums.go @@ -210,6 +210,22 @@ func (DataQualityMetricType) Values() []DataQualityMetricType { } } +type FilterOperation string + +// Enum values for FilterOperation +const ( + FilterOperationEquals FilterOperation = "EQUALS" +) + +// Values returns all known values for FilterOperation. Note that this can be +// expanded in the future, and so it is only as up to date as the client. The +// ordering of this slice is not guaranteed to be stable across updates. +func (FilterOperation) Values() []FilterOperation { + return []FilterOperation{ + "EQUALS", + } +} + type Frequency string // Enum values for Frequency diff --git a/service/lookoutmetrics/types/types.go b/service/lookoutmetrics/types/types.go index 3c9842966b9..4f4949479e3 100644 --- a/service/lookoutmetrics/types/types.go +++ b/service/lookoutmetrics/types/types.go @@ -598,6 +598,20 @@ type FileFormatDescriptor struct { noSmithyDocumentSerde } +// Describes a filter for choosing a subset of dimension values. Each filter +// consists of the dimension that you want to include and the condition statement. +// The condition statement is specified in the FilterOperation object. +type Filter struct { + + // The value that you want to include in the filter. + DimensionValue *string + + // The condition to apply. + FilterOperation FilterOperation + + noSmithyDocumentSerde +} + // Aggregated details about the measures contributing to the anomaly group, and the // measures potentially impacted by the anomaly group. type InterMetricImpactDetails struct { @@ -708,6 +722,21 @@ type MetricSetDataQualityMetric struct { noSmithyDocumentSerde } +// Describes a list of filters for choosing a subset of dimension values. Each +// filter consists of the dimension and one of its values that you want to include. +// When multiple dimensions or values are specified, the dimensions are joined with +// an AND operation and the values are joined with an OR operation. +type MetricSetDimensionFilter struct { + + // The list of filters that you are applying. + FilterList []Filter + + // The dimension that you want to filter on. + Name *string + + noSmithyDocumentSerde +} + // Contains information about a dataset. type MetricSetSummary struct { diff --git a/service/medialive/deserializers.go b/service/medialive/deserializers.go index fcfe64c2676..fb301e9da59 100644 --- a/service/medialive/deserializers.go +++ b/service/medialive/deserializers.go @@ -13417,6 +13417,11 @@ func awsRestjson1_deserializeDocumentAudioCodecSettings(v **types.AudioCodecSett return err } + case "eac3AtmosSettings": + if err := awsRestjson1_deserializeDocumentEac3AtmosSettings(&sv.Eac3AtmosSettings, value); err != nil { + return err + } + case "eac3Settings": if err := awsRestjson1_deserializeDocumentEac3Settings(&sv.Eac3Settings, value); err != nil { return err @@ -15844,6 +15849,37 @@ func awsRestjson1_deserializeDocumentConflictException(v **types.ConflictExcepti return nil } +func awsRestjson1_deserializeDocumentDolbyVision81Settings(v **types.DolbyVision81Settings, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.DolbyVision81Settings + if *v == nil { + sv = &types.DolbyVision81Settings{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentDvbNitSettings(v **types.DvbNitSettings, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -16294,6 +16330,179 @@ func awsRestjson1_deserializeDocumentDvbTdtSettings(v **types.DvbTdtSettings, va return nil } +func awsRestjson1_deserializeDocumentEac3AtmosSettings(v **types.Eac3AtmosSettings, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.Eac3AtmosSettings + if *v == nil { + sv = &types.Eac3AtmosSettings{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "bitrate": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.Bitrate = f64 + + case string: + var f64 float64 + switch { + case strings.EqualFold(jtv, "NaN"): + f64 = math.NaN() + + case strings.EqualFold(jtv, "Infinity"): + f64 = math.Inf(1) + + case strings.EqualFold(jtv, "-Infinity"): + f64 = math.Inf(-1) + + default: + return fmt.Errorf("unknown JSON number value: %s", jtv) + + } + sv.Bitrate = f64 + + default: + return fmt.Errorf("expected __double to be a JSON Number, got %T instead", value) + + } + } + + case "codingMode": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Eac3AtmosCodingMode to be of type string, got %T instead", value) + } + sv.CodingMode = types.Eac3AtmosCodingMode(jtv) + } + + case "dialnorm": + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected __integerMin1Max31 to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + sv.Dialnorm = int32(i64) + } + + case "drcLine": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Eac3AtmosDrcLine to be of type string, got %T instead", value) + } + sv.DrcLine = types.Eac3AtmosDrcLine(jtv) + } + + case "drcRf": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Eac3AtmosDrcRf to be of type string, got %T instead", value) + } + sv.DrcRf = types.Eac3AtmosDrcRf(jtv) + } + + case "heightTrim": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.HeightTrim = f64 + + case string: + var f64 float64 + switch { + case strings.EqualFold(jtv, "NaN"): + f64 = math.NaN() + + case strings.EqualFold(jtv, "Infinity"): + f64 = math.Inf(1) + + case strings.EqualFold(jtv, "-Infinity"): + f64 = math.Inf(-1) + + default: + return fmt.Errorf("unknown JSON number value: %s", jtv) + + } + sv.HeightTrim = f64 + + default: + return fmt.Errorf("expected __double to be a JSON Number, got %T instead", value) + + } + } + + case "surroundTrim": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.SurroundTrim = f64 + + case string: + var f64 float64 + switch { + case strings.EqualFold(jtv, "NaN"): + f64 = math.NaN() + + case strings.EqualFold(jtv, "Infinity"): + f64 = math.Inf(1) + + case strings.EqualFold(jtv, "-Infinity"): + f64 = math.Inf(-1) + + default: + return fmt.Errorf("unknown JSON number value: %s", jtv) + + } + sv.SurroundTrim = f64 + + default: + return fmt.Errorf("expected __double to be a JSON Number, got %T instead", value) + + } + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentEac3Settings(v **types.Eac3Settings, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -18256,6 +18465,11 @@ func awsRestjson1_deserializeDocumentH265ColorSpaceSettings(v **types.H265ColorS return err } + case "dolbyVision81Settings": + if err := awsRestjson1_deserializeDocumentDolbyVision81Settings(&sv.DolbyVision81Settings, value); err != nil { + return err + } + case "hdr10Settings": if err := awsRestjson1_deserializeDocumentHdr10Settings(&sv.Hdr10Settings, value); err != nil { return err diff --git a/service/medialive/serializers.go b/service/medialive/serializers.go index 15d1f0679c4..5a7f99f8e31 100644 --- a/service/medialive/serializers.go +++ b/service/medialive/serializers.go @@ -5063,6 +5063,13 @@ func awsRestjson1_serializeDocumentAudioCodecSettings(v *types.AudioCodecSetting } } + if v.Eac3AtmosSettings != nil { + ok := object.Key("eac3AtmosSettings") + if err := awsRestjson1_serializeDocumentEac3AtmosSettings(v.Eac3AtmosSettings, ok); err != nil { + return err + } + } + if v.Eac3Settings != nil { ok := object.Key("eac3Settings") if err := awsRestjson1_serializeDocumentEac3Settings(v.Eac3Settings, ok); err != nil { @@ -5963,6 +5970,13 @@ func awsRestjson1_serializeDocumentColorSpacePassthroughSettings(v *types.ColorS return nil } +func awsRestjson1_serializeDocumentDolbyVision81Settings(v *types.DolbyVision81Settings, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + return nil +} + func awsRestjson1_serializeDocumentDvbNitSettings(v *types.DvbNitSettings, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -6135,6 +6149,87 @@ func awsRestjson1_serializeDocumentDvbTdtSettings(v *types.DvbTdtSettings, value return nil } +func awsRestjson1_serializeDocumentEac3AtmosSettings(v *types.Eac3AtmosSettings, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Bitrate != 0 { + ok := object.Key("bitrate") + switch { + case math.IsNaN(v.Bitrate): + ok.String("NaN") + + case math.IsInf(v.Bitrate, 1): + ok.String("Infinity") + + case math.IsInf(v.Bitrate, -1): + ok.String("-Infinity") + + default: + ok.Double(v.Bitrate) + + } + } + + if len(v.CodingMode) > 0 { + ok := object.Key("codingMode") + ok.String(string(v.CodingMode)) + } + + if v.Dialnorm != 0 { + ok := object.Key("dialnorm") + ok.Integer(v.Dialnorm) + } + + if len(v.DrcLine) > 0 { + ok := object.Key("drcLine") + ok.String(string(v.DrcLine)) + } + + if len(v.DrcRf) > 0 { + ok := object.Key("drcRf") + ok.String(string(v.DrcRf)) + } + + if v.HeightTrim != 0 { + ok := object.Key("heightTrim") + switch { + case math.IsNaN(v.HeightTrim): + ok.String("NaN") + + case math.IsInf(v.HeightTrim, 1): + ok.String("Infinity") + + case math.IsInf(v.HeightTrim, -1): + ok.String("-Infinity") + + default: + ok.Double(v.HeightTrim) + + } + } + + if v.SurroundTrim != 0 { + ok := object.Key("surroundTrim") + switch { + case math.IsNaN(v.SurroundTrim): + ok.String("NaN") + + case math.IsInf(v.SurroundTrim, 1): + ok.String("Infinity") + + case math.IsInf(v.SurroundTrim, -1): + ok.String("-Infinity") + + default: + ok.Double(v.SurroundTrim) + + } + } + + return nil +} + func awsRestjson1_serializeDocumentEac3Settings(v *types.Eac3Settings, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -6997,6 +7092,13 @@ func awsRestjson1_serializeDocumentH265ColorSpaceSettings(v *types.H265ColorSpac } } + if v.DolbyVision81Settings != nil { + ok := object.Key("dolbyVision81Settings") + if err := awsRestjson1_serializeDocumentDolbyVision81Settings(v.DolbyVision81Settings, ok); err != nil { + return err + } + } + if v.Hdr10Settings != nil { ok := object.Key("hdr10Settings") if err := awsRestjson1_serializeDocumentHdr10Settings(v.Hdr10Settings, ok); err != nil { diff --git a/service/medialive/types/enums.go b/service/medialive/types/enums.go index c1db0b870a4..904e88d8b18 100644 --- a/service/medialive/types/enums.go +++ b/service/medialive/types/enums.go @@ -967,6 +967,78 @@ func (DvbSubOcrLanguage) Values() []DvbSubOcrLanguage { } } +type Eac3AtmosCodingMode string + +// Enum values for Eac3AtmosCodingMode +const ( + Eac3AtmosCodingModeCodingMode514 Eac3AtmosCodingMode = "CODING_MODE_5_1_4" + Eac3AtmosCodingModeCodingMode714 Eac3AtmosCodingMode = "CODING_MODE_7_1_4" + Eac3AtmosCodingModeCodingMode916 Eac3AtmosCodingMode = "CODING_MODE_9_1_6" +) + +// Values returns all known values for Eac3AtmosCodingMode. Note that this can be +// expanded in the future, and so it is only as up to date as the client. The +// ordering of this slice is not guaranteed to be stable across updates. +func (Eac3AtmosCodingMode) Values() []Eac3AtmosCodingMode { + return []Eac3AtmosCodingMode{ + "CODING_MODE_5_1_4", + "CODING_MODE_7_1_4", + "CODING_MODE_9_1_6", + } +} + +type Eac3AtmosDrcLine string + +// Enum values for Eac3AtmosDrcLine +const ( + Eac3AtmosDrcLineFilmLight Eac3AtmosDrcLine = "FILM_LIGHT" + Eac3AtmosDrcLineFilmStandard Eac3AtmosDrcLine = "FILM_STANDARD" + Eac3AtmosDrcLineMusicLight Eac3AtmosDrcLine = "MUSIC_LIGHT" + Eac3AtmosDrcLineMusicStandard Eac3AtmosDrcLine = "MUSIC_STANDARD" + Eac3AtmosDrcLineNone Eac3AtmosDrcLine = "NONE" + Eac3AtmosDrcLineSpeech Eac3AtmosDrcLine = "SPEECH" +) + +// Values returns all known values for Eac3AtmosDrcLine. Note that this can be +// expanded in the future, and so it is only as up to date as the client. The +// ordering of this slice is not guaranteed to be stable across updates. +func (Eac3AtmosDrcLine) Values() []Eac3AtmosDrcLine { + return []Eac3AtmosDrcLine{ + "FILM_LIGHT", + "FILM_STANDARD", + "MUSIC_LIGHT", + "MUSIC_STANDARD", + "NONE", + "SPEECH", + } +} + +type Eac3AtmosDrcRf string + +// Enum values for Eac3AtmosDrcRf +const ( + Eac3AtmosDrcRfFilmLight Eac3AtmosDrcRf = "FILM_LIGHT" + Eac3AtmosDrcRfFilmStandard Eac3AtmosDrcRf = "FILM_STANDARD" + Eac3AtmosDrcRfMusicLight Eac3AtmosDrcRf = "MUSIC_LIGHT" + Eac3AtmosDrcRfMusicStandard Eac3AtmosDrcRf = "MUSIC_STANDARD" + Eac3AtmosDrcRfNone Eac3AtmosDrcRf = "NONE" + Eac3AtmosDrcRfSpeech Eac3AtmosDrcRf = "SPEECH" +) + +// Values returns all known values for Eac3AtmosDrcRf. Note that this can be +// expanded in the future, and so it is only as up to date as the client. The +// ordering of this slice is not guaranteed to be stable across updates. +func (Eac3AtmosDrcRf) Values() []Eac3AtmosDrcRf { + return []Eac3AtmosDrcRf{ + "FILM_LIGHT", + "FILM_STANDARD", + "MUSIC_LIGHT", + "MUSIC_STANDARD", + "NONE", + "SPEECH", + } +} + type Eac3AttenuationControl string // Enum values for Eac3AttenuationControl diff --git a/service/medialive/types/types.go b/service/medialive/types/types.go index 266689184ae..3d74addc130 100644 --- a/service/medialive/types/types.go +++ b/service/medialive/types/types.go @@ -199,6 +199,9 @@ type AudioCodecSettings struct { // Ac3 Settings Ac3Settings *Ac3Settings + // Eac3 Atmos Settings + Eac3AtmosSettings *Eac3AtmosSettings + // Eac3 Settings Eac3Settings *Eac3Settings @@ -1066,6 +1069,11 @@ type ColorSpacePassthroughSettings struct { noSmithyDocumentSerde } +// Dolby Vision Profile 8.1 Settings +type DolbyVision81Settings struct { + noSmithyDocumentSerde +} + // DVB Network Information Table (NIT) type DvbNitSettings struct { @@ -1245,6 +1253,39 @@ type DvbTdtSettings struct { noSmithyDocumentSerde } +// Eac3 Atmos Settings +type Eac3AtmosSettings struct { + + // Average bitrate in bits/second. Valid bitrates depend on the coding mode. // * + // @affectsRightSizing true + Bitrate float64 + + // Dolby Digital Plus with Dolby Atmos coding mode. Determines number of channels. + CodingMode Eac3AtmosCodingMode + + // Sets the dialnorm for the output. Default 23. + Dialnorm int32 + + // Sets the Dolby dynamic range compression profile. + DrcLine Eac3AtmosDrcLine + + // Sets the profile for heavy Dolby dynamic range compression, ensures that the + // instantaneous signal peaks do not exceed specified levels. + DrcRf Eac3AtmosDrcRf + + // Height dimensional trim. Sets the maximum amount to attenuate the height + // channels when the downstream player isn??t configured to handle Dolby Digital + // Plus with Dolby Atmos and must remix the channels. + HeightTrim float64 + + // Surround dimensional trim. Sets the maximum amount to attenuate the surround + // channels when the downstream player isn't configured to handle Dolby Digital + // Plus with Dolby Atmos and must remix the channels. + SurroundTrim float64 + + noSmithyDocumentSerde +} + // Eac3 Settings type Eac3Settings struct { @@ -1950,6 +1991,9 @@ type H265ColorSpaceSettings struct { // Passthrough applies no color space conversion to the output ColorSpacePassthroughSettings *ColorSpacePassthroughSettings + // Dolby Vision Profile 8.1 Settings + DolbyVision81Settings *DolbyVision81Settings + // Hdr10 Settings Hdr10Settings *Hdr10Settings diff --git a/service/redshift/api_op_CreateCluster.go b/service/redshift/api_op_CreateCluster.go index 3a6f64625d2..712cc967b08 100644 --- a/service/redshift/api_op_CreateCluster.go +++ b/service/redshift/api_op_CreateCluster.go @@ -114,17 +114,9 @@ type CreateClusterInput struct { // Redshift engine that is running on your cluster. Default: true AllowVersionUpgrade *bool - // The value represents how the cluster is configured to use AQUA (Advanced Query - // Accelerator) when it is created. Possible values include the following. - // - // * - // enabled - Use AQUA if it is available for the current Amazon Web Services Region - // and Amazon Redshift node type. - // - // * disabled - Don't use AQUA. - // - // * auto - Amazon - // Redshift determines whether to use AQUA. + // This parameter is retired. It does not set the AQUA configuration status. Amazon + // Redshift automatically determines whether to use AQUA (Advanced Query + // Accelerator). AquaConfigurationStatus types.AquaConfigurationStatus // The number of days that automated snapshots are retained. If the value is 0, @@ -212,11 +204,10 @@ type CreateClusterInput struct { // cluster when the cluster was created. DefaultIamRoleArn *string - // The Elastic IP (EIP) address for the cluster. You don't have to specify the EIP - // for a publicly accessible cluster with AvailabilityZoneRelocation turned on. - // Constraints: The cluster must be provisioned in EC2-VPC and publicly-accessible - // through an Internet gateway. For more information about provisioning clusters in - // EC2-VPC, go to Supported Platforms to Launch Your Cluster + // The Elastic IP (EIP) address for the cluster. Constraints: The cluster must be + // provisioned in EC2-VPC and publicly-accessible through an Internet gateway. For + // more information about provisioning clusters in EC2-VPC, go to Supported + // Platforms to Launch Your Cluster // (https://docs.aws.amazon.com/redshift/latest/mgmt/working-with-clusters.html#cluster-platforms) // in the Amazon Redshift Cluster Management Guide. ElasticIp *string diff --git a/service/redshift/api_op_GetClusterCredentials.go b/service/redshift/api_op_GetClusterCredentials.go index 8991e147803..f7cad264ee1 100644 --- a/service/redshift/api_op_GetClusterCredentials.go +++ b/service/redshift/api_op_GetClusterCredentials.go @@ -70,16 +70,16 @@ type GetClusterCredentialsInput struct { // alphanumeric characters or hyphens. The user name can't be PUBLIC. // // * Must - // contain only lowercase letters, numbers, underscore, plus sign, period (dot), at - // symbol (@), or hyphen. + // contain uppercase or lowercase letters, numbers, underscore, plus sign, period + // (dot), at symbol (@), or hyphen. // // * First character must be a letter. // - // * Must not contain - // a colon ( : ) or slash ( / ). + // * Must + // not contain a colon ( : ) or slash ( / ). // - // * Cannot be a reserved word. A list of reserved - // words can be found in Reserved Words + // * Cannot be a reserved word. A list + // of reserved words can be found in Reserved Words // (http://docs.aws.amazon.com/redshift/latest/dg/r_pg_keywords.html) in the Amazon // Redshift Database Developer Guide. // @@ -118,18 +118,19 @@ type GetClusterCredentialsInput struct { // * Must be 1 // to 64 alphanumeric characters or hyphens // - // * Must contain only lowercase letters, - // numbers, underscore, plus sign, period (dot), at symbol (@), or hyphen. + // * Must contain uppercase or lowercase + // letters, numbers, underscore, plus sign, period (dot), at symbol (@), or + // hyphen. // - // * First - // character must be a letter. + // * First character must be a letter. // - // * Must not contain a colon ( : ) or slash ( / ). + // * Must not contain a colon ( : ) + // or slash ( / ). // - // * - // Cannot be a reserved word. A list of reserved words can be found in Reserved - // Words (http://docs.aws.amazon.com/redshift/latest/dg/r_pg_keywords.html) in the - // Amazon Redshift Database Developer Guide. + // * Cannot be a reserved word. A list of reserved words can be + // found in Reserved Words + // (http://docs.aws.amazon.com/redshift/latest/dg/r_pg_keywords.html) in the Amazon + // Redshift Database Developer Guide. DbName *string // The number of seconds until the returned temporary password expires. Constraint: diff --git a/service/redshift/api_op_ModifyAquaConfiguration.go b/service/redshift/api_op_ModifyAquaConfiguration.go index 627b981a966..282c2f5d956 100644 --- a/service/redshift/api_op_ModifyAquaConfiguration.go +++ b/service/redshift/api_op_ModifyAquaConfiguration.go @@ -11,7 +11,9 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Modifies whether a cluster can use AQUA (Advanced Query Accelerator). +// This operation is retired. Calling this operation does not change AQUA +// configuration. Amazon Redshift automatically determines whether to use AQUA +// (Advanced Query Accelerator). func (c *Client) ModifyAquaConfiguration(ctx context.Context, params *ModifyAquaConfigurationInput, optFns ...func(*Options)) (*ModifyAquaConfigurationOutput, error) { if params == nil { params = &ModifyAquaConfigurationInput{} @@ -34,16 +36,8 @@ type ModifyAquaConfigurationInput struct { // This member is required. ClusterIdentifier *string - // The new value of AQUA configuration status. Possible values include the - // following. - // - // * enabled - Use AQUA if it is available for the current Amazon Web - // Services Region and Amazon Redshift node type. - // - // * disabled - Don't use AQUA. - // - // * - // auto - Amazon Redshift determines whether to use AQUA. + // This parameter is retired. Amazon Redshift automatically determines whether to + // use AQUA (Advanced Query Accelerator). AquaConfigurationStatus types.AquaConfigurationStatus noSmithyDocumentSerde @@ -51,7 +45,8 @@ type ModifyAquaConfigurationInput struct { type ModifyAquaConfigurationOutput struct { - // The updated AQUA configuration of the cluster. + // This parameter is retired. Amazon Redshift automatically determines whether to + // use AQUA (Advanced Query Accelerator). AquaConfiguration *types.AquaConfiguration // Metadata pertaining to the operation's result. diff --git a/service/redshift/api_op_RestoreFromClusterSnapshot.go b/service/redshift/api_op_RestoreFromClusterSnapshot.go index 45343f36438..80231536818 100644 --- a/service/redshift/api_op_RestoreFromClusterSnapshot.go +++ b/service/redshift/api_op_RestoreFromClusterSnapshot.go @@ -66,17 +66,9 @@ type RestoreFromClusterSnapshotInput struct { // the Amazon Redshift engine that is running on the cluster. Default: true AllowVersionUpgrade *bool - // The value represents how the cluster is configured to use AQUA (Advanced Query - // Accelerator) after the cluster is restored. Possible values include the - // following. - // - // * enabled - Use AQUA if it is available for the current Amazon Web - // Services Region and Amazon Redshift node type. - // - // * disabled - Don't use AQUA. - // - // * - // auto - Amazon Redshift determines whether to use AQUA. + // This parameter is retired. It does not set the AQUA configuration status. Amazon + // Redshift automatically determines whether to use AQUA (Advanced Query + // Accelerator). AquaConfigurationStatus types.AquaConfigurationStatus // The number of days that automated snapshots are retained. If the value is 0, @@ -125,8 +117,7 @@ type RestoreFromClusterSnapshotInput struct { // snapshot. DefaultIamRoleArn *string - // The elastic IP (EIP) address for the cluster. You don't have to specify the EIP - // for a publicly accessible cluster with AvailabilityZoneRelocation turned on. + // The elastic IP (EIP) address for the cluster. ElasticIp *string // Enables support for restoring an unencrypted snapshot to a cluster encrypted @@ -221,7 +212,8 @@ type RestoreFromClusterSnapshotInput struct { ReservedNodeId *string // The Amazon Resource Name (ARN) of the snapshot associated with the message to - // restore from a cluster. + // restore from a cluster. You can specify this parameter or snapshotIdentifier, + // but not both. SnapshotArn *string // The name of the cluster the source snapshot was created from. This parameter is @@ -230,7 +222,8 @@ type RestoreFromClusterSnapshotInput struct { SnapshotClusterIdentifier *string // The name of the snapshot from which to create the new cluster. This parameter - // isn't case sensitive. Example: my-snapshot-id + // isn't case sensitive. You can specify this parameter or snapshotArn, but not + // both. Example: my-snapshot-id SnapshotIdentifier *string // A unique identifier for the snapshot schedule. diff --git a/service/redshift/types/types.go b/service/redshift/types/types.go index 4b59ff163f7..316d9f81ab0 100644 --- a/service/redshift/types/types.go +++ b/service/redshift/types/types.go @@ -34,30 +34,16 @@ type AccountWithRestoreAccess struct { noSmithyDocumentSerde } -// The AQUA (Advanced Query Accelerator) configuration of the cluster. +// The operation that uses this structure is retired. Amazon Redshift automatically +// determines whether to use AQUA (Advanced Query Accelerator). type AquaConfiguration struct { - // The value represents how the cluster is configured to use AQUA. Possible values - // include the following. - // - // * enabled - Use AQUA if it is available for the current - // Amazon Web Services Region and Amazon Redshift node type. - // - // * disabled - Don't - // use AQUA. - // - // * auto - Amazon Redshift determines whether to use AQUA. + // This field is retired. Amazon Redshift automatically determines whether to use + // AQUA (Advanced Query Accelerator). AquaConfigurationStatus AquaConfigurationStatus - // The value indicates the status of AQUA on the cluster. Possible values include - // the following. - // - // * enabled - AQUA is enabled. - // - // * disabled - AQUA is not - // enabled. - // - // * applying - AQUA status is being applied. + // This field is retired. Amazon Redshift automatically determines whether to use + // AQUA (Advanced Query Accelerator). AquaStatus AquaStatus noSmithyDocumentSerde @@ -104,7 +90,8 @@ type Cluster struct { // applied automatically to the cluster during the maintenance window. AllowVersionUpgrade bool - // The AQUA (Advanced Query Accelerator) configuration of the cluster. + // This field is retired. Amazon Redshift automatically determines whether to use + // AQUA (Advanced Query Accelerator). AquaConfiguration *AquaConfiguration // The number of days that automatic cluster snapshots are retained. diff --git a/service/route53/doc.go b/service/route53/doc.go index 82ea541cc6c..9357dc6c59b 100644 --- a/service/route53/doc.go +++ b/service/route53/doc.go @@ -4,19 +4,5 @@ // Amazon Route 53. // // Amazon Route 53 is a highly available and scalable Domain Name System (DNS) web -// service. You can use Route 53 to: -// -// * Register domain names. For more -// information, see How domain registration works -// (https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/welcome-domain-registration.html). -// -// * -// Route internet traffic to the resources for your domain For more information, -// see How internet traffic is routed to your website or web application -// (https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/welcome-dns-service.html). -// -// * -// Check the health of your resources. For more information, see How Route 53 -// checks the health of your resources -// (https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/welcome-health-checks.html). +// service. package route53 diff --git a/service/route53/types/enums.go b/service/route53/types/enums.go index 747e965dfcf..7a021fd3e04 100644 --- a/service/route53/types/enums.go +++ b/service/route53/types/enums.go @@ -97,6 +97,7 @@ const ( CloudWatchRegionEuWest3 CloudWatchRegion = "eu-west-3" CloudWatchRegionApEast1 CloudWatchRegion = "ap-east-1" CloudWatchRegionMeSouth1 CloudWatchRegion = "me-south-1" + CloudWatchRegionMeCentral1 CloudWatchRegion = "me-central-1" CloudWatchRegionApSouth1 CloudWatchRegion = "ap-south-1" CloudWatchRegionApSoutheast1 CloudWatchRegion = "ap-southeast-1" CloudWatchRegionApSoutheast2 CloudWatchRegion = "ap-southeast-2" @@ -133,6 +134,7 @@ func (CloudWatchRegion) Values() []CloudWatchRegion { "eu-west-3", "ap-east-1", "me-south-1", + "me-central-1", "ap-south-1", "ap-southeast-1", "ap-southeast-2", @@ -494,6 +496,7 @@ const ( VPCRegionUsIsoEast1 VPCRegion = "us-iso-east-1" VPCRegionUsIsoWest1 VPCRegion = "us-iso-west-1" VPCRegionUsIsobEast1 VPCRegion = "us-isob-east-1" + VPCRegionMeCentral1 VPCRegion = "me-central-1" VPCRegionApSoutheast1 VPCRegion = "ap-southeast-1" VPCRegionApSoutheast2 VPCRegion = "ap-southeast-2" VPCRegionApSoutheast3 VPCRegion = "ap-southeast-3" @@ -529,6 +532,7 @@ func (VPCRegion) Values() []VPCRegion { "us-iso-east-1", "us-iso-west-1", "us-isob-east-1", + "me-central-1", "ap-southeast-1", "ap-southeast-2", "ap-southeast-3", diff --git a/service/sagemaker/api_op_CreateTrainingJob.go b/service/sagemaker/api_op_CreateTrainingJob.go index 093b1f6a0ea..869c3407d86 100644 --- a/service/sagemaker/api_op_CreateTrainingJob.go +++ b/service/sagemaker/api_op_CreateTrainingJob.go @@ -26,23 +26,27 @@ import ( // estimation of model parameters during training. Hyperparameters can be tuned to // optimize this learning process. For a list of hyperparameters for each training // algorithm provided by SageMaker, see Algorithms -// (https://docs.aws.amazon.com/sagemaker/latest/dg/algos.html). +// (https://docs.aws.amazon.com/sagemaker/latest/dg/algos.html). You must not +// include any security-sensitive information, such as account access IDs, secrets, +// and tokens, in the dictionary for configuring hyperparameters. SageMaker rejects +// the training job request and returns an exception error for detected +// credentials, if such user input is found. // -// * InputDataConfig -// - Describes the training dataset and the Amazon S3, EFS, or FSx location where -// it is stored. +// * InputDataConfig - Describes the +// training dataset and the Amazon S3, EFS, or FSx location where it is stored. // -// * OutputDataConfig - Identifies the Amazon S3 bucket where you -// want SageMaker to save the results of model training. +// * +// OutputDataConfig - Identifies the Amazon S3 bucket where you want SageMaker to +// save the results of model training. // -// * ResourceConfig - -// Identifies the resources, ML compute instances, and ML storage volumes to deploy -// for model training. In distributed training, you specify more than one -// instance. +// * ResourceConfig - Identifies the +// resources, ML compute instances, and ML storage volumes to deploy for model +// training. In distributed training, you specify more than one instance. // -// * EnableManagedSpotTraining - Optimize the cost of training machine -// learning models by up to 80% by using Amazon EC2 Spot instances. For more -// information, see Managed Spot Training +// * +// EnableManagedSpotTraining - Optimize the cost of training machine learning +// models by up to 80% by using Amazon EC2 Spot instances. For more information, +// see Managed Spot Training // (https://docs.aws.amazon.com/sagemaker/latest/dg/model-managed-spot-training.html). // // * @@ -199,7 +203,10 @@ type CreateTrainingJobInput struct { // Algorithms (https://docs.aws.amazon.com/sagemaker/latest/dg/algos.html). You can // specify a maximum of 100 hyperparameters. Each hyperparameter is a key-value // pair. Each key and value is limited to 256 characters, as specified by the - // Length Constraint. + // Length Constraint. You must not include any security-sensitive information, such + // as account access IDs, secrets, and tokens, in the dictionary for configuring + // hyperparameters. SageMaker rejects the training job request and returns an + // exception error for detected credentials, if such user input is found. HyperParameters map[string]string // An array of Channel objects. Each channel is a named input source. diff --git a/service/sagemaker/deserializers.go b/service/sagemaker/deserializers.go index 166e9e2fa74..8cc55d2eb98 100644 --- a/service/sagemaker/deserializers.go +++ b/service/sagemaker/deserializers.go @@ -30932,6 +30932,15 @@ func awsAwsjson11_deserializeDocumentAutoMLJobConfig(v **types.AutoMLJobConfig, return err } + case "Mode": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected AutoMLMode to be of type string, got %T instead", value) + } + sv.Mode = types.AutoMLMode(jtv) + } + case "SecurityConfig": if err := awsAwsjson11_deserializeDocumentAutoMLSecurityConfig(&sv.SecurityConfig, value); err != nil { return err @@ -41270,6 +41279,166 @@ func awsAwsjson11_deserializeDocumentHyperParameterTuningJobObjectives(v *[]type return nil } +func awsAwsjson11_deserializeDocumentHyperParameterTuningJobSearchEntity(v **types.HyperParameterTuningJobSearchEntity, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.HyperParameterTuningJobSearchEntity + if *v == nil { + sv = &types.HyperParameterTuningJobSearchEntity{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "BestTrainingJob": + if err := awsAwsjson11_deserializeDocumentHyperParameterTrainingJobSummary(&sv.BestTrainingJob, value); err != nil { + return err + } + + case "CreationTime": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.CreationTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "FailureReason": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected FailureReason to be of type string, got %T instead", value) + } + sv.FailureReason = ptr.String(jtv) + } + + case "HyperParameterTuningEndTime": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.HyperParameterTuningEndTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "HyperParameterTuningJobArn": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HyperParameterTuningJobArn to be of type string, got %T instead", value) + } + sv.HyperParameterTuningJobArn = ptr.String(jtv) + } + + case "HyperParameterTuningJobConfig": + if err := awsAwsjson11_deserializeDocumentHyperParameterTuningJobConfig(&sv.HyperParameterTuningJobConfig, value); err != nil { + return err + } + + case "HyperParameterTuningJobName": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HyperParameterTuningJobName to be of type string, got %T instead", value) + } + sv.HyperParameterTuningJobName = ptr.String(jtv) + } + + case "HyperParameterTuningJobStatus": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HyperParameterTuningJobStatus to be of type string, got %T instead", value) + } + sv.HyperParameterTuningJobStatus = types.HyperParameterTuningJobStatus(jtv) + } + + case "LastModifiedTime": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.LastModifiedTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "ObjectiveStatusCounters": + if err := awsAwsjson11_deserializeDocumentObjectiveStatusCounters(&sv.ObjectiveStatusCounters, value); err != nil { + return err + } + + case "OverallBestTrainingJob": + if err := awsAwsjson11_deserializeDocumentHyperParameterTrainingJobSummary(&sv.OverallBestTrainingJob, value); err != nil { + return err + } + + case "Tags": + if err := awsAwsjson11_deserializeDocumentTagList(&sv.Tags, value); err != nil { + return err + } + + case "TrainingJobDefinition": + if err := awsAwsjson11_deserializeDocumentHyperParameterTrainingJobDefinition(&sv.TrainingJobDefinition, value); err != nil { + return err + } + + case "TrainingJobDefinitions": + if err := awsAwsjson11_deserializeDocumentHyperParameterTrainingJobDefinitions(&sv.TrainingJobDefinitions, value); err != nil { + return err + } + + case "TrainingJobStatusCounters": + if err := awsAwsjson11_deserializeDocumentTrainingJobStatusCounters(&sv.TrainingJobStatusCounters, value); err != nil { + return err + } + + case "WarmStartConfig": + if err := awsAwsjson11_deserializeDocumentHyperParameterTuningJobWarmStartConfig(&sv.WarmStartConfig, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson11_deserializeDocumentHyperParameterTuningJobSummaries(v *[]types.HyperParameterTuningJobSummary, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -52394,6 +52563,19 @@ func awsAwsjson11_deserializeDocumentProductionVariant(v **types.ProductionVaria sv.AcceleratorType = types.ProductionVariantAcceleratorType(jtv) } + case "ContainerStartupHealthCheckTimeoutInSeconds": + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected ProductionVariantContainerStartupHealthCheckTimeoutInSeconds to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + sv.ContainerStartupHealthCheckTimeoutInSeconds = ptr.Int32(int32(i64)) + } + case "CoreDumpConfig": if err := awsAwsjson11_deserializeDocumentProductionVariantCoreDumpConfig(&sv.CoreDumpConfig, value); err != nil { return err @@ -52455,6 +52637,19 @@ func awsAwsjson11_deserializeDocumentProductionVariant(v **types.ProductionVaria sv.InstanceType = types.ProductionVariantInstanceType(jtv) } + case "ModelDataDownloadTimeoutInSeconds": + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected ProductionVariantModelDataDownloadTimeoutInSeconds to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + sv.ModelDataDownloadTimeoutInSeconds = ptr.Int32(int32(i64)) + } + case "ModelName": if value != nil { jtv, ok := value.(string) @@ -52478,6 +52673,19 @@ func awsAwsjson11_deserializeDocumentProductionVariant(v **types.ProductionVaria sv.VariantName = ptr.String(jtv) } + case "VolumeSizeInGB": + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected ProductionVariantVolumeSizeInGB to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + sv.VolumeSizeInGB = ptr.Int32(int32(i64)) + } + default: _, _ = key, value @@ -55540,6 +55748,11 @@ func awsAwsjson11_deserializeDocumentSearchRecord(v **types.SearchRecord, value return err } + case "HyperParameterTuningJob": + if err := awsAwsjson11_deserializeDocumentHyperParameterTuningJobSearchEntity(&sv.HyperParameterTuningJob, value); err != nil { + return err + } + case "ModelPackage": if err := awsAwsjson11_deserializeDocumentModelPackage(&sv.ModelPackage, value); err != nil { return err diff --git a/service/sagemaker/serializers.go b/service/sagemaker/serializers.go index c9a678151ce..e92a6555d31 100644 --- a/service/sagemaker/serializers.go +++ b/service/sagemaker/serializers.go @@ -15060,6 +15060,11 @@ func awsAwsjson11_serializeDocumentAutoMLJobConfig(v *types.AutoMLJobConfig, val } } + if len(v.Mode) > 0 { + ok := object.Key("Mode") + ok.String(string(v.Mode)) + } + if v.SecurityConfig != nil { ok := object.Key("SecurityConfig") if err := awsAwsjson11_serializeDocumentAutoMLSecurityConfig(v.SecurityConfig, ok); err != nil { @@ -20008,6 +20013,11 @@ func awsAwsjson11_serializeDocumentProductionVariant(v *types.ProductionVariant, ok.String(string(v.AcceleratorType)) } + if v.ContainerStartupHealthCheckTimeoutInSeconds != nil { + ok := object.Key("ContainerStartupHealthCheckTimeoutInSeconds") + ok.Integer(*v.ContainerStartupHealthCheckTimeoutInSeconds) + } + if v.CoreDumpConfig != nil { ok := object.Key("CoreDumpConfig") if err := awsAwsjson11_serializeDocumentProductionVariantCoreDumpConfig(v.CoreDumpConfig, ok); err != nil { @@ -20043,6 +20053,11 @@ func awsAwsjson11_serializeDocumentProductionVariant(v *types.ProductionVariant, ok.String(string(v.InstanceType)) } + if v.ModelDataDownloadTimeoutInSeconds != nil { + ok := object.Key("ModelDataDownloadTimeoutInSeconds") + ok.Integer(*v.ModelDataDownloadTimeoutInSeconds) + } + if v.ModelName != nil { ok := object.Key("ModelName") ok.String(*v.ModelName) @@ -20060,6 +20075,11 @@ func awsAwsjson11_serializeDocumentProductionVariant(v *types.ProductionVariant, ok.String(*v.VariantName) } + if v.VolumeSizeInGB != nil { + ok := object.Key("VolumeSizeInGB") + ok.Integer(*v.VolumeSizeInGB) + } + return nil } diff --git a/service/sagemaker/types/enums.go b/service/sagemaker/types/enums.go index 3de2f57a2d0..e2a24ae4c6e 100644 --- a/service/sagemaker/types/enums.go +++ b/service/sagemaker/types/enums.go @@ -616,6 +616,26 @@ func (AutoMLMetricExtendedEnum) Values() []AutoMLMetricExtendedEnum { } } +type AutoMLMode string + +// Enum values for AutoMLMode +const ( + AutoMLModeAuto AutoMLMode = "AUTO" + AutoMLModeEnsembling AutoMLMode = "ENSEMBLING" + AutoMLModeHyperparameterTuning AutoMLMode = "HYPERPARAMETER_TUNING" +) + +// Values returns all known values for AutoMLMode. Note that this can be expanded +// in the future, and so it is only as up to date as the client. The ordering of +// this slice is not guaranteed to be stable across updates. +func (AutoMLMode) Values() []AutoMLMode { + return []AutoMLMode{ + "AUTO", + "ENSEMBLING", + "HYPERPARAMETER_TUNING", + } +} + type AutoMLS3DataType string // Enum values for AutoMLS3DataType @@ -3528,6 +3548,7 @@ const ( ResourceTypeFeatureGroup ResourceType = "FeatureGroup" ResourceTypeProject ResourceType = "Project" ResourceTypeFeatureMetadata ResourceType = "FeatureMetadata" + ResourceTypeHyperParameterTuningJob ResourceType = "HyperParameterTuningJob" ) // Values returns all known values for ResourceType. Note that this can be expanded @@ -3547,6 +3568,7 @@ func (ResourceType) Values() []ResourceType { "FeatureGroup", "Project", "FeatureMetadata", + "HyperParameterTuningJob", } } diff --git a/service/sagemaker/types/types.go b/service/sagemaker/types/types.go index 735980c8ba3..51d9f5bb107 100644 --- a/service/sagemaker/types/types.go +++ b/service/sagemaker/types/types.go @@ -1707,6 +1707,26 @@ type AutoMLJobConfig struct { // AutoMLDataSplitConfig DataSplitConfig *AutoMLDataSplitConfig + // The method that Autopilot uses to train the data. You can either specify the + // mode manually or let Autopilot choose for you based on the dataset size by + // selecting AUTO. In AUTO mode, Autopilot chooses ENSEMBLING for datasets smaller + // than 100 MB, and HYPERPARAMETER_TUNING for larger ones. The ENSEMBLING mode uses + // a multi-stack ensemble model to predict classification and regression tasks + // directly from your dataset. This machine learning mode combines several base + // models to produce an optimal predictive model. It then uses a stacking ensemble + // method to combine predictions from contributing members. A multi-stack ensemble + // model can provide better performance over a single model by combining the + // predictive capabilities of multiple models. See Autopilot algorithm support + // (https://docs.aws.amazon.com/sagemaker/latest/dg/autopilot-model-support-validation.html#autopilot-algorithm-suppprt) + // for a list of algorithms supported by ENSEMBLING mode. The HYPERPARAMETER_TUNING + // (HPO) mode uses the best hyperparameters to train the best version of a model. + // HPO will automatically select an algorithm for the type of problem you want to + // solve. Then HPO finds the best hyperparameters according to your objective + // metric. See Autopilot algorithm support + // (https://docs.aws.amazon.com/sagemaker/latest/dg/autopilot-model-support-validation.html#autopilot-algorithm-suppprt) + // for a list of algorithms supported by HYPERPARAMETER_TUNING mode. + Mode AutoMLMode + // The security configuration for traffic encryption or Amazon VPC settings. SecurityConfig *AutoMLSecurityConfig @@ -6249,6 +6269,77 @@ type HyperParameterTuningJobObjective struct { noSmithyDocumentSerde } +// An entity having characteristics over which a user can search for a +// hyperparameter tuning job. +type HyperParameterTuningJobSearchEntity struct { + + // The container for the summary information about a training job. + BestTrainingJob *HyperParameterTrainingJobSummary + + // The time that a hyperparameter tuning job was created. + CreationTime *time.Time + + // The error that was created when a hyperparameter tuning job failed. + FailureReason *string + + // The time that a hyperparameter tuning job ended. + HyperParameterTuningEndTime *time.Time + + // The Amazon Resource Name (ARN) of a hyperparameter tuning job. + HyperParameterTuningJobArn *string + + // Configures a hyperparameter tuning job. + HyperParameterTuningJobConfig *HyperParameterTuningJobConfig + + // The name of a hyperparameter tuning job. + HyperParameterTuningJobName *string + + // The status of a hyperparameter tuning job. + HyperParameterTuningJobStatus HyperParameterTuningJobStatus + + // The time that a hyperparameter tuning job was last modified. + LastModifiedTime *time.Time + + // Specifies the number of training jobs that this hyperparameter tuning job + // launched, categorized by the status of their objective metric. The objective + // metric status shows whether the final objective metric for the training job has + // been evaluated by the tuning job and used in the hyperparameter tuning process. + ObjectiveStatusCounters *ObjectiveStatusCounters + + // The container for the summary information about a training job. + OverallBestTrainingJob *HyperParameterTrainingJobSummary + + // The tags associated with a hyperparameter tuning job. For more information see + // Tagging Amazon Web Services resources + // (https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html). + Tags []Tag + + // Defines the training jobs launched by a hyperparameter tuning job. + TrainingJobDefinition *HyperParameterTrainingJobDefinition + + // The job definitions included in a hyperparameter tuning job. + TrainingJobDefinitions []HyperParameterTrainingJobDefinition + + // The numbers of training jobs launched by a hyperparameter tuning job, + // categorized by status. + TrainingJobStatusCounters *TrainingJobStatusCounters + + // Specifies the configuration for a hyperparameter tuning job that uses one or + // more previous hyperparameter tuning jobs as a starting point. The results of + // previous tuning jobs are used to inform which combinations of hyperparameters to + // search over in the new tuning job. All training jobs launched by the new + // hyperparameter tuning job are evaluated by using the objective metric, and the + // training job that performs the best is compared to the best training jobs from + // the parent tuning jobs. From these, the training job that performs the best as + // measured by the objective metric is returned as the overall best training job. + // All training jobs launched by parent hyperparameter tuning jobs and the new + // hyperparameter tuning jobs count against the limit of training jobs for the + // tuning job. + WarmStartConfig *HyperParameterTuningJobWarmStartConfig + + noSmithyDocumentSerde +} + // Provides summary information about a hyperparameter tuning job. type HyperParameterTuningJobSummary struct { @@ -10304,6 +10395,12 @@ type ProductionVariant struct { // (https://docs.aws.amazon.com/sagemaker/latest/dg/ei.html). AcceleratorType ProductionVariantAcceleratorType + // The timeout value, in seconds, for your inference container to pass health check + // by SageMaker Hosting. For more information about health check, see How Your + // Container Should Respond to Health Check (Ping) Requests + // (https://docs.aws.amazon.com/sagemaker/latest/dg/your-algorithms-inference-code.html#your-algorithms-inference-algo-ping-requests). + ContainerStartupHealthCheckTimeoutInSeconds *int32 + // Specifies configuration for a core dump from the model container when the // process crashes. CoreDumpConfig *ProductionVariantCoreDumpConfig @@ -10320,10 +10417,20 @@ type ProductionVariant struct { // The ML compute instance type. InstanceType ProductionVariantInstanceType + // The timeout value, in seconds, to download and extract the model that you want + // to host from Amazon S3 to the individual inference instance associated with this + // production variant. + ModelDataDownloadTimeoutInSeconds *int32 + // The serverless configuration for an endpoint. Specifies a serverless endpoint // configuration instead of an instance-based endpoint configuration. ServerlessConfig *ProductionVariantServerlessConfig + // The size, in GB, of the ML storage volume attached to individual inference + // instance associated with the production variant. Currenly only Amazon EBS gp2 + // storage volumes are supported. + VolumeSizeInGB *int32 + noSmithyDocumentSerde } @@ -11724,6 +11831,9 @@ type SearchRecord struct { // The feature metadata used to search through the features. FeatureMetadata *FeatureMetadata + // The properties of a hyperparameter tuning job. + HyperParameterTuningJob *HyperParameterTuningJobSearchEntity + // A versioned model that can be deployed for SageMaker inference. ModelPackage *ModelPackage diff --git a/service/sns/api_op_CreateTopic.go b/service/sns/api_op_CreateTopic.go index fc57d689f29..cc51ec20582 100644 --- a/service/sns/api_op_CreateTopic.go +++ b/service/sns/api_op_CreateTopic.go @@ -95,6 +95,11 @@ type CreateTopicInput struct { // specify a value for the MessageDeduplicationId parameter for the Publish action. Attributes map[string]string + // The body of the policy document you want to use for this topic. You can only add + // one policy per topic. The policy must be in JSON string format. Length + // Constraints: Maximum length of 30,720. + DataProtectionPolicy *string + // The list of tags to add to a new topic. To be able to tag a topic on creation, // you must have the sns:CreateTopic and sns:TagResource permissions. Tags []types.Tag diff --git a/service/sns/api_op_GetDataProtectionPolicy.go b/service/sns/api_op_GetDataProtectionPolicy.go new file mode 100644 index 00000000000..425c0fcdc17 --- /dev/null +++ b/service/sns/api_op_GetDataProtectionPolicy.go @@ -0,0 +1,124 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package sns + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Retrieves the specified inline DataProtectionPolicy document that is stored in +// the specified Amazon SNS topic. +func (c *Client) GetDataProtectionPolicy(ctx context.Context, params *GetDataProtectionPolicyInput, optFns ...func(*Options)) (*GetDataProtectionPolicyOutput, error) { + if params == nil { + params = &GetDataProtectionPolicyInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "GetDataProtectionPolicy", params, optFns, c.addOperationGetDataProtectionPolicyMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*GetDataProtectionPolicyOutput) + out.ResultMetadata = metadata + return out, nil +} + +type GetDataProtectionPolicyInput struct { + + // The ARN of the topic whose DataProtectionPolicy you want to get. For more + // information about ARNs, see Amazon Resource Names (ARNs) + // (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) in + // the Amazon Web Services General Reference. + // + // This member is required. + ResourceArn *string + + noSmithyDocumentSerde +} + +type GetDataProtectionPolicyOutput struct { + + // Retrieves the DataProtectionPolicy in JSON string format. + DataProtectionPolicy *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationGetDataProtectionPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsquery_serializeOpGetDataProtectionPolicy{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsquery_deserializeOpGetDataProtectionPolicy{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpGetDataProtectionPolicyValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetDataProtectionPolicy(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opGetDataProtectionPolicy(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "sns", + OperationName: "GetDataProtectionPolicy", + } +} diff --git a/service/sns/api_op_PutDataProtectionPolicy.go b/service/sns/api_op_PutDataProtectionPolicy.go new file mode 100644 index 00000000000..34a3819f87f --- /dev/null +++ b/service/sns/api_op_PutDataProtectionPolicy.go @@ -0,0 +1,127 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package sns + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Adds or updates an inline policy document that is stored in the specified Amazon +// SNS topic. +func (c *Client) PutDataProtectionPolicy(ctx context.Context, params *PutDataProtectionPolicyInput, optFns ...func(*Options)) (*PutDataProtectionPolicyOutput, error) { + if params == nil { + params = &PutDataProtectionPolicyInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "PutDataProtectionPolicy", params, optFns, c.addOperationPutDataProtectionPolicyMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*PutDataProtectionPolicyOutput) + out.ResultMetadata = metadata + return out, nil +} + +type PutDataProtectionPolicyInput struct { + + // The JSON serialization of the topic's DataProtectionPolicy. The + // DataProtectionPolicy must be in JSON string format. Length Constraints: Maximum + // length of 30,720. + // + // This member is required. + DataProtectionPolicy *string + + // The ARN of the topic whose DataProtectionPolicy you want to add or update. For + // more information about ARNs, see Amazon Resource Names (ARNs) + // (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) in + // the Amazon Web Services General Reference. + // + // This member is required. + ResourceArn *string + + noSmithyDocumentSerde +} + +type PutDataProtectionPolicyOutput struct { + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationPutDataProtectionPolicyMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsquery_serializeOpPutDataProtectionPolicy{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsquery_deserializeOpPutDataProtectionPolicy{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpPutDataProtectionPolicyValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opPutDataProtectionPolicy(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opPutDataProtectionPolicy(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "sns", + OperationName: "PutDataProtectionPolicy", + } +} diff --git a/service/sns/deserializers.go b/service/sns/deserializers.go index ef4c0844371..329c856579e 100644 --- a/service/sns/deserializers.go +++ b/service/sns/deserializers.go @@ -1203,6 +1203,126 @@ func awsAwsquery_deserializeOpErrorDeleteTopic(response *smithyhttp.Response, me } } +type awsAwsquery_deserializeOpGetDataProtectionPolicy struct { +} + +func (*awsAwsquery_deserializeOpGetDataProtectionPolicy) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsquery_deserializeOpGetDataProtectionPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsAwsquery_deserializeOpErrorGetDataProtectionPolicy(response, &metadata) + } + output := &GetDataProtectionPolicyOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + body := io.TeeReader(response.Body, ringBuffer) + rootDecoder := xml.NewDecoder(body) + t, err := smithyxml.FetchRootElement(rootDecoder) + if err == io.EOF { + return out, metadata, nil + } + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + } + + decoder := smithyxml.WrapNodeDecoder(rootDecoder, t) + t, err = decoder.GetElement("GetDataProtectionPolicyResult") + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + decoder = smithyxml.WrapNodeDecoder(decoder.Decoder, t) + err = awsAwsquery_deserializeOpDocumentGetDataProtectionPolicyOutput(&output, decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsAwsquery_deserializeOpErrorGetDataProtectionPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := awsxml.GetErrorResponseComponents(errorBody, false) + if err != nil { + return err + } + if reqID := errorComponents.RequestID; len(reqID) != 0 { + awsmiddleware.SetRequestIDMetadata(metadata, reqID) + } + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + case strings.EqualFold("AuthorizationError", errorCode): + return awsAwsquery_deserializeErrorAuthorizationErrorException(response, errorBody) + + case strings.EqualFold("InternalError", errorCode): + return awsAwsquery_deserializeErrorInternalErrorException(response, errorBody) + + case strings.EqualFold("InvalidParameter", errorCode): + return awsAwsquery_deserializeErrorInvalidParameterException(response, errorBody) + + case strings.EqualFold("InvalidSecurity", errorCode): + return awsAwsquery_deserializeErrorInvalidSecurityException(response, errorBody) + + case strings.EqualFold("NotFound", errorCode): + return awsAwsquery_deserializeErrorNotFoundException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + type awsAwsquery_deserializeOpGetEndpointAttributes struct { } @@ -3212,6 +3332,9 @@ func awsAwsquery_deserializeOpErrorPublish(response *smithyhttp.Response, metada case strings.EqualFold("PlatformApplicationDisabled", errorCode): return awsAwsquery_deserializeErrorPlatformApplicationDisabledException(response, errorBody) + case strings.EqualFold("ValidationException", errorCode): + return awsAwsquery_deserializeErrorValidationException(response, errorBody) + default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -3374,6 +3497,94 @@ func awsAwsquery_deserializeOpErrorPublishBatch(response *smithyhttp.Response, m case strings.EqualFold("TooManyEntriesInBatchRequest", errorCode): return awsAwsquery_deserializeErrorTooManyEntriesInBatchRequestException(response, errorBody) + case strings.EqualFold("ValidationException", errorCode): + return awsAwsquery_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsquery_deserializeOpPutDataProtectionPolicy struct { +} + +func (*awsAwsquery_deserializeOpPutDataProtectionPolicy) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsquery_deserializeOpPutDataProtectionPolicy) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsAwsquery_deserializeOpErrorPutDataProtectionPolicy(response, &metadata) + } + output := &PutDataProtectionPolicyOutput{} + out.Result = output + + if _, err = io.Copy(ioutil.Discard, response.Body); err != nil { + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to discard response body, %w", err), + } + } + + return out, metadata, err +} + +func awsAwsquery_deserializeOpErrorPutDataProtectionPolicy(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + errorComponents, err := awsxml.GetErrorResponseComponents(errorBody, false) + if err != nil { + return err + } + if reqID := errorComponents.RequestID; len(reqID) != 0 { + awsmiddleware.SetRequestIDMetadata(metadata, reqID) + } + if len(errorComponents.Code) != 0 { + errorCode = errorComponents.Code + } + if len(errorComponents.Message) != 0 { + errorMessage = errorComponents.Message + } + errorBody.Seek(0, io.SeekStart) + switch { + case strings.EqualFold("AuthorizationError", errorCode): + return awsAwsquery_deserializeErrorAuthorizationErrorException(response, errorBody) + + case strings.EqualFold("InternalError", errorCode): + return awsAwsquery_deserializeErrorInternalErrorException(response, errorBody) + + case strings.EqualFold("InvalidParameter", errorCode): + return awsAwsquery_deserializeErrorInvalidParameterException(response, errorBody) + + case strings.EqualFold("InvalidSecurity", errorCode): + return awsAwsquery_deserializeErrorInvalidSecurityException(response, errorBody) + + case strings.EqualFold("NotFound", errorCode): + return awsAwsquery_deserializeErrorNotFoundException(response, errorBody) + default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -9539,6 +9750,55 @@ func awsAwsquery_deserializeOpDocumentDeleteSMSSandboxPhoneNumberOutput(v **Dele return nil } +func awsAwsquery_deserializeOpDocumentGetDataProtectionPolicyOutput(v **GetDataProtectionPolicyOutput, decoder smithyxml.NodeDecoder) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + var sv *GetDataProtectionPolicyOutput + if *v == nil { + sv = &GetDataProtectionPolicyOutput{} + } else { + sv = *v + } + + for { + t, done, err := decoder.Token() + if err != nil { + return err + } + if done { + break + } + originalDecoder := decoder + decoder = smithyxml.WrapNodeDecoder(originalDecoder.Decoder, t) + switch { + case strings.EqualFold("DataProtectionPolicy", t.Name.Local): + val, err := decoder.Value() + if err != nil { + return err + } + if val == nil { + break + } + { + xtv := string(val) + sv.DataProtectionPolicy = ptr.String(xtv) + } + + default: + // Do nothing and ignore the unexpected tag element + err = decoder.Decoder.Skip() + if err != nil { + return err + } + + } + decoder = originalDecoder + } + *v = sv + return nil +} + func awsAwsquery_deserializeOpDocumentGetEndpointAttributesOutput(v **GetEndpointAttributesOutput, decoder smithyxml.NodeDecoder) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/sns/generated.json b/service/sns/generated.json index fa80a5cd417..19a553b38a8 100644 --- a/service/sns/generated.json +++ b/service/sns/generated.json @@ -19,6 +19,7 @@ "api_op_DeletePlatformApplication.go", "api_op_DeleteSMSSandboxPhoneNumber.go", "api_op_DeleteTopic.go", + "api_op_GetDataProtectionPolicy.go", "api_op_GetEndpointAttributes.go", "api_op_GetPlatformApplicationAttributes.go", "api_op_GetSMSAttributes.go", @@ -37,6 +38,7 @@ "api_op_OptInPhoneNumber.go", "api_op_Publish.go", "api_op_PublishBatch.go", + "api_op_PutDataProtectionPolicy.go", "api_op_RemovePermission.go", "api_op_SetEndpointAttributes.go", "api_op_SetPlatformApplicationAttributes.go", diff --git a/service/sns/serializers.go b/service/sns/serializers.go index f815607b79f..5c804c83a91 100644 --- a/service/sns/serializers.go +++ b/service/sns/serializers.go @@ -720,6 +720,70 @@ func (m *awsAwsquery_serializeOpDeleteTopic) HandleSerialize(ctx context.Context return next.HandleSerialize(ctx, in) } +type awsAwsquery_serializeOpGetDataProtectionPolicy struct { +} + +func (*awsAwsquery_serializeOpGetDataProtectionPolicy) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsquery_serializeOpGetDataProtectionPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*GetDataProtectionPolicyInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("GetDataProtectionPolicy") + body.Key("Version").String("2010-03-31") + + if err := awsAwsquery_serializeOpDocumentGetDataProtectionPolicyInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsAwsquery_serializeOpGetEndpointAttributes struct { } @@ -1868,6 +1932,70 @@ func (m *awsAwsquery_serializeOpPublishBatch) HandleSerialize(ctx context.Contex return next.HandleSerialize(ctx, in) } +type awsAwsquery_serializeOpPutDataProtectionPolicy struct { +} + +func (*awsAwsquery_serializeOpPutDataProtectionPolicy) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsquery_serializeOpPutDataProtectionPolicy) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*PutDataProtectionPolicyInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-www-form-urlencoded") + + bodyWriter := bytes.NewBuffer(nil) + bodyEncoder := query.NewEncoder(bodyWriter) + body := bodyEncoder.Object() + body.Key("Action").String("PutDataProtectionPolicy") + body.Key("Version").String("2010-03-31") + + if err := awsAwsquery_serializeOpDocumentPutDataProtectionPolicyInput(input, bodyEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + err = bodyEncoder.Encode() + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(bodyWriter.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsAwsquery_serializeOpRemovePermission struct { } @@ -2961,6 +3089,11 @@ func awsAwsquery_serializeOpDocumentCreateTopicInput(v *CreateTopicInput, value } } + if v.DataProtectionPolicy != nil { + objectKey := object.Key("DataProtectionPolicy") + objectKey.String(*v.DataProtectionPolicy) + } + if v.Name != nil { objectKey := object.Key("Name") objectKey.String(*v.Name) @@ -3024,6 +3157,18 @@ func awsAwsquery_serializeOpDocumentDeleteTopicInput(v *DeleteTopicInput, value return nil } +func awsAwsquery_serializeOpDocumentGetDataProtectionPolicyInput(v *GetDataProtectionPolicyInput, value query.Value) error { + object := value.Object() + _ = object + + if v.ResourceArn != nil { + objectKey := object.Key("ResourceArn") + objectKey.String(*v.ResourceArn) + } + + return nil +} + func awsAwsquery_serializeOpDocumentGetEndpointAttributesInput(v *GetEndpointAttributesInput, value query.Value) error { object := value.Object() _ = object @@ -3306,6 +3451,23 @@ func awsAwsquery_serializeOpDocumentPublishInput(v *PublishInput, value query.Va return nil } +func awsAwsquery_serializeOpDocumentPutDataProtectionPolicyInput(v *PutDataProtectionPolicyInput, value query.Value) error { + object := value.Object() + _ = object + + if v.DataProtectionPolicy != nil { + objectKey := object.Key("DataProtectionPolicy") + objectKey.String(*v.DataProtectionPolicy) + } + + if v.ResourceArn != nil { + objectKey := object.Key("ResourceArn") + objectKey.String(*v.ResourceArn) + } + + return nil +} + func awsAwsquery_serializeOpDocumentRemovePermissionInput(v *RemovePermissionInput, value query.Value) error { object := value.Object() _ = object diff --git a/service/sns/validators.go b/service/sns/validators.go index 63093228547..b0ae18bbd01 100644 --- a/service/sns/validators.go +++ b/service/sns/validators.go @@ -230,6 +230,26 @@ func (m *validateOpDeleteTopic) HandleInitialize(ctx context.Context, in middlew return next.HandleInitialize(ctx, in) } +type validateOpGetDataProtectionPolicy struct { +} + +func (*validateOpGetDataProtectionPolicy) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpGetDataProtectionPolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*GetDataProtectionPolicyInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpGetDataProtectionPolicyInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpGetEndpointAttributes struct { } @@ -430,6 +450,26 @@ func (m *validateOpPublish) HandleInitialize(ctx context.Context, in middleware. return next.HandleInitialize(ctx, in) } +type validateOpPutDataProtectionPolicy struct { +} + +func (*validateOpPutDataProtectionPolicy) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpPutDataProtectionPolicy) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*PutDataProtectionPolicyInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpPutDataProtectionPolicyInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpRemovePermission struct { } @@ -694,6 +734,10 @@ func addOpDeleteTopicValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDeleteTopic{}, middleware.After) } +func addOpGetDataProtectionPolicyValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpGetDataProtectionPolicy{}, middleware.After) +} + func addOpGetEndpointAttributesValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpGetEndpointAttributes{}, middleware.After) } @@ -734,6 +778,10 @@ func addOpPublishValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpPublish{}, middleware.After) } +func addOpPutDataProtectionPolicyValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpPutDataProtectionPolicy{}, middleware.After) +} + func addOpRemovePermissionValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpRemovePermission{}, middleware.After) } @@ -1077,6 +1125,21 @@ func validateOpDeleteTopicInput(v *DeleteTopicInput) error { } } +func validateOpGetDataProtectionPolicyInput(v *GetDataProtectionPolicyInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "GetDataProtectionPolicyInput"} + if v.ResourceArn == nil { + invalidParams.Add(smithy.NewErrParamRequired("ResourceArn")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpGetEndpointAttributesInput(v *GetEndpointAttributesInput) error { if v == nil { return nil @@ -1239,6 +1302,24 @@ func validateOpPublishInput(v *PublishInput) error { } } +func validateOpPutDataProtectionPolicyInput(v *PutDataProtectionPolicyInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "PutDataProtectionPolicyInput"} + if v.ResourceArn == nil { + invalidParams.Add(smithy.NewErrParamRequired("ResourceArn")) + } + if v.DataProtectionPolicy == nil { + invalidParams.Add(smithy.NewErrParamRequired("DataProtectionPolicy")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpRemovePermissionInput(v *RemovePermissionInput) error { if v == nil { return nil diff --git a/service/ssm/api_op_CreateAssociation.go b/service/ssm/api_op_CreateAssociation.go index 2a50832b116..3870de13fc8 100644 --- a/service/ssm/api_op_CreateAssociation.go +++ b/service/ssm/api_op_CreateAssociation.go @@ -155,6 +155,13 @@ type CreateAssociationInput struct { // associations use AUTO mode. SyncCompliance types.AssociationSyncCompliance + // Adds or overwrites one or more tags for a State Manager association. Tags are + // metadata that you can assign to your Amazon Web Services resources. Tags enable + // you to categorize your resources in different ways, for example, by purpose, + // owner, or environment. Each tag consists of a key and an optional value, both of + // which you define. + Tags []types.Tag + // A location is a combination of Amazon Web Services Regions and Amazon Web // Services accounts where you want to run the association. Use this action to // create an association in multiple Regions and multiple accounts. diff --git a/service/ssm/api_op_CreateDocument.go b/service/ssm/api_op_CreateDocument.go index 04fb38e2e8d..46d4962783d 100644 --- a/service/ssm/api_op_CreateDocument.go +++ b/service/ssm/api_op_CreateDocument.go @@ -58,7 +58,7 @@ type CreateDocumentInput struct { // name prefixes. These are reserved by Amazon Web Services for use as document // name prefixes: // - // * aws- + // * aws // // * amazon // diff --git a/service/ssm/api_op_DescribeInstanceInformation.go b/service/ssm/api_op_DescribeInstanceInformation.go index e201d6e4d51..d8fcc0adbac 100644 --- a/service/ssm/api_op_DescribeInstanceInformation.go +++ b/service/ssm/api_op_DescribeInstanceInformation.go @@ -39,8 +39,8 @@ func (c *Client) DescribeInstanceInformation(ctx context.Context, params *Descri type DescribeInstanceInformationInput struct { // One or more filters. Use a filter to return a more specific list of managed - // nodes. You can filter based on tags applied to EC2 instances. Use this Filters - // data type instead of InstanceInformationFilterList, which is deprecated. + // nodes. You can filter based on tags applied to your managed nodes. Use this + // Filters data type instead of InstanceInformationFilterList, which is deprecated. Filters []types.InstanceInformationStringFilter // This is a legacy method. We recommend that you don't use this method. Instead, diff --git a/service/ssm/api_op_SendCommand.go b/service/ssm/api_op_SendCommand.go index c9c4c5b119b..a89ce8624e8 100644 --- a/service/ssm/api_op_SendCommand.go +++ b/service/ssm/api_op_SendCommand.go @@ -115,7 +115,11 @@ type SendCommandInput struct { // The ARN of the Identity and Access Management (IAM) service role to use to // publish Amazon Simple Notification Service (Amazon SNS) notifications for Run - // Command commands. + // Command commands. This role must provide the sns:Publish permission for your + // notification topic. For information about creating and using this service role, + // see Monitoring Systems Manager status changes using Amazon SNS notifications + // (https://docs.aws.amazon.com/systems-manager/latest/userguide/monitoring-sns-notifications.html) + // in the Amazon Web Services Systems Manager User Guide. ServiceRoleArn *string // An array of search criteria that targets managed nodes using a Key,Value diff --git a/service/ssm/api_op_StartSession.go b/service/ssm/api_op_StartSession.go index a4beca2f0ed..ae93b8cdec7 100644 --- a/service/ssm/api_op_StartSession.go +++ b/service/ssm/api_op_StartSession.go @@ -80,8 +80,10 @@ type StartSessionOutput struct { // Manager session, such as 1a2b3c4dEXAMPLE. StreamUrl *string - // An encrypted token value containing session and caller information. Used to - // authenticate the connection to the managed node. + // An encrypted token value containing session and caller information. This token + // is used to authenticate the connection to the managed node, and is valid only + // long enough to ensure the connection is successful. Never share your session's + // token. TokenValue *string // Metadata pertaining to the operation's result. diff --git a/service/ssm/deserializers.go b/service/ssm/deserializers.go index 3cccb6f726e..e7121275d36 100644 --- a/service/ssm/deserializers.go +++ b/service/ssm/deserializers.go @@ -739,6 +739,9 @@ func awsAwsjson11_deserializeOpErrorCreateAssociation(response *smithyhttp.Respo case strings.EqualFold("InvalidSchedule", errorCode): return awsAwsjson11_deserializeErrorInvalidSchedule(response, errorBody) + case strings.EqualFold("InvalidTag", errorCode): + return awsAwsjson11_deserializeErrorInvalidTag(response, errorBody) + case strings.EqualFold("InvalidTarget", errorCode): return awsAwsjson11_deserializeErrorInvalidTarget(response, errorBody) @@ -18655,6 +18658,41 @@ func awsAwsjson11_deserializeErrorInvalidSchedule(response *smithyhttp.Response, return output } +func awsAwsjson11_deserializeErrorInvalidTag(response *smithyhttp.Response, errorBody *bytes.Reader) error { + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + output := &types.InvalidTag{} + err := awsAwsjson11_deserializeDocumentInvalidTag(&output, shape) + + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + return output +} + func awsAwsjson11_deserializeErrorInvalidTarget(response *smithyhttp.Response, errorBody *bytes.Reader) error { var buff [1024]byte ringBuffer := smithyio.NewRingBuffer(buff[:]) @@ -29429,6 +29467,46 @@ func awsAwsjson11_deserializeDocumentInvalidSchedule(v **types.InvalidSchedule, return nil } +func awsAwsjson11_deserializeDocumentInvalidTag(v **types.InvalidTag, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.InvalidTag + if *v == nil { + sv = &types.InvalidTag{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "Message": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected String to be of type string, got %T instead", value) + } + sv.Message = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson11_deserializeDocumentInvalidTarget(v **types.InvalidTarget, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/ssm/serializers.go b/service/ssm/serializers.go index e0013a6aaa1..3012c63778e 100644 --- a/service/ssm/serializers.go +++ b/service/ssm/serializers.go @@ -10581,6 +10581,13 @@ func awsAwsjson11_serializeOpDocumentCreateAssociationInput(v *CreateAssociation ok.String(string(v.SyncCompliance)) } + if v.Tags != nil { + ok := object.Key("Tags") + if err := awsAwsjson11_serializeDocumentTagList(v.Tags, ok); err != nil { + return err + } + } + if v.TargetLocations != nil { ok := object.Key("TargetLocations") if err := awsAwsjson11_serializeDocumentTargetLocations(v.TargetLocations, ok); err != nil { diff --git a/service/ssm/types/enums.go b/service/ssm/types/enums.go index 4ede68f9764..e6527cc38a4 100644 --- a/service/ssm/types/enums.go +++ b/service/ssm/types/enums.go @@ -1770,6 +1770,7 @@ const ( ResourceTypeForTaggingOpsItem ResourceTypeForTagging = "OpsItem" ResourceTypeForTaggingOpsmetadata ResourceTypeForTagging = "OpsMetadata" ResourceTypeForTaggingAutomation ResourceTypeForTagging = "Automation" + ResourceTypeForTaggingAssociation ResourceTypeForTagging = "Association" ) // Values returns all known values for ResourceTypeForTagging. Note that this can @@ -1785,6 +1786,7 @@ func (ResourceTypeForTagging) Values() []ResourceTypeForTagging { "OpsItem", "OpsMetadata", "Automation", + "Association", } } diff --git a/service/ssm/types/errors.go b/service/ssm/types/errors.go index e335ea9ebe3..39368ebaa43 100644 --- a/service/ssm/types/errors.go +++ b/service/ssm/types/errors.go @@ -1531,6 +1531,25 @@ func (e *InvalidSchedule) ErrorMessage() string { func (e *InvalidSchedule) ErrorCode() string { return "InvalidSchedule" } func (e *InvalidSchedule) ErrorFault() smithy.ErrorFault { return smithy.FaultClient } +// The specified tag key or value is not valid. +type InvalidTag struct { + Message *string + + noSmithyDocumentSerde +} + +func (e *InvalidTag) Error() string { + return fmt.Sprintf("%s: %s", e.ErrorCode(), e.ErrorMessage()) +} +func (e *InvalidTag) ErrorMessage() string { + if e.Message == nil { + return "" + } + return *e.Message +} +func (e *InvalidTag) ErrorCode() string { return "InvalidTag" } +func (e *InvalidTag) ErrorFault() smithy.ErrorFault { return smithy.FaultClient } + // The target isn't valid or doesn't exist. It might not be configured for Systems // Manager or you might not have permission to perform the operation. type InvalidTarget struct { diff --git a/service/ssm/types/types.go b/service/ssm/types/types.go index fca3a690ad2..70dbdb7bcf6 100644 --- a/service/ssm/types/types.go +++ b/service/ssm/types/types.go @@ -2300,12 +2300,12 @@ type InstanceInformationFilter struct { // The filters to describe or get information about your managed nodes. type InstanceInformationStringFilter struct { - // The filter key name to describe your managed nodes. For example: - // "InstanceIds"|"AgentVersion"|"PingStatus"|"PlatformTypes"|"ActivationIds"|"IamRole"|"ResourceType"|"AssociationStatus"|"Tag - // Key" Tag key isn't a valid filter. You must specify either tag-key or - // tag:keyname and a string. Here are some valid examples: tag-key, tag:123, - // tag:al!, tag:Windows. Here are some invalid examples: tag-keys, Tag Key, tag:, - // tagKey, abc:keyname. + // The filter key name to describe your managed nodes. For example: "InstanceIds" | + // "AgentVersion" | "PingStatus" | "PlatformTypes" | "ActivationIds" | "IamRole" | + // "ResourceType" | "AssociationStatus" | "tag-key" | "tag:{keyname}Tag Key isn't a + // valid filter. You must specify either tag-key or tag:{keyname} and a string. + // Here are some valid examples: tag-key, tag:123, tag:al!, tag:Windows. Here are + // some invalid examples: tag-keys, Tag Key, tag:, tagKey, abc:keyname. // // This member is required. Key *string diff --git a/service/ssm/validators.go b/service/ssm/validators.go index b640ff51524..3a59a824809 100644 --- a/service/ssm/validators.go +++ b/service/ssm/validators.go @@ -4452,6 +4452,11 @@ func validateOpCreateAssociationInput(v *CreateAssociationInput) error { if v.Name == nil { invalidParams.Add(smithy.NewErrParamRequired("Name")) } + if v.Tags != nil { + if err := validateTagList(v.Tags); err != nil { + invalidParams.AddNested("Tags", err.(smithy.InvalidParamsError)) + } + } if invalidParams.Len() > 0 { return invalidParams } else { diff --git a/service/transfer/api_op_DeleteHostKey.go b/service/transfer/api_op_DeleteHostKey.go new file mode 100644 index 00000000000..daee9456457 --- /dev/null +++ b/service/transfer/api_op_DeleteHostKey.go @@ -0,0 +1,121 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package transfer + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Deletes the host key that's specified in the HoskKeyId parameter. +func (c *Client) DeleteHostKey(ctx context.Context, params *DeleteHostKeyInput, optFns ...func(*Options)) (*DeleteHostKeyOutput, error) { + if params == nil { + params = &DeleteHostKeyInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DeleteHostKey", params, optFns, c.addOperationDeleteHostKeyMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DeleteHostKeyOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DeleteHostKeyInput struct { + + // The ID of the host key that you are deleting. + // + // This member is required. + HostKeyId *string + + // Provide the ID of the server that contains the host key that you are deleting. + // + // This member is required. + ServerId *string + + noSmithyDocumentSerde +} + +type DeleteHostKeyOutput struct { + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDeleteHostKeyMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson11_serializeOpDeleteHostKey{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDeleteHostKey{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpDeleteHostKeyValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteHostKey(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opDeleteHostKey(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "transfer", + OperationName: "DeleteHostKey", + } +} diff --git a/service/transfer/api_op_DescribeHostKey.go b/service/transfer/api_op_DescribeHostKey.go new file mode 100644 index 00000000000..82bc0c40644 --- /dev/null +++ b/service/transfer/api_op_DescribeHostKey.go @@ -0,0 +1,129 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package transfer + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/transfer/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Returns the details of the host key that's specified by the HostKeyId and +// ServerId. +func (c *Client) DescribeHostKey(ctx context.Context, params *DescribeHostKeyInput, optFns ...func(*Options)) (*DescribeHostKeyOutput, error) { + if params == nil { + params = &DescribeHostKeyInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DescribeHostKey", params, optFns, c.addOperationDescribeHostKeyMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DescribeHostKeyOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DescribeHostKeyInput struct { + + // Provide the ID of the host key that you want described. + // + // This member is required. + HostKeyId *string + + // Provide the ID of the server that contains the host key that you want described. + // + // This member is required. + ServerId *string + + noSmithyDocumentSerde +} + +type DescribeHostKeyOutput struct { + + // Returns the details for the specified host key. + // + // This member is required. + HostKey *types.DescribedHostKey + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDescribeHostKeyMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson11_serializeOpDescribeHostKey{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDescribeHostKey{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpDescribeHostKeyValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeHostKey(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opDescribeHostKey(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "transfer", + OperationName: "DescribeHostKey", + } +} diff --git a/service/transfer/api_op_ImportHostKey.go b/service/transfer/api_op_ImportHostKey.go new file mode 100644 index 00000000000..594650278a6 --- /dev/null +++ b/service/transfer/api_op_ImportHostKey.go @@ -0,0 +1,140 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package transfer + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/transfer/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Adds a host key to the server specified by the ServerId parameter. +func (c *Client) ImportHostKey(ctx context.Context, params *ImportHostKeyInput, optFns ...func(*Options)) (*ImportHostKeyOutput, error) { + if params == nil { + params = &ImportHostKeyInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "ImportHostKey", params, optFns, c.addOperationImportHostKeyMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*ImportHostKeyOutput) + out.ResultMetadata = metadata + return out, nil +} + +type ImportHostKeyInput struct { + + // The public key portion of an SSH key pair. Transfer Family accepts RSA, ECDSA, + // and ED25519 keys. + // + // This member is required. + HostKeyBody *string + + // Provide the ID of the server that contains the host key that you are importing. + // + // This member is required. + ServerId *string + + // Enter a text description to identify this host key. + Description *string + + // Key-value pairs that can be used to group and search for host keys. + Tags []types.Tag + + noSmithyDocumentSerde +} + +type ImportHostKeyOutput struct { + + // Returns the host key ID for the imported key. + // + // This member is required. + HostKeyId *string + + // Returns the server ID that contains the imported key. + // + // This member is required. + ServerId *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationImportHostKeyMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson11_serializeOpImportHostKey{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpImportHostKey{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpImportHostKeyValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opImportHostKey(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opImportHostKey(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "transfer", + OperationName: "ImportHostKey", + } +} diff --git a/service/transfer/api_op_ListHostKeys.go b/service/transfer/api_op_ListHostKeys.go new file mode 100644 index 00000000000..430f5361933 --- /dev/null +++ b/service/transfer/api_op_ListHostKeys.go @@ -0,0 +1,140 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package transfer + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/aws-sdk-go-v2/service/transfer/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Returns a list of host keys for the server specified by the ServerId paramter. +func (c *Client) ListHostKeys(ctx context.Context, params *ListHostKeysInput, optFns ...func(*Options)) (*ListHostKeysOutput, error) { + if params == nil { + params = &ListHostKeysInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "ListHostKeys", params, optFns, c.addOperationListHostKeysMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*ListHostKeysOutput) + out.ResultMetadata = metadata + return out, nil +} + +type ListHostKeysInput struct { + + // Provide the ID of the server that contains the host keys that you want to view. + // + // This member is required. + ServerId *string + + // The maximum number of host keys to return. + MaxResults *int32 + + // When there are additional results that were not returned, a NextToken parameter + // is returned. You can use that value for a subsequent call to ListHostKeys to + // continue listing results. + NextToken *string + + noSmithyDocumentSerde +} + +type ListHostKeysOutput struct { + + // Returns an array, where each item contains the details of a host key. + // + // This member is required. + HostKeys []types.ListedHostKey + + // Returns the server ID that contains the listed host keys. + // + // This member is required. + ServerId *string + + // Returns a token that you can use to call ListHostKeys again and receive + // additional results, if there are any. + NextToken *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationListHostKeysMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson11_serializeOpListHostKeys{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpListHostKeys{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpListHostKeysValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opListHostKeys(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opListHostKeys(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "transfer", + OperationName: "ListHostKeys", + } +} diff --git a/service/transfer/api_op_UpdateHostKey.go b/service/transfer/api_op_UpdateHostKey.go new file mode 100644 index 00000000000..6dc239c80a9 --- /dev/null +++ b/service/transfer/api_op_UpdateHostKey.go @@ -0,0 +1,138 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package transfer + +import ( + "context" + awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" + "github.com/aws/aws-sdk-go-v2/aws/signer/v4" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Updates the description for the host key specified by the specified by the +// ServerId and HostKeyId parameters. +func (c *Client) UpdateHostKey(ctx context.Context, params *UpdateHostKeyInput, optFns ...func(*Options)) (*UpdateHostKeyOutput, error) { + if params == nil { + params = &UpdateHostKeyInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "UpdateHostKey", params, optFns, c.addOperationUpdateHostKeyMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*UpdateHostKeyOutput) + out.ResultMetadata = metadata + return out, nil +} + +type UpdateHostKeyInput struct { + + // Provide an updated description for the host key. + // + // This member is required. + Description *string + + // Provide the ID of the host key that you are updating. + // + // This member is required. + HostKeyId *string + + // Provide the ID of the server that contains the host key that you are updating. + // + // This member is required. + ServerId *string + + noSmithyDocumentSerde +} + +type UpdateHostKeyOutput struct { + + // Returns the host key ID for the updated host key. + // + // This member is required. + HostKeyId *string + + // Returns the server ID for the server that contains the updated host key. + // + // This member is required. + ServerId *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationUpdateHostKeyMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson11_serializeOpUpdateHostKey{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpUpdateHostKey{}, middleware.After) + if err != nil { + return err + } + if err = addSetLoggerMiddleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { + return err + } + if err = addResolveEndpointMiddleware(stack, options); err != nil { + return err + } + if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { + return err + } + if err = addRetryMiddlewares(stack, options); err != nil { + return err + } + if err = addHTTPSignerV4Middleware(stack, options); err != nil { + return err + } + if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { + return err + } + if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { + return err + } + if err = addClientUserAgent(stack); err != nil { + return err + } + if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { + return err + } + if err = addOpUpdateHostKeyValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opUpdateHostKey(options.Region), middleware.Before); err != nil { + return err + } + if err = addRequestIDRetrieverMiddleware(stack); err != nil { + return err + } + if err = addResponseErrorMiddleware(stack); err != nil { + return err + } + if err = addRequestResponseLogging(stack, options); err != nil { + return err + } + return nil +} + +func newServiceMetadataMiddleware_opUpdateHostKey(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "transfer", + OperationName: "UpdateHostKey", + } +} diff --git a/service/transfer/deserializers.go b/service/transfer/deserializers.go index 6d96cabce20..8eb5537558e 100644 --- a/service/transfer/deserializers.go +++ b/service/transfer/deserializers.go @@ -1279,6 +1279,107 @@ func awsAwsjson11_deserializeOpErrorDeleteConnector(response *smithyhttp.Respons } } +type awsAwsjson11_deserializeOpDeleteHostKey struct { +} + +func (*awsAwsjson11_deserializeOpDeleteHostKey) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson11_deserializeOpDeleteHostKey) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsAwsjson11_deserializeOpErrorDeleteHostKey(response, &metadata) + } + output := &DeleteHostKeyOutput{} + out.Result = output + + if _, err = io.Copy(ioutil.Discard, response.Body); err != nil { + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to discard response body, %w", err), + } + } + + return out, metadata, err +} + +func awsAwsjson11_deserializeOpErrorDeleteHostKey(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InternalServiceError", errorCode): + return awsAwsjson11_deserializeErrorInternalServiceError(response, errorBody) + + case strings.EqualFold("InvalidRequestException", errorCode): + return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ServiceUnavailableException", errorCode): + return awsAwsjson11_deserializeErrorServiceUnavailableException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson11_deserializeErrorThrottlingException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + type awsAwsjson11_deserializeOpDeleteProfile struct { } @@ -2378,6 +2479,126 @@ func awsAwsjson11_deserializeOpErrorDescribeExecution(response *smithyhttp.Respo } } +type awsAwsjson11_deserializeOpDescribeHostKey struct { +} + +func (*awsAwsjson11_deserializeOpDescribeHostKey) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson11_deserializeOpDescribeHostKey) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsAwsjson11_deserializeOpErrorDescribeHostKey(response, &metadata) + } + output := &DescribeHostKeyOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsAwsjson11_deserializeOpDocumentDescribeHostKeyOutput(&output, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsAwsjson11_deserializeOpErrorDescribeHostKey(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InternalServiceError", errorCode): + return awsAwsjson11_deserializeErrorInternalServiceError(response, errorBody) + + case strings.EqualFold("InvalidRequestException", errorCode): + return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ServiceUnavailableException", errorCode): + return awsAwsjson11_deserializeErrorServiceUnavailableException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + type awsAwsjson11_deserializeOpDescribeProfile struct { } @@ -2745,7 +2966,247 @@ func (*awsAwsjson11_deserializeOpDescribeUser) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpDescribeUser) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpDescribeUser) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsAwsjson11_deserializeOpErrorDescribeUser(response, &metadata) + } + output := &DescribeUserOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsAwsjson11_deserializeOpDocumentDescribeUserOutput(&output, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsAwsjson11_deserializeOpErrorDescribeUser(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InternalServiceError", errorCode): + return awsAwsjson11_deserializeErrorInternalServiceError(response, errorBody) + + case strings.EqualFold("InvalidRequestException", errorCode): + return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ServiceUnavailableException", errorCode): + return awsAwsjson11_deserializeErrorServiceUnavailableException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson11_deserializeOpDescribeWorkflow struct { +} + +func (*awsAwsjson11_deserializeOpDescribeWorkflow) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson11_deserializeOpDescribeWorkflow) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsAwsjson11_deserializeOpErrorDescribeWorkflow(response, &metadata) + } + output := &DescribeWorkflowOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsAwsjson11_deserializeOpDocumentDescribeWorkflowOutput(&output, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + return out, metadata, err +} + +func awsAwsjson11_deserializeOpErrorDescribeWorkflow(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InternalServiceError", errorCode): + return awsAwsjson11_deserializeErrorInternalServiceError(response, errorBody) + + case strings.EqualFold("InvalidRequestException", errorCode): + return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ServiceUnavailableException", errorCode): + return awsAwsjson11_deserializeErrorServiceUnavailableException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson11_deserializeOpImportCertificate struct { +} + +func (*awsAwsjson11_deserializeOpImportCertificate) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson11_deserializeOpImportCertificate) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -2759,9 +3220,9 @@ func (m *awsAwsjson11_deserializeOpDescribeUser) HandleDeserialize(ctx context.C } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorDescribeUser(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorImportCertificate(response, &metadata) } - output := &DescribeUserOutput{} + output := &ImportCertificateOutput{} out.Result = output var buff [1024]byte @@ -2781,7 +3242,7 @@ func (m *awsAwsjson11_deserializeOpDescribeUser) HandleDeserialize(ctx context.C return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentDescribeUserOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentImportCertificateOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -2795,7 +3256,7 @@ func (m *awsAwsjson11_deserializeOpDescribeUser) HandleDeserialize(ctx context.C return out, metadata, err } -func awsAwsjson11_deserializeOpErrorDescribeUser(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorImportCertificate(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -2858,14 +3319,14 @@ func awsAwsjson11_deserializeOpErrorDescribeUser(response *smithyhttp.Response, } } -type awsAwsjson11_deserializeOpDescribeWorkflow struct { +type awsAwsjson11_deserializeOpImportHostKey struct { } -func (*awsAwsjson11_deserializeOpDescribeWorkflow) ID() string { +func (*awsAwsjson11_deserializeOpImportHostKey) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpDescribeWorkflow) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpImportHostKey) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -2879,9 +3340,9 @@ func (m *awsAwsjson11_deserializeOpDescribeWorkflow) HandleDeserialize(ctx conte } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorDescribeWorkflow(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorImportHostKey(response, &metadata) } - output := &DescribeWorkflowOutput{} + output := &ImportHostKeyOutput{} out.Result = output var buff [1024]byte @@ -2901,7 +3362,7 @@ func (m *awsAwsjson11_deserializeOpDescribeWorkflow) HandleDeserialize(ctx conte return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentDescribeWorkflowOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentImportHostKeyOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -2915,7 +3376,7 @@ func (m *awsAwsjson11_deserializeOpDescribeWorkflow) HandleDeserialize(ctx conte return out, metadata, err } -func awsAwsjson11_deserializeOpErrorDescribeWorkflow(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorImportHostKey(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -2962,12 +3423,18 @@ func awsAwsjson11_deserializeOpErrorDescribeWorkflow(response *smithyhttp.Respon case strings.EqualFold("InvalidRequestException", errorCode): return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) + case strings.EqualFold("ResourceExistsException", errorCode): + return awsAwsjson11_deserializeErrorResourceExistsException(response, errorBody) + case strings.EqualFold("ResourceNotFoundException", errorCode): return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) case strings.EqualFold("ServiceUnavailableException", errorCode): return awsAwsjson11_deserializeErrorServiceUnavailableException(response, errorBody) + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson11_deserializeErrorThrottlingException(response, errorBody) + default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -2978,14 +3445,14 @@ func awsAwsjson11_deserializeOpErrorDescribeWorkflow(response *smithyhttp.Respon } } -type awsAwsjson11_deserializeOpImportCertificate struct { +type awsAwsjson11_deserializeOpImportSshPublicKey struct { } -func (*awsAwsjson11_deserializeOpImportCertificate) ID() string { +func (*awsAwsjson11_deserializeOpImportSshPublicKey) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpImportCertificate) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpImportSshPublicKey) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -2999,9 +3466,9 @@ func (m *awsAwsjson11_deserializeOpImportCertificate) HandleDeserialize(ctx cont } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorImportCertificate(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorImportSshPublicKey(response, &metadata) } - output := &ImportCertificateOutput{} + output := &ImportSshPublicKeyOutput{} out.Result = output var buff [1024]byte @@ -3021,7 +3488,7 @@ func (m *awsAwsjson11_deserializeOpImportCertificate) HandleDeserialize(ctx cont return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentImportCertificateOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentImportSshPublicKeyOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -3035,7 +3502,7 @@ func (m *awsAwsjson11_deserializeOpImportCertificate) HandleDeserialize(ctx cont return out, metadata, err } -func awsAwsjson11_deserializeOpErrorImportCertificate(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorImportSshPublicKey(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -3082,12 +3549,18 @@ func awsAwsjson11_deserializeOpErrorImportCertificate(response *smithyhttp.Respo case strings.EqualFold("InvalidRequestException", errorCode): return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) + case strings.EqualFold("ResourceExistsException", errorCode): + return awsAwsjson11_deserializeErrorResourceExistsException(response, errorBody) + case strings.EqualFold("ResourceNotFoundException", errorCode): return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) case strings.EqualFold("ServiceUnavailableException", errorCode): return awsAwsjson11_deserializeErrorServiceUnavailableException(response, errorBody) + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson11_deserializeErrorThrottlingException(response, errorBody) + default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -3098,14 +3571,14 @@ func awsAwsjson11_deserializeOpErrorImportCertificate(response *smithyhttp.Respo } } -type awsAwsjson11_deserializeOpImportSshPublicKey struct { +type awsAwsjson11_deserializeOpListAccesses struct { } -func (*awsAwsjson11_deserializeOpImportSshPublicKey) ID() string { +func (*awsAwsjson11_deserializeOpListAccesses) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpImportSshPublicKey) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpListAccesses) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -3119,9 +3592,9 @@ func (m *awsAwsjson11_deserializeOpImportSshPublicKey) HandleDeserialize(ctx con } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorImportSshPublicKey(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorListAccesses(response, &metadata) } - output := &ImportSshPublicKeyOutput{} + output := &ListAccessesOutput{} out.Result = output var buff [1024]byte @@ -3141,7 +3614,7 @@ func (m *awsAwsjson11_deserializeOpImportSshPublicKey) HandleDeserialize(ctx con return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentImportSshPublicKeyOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentListAccessesOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -3155,7 +3628,7 @@ func (m *awsAwsjson11_deserializeOpImportSshPublicKey) HandleDeserialize(ctx con return out, metadata, err } -func awsAwsjson11_deserializeOpErrorImportSshPublicKey(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorListAccesses(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -3199,21 +3672,18 @@ func awsAwsjson11_deserializeOpErrorImportSshPublicKey(response *smithyhttp.Resp case strings.EqualFold("InternalServiceError", errorCode): return awsAwsjson11_deserializeErrorInternalServiceError(response, errorBody) + case strings.EqualFold("InvalidNextTokenException", errorCode): + return awsAwsjson11_deserializeErrorInvalidNextTokenException(response, errorBody) + case strings.EqualFold("InvalidRequestException", errorCode): return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) - case strings.EqualFold("ResourceExistsException", errorCode): - return awsAwsjson11_deserializeErrorResourceExistsException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) case strings.EqualFold("ServiceUnavailableException", errorCode): return awsAwsjson11_deserializeErrorServiceUnavailableException(response, errorBody) - case strings.EqualFold("ThrottlingException", errorCode): - return awsAwsjson11_deserializeErrorThrottlingException(response, errorBody) - default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -3224,14 +3694,14 @@ func awsAwsjson11_deserializeOpErrorImportSshPublicKey(response *smithyhttp.Resp } } -type awsAwsjson11_deserializeOpListAccesses struct { +type awsAwsjson11_deserializeOpListAgreements struct { } -func (*awsAwsjson11_deserializeOpListAccesses) ID() string { +func (*awsAwsjson11_deserializeOpListAgreements) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpListAccesses) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpListAgreements) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -3245,9 +3715,9 @@ func (m *awsAwsjson11_deserializeOpListAccesses) HandleDeserialize(ctx context.C } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorListAccesses(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorListAgreements(response, &metadata) } - output := &ListAccessesOutput{} + output := &ListAgreementsOutput{} out.Result = output var buff [1024]byte @@ -3267,7 +3737,7 @@ func (m *awsAwsjson11_deserializeOpListAccesses) HandleDeserialize(ctx context.C return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentListAccessesOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentListAgreementsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -3281,7 +3751,7 @@ func (m *awsAwsjson11_deserializeOpListAccesses) HandleDeserialize(ctx context.C return out, metadata, err } -func awsAwsjson11_deserializeOpErrorListAccesses(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorListAgreements(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -3347,14 +3817,14 @@ func awsAwsjson11_deserializeOpErrorListAccesses(response *smithyhttp.Response, } } -type awsAwsjson11_deserializeOpListAgreements struct { +type awsAwsjson11_deserializeOpListCertificates struct { } -func (*awsAwsjson11_deserializeOpListAgreements) ID() string { +func (*awsAwsjson11_deserializeOpListCertificates) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpListAgreements) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpListCertificates) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -3368,9 +3838,9 @@ func (m *awsAwsjson11_deserializeOpListAgreements) HandleDeserialize(ctx context } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorListAgreements(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorListCertificates(response, &metadata) } - output := &ListAgreementsOutput{} + output := &ListCertificatesOutput{} out.Result = output var buff [1024]byte @@ -3390,7 +3860,7 @@ func (m *awsAwsjson11_deserializeOpListAgreements) HandleDeserialize(ctx context return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentListAgreementsOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentListCertificatesOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -3404,7 +3874,7 @@ func (m *awsAwsjson11_deserializeOpListAgreements) HandleDeserialize(ctx context return out, metadata, err } -func awsAwsjson11_deserializeOpErrorListAgreements(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorListCertificates(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -3470,14 +3940,14 @@ func awsAwsjson11_deserializeOpErrorListAgreements(response *smithyhttp.Response } } -type awsAwsjson11_deserializeOpListCertificates struct { +type awsAwsjson11_deserializeOpListConnectors struct { } -func (*awsAwsjson11_deserializeOpListCertificates) ID() string { +func (*awsAwsjson11_deserializeOpListConnectors) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpListCertificates) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpListConnectors) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -3491,9 +3961,9 @@ func (m *awsAwsjson11_deserializeOpListCertificates) HandleDeserialize(ctx conte } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorListCertificates(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorListConnectors(response, &metadata) } - output := &ListCertificatesOutput{} + output := &ListConnectorsOutput{} out.Result = output var buff [1024]byte @@ -3513,7 +3983,7 @@ func (m *awsAwsjson11_deserializeOpListCertificates) HandleDeserialize(ctx conte return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentListCertificatesOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentListConnectorsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -3527,7 +3997,7 @@ func (m *awsAwsjson11_deserializeOpListCertificates) HandleDeserialize(ctx conte return out, metadata, err } -func awsAwsjson11_deserializeOpErrorListCertificates(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorListConnectors(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -3593,14 +4063,14 @@ func awsAwsjson11_deserializeOpErrorListCertificates(response *smithyhttp.Respon } } -type awsAwsjson11_deserializeOpListConnectors struct { +type awsAwsjson11_deserializeOpListExecutions struct { } -func (*awsAwsjson11_deserializeOpListConnectors) ID() string { +func (*awsAwsjson11_deserializeOpListExecutions) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpListConnectors) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpListExecutions) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -3614,9 +4084,9 @@ func (m *awsAwsjson11_deserializeOpListConnectors) HandleDeserialize(ctx context } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorListConnectors(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorListExecutions(response, &metadata) } - output := &ListConnectorsOutput{} + output := &ListExecutionsOutput{} out.Result = output var buff [1024]byte @@ -3636,7 +4106,7 @@ func (m *awsAwsjson11_deserializeOpListConnectors) HandleDeserialize(ctx context return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentListConnectorsOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentListExecutionsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -3650,7 +4120,7 @@ func (m *awsAwsjson11_deserializeOpListConnectors) HandleDeserialize(ctx context return out, metadata, err } -func awsAwsjson11_deserializeOpErrorListConnectors(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorListExecutions(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -3716,14 +4186,14 @@ func awsAwsjson11_deserializeOpErrorListConnectors(response *smithyhttp.Response } } -type awsAwsjson11_deserializeOpListExecutions struct { +type awsAwsjson11_deserializeOpListHostKeys struct { } -func (*awsAwsjson11_deserializeOpListExecutions) ID() string { +func (*awsAwsjson11_deserializeOpListHostKeys) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpListExecutions) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpListHostKeys) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -3737,9 +4207,9 @@ func (m *awsAwsjson11_deserializeOpListExecutions) HandleDeserialize(ctx context } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorListExecutions(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorListHostKeys(response, &metadata) } - output := &ListExecutionsOutput{} + output := &ListHostKeysOutput{} out.Result = output var buff [1024]byte @@ -3759,7 +4229,7 @@ func (m *awsAwsjson11_deserializeOpListExecutions) HandleDeserialize(ctx context return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentListExecutionsOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentListHostKeysOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -3773,7 +4243,7 @@ func (m *awsAwsjson11_deserializeOpListExecutions) HandleDeserialize(ctx context return out, metadata, err } -func awsAwsjson11_deserializeOpErrorListExecutions(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorListHostKeys(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5249,27 +5719,147 @@ func (m *awsAwsjson11_deserializeOpUntagResource) HandleDeserialize(ctx context. return out, metadata, err } - response, ok := out.RawResponse.(*smithyhttp.Response) - if !ok { - return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} - } - - if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorUntagResource(response, &metadata) - } - output := &UntagResourceOutput{} - out.Result = output - - if _, err = io.Copy(ioutil.Discard, response.Body); err != nil { - return out, metadata, &smithy.DeserializationError{ - Err: fmt.Errorf("failed to discard response body, %w", err), + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsAwsjson11_deserializeOpErrorUntagResource(response, &metadata) + } + output := &UntagResourceOutput{} + out.Result = output + + if _, err = io.Copy(ioutil.Discard, response.Body); err != nil { + return out, metadata, &smithy.DeserializationError{ + Err: fmt.Errorf("failed to discard response body, %w", err), + } + } + + return out, metadata, err +} + +func awsAwsjson11_deserializeOpErrorUntagResource(response *smithyhttp.Response, metadata *middleware.Metadata) error { + var errorBuffer bytes.Buffer + if _, err := io.Copy(&errorBuffer, response.Body); err != nil { + return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} + } + errorBody := bytes.NewReader(errorBuffer.Bytes()) + + errorCode := "UnknownError" + errorMessage := errorCode + + code := response.Header.Get("X-Amzn-ErrorType") + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(errorBody, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + code, message, err := restjson.GetErrorInfo(decoder) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return err + } + + errorBody.Seek(0, io.SeekStart) + if len(code) != 0 { + errorCode = restjson.SanitizeErrorCode(code) + } + if len(message) != 0 { + errorMessage = message + } + + switch { + case strings.EqualFold("InternalServiceError", errorCode): + return awsAwsjson11_deserializeErrorInternalServiceError(response, errorBody) + + case strings.EqualFold("InvalidRequestException", errorCode): + return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ServiceUnavailableException", errorCode): + return awsAwsjson11_deserializeErrorServiceUnavailableException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson11_deserializeOpUpdateAccess struct { +} + +func (*awsAwsjson11_deserializeOpUpdateAccess) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson11_deserializeOpUpdateAccess) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( + out middleware.DeserializeOutput, metadata middleware.Metadata, err error, +) { + out, metadata, err = next.HandleDeserialize(ctx, in) + if err != nil { + return out, metadata, err + } + + response, ok := out.RawResponse.(*smithyhttp.Response) + if !ok { + return out, metadata, &smithy.DeserializationError{Err: fmt.Errorf("unknown transport type %T", out.RawResponse)} + } + + if response.StatusCode < 200 || response.StatusCode >= 300 { + return out, metadata, awsAwsjson11_deserializeOpErrorUpdateAccess(response, &metadata) + } + output := &UpdateAccessOutput{} + out.Result = output + + var buff [1024]byte + ringBuffer := smithyio.NewRingBuffer(buff[:]) + + body := io.TeeReader(response.Body, ringBuffer) + decoder := json.NewDecoder(body) + decoder.UseNumber() + var shape interface{} + if err := decoder.Decode(&shape); err != nil && err != io.EOF { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), + } + return out, metadata, err + } + + err = awsAwsjson11_deserializeOpDocumentUpdateAccessOutput(&output, shape) + if err != nil { + var snapshot bytes.Buffer + io.Copy(&snapshot, ringBuffer) + err = &smithy.DeserializationError{ + Err: fmt.Errorf("failed to decode response body, %w", err), + Snapshot: snapshot.Bytes(), } + return out, metadata, err } return out, metadata, err } -func awsAwsjson11_deserializeOpErrorUntagResource(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorUpdateAccess(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5316,6 +5906,9 @@ func awsAwsjson11_deserializeOpErrorUntagResource(response *smithyhttp.Response, case strings.EqualFold("InvalidRequestException", errorCode): return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) + case strings.EqualFold("ResourceExistsException", errorCode): + return awsAwsjson11_deserializeErrorResourceExistsException(response, errorBody) + case strings.EqualFold("ResourceNotFoundException", errorCode): return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) @@ -5332,14 +5925,14 @@ func awsAwsjson11_deserializeOpErrorUntagResource(response *smithyhttp.Response, } } -type awsAwsjson11_deserializeOpUpdateAccess struct { +type awsAwsjson11_deserializeOpUpdateAgreement struct { } -func (*awsAwsjson11_deserializeOpUpdateAccess) ID() string { +func (*awsAwsjson11_deserializeOpUpdateAgreement) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpUpdateAccess) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpUpdateAgreement) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5353,9 +5946,9 @@ func (m *awsAwsjson11_deserializeOpUpdateAccess) HandleDeserialize(ctx context.C } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorUpdateAccess(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorUpdateAgreement(response, &metadata) } - output := &UpdateAccessOutput{} + output := &UpdateAgreementOutput{} out.Result = output var buff [1024]byte @@ -5375,7 +5968,7 @@ func (m *awsAwsjson11_deserializeOpUpdateAccess) HandleDeserialize(ctx context.C return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentUpdateAccessOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentUpdateAgreementOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5389,7 +5982,7 @@ func (m *awsAwsjson11_deserializeOpUpdateAccess) HandleDeserialize(ctx context.C return out, metadata, err } -func awsAwsjson11_deserializeOpErrorUpdateAccess(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorUpdateAgreement(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5455,14 +6048,14 @@ func awsAwsjson11_deserializeOpErrorUpdateAccess(response *smithyhttp.Response, } } -type awsAwsjson11_deserializeOpUpdateAgreement struct { +type awsAwsjson11_deserializeOpUpdateCertificate struct { } -func (*awsAwsjson11_deserializeOpUpdateAgreement) ID() string { +func (*awsAwsjson11_deserializeOpUpdateCertificate) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpUpdateAgreement) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpUpdateCertificate) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5476,9 +6069,9 @@ func (m *awsAwsjson11_deserializeOpUpdateAgreement) HandleDeserialize(ctx contex } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorUpdateAgreement(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorUpdateCertificate(response, &metadata) } - output := &UpdateAgreementOutput{} + output := &UpdateCertificateOutput{} out.Result = output var buff [1024]byte @@ -5498,7 +6091,7 @@ func (m *awsAwsjson11_deserializeOpUpdateAgreement) HandleDeserialize(ctx contex return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentUpdateAgreementOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentUpdateCertificateOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5512,7 +6105,7 @@ func (m *awsAwsjson11_deserializeOpUpdateAgreement) HandleDeserialize(ctx contex return out, metadata, err } -func awsAwsjson11_deserializeOpErrorUpdateAgreement(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorUpdateCertificate(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5559,9 +6152,6 @@ func awsAwsjson11_deserializeOpErrorUpdateAgreement(response *smithyhttp.Respons case strings.EqualFold("InvalidRequestException", errorCode): return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) - case strings.EqualFold("ResourceExistsException", errorCode): - return awsAwsjson11_deserializeErrorResourceExistsException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) @@ -5578,14 +6168,14 @@ func awsAwsjson11_deserializeOpErrorUpdateAgreement(response *smithyhttp.Respons } } -type awsAwsjson11_deserializeOpUpdateCertificate struct { +type awsAwsjson11_deserializeOpUpdateConnector struct { } -func (*awsAwsjson11_deserializeOpUpdateCertificate) ID() string { +func (*awsAwsjson11_deserializeOpUpdateConnector) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpUpdateCertificate) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpUpdateConnector) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5599,9 +6189,9 @@ func (m *awsAwsjson11_deserializeOpUpdateCertificate) HandleDeserialize(ctx cont } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorUpdateCertificate(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorUpdateConnector(response, &metadata) } - output := &UpdateCertificateOutput{} + output := &UpdateConnectorOutput{} out.Result = output var buff [1024]byte @@ -5621,7 +6211,7 @@ func (m *awsAwsjson11_deserializeOpUpdateCertificate) HandleDeserialize(ctx cont return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentUpdateCertificateOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentUpdateConnectorOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5635,7 +6225,7 @@ func (m *awsAwsjson11_deserializeOpUpdateCertificate) HandleDeserialize(ctx cont return out, metadata, err } -func awsAwsjson11_deserializeOpErrorUpdateCertificate(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorUpdateConnector(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5682,6 +6272,9 @@ func awsAwsjson11_deserializeOpErrorUpdateCertificate(response *smithyhttp.Respo case strings.EqualFold("InvalidRequestException", errorCode): return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) + case strings.EqualFold("ResourceExistsException", errorCode): + return awsAwsjson11_deserializeErrorResourceExistsException(response, errorBody) + case strings.EqualFold("ResourceNotFoundException", errorCode): return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) @@ -5698,14 +6291,14 @@ func awsAwsjson11_deserializeOpErrorUpdateCertificate(response *smithyhttp.Respo } } -type awsAwsjson11_deserializeOpUpdateConnector struct { +type awsAwsjson11_deserializeOpUpdateHostKey struct { } -func (*awsAwsjson11_deserializeOpUpdateConnector) ID() string { +func (*awsAwsjson11_deserializeOpUpdateHostKey) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson11_deserializeOpUpdateConnector) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson11_deserializeOpUpdateHostKey) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( out middleware.DeserializeOutput, metadata middleware.Metadata, err error, ) { out, metadata, err = next.HandleDeserialize(ctx, in) @@ -5719,9 +6312,9 @@ func (m *awsAwsjson11_deserializeOpUpdateConnector) HandleDeserialize(ctx contex } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson11_deserializeOpErrorUpdateConnector(response, &metadata) + return out, metadata, awsAwsjson11_deserializeOpErrorUpdateHostKey(response, &metadata) } - output := &UpdateConnectorOutput{} + output := &UpdateHostKeyOutput{} out.Result = output var buff [1024]byte @@ -5741,7 +6334,7 @@ func (m *awsAwsjson11_deserializeOpUpdateConnector) HandleDeserialize(ctx contex return out, metadata, err } - err = awsAwsjson11_deserializeOpDocumentUpdateConnectorOutput(&output, shape) + err = awsAwsjson11_deserializeOpDocumentUpdateHostKeyOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -5755,7 +6348,7 @@ func (m *awsAwsjson11_deserializeOpUpdateConnector) HandleDeserialize(ctx contex return out, metadata, err } -func awsAwsjson11_deserializeOpErrorUpdateConnector(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson11_deserializeOpErrorUpdateHostKey(response *smithyhttp.Response, metadata *middleware.Metadata) error { var errorBuffer bytes.Buffer if _, err := io.Copy(&errorBuffer, response.Body); err != nil { return &smithy.DeserializationError{Err: fmt.Errorf("failed to copy error response body, %w", err)} @@ -5802,15 +6395,15 @@ func awsAwsjson11_deserializeOpErrorUpdateConnector(response *smithyhttp.Respons case strings.EqualFold("InvalidRequestException", errorCode): return awsAwsjson11_deserializeErrorInvalidRequestException(response, errorBody) - case strings.EqualFold("ResourceExistsException", errorCode): - return awsAwsjson11_deserializeErrorResourceExistsException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): return awsAwsjson11_deserializeErrorResourceNotFoundException(response, errorBody) case strings.EqualFold("ServiceUnavailableException", errorCode): return awsAwsjson11_deserializeErrorServiceUnavailableException(response, errorBody) + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson11_deserializeErrorThrottlingException(response, errorBody) + default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -7538,6 +8131,103 @@ func awsAwsjson11_deserializeDocumentDescribedExecution(v **types.DescribedExecu return nil } +func awsAwsjson11_deserializeDocumentDescribedHostKey(v **types.DescribedHostKey, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.DescribedHostKey + if *v == nil { + sv = &types.DescribedHostKey{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "Arn": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Arn to be of type string, got %T instead", value) + } + sv.Arn = ptr.String(jtv) + } + + case "DateImported": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.DateImported = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected DateImported to be a JSON Number, got %T instead", value) + + } + } + + case "Description": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HostKeyDescription to be of type string, got %T instead", value) + } + sv.Description = ptr.String(jtv) + } + + case "HostKeyFingerprint": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HostKeyFingerprint to be of type string, got %T instead", value) + } + sv.HostKeyFingerprint = ptr.String(jtv) + } + + case "HostKeyId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HostKeyId to be of type string, got %T instead", value) + } + sv.HostKeyId = ptr.String(jtv) + } + + case "Tags": + if err := awsAwsjson11_deserializeDocumentTags(&sv.Tags, value); err != nil { + return err + } + + case "Type": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HostKeyType to be of type string, got %T instead", value) + } + sv.Type = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson11_deserializeDocumentDescribedProfile(v **types.DescribedProfile, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -9102,18 +9792,111 @@ func awsAwsjson11_deserializeDocumentListedConnector(v **types.ListedConnector, if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ConnectorId to be of type string, got %T instead", value) + return fmt.Errorf("expected ConnectorId to be of type string, got %T instead", value) + } + sv.ConnectorId = ptr.String(jtv) + } + + case "Url": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Url to be of type string, got %T instead", value) + } + sv.Url = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson11_deserializeDocumentListedConnectors(v *[]types.ListedConnector, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.([]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var cv []types.ListedConnector + if *v == nil { + cv = []types.ListedConnector{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.ListedConnector + destAddr := &col + if err := awsAwsjson11_deserializeDocumentListedConnector(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsAwsjson11_deserializeDocumentListedExecution(v **types.ListedExecution, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.ListedExecution + if *v == nil { + sv = &types.ListedExecution{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "ExecutionId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ExecutionId to be of type string, got %T instead", value) } - sv.ConnectorId = ptr.String(jtv) + sv.ExecutionId = ptr.String(jtv) } - case "Url": + case "InitialFileLocation": + if err := awsAwsjson11_deserializeDocumentFileLocation(&sv.InitialFileLocation, value); err != nil { + return err + } + + case "ServiceMetadata": + if err := awsAwsjson11_deserializeDocumentServiceMetadata(&sv.ServiceMetadata, value); err != nil { + return err + } + + case "Status": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected Url to be of type string, got %T instead", value) + return fmt.Errorf("expected ExecutionStatus to be of type string, got %T instead", value) } - sv.Url = ptr.String(jtv) + sv.Status = types.ExecutionStatus(jtv) } default: @@ -9125,7 +9908,7 @@ func awsAwsjson11_deserializeDocumentListedConnector(v **types.ListedConnector, return nil } -func awsAwsjson11_deserializeDocumentListedConnectors(v *[]types.ListedConnector, value interface{}) error { +func awsAwsjson11_deserializeDocumentListedExecutions(v *[]types.ListedExecution, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -9138,17 +9921,17 @@ func awsAwsjson11_deserializeDocumentListedConnectors(v *[]types.ListedConnector return fmt.Errorf("unexpected JSON type %v", value) } - var cv []types.ListedConnector + var cv []types.ListedExecution if *v == nil { - cv = []types.ListedConnector{} + cv = []types.ListedExecution{} } else { cv = *v } for _, value := range shape { - var col types.ListedConnector + var col types.ListedExecution destAddr := &col - if err := awsAwsjson11_deserializeDocumentListedConnector(&destAddr, value); err != nil { + if err := awsAwsjson11_deserializeDocumentListedExecution(&destAddr, value); err != nil { return err } col = *destAddr @@ -9159,7 +9942,7 @@ func awsAwsjson11_deserializeDocumentListedConnectors(v *[]types.ListedConnector return nil } -func awsAwsjson11_deserializeDocumentListedExecution(v **types.ListedExecution, value interface{}) error { +func awsAwsjson11_deserializeDocumentListedHostKey(v **types.ListedHostKey, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -9172,41 +9955,74 @@ func awsAwsjson11_deserializeDocumentListedExecution(v **types.ListedExecution, return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ListedExecution + var sv *types.ListedHostKey if *v == nil { - sv = &types.ListedExecution{} + sv = &types.ListedHostKey{} } else { sv = *v } for key, value := range shape { switch key { - case "ExecutionId": + case "Arn": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ExecutionId to be of type string, got %T instead", value) + return fmt.Errorf("expected Arn to be of type string, got %T instead", value) } - sv.ExecutionId = ptr.String(jtv) + sv.Arn = ptr.String(jtv) } - case "InitialFileLocation": - if err := awsAwsjson11_deserializeDocumentFileLocation(&sv.InitialFileLocation, value); err != nil { - return err + case "DateImported": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.DateImported = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected DateImported to be a JSON Number, got %T instead", value) + + } } - case "ServiceMetadata": - if err := awsAwsjson11_deserializeDocumentServiceMetadata(&sv.ServiceMetadata, value); err != nil { - return err + case "Description": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HostKeyDescription to be of type string, got %T instead", value) + } + sv.Description = ptr.String(jtv) } - case "Status": + case "Fingerprint": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ExecutionStatus to be of type string, got %T instead", value) + return fmt.Errorf("expected HostKeyFingerprint to be of type string, got %T instead", value) } - sv.Status = types.ExecutionStatus(jtv) + sv.Fingerprint = ptr.String(jtv) + } + + case "HostKeyId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HostKeyId to be of type string, got %T instead", value) + } + sv.HostKeyId = ptr.String(jtv) + } + + case "Type": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HostKeyType to be of type string, got %T instead", value) + } + sv.Type = ptr.String(jtv) } default: @@ -9218,7 +10034,7 @@ func awsAwsjson11_deserializeDocumentListedExecution(v **types.ListedExecution, return nil } -func awsAwsjson11_deserializeDocumentListedExecutions(v *[]types.ListedExecution, value interface{}) error { +func awsAwsjson11_deserializeDocumentListedHostKeys(v *[]types.ListedHostKey, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -9231,17 +10047,17 @@ func awsAwsjson11_deserializeDocumentListedExecutions(v *[]types.ListedExecution return fmt.Errorf("unexpected JSON type %v", value) } - var cv []types.ListedExecution + var cv []types.ListedHostKey if *v == nil { - cv = []types.ListedExecution{} + cv = []types.ListedHostKey{} } else { cv = *v } for _, value := range shape { - var col types.ListedExecution + var col types.ListedHostKey destAddr := &col - if err := awsAwsjson11_deserializeDocumentListedExecution(&destAddr, value); err != nil { + if err := awsAwsjson11_deserializeDocumentListedHostKey(&destAddr, value); err != nil { return err } col = *destAddr @@ -11537,6 +12353,42 @@ func awsAwsjson11_deserializeOpDocumentDescribeExecutionOutput(v **DescribeExecu return nil } +func awsAwsjson11_deserializeOpDocumentDescribeHostKeyOutput(v **DescribeHostKeyOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *DescribeHostKeyOutput + if *v == nil { + sv = &DescribeHostKeyOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "HostKey": + if err := awsAwsjson11_deserializeDocumentDescribedHostKey(&sv.HostKey, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson11_deserializeOpDocumentDescribeProfileOutput(v **DescribeProfileOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -11766,6 +12618,55 @@ func awsAwsjson11_deserializeOpDocumentImportCertificateOutput(v **ImportCertifi return nil } +func awsAwsjson11_deserializeOpDocumentImportHostKeyOutput(v **ImportHostKeyOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *ImportHostKeyOutput + if *v == nil { + sv = &ImportHostKeyOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "HostKeyId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HostKeyId to be of type string, got %T instead", value) + } + sv.HostKeyId = ptr.String(jtv) + } + + case "ServerId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ServerId to be of type string, got %T instead", value) + } + sv.ServerId = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson11_deserializeOpDocumentImportSshPublicKeyOutput(v **ImportSshPublicKeyOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -12067,6 +12968,60 @@ func awsAwsjson11_deserializeOpDocumentListExecutionsOutput(v **ListExecutionsOu return nil } +func awsAwsjson11_deserializeOpDocumentListHostKeysOutput(v **ListHostKeysOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *ListHostKeysOutput + if *v == nil { + sv = &ListHostKeysOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "HostKeys": + if err := awsAwsjson11_deserializeDocumentListedHostKeys(&sv.HostKeys, value); err != nil { + return err + } + + case "NextToken": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected NextToken to be of type string, got %T instead", value) + } + sv.NextToken = ptr.String(jtv) + } + + case "ServerId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ServerId to be of type string, got %T instead", value) + } + sv.ServerId = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson11_deserializeOpDocumentListProfilesOutput(v **ListProfilesOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -12666,6 +13621,55 @@ func awsAwsjson11_deserializeOpDocumentUpdateConnectorOutput(v **UpdateConnector return nil } +func awsAwsjson11_deserializeOpDocumentUpdateHostKeyOutput(v **UpdateHostKeyOutput, value interface{}) error { + if v == nil { + return fmt.Errorf("unexpected nil of type %T", v) + } + if value == nil { + return nil + } + + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *UpdateHostKeyOutput + if *v == nil { + sv = &UpdateHostKeyOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "HostKeyId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected HostKeyId to be of type string, got %T instead", value) + } + sv.HostKeyId = ptr.String(jtv) + } + + case "ServerId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ServerId to be of type string, got %T instead", value) + } + sv.ServerId = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson11_deserializeOpDocumentUpdateProfileOutput(v **UpdateProfileOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/transfer/generated.json b/service/transfer/generated.json index b31c9bbbbe3..74009c6c1e8 100644 --- a/service/transfer/generated.json +++ b/service/transfer/generated.json @@ -20,6 +20,7 @@ "api_op_DeleteAgreement.go", "api_op_DeleteCertificate.go", "api_op_DeleteConnector.go", + "api_op_DeleteHostKey.go", "api_op_DeleteProfile.go", "api_op_DeleteServer.go", "api_op_DeleteSshPublicKey.go", @@ -30,18 +31,21 @@ "api_op_DescribeCertificate.go", "api_op_DescribeConnector.go", "api_op_DescribeExecution.go", + "api_op_DescribeHostKey.go", "api_op_DescribeProfile.go", "api_op_DescribeSecurityPolicy.go", "api_op_DescribeServer.go", "api_op_DescribeUser.go", "api_op_DescribeWorkflow.go", "api_op_ImportCertificate.go", + "api_op_ImportHostKey.go", "api_op_ImportSshPublicKey.go", "api_op_ListAccesses.go", "api_op_ListAgreements.go", "api_op_ListCertificates.go", "api_op_ListConnectors.go", "api_op_ListExecutions.go", + "api_op_ListHostKeys.go", "api_op_ListProfiles.go", "api_op_ListSecurityPolicies.go", "api_op_ListServers.go", @@ -59,6 +63,7 @@ "api_op_UpdateAgreement.go", "api_op_UpdateCertificate.go", "api_op_UpdateConnector.go", + "api_op_UpdateHostKey.go", "api_op_UpdateProfile.go", "api_op_UpdateServer.go", "api_op_UpdateUser.go", diff --git a/service/transfer/serializers.go b/service/transfer/serializers.go index ca3f8763e09..b495cfb2e80 100644 --- a/service/transfer/serializers.go +++ b/service/transfer/serializers.go @@ -621,6 +621,61 @@ func (m *awsAwsjson11_serializeOpDeleteConnector) HandleSerialize(ctx context.Co return next.HandleSerialize(ctx, in) } +type awsAwsjson11_serializeOpDeleteHostKey struct { +} + +func (*awsAwsjson11_serializeOpDeleteHostKey) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson11_serializeOpDeleteHostKey) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*DeleteHostKeyInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1") + httpBindingEncoder.SetHeader("X-Amz-Target").String("TransferService.DeleteHostKey") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson11_serializeOpDocumentDeleteHostKeyInput(input, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsAwsjson11_serializeOpDeleteProfile struct { } @@ -1171,6 +1226,61 @@ func (m *awsAwsjson11_serializeOpDescribeExecution) HandleSerialize(ctx context. return next.HandleSerialize(ctx, in) } +type awsAwsjson11_serializeOpDescribeHostKey struct { +} + +func (*awsAwsjson11_serializeOpDescribeHostKey) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson11_serializeOpDescribeHostKey) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*DescribeHostKeyInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1") + httpBindingEncoder.SetHeader("X-Amz-Target").String("TransferService.DescribeHostKey") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson11_serializeOpDocumentDescribeHostKeyInput(input, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsAwsjson11_serializeOpDescribeProfile struct { } @@ -1501,6 +1611,61 @@ func (m *awsAwsjson11_serializeOpImportCertificate) HandleSerialize(ctx context. return next.HandleSerialize(ctx, in) } +type awsAwsjson11_serializeOpImportHostKey struct { +} + +func (*awsAwsjson11_serializeOpImportHostKey) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson11_serializeOpImportHostKey) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*ImportHostKeyInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1") + httpBindingEncoder.SetHeader("X-Amz-Target").String("TransferService.ImportHostKey") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson11_serializeOpDocumentImportHostKeyInput(input, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsAwsjson11_serializeOpImportSshPublicKey struct { } @@ -1831,6 +1996,61 @@ func (m *awsAwsjson11_serializeOpListExecutions) HandleSerialize(ctx context.Con return next.HandleSerialize(ctx, in) } +type awsAwsjson11_serializeOpListHostKeys struct { +} + +func (*awsAwsjson11_serializeOpListHostKeys) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson11_serializeOpListHostKeys) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*ListHostKeysInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1") + httpBindingEncoder.SetHeader("X-Amz-Target").String("TransferService.ListHostKeys") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson11_serializeOpDocumentListHostKeysInput(input, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsAwsjson11_serializeOpListProfiles struct { } @@ -2766,6 +2986,61 @@ func (m *awsAwsjson11_serializeOpUpdateConnector) HandleSerialize(ctx context.Co return next.HandleSerialize(ctx, in) } +type awsAwsjson11_serializeOpUpdateHostKey struct { +} + +func (*awsAwsjson11_serializeOpUpdateHostKey) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson11_serializeOpUpdateHostKey) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( + out middleware.SerializeOutput, metadata middleware.Metadata, err error, +) { + request, ok := in.Request.(*smithyhttp.Request) + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} + } + + input, ok := in.Parameters.(*UpdateHostKeyInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + operationPath := "/" + if len(request.Request.URL.Path) == 0 { + request.Request.URL.Path = operationPath + } else { + request.Request.URL.Path = path.Join(request.Request.URL.Path, operationPath) + if request.Request.URL.Path != "/" && operationPath[len(operationPath)-1] == '/' { + request.Request.URL.Path += "/" + } + } + request.Request.Method = "POST" + httpBindingEncoder, err := httpbinding.NewEncoder(request.URL.Path, request.URL.RawQuery, request.Header) + if err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.1") + httpBindingEncoder.SetHeader("X-Amz-Target").String("TransferService.UpdateHostKey") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson11_serializeOpDocumentUpdateHostKeyInput(input, jsonEncoder.Value); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request, err = request.SetStream(bytes.NewReader(jsonEncoder.Bytes())); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + if request.Request, err = httpBindingEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} + type awsAwsjson11_serializeOpUpdateProfile struct { } @@ -3948,6 +4223,23 @@ func awsAwsjson11_serializeOpDocumentDeleteConnectorInput(v *DeleteConnectorInpu return nil } +func awsAwsjson11_serializeOpDocumentDeleteHostKeyInput(v *DeleteHostKeyInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.HostKeyId != nil { + ok := object.Key("HostKeyId") + ok.String(*v.HostKeyId) + } + + if v.ServerId != nil { + ok := object.Key("ServerId") + ok.String(*v.ServerId) + } + + return nil +} + func awsAwsjson11_serializeOpDocumentDeleteProfileInput(v *DeleteProfileInput, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -4098,6 +4390,23 @@ func awsAwsjson11_serializeOpDocumentDescribeExecutionInput(v *DescribeExecution return nil } +func awsAwsjson11_serializeOpDocumentDescribeHostKeyInput(v *DescribeHostKeyInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.HostKeyId != nil { + ok := object.Key("HostKeyId") + ok.String(*v.HostKeyId) + } + + if v.ServerId != nil { + ok := object.Key("ServerId") + ok.String(*v.ServerId) + } + + return nil +} + func awsAwsjson11_serializeOpDocumentDescribeProfileInput(v *DescribeProfileInput, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -4212,6 +4521,35 @@ func awsAwsjson11_serializeOpDocumentImportCertificateInput(v *ImportCertificate return nil } +func awsAwsjson11_serializeOpDocumentImportHostKeyInput(v *ImportHostKeyInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Description != nil { + ok := object.Key("Description") + ok.String(*v.Description) + } + + if v.HostKeyBody != nil { + ok := object.Key("HostKeyBody") + ok.String(*v.HostKeyBody) + } + + if v.ServerId != nil { + ok := object.Key("ServerId") + ok.String(*v.ServerId) + } + + if v.Tags != nil { + ok := object.Key("Tags") + if err := awsAwsjson11_serializeDocumentTags(v.Tags, ok); err != nil { + return err + } + } + + return nil +} + func awsAwsjson11_serializeOpDocumentImportSshPublicKeyInput(v *ImportSshPublicKeyInput, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -4334,6 +4672,28 @@ func awsAwsjson11_serializeOpDocumentListExecutionsInput(v *ListExecutionsInput, return nil } +func awsAwsjson11_serializeOpDocumentListHostKeysInput(v *ListHostKeysInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.MaxResults != nil { + ok := object.Key("MaxResults") + ok.Integer(*v.MaxResults) + } + + if v.NextToken != nil { + ok := object.Key("NextToken") + ok.String(*v.NextToken) + } + + if v.ServerId != nil { + ok := object.Key("ServerId") + ok.String(*v.ServerId) + } + + return nil +} + func awsAwsjson11_serializeOpDocumentListProfilesInput(v *ListProfilesInput, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -4750,6 +5110,28 @@ func awsAwsjson11_serializeOpDocumentUpdateConnectorInput(v *UpdateConnectorInpu return nil } +func awsAwsjson11_serializeOpDocumentUpdateHostKeyInput(v *UpdateHostKeyInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Description != nil { + ok := object.Key("Description") + ok.String(*v.Description) + } + + if v.HostKeyId != nil { + ok := object.Key("HostKeyId") + ok.String(*v.HostKeyId) + } + + if v.ServerId != nil { + ok := object.Key("ServerId") + ok.String(*v.ServerId) + } + + return nil +} + func awsAwsjson11_serializeOpDocumentUpdateProfileInput(v *UpdateProfileInput, value smithyjson.Value) error { object := value.Object() defer object.Close() diff --git a/service/transfer/types/types.go b/service/transfer/types/types.go index 5e8bd5be4cf..0975ad58664 100644 --- a/service/transfer/types/types.go +++ b/service/transfer/types/types.go @@ -376,6 +376,48 @@ type DescribedExecution struct { noSmithyDocumentSerde } +// The details for a server host key. +type DescribedHostKey struct { + + // The unique Amazon Resource Name (ARN) for the host key. + // + // This member is required. + Arn *string + + // The date on which the host key was added to the server. + DateImported *time.Time + + // The text description for this host key. + Description *string + + // The public key fingerprint, which is a short sequence of bytes used to identify + // the longer public key. + HostKeyFingerprint *string + + // A unique identifier for the host key. + HostKeyId *string + + // Key-value pairs that can be used to group and search for host keys. + Tags []Tag + + // The encryption algorithm used for the host key. The Type is one of the following + // values: + // + // * ssh-rsa + // + // * ssh-ed25519 + // + // * ecdsa-sha2-nistp256 + // + // * + // ecdsa-sha2-nistp384 + // + // * ecdsa-sha2-nistp521 + Type *string + + noSmithyDocumentSerde +} + // The details for a local or partner AS2 profile. profile. type DescribedProfile struct { @@ -1050,6 +1092,46 @@ type ListedExecution struct { noSmithyDocumentSerde } +// Returns properties of the host key that is specified. +type ListedHostKey struct { + + // Specifies the unique Amazon Resource Name (ARN) of the host key. + // + // This member is required. + Arn *string + + // The date on which the host key was added to the server. + DateImported *time.Time + + // The current description for the host key. You can change it by calling the + // UpdateHostKey operation and providing a new description. + Description *string + + // The public key fingerprint, which is a short sequence of bytes used to identify + // the longer public key. + Fingerprint *string + + // + HostKeyId *string + + // The encryption algorithm used for the host key. The Type is one of the following + // values: + // + // * ssh-rsa + // + // * ssh-ed25519 + // + // * ecdsa-sha2-nistp256 + // + // * + // ecdsa-sha2-nistp384 + // + // * ecdsa-sha2-nistp521 + Type *string + + noSmithyDocumentSerde +} + // Returns the properties of the profile that was specified. type ListedProfile struct { diff --git a/service/transfer/validators.go b/service/transfer/validators.go index df2c3546f5b..6fc1c0ed9b2 100644 --- a/service/transfer/validators.go +++ b/service/transfer/validators.go @@ -230,6 +230,26 @@ func (m *validateOpDeleteConnector) HandleInitialize(ctx context.Context, in mid return next.HandleInitialize(ctx, in) } +type validateOpDeleteHostKey struct { +} + +func (*validateOpDeleteHostKey) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDeleteHostKey) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DeleteHostKeyInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDeleteHostKeyInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpDeleteProfile struct { } @@ -430,6 +450,26 @@ func (m *validateOpDescribeExecution) HandleInitialize(ctx context.Context, in m return next.HandleInitialize(ctx, in) } +type validateOpDescribeHostKey struct { +} + +func (*validateOpDescribeHostKey) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDescribeHostKey) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DescribeHostKeyInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDescribeHostKeyInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpDescribeProfile struct { } @@ -550,6 +590,26 @@ func (m *validateOpImportCertificate) HandleInitialize(ctx context.Context, in m return next.HandleInitialize(ctx, in) } +type validateOpImportHostKey struct { +} + +func (*validateOpImportHostKey) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpImportHostKey) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*ImportHostKeyInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpImportHostKeyInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpImportSshPublicKey struct { } @@ -630,6 +690,26 @@ func (m *validateOpListExecutions) HandleInitialize(ctx context.Context, in midd return next.HandleInitialize(ctx, in) } +type validateOpListHostKeys struct { +} + +func (*validateOpListHostKeys) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpListHostKeys) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*ListHostKeysInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpListHostKeysInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpListTagsForResource struct { } @@ -890,6 +970,26 @@ func (m *validateOpUpdateConnector) HandleInitialize(ctx context.Context, in mid return next.HandleInitialize(ctx, in) } +type validateOpUpdateHostKey struct { +} + +func (*validateOpUpdateHostKey) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpUpdateHostKey) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*UpdateHostKeyInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpUpdateHostKeyInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpUpdateProfile struct { } @@ -994,6 +1094,10 @@ func addOpDeleteConnectorValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDeleteConnector{}, middleware.After) } +func addOpDeleteHostKeyValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDeleteHostKey{}, middleware.After) +} + func addOpDeleteProfileValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDeleteProfile{}, middleware.After) } @@ -1034,6 +1138,10 @@ func addOpDescribeExecutionValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDescribeExecution{}, middleware.After) } +func addOpDescribeHostKeyValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDescribeHostKey{}, middleware.After) +} + func addOpDescribeProfileValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDescribeProfile{}, middleware.After) } @@ -1058,6 +1166,10 @@ func addOpImportCertificateValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpImportCertificate{}, middleware.After) } +func addOpImportHostKeyValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpImportHostKey{}, middleware.After) +} + func addOpImportSshPublicKeyValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpImportSshPublicKey{}, middleware.After) } @@ -1074,6 +1186,10 @@ func addOpListExecutionsValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpListExecutions{}, middleware.After) } +func addOpListHostKeysValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpListHostKeys{}, middleware.After) +} + func addOpListTagsForResourceValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpListTagsForResource{}, middleware.After) } @@ -1126,6 +1242,10 @@ func addOpUpdateConnectorValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpUpdateConnector{}, middleware.After) } +func addOpUpdateHostKeyValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpUpdateHostKey{}, middleware.After) +} + func addOpUpdateProfileValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpUpdateProfile{}, middleware.After) } @@ -1631,6 +1751,24 @@ func validateOpDeleteConnectorInput(v *DeleteConnectorInput) error { } } +func validateOpDeleteHostKeyInput(v *DeleteHostKeyInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DeleteHostKeyInput"} + if v.ServerId == nil { + invalidParams.Add(smithy.NewErrParamRequired("ServerId")) + } + if v.HostKeyId == nil { + invalidParams.Add(smithy.NewErrParamRequired("HostKeyId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpDeleteProfileInput(v *DeleteProfileInput) error { if v == nil { return nil @@ -1799,6 +1937,24 @@ func validateOpDescribeExecutionInput(v *DescribeExecutionInput) error { } } +func validateOpDescribeHostKeyInput(v *DescribeHostKeyInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DescribeHostKeyInput"} + if v.ServerId == nil { + invalidParams.Add(smithy.NewErrParamRequired("ServerId")) + } + if v.HostKeyId == nil { + invalidParams.Add(smithy.NewErrParamRequired("HostKeyId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpDescribeProfileInput(v *DescribeProfileInput) error { if v == nil { return nil @@ -1900,6 +2056,29 @@ func validateOpImportCertificateInput(v *ImportCertificateInput) error { } } +func validateOpImportHostKeyInput(v *ImportHostKeyInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ImportHostKeyInput"} + if v.ServerId == nil { + invalidParams.Add(smithy.NewErrParamRequired("ServerId")) + } + if v.HostKeyBody == nil { + invalidParams.Add(smithy.NewErrParamRequired("HostKeyBody")) + } + if v.Tags != nil { + if err := validateTags(v.Tags); err != nil { + invalidParams.AddNested("Tags", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpImportSshPublicKeyInput(v *ImportSshPublicKeyInput) error { if v == nil { return nil @@ -1966,6 +2145,21 @@ func validateOpListExecutionsInput(v *ListExecutionsInput) error { } } +func validateOpListHostKeysInput(v *ListHostKeysInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ListHostKeysInput"} + if v.ServerId == nil { + invalidParams.Add(smithy.NewErrParamRequired("ServerId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpListTagsForResourceInput(v *ListTagsForResourceInput) error { if v == nil { return nil @@ -2202,6 +2396,27 @@ func validateOpUpdateConnectorInput(v *UpdateConnectorInput) error { } } +func validateOpUpdateHostKeyInput(v *UpdateHostKeyInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "UpdateHostKeyInput"} + if v.ServerId == nil { + invalidParams.Add(smithy.NewErrParamRequired("ServerId")) + } + if v.HostKeyId == nil { + invalidParams.Add(smithy.NewErrParamRequired("HostKeyId")) + } + if v.Description == nil { + invalidParams.Add(smithy.NewErrParamRequired("Description")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpUpdateProfileInput(v *UpdateProfileInput) error { if v == nil { return nil