diff --git a/.changelog/1f6c3227a9b446409e56656b80e6302c.json b/.changelog/1f6c3227a9b446409e56656b80e6302c.json new file mode 100644 index 00000000000..08479ff861d --- /dev/null +++ b/.changelog/1f6c3227a9b446409e56656b80e6302c.json @@ -0,0 +1,8 @@ +{ + "id": "1f6c3227-a9b4-4640-9e56-656b80e6302c", + "type": "documentation", + "description": "Documentation updates for the AWS IAM Identity Center Portal CLI Reference.", + "modules": [ + "service/sso" + ] +} \ No newline at end of file diff --git a/.changelog/32887076c73e4d5da0bc6b65913aac78.json b/.changelog/32887076c73e4d5da0bc6b65913aac78.json new file mode 100644 index 00000000000..2a3e619f440 --- /dev/null +++ b/.changelog/32887076c73e4d5da0bc6b65913aac78.json @@ -0,0 +1,8 @@ +{ + "id": "32887076-c73e-4d5d-a0bc-6b65913aac78", + "type": "documentation", + "description": "Documentation updates for the Identity Store CLI Reference.", + "modules": [ + "service/identitystore" + ] +} \ No newline at end of file diff --git a/.changelog/42c6b859c1234a55bae98cabee655f74.json b/.changelog/42c6b859c1234a55bae98cabee655f74.json new file mode 100644 index 00000000000..d513edfb3f2 --- /dev/null +++ b/.changelog/42c6b859c1234a55bae98cabee655f74.json @@ -0,0 +1,8 @@ +{ + "id": "42c6b859-c123-4a55-bae9-8cabee655f74", + "type": "feature", + "description": "This release adds new apis for providing labels.", + "modules": [ + "service/lookoutequipment" + ] +} \ No newline at end of file diff --git a/.changelog/6b9865badd184bf4956dbae6b13fbce4.json b/.changelog/6b9865badd184bf4956dbae6b13fbce4.json new file mode 100644 index 00000000000..72bea4caeda --- /dev/null +++ b/.changelog/6b9865badd184bf4956dbae6b13fbce4.json @@ -0,0 +1,8 @@ +{ + "id": "6b9865ba-dd18-4bf4-956d-bae6b13fbce4", + "type": "feature", + "description": "Adds topologyFilter to ListInstalledComponentsRequest which allows filtration of components by ROOT or ALL (including root and dependency components). Adds lastStatusChangeTimestamp to ListInstalledComponents response to show the last time a component changed state on a device.", + "modules": [ + "service/greengrassv2" + ] +} \ No newline at end of file diff --git a/.changelog/70940e20b88447768841ee451f839f78.json b/.changelog/70940e20b88447768841ee451f839f78.json new file mode 100644 index 00000000000..b8a32b20b6c --- /dev/null +++ b/.changelog/70940e20b88447768841ee451f839f78.json @@ -0,0 +1,8 @@ +{ + "id": "70940e20-b884-4776-8841-ee451f839f78", + "type": "documentation", + "description": "Documentation updates for the AWS IAM Identity Center CLI Reference.", + "modules": [ + "service/ssoadmin" + ] +} \ No newline at end of file diff --git a/.changelog/a22e3ee9a71448f79c680d4e7ce72540.json b/.changelog/a22e3ee9a71448f79c680d4e7ce72540.json new file mode 100644 index 00000000000..cb4cd654e19 --- /dev/null +++ b/.changelog/a22e3ee9a71448f79c680d4e7ce72540.json @@ -0,0 +1,8 @@ +{ + "id": "a22e3ee9-a714-48f7-9c68-0d4e7ce72540", + "type": "feature", + "description": "This release of the Amazon Macie API adds support for using allow lists to define specific text and text patterns to ignore when inspecting data sources for sensitive data.", + "modules": [ + "service/macie2" + ] +} \ No newline at end of file diff --git a/service/accessanalyzer/internal/endpoints/endpoints.go b/service/accessanalyzer/internal/endpoints/endpoints.go index c7e461d869e..6fd1f48b252 100644 --- a/service/accessanalyzer/internal/endpoints/endpoints.go +++ b/service/accessanalyzer/internal/endpoints/endpoints.go @@ -234,6 +234,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/acm/internal/endpoints/endpoints.go b/service/acm/internal/endpoints/endpoints.go index 21d9dab146e..b41048e5116 100644 --- a/service/acm/internal/endpoints/endpoints.go +++ b/service/acm/internal/endpoints/endpoints.go @@ -198,6 +198,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/apigateway/internal/endpoints/endpoints.go b/service/apigateway/internal/endpoints/endpoints.go index ba752f21572..65d8a83d576 100644 --- a/service/apigateway/internal/endpoints/endpoints.go +++ b/service/apigateway/internal/endpoints/endpoints.go @@ -159,9 +159,18 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "ap-southeast-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-3", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "ca-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ca-central-1", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "apigateway-fips.ca-central-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "eu-central-1", }: endpoints.Endpoint{}, @@ -180,6 +189,54 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "fips-ca-central-1", + }: endpoints.Endpoint{ + Hostname: "apigateway-fips.ca-central-1.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "ca-central-1", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-east-1", + }: endpoints.Endpoint{ + Hostname: "apigateway-fips.us-east-1.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-east-1", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-east-2", + }: endpoints.Endpoint{ + Hostname: "apigateway-fips.us-east-2.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-east-2", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-west-1", + }: endpoints.Endpoint{ + Hostname: "apigateway-fips.us-west-1.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-west-1", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-west-2", + }: endpoints.Endpoint{ + Hostname: "apigateway-fips.us-west-2.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-west-2", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, @@ -189,15 +246,39 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "us-east-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-east-1", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "apigateway-fips.us-east-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "us-east-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-east-2", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "apigateway-fips.us-east-2.amazonaws.com", + }, endpoints.EndpointKey{ Region: "us-west-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-west-1", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "apigateway-fips.us-west-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "us-west-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-west-2", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "apigateway-fips.us-west-2.amazonaws.com", + }, }, }, { diff --git a/service/apigatewayv2/internal/endpoints/endpoints.go b/service/apigatewayv2/internal/endpoints/endpoints.go index f5cf46f4b66..c5b8929b43c 100644 --- a/service/apigatewayv2/internal/endpoints/endpoints.go +++ b/service/apigatewayv2/internal/endpoints/endpoints.go @@ -159,9 +159,18 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "ap-southeast-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ap-southeast-3", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "ca-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ca-central-1", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "apigateway-fips.ca-central-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "eu-central-1", }: endpoints.Endpoint{}, @@ -180,6 +189,54 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "fips-ca-central-1", + }: endpoints.Endpoint{ + Hostname: "apigateway-fips.ca-central-1.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "ca-central-1", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-east-1", + }: endpoints.Endpoint{ + Hostname: "apigateway-fips.us-east-1.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-east-1", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-east-2", + }: endpoints.Endpoint{ + Hostname: "apigateway-fips.us-east-2.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-east-2", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-west-1", + }: endpoints.Endpoint{ + Hostname: "apigateway-fips.us-west-1.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-west-1", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-west-2", + }: endpoints.Endpoint{ + Hostname: "apigateway-fips.us-west-2.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-west-2", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, @@ -189,15 +246,39 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "us-east-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-east-1", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "apigateway-fips.us-east-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "us-east-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-east-2", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "apigateway-fips.us-east-2.amazonaws.com", + }, endpoints.EndpointKey{ Region: "us-west-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-west-1", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "apigateway-fips.us-west-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "us-west-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-west-2", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "apigateway-fips.us-west-2.amazonaws.com", + }, }, }, { diff --git a/service/appconfig/internal/endpoints/endpoints.go b/service/appconfig/internal/endpoints/endpoints.go index 8e2fa366ee4..3cd9423aa4c 100644 --- a/service/appconfig/internal/endpoints/endpoints.go +++ b/service/appconfig/internal/endpoints/endpoints.go @@ -183,6 +183,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/applicationautoscaling/internal/endpoints/endpoints.go b/service/applicationautoscaling/internal/endpoints/endpoints.go index cf2d7916b1d..a240e75bb63 100644 --- a/service/applicationautoscaling/internal/endpoints/endpoints.go +++ b/service/applicationautoscaling/internal/endpoints/endpoints.go @@ -183,6 +183,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/autoscaling/internal/endpoints/endpoints.go b/service/autoscaling/internal/endpoints/endpoints.go index 8e23420fd1f..4f938b0b167 100644 --- a/service/autoscaling/internal/endpoints/endpoints.go +++ b/service/autoscaling/internal/endpoints/endpoints.go @@ -183,6 +183,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/cloudformation/internal/endpoints/endpoints.go b/service/cloudformation/internal/endpoints/endpoints.go index 802128e4895..6b80c940c3b 100644 --- a/service/cloudformation/internal/endpoints/endpoints.go +++ b/service/cloudformation/internal/endpoints/endpoints.go @@ -183,6 +183,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/cloudtrail/internal/endpoints/endpoints.go b/service/cloudtrail/internal/endpoints/endpoints.go index 9df2c9bb815..26fc74e5391 100644 --- a/service/cloudtrail/internal/endpoints/endpoints.go +++ b/service/cloudtrail/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/cloudwatch/internal/endpoints/endpoints.go b/service/cloudwatch/internal/endpoints/endpoints.go index 60e2dd8fd9a..53dd7abc1cd 100644 --- a/service/cloudwatch/internal/endpoints/endpoints.go +++ b/service/cloudwatch/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/cloudwatchevents/internal/endpoints/endpoints.go b/service/cloudwatchevents/internal/endpoints/endpoints.go index 4182898186d..15a949de16f 100644 --- a/service/cloudwatchevents/internal/endpoints/endpoints.go +++ b/service/cloudwatchevents/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/cloudwatchlogs/internal/endpoints/endpoints.go b/service/cloudwatchlogs/internal/endpoints/endpoints.go index cdd8d8f5385..cb524982da5 100644 --- a/service/cloudwatchlogs/internal/endpoints/endpoints.go +++ b/service/cloudwatchlogs/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/codedeploy/internal/endpoints/endpoints.go b/service/codedeploy/internal/endpoints/endpoints.go index 8b3a51fe2e5..af032a035a3 100644 --- a/service/codedeploy/internal/endpoints/endpoints.go +++ b/service/codedeploy/internal/endpoints/endpoints.go @@ -183,6 +183,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/configservice/internal/endpoints/endpoints.go b/service/configservice/internal/endpoints/endpoints.go index 985e58237dd..f09ba5c7a67 100644 --- a/service/configservice/internal/endpoints/endpoints.go +++ b/service/configservice/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/databasemigrationservice/internal/endpoints/endpoints.go b/service/databasemigrationservice/internal/endpoints/endpoints.go index deeee5d80ec..d98148632c4 100644 --- a/service/databasemigrationservice/internal/endpoints/endpoints.go +++ b/service/databasemigrationservice/internal/endpoints/endpoints.go @@ -210,6 +210,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/directconnect/internal/endpoints/endpoints.go b/service/directconnect/internal/endpoints/endpoints.go index 458f6cff3b4..f491539fee0 100644 --- a/service/directconnect/internal/endpoints/endpoints.go +++ b/service/directconnect/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/docdb/internal/endpoints/endpoints.go b/service/docdb/internal/endpoints/endpoints.go index 71237d919d0..3db2525fec5 100644 --- a/service/docdb/internal/endpoints/endpoints.go +++ b/service/docdb/internal/endpoints/endpoints.go @@ -198,6 +198,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/dynamodb/internal/endpoints/endpoints.go b/service/dynamodb/internal/endpoints/endpoints.go index 2b24f8b0cfc..0f35aa7353d 100644 --- a/service/dynamodb/internal/endpoints/endpoints.go +++ b/service/dynamodb/internal/endpoints/endpoints.go @@ -207,6 +207,9 @@ var defaultPartitions = endpoints.Partitions{ Region: "us-east-1", }, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/dynamodbstreams/internal/endpoints/endpoints.go b/service/dynamodbstreams/internal/endpoints/endpoints.go index d8156ef740c..dd102719654 100644 --- a/service/dynamodbstreams/internal/endpoints/endpoints.go +++ b/service/dynamodbstreams/internal/endpoints/endpoints.go @@ -204,6 +204,9 @@ var defaultPartitions = endpoints.Partitions{ Region: "us-east-1", }, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/ec2/internal/endpoints/endpoints.go b/service/ec2/internal/endpoints/endpoints.go index 94dfadfafc9..af30850ad29 100644 --- a/service/ec2/internal/endpoints/endpoints.go +++ b/service/ec2/internal/endpoints/endpoints.go @@ -246,6 +246,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/ecr/internal/endpoints/endpoints.go b/service/ecr/internal/endpoints/endpoints.go index c74ddafcd57..e91c8df93cc 100644 --- a/service/ecr/internal/endpoints/endpoints.go +++ b/service/ecr/internal/endpoints/endpoints.go @@ -407,6 +407,14 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{ + Hostname: "api.ecr.me-central-1.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "me-central-1", + }, + }, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{ diff --git a/service/ecs/internal/endpoints/endpoints.go b/service/ecs/internal/endpoints/endpoints.go index 831e54bec47..4f7d3c2085c 100644 --- a/service/ecs/internal/endpoints/endpoints.go +++ b/service/ecs/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/elasticache/internal/endpoints/endpoints.go b/service/elasticache/internal/endpoints/endpoints.go index 1568bec1779..ba51fa0836d 100644 --- a/service/elasticache/internal/endpoints/endpoints.go +++ b/service/elasticache/internal/endpoints/endpoints.go @@ -192,6 +192,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/elasticloadbalancing/internal/endpoints/endpoints.go b/service/elasticloadbalancing/internal/endpoints/endpoints.go index afa7d7b0a4d..cd5c48f7bcb 100644 --- a/service/elasticloadbalancing/internal/endpoints/endpoints.go +++ b/service/elasticloadbalancing/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/elasticloadbalancingv2/internal/endpoints/endpoints.go b/service/elasticloadbalancingv2/internal/endpoints/endpoints.go index c2c4d8b03a4..040bb81d541 100644 --- a/service/elasticloadbalancingv2/internal/endpoints/endpoints.go +++ b/service/elasticloadbalancingv2/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/elasticsearchservice/internal/endpoints/endpoints.go b/service/elasticsearchservice/internal/endpoints/endpoints.go index ce47f8f233c..b11e7abc325 100644 --- a/service/elasticsearchservice/internal/endpoints/endpoints.go +++ b/service/elasticsearchservice/internal/endpoints/endpoints.go @@ -192,6 +192,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/emr/internal/endpoints/endpoints.go b/service/emr/internal/endpoints/endpoints.go index e00ec9b4345..abed125a184 100644 --- a/service/emr/internal/endpoints/endpoints.go +++ b/service/emr/internal/endpoints/endpoints.go @@ -234,6 +234,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/eventbridge/internal/endpoints/endpoints.go b/service/eventbridge/internal/endpoints/endpoints.go index 8b57cb110fc..2626adabd32 100644 --- a/service/eventbridge/internal/endpoints/endpoints.go +++ b/service/eventbridge/internal/endpoints/endpoints.go @@ -221,6 +221,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/greengrassv2/api_op_GetComponent.go b/service/greengrassv2/api_op_GetComponent.go index 301b9d1eb8a..8ae73e0d72c 100644 --- a/service/greengrassv2/api_op_GetComponent.go +++ b/service/greengrassv2/api_op_GetComponent.go @@ -11,8 +11,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Gets the recipe for a version of a component. Core devices can call this -// operation to identify the artifacts and requirements to install a component. +// Gets the recipe for a version of a component. func (c *Client) GetComponent(ctx context.Context, params *GetComponentInput, optFns ...func(*Options)) (*GetComponentOutput, error) { if params == nil { params = &GetComponentInput{} diff --git a/service/greengrassv2/api_op_GetCoreDevice.go b/service/greengrassv2/api_op_GetCoreDevice.go index ff344a475b5..9e315887553 100644 --- a/service/greengrassv2/api_op_GetCoreDevice.go +++ b/service/greengrassv2/api_op_GetCoreDevice.go @@ -32,6 +32,9 @@ import ( // interval that you can configure // (https://docs.aws.amazon.com/greengrass/v2/developerguide/greengrass-nucleus-component.html#greengrass-nucleus-component-configuration-fss), // which defaults to 24 hours +// +// * For IoT Greengrass Core v2.7.0, the core device +// sends status updates upon local deployment and cloud deployment func (c *Client) GetCoreDevice(ctx context.Context, params *GetCoreDeviceInput, optFns ...func(*Options)) (*GetCoreDeviceOutput, error) { if params == nil { params = &GetCoreDeviceInput{} diff --git a/service/greengrassv2/api_op_ListCoreDevices.go b/service/greengrassv2/api_op_ListCoreDevices.go index f2a940a66c0..65934402f39 100644 --- a/service/greengrassv2/api_op_ListCoreDevices.go +++ b/service/greengrassv2/api_op_ListCoreDevices.go @@ -32,6 +32,9 @@ import ( // interval that you can configure // (https://docs.aws.amazon.com/greengrass/v2/developerguide/greengrass-nucleus-component.html#greengrass-nucleus-component-configuration-fss), // which defaults to 24 hours +// +// * For IoT Greengrass Core v2.7.0, the core device +// sends status updates upon local deployment and cloud deployment func (c *Client) ListCoreDevices(ctx context.Context, params *ListCoreDevicesInput, optFns ...func(*Options)) (*ListCoreDevicesOutput, error) { if params == nil { params = &ListCoreDevicesInput{} diff --git a/service/greengrassv2/api_op_ListInstalledComponents.go b/service/greengrassv2/api_op_ListInstalledComponents.go index be9d1d5f90a..cbdeafe3b54 100644 --- a/service/greengrassv2/api_op_ListInstalledComponents.go +++ b/service/greengrassv2/api_op_ListInstalledComponents.go @@ -13,27 +13,31 @@ import ( ) // Retrieves a paginated list of the components that a Greengrass core device runs. -// This list doesn't include components that are deployed from local deployments or -// components that are deployed as dependencies of other components. IoT Greengrass -// relies on individual devices to send status updates to the Amazon Web Services -// Cloud. If the IoT Greengrass Core software isn't running on the device, or if -// device isn't connected to the Amazon Web Services Cloud, then the reported -// status of that device might not reflect its current status. The status timestamp -// indicates when the device status was last updated. Core devices send status -// updates at the following times: +// By default, this list doesn't include components that are deployed as +// dependencies of other components. To include dependencies in the response, set +// the topologyFilter parameter to ALL. IoT Greengrass relies on individual devices +// to send status updates to the Amazon Web Services Cloud. If the IoT Greengrass +// Core software isn't running on the device, or if device isn't connected to the +// Amazon Web Services Cloud, then the reported status of that device might not +// reflect its current status. The status timestamp indicates when the device +// status was last updated. Core devices send status updates at the following +// times: // -// * When the IoT Greengrass Core software -// starts +// * When the IoT Greengrass Core software starts // -// * When the core device receives a deployment from the Amazon Web -// Services Cloud +// * When the core device +// receives a deployment from the Amazon Web Services Cloud // -// * When the status of any component on the core device becomes -// BROKEN +// * When the status of +// any component on the core device becomes BROKEN // -// * At a regular interval that you can configure +// * At a regular interval that +// you can configure // (https://docs.aws.amazon.com/greengrass/v2/developerguide/greengrass-nucleus-component.html#greengrass-nucleus-component-configuration-fss), // which defaults to 24 hours +// +// * For IoT Greengrass Core v2.7.0, the core device +// sends status updates upon local deployment and cloud deployment func (c *Client) ListInstalledComponents(ctx context.Context, params *ListInstalledComponentsInput, optFns ...func(*Options)) (*ListInstalledComponentsOutput, error) { if params == nil { params = &ListInstalledComponentsInput{} @@ -62,12 +66,29 @@ type ListInstalledComponentsInput struct { // The token to be used for the next set of paginated results. NextToken *string + // The filter for the list of components. Choose from the following options: + // + // * ALL + // – The list includes all components installed on the core device. + // + // * ROOT – The + // list includes only root components, which are components that you specify in a + // deployment. When you choose this option, the list doesn't include components + // that the core device installs as dependencies of other components. + // + // Default: + // ROOT + TopologyFilter types.InstalledComponentTopologyFilter + noSmithyDocumentSerde } type ListInstalledComponentsOutput struct { - // A list that summarizes each component on the core device. + // A list that summarizes each component on the core device. Accuracy of the + // lastStatusChangeTimestamp response depends on Greengrass nucleus v2.7.0. It + // performs best on Greengrass nucleus v2.7.0 and can be inaccurate on earlier + // versions. InstalledComponents []types.InstalledComponent // The token for the next set of results, or null if there are no additional diff --git a/service/greengrassv2/deserializers.go b/service/greengrassv2/deserializers.go index 57b3b68c668..605296dfad7 100644 --- a/service/greengrassv2/deserializers.go +++ b/service/greengrassv2/deserializers.go @@ -6809,6 +6809,22 @@ func awsRestjson1_deserializeDocumentInstalledComponent(v **types.InstalledCompo sv.IsRoot = jtv } + case "lastStatusChangeTimestamp": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.LastStatusChangeTimestamp = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + case "lifecycleState": if value != nil { jtv, ok := value.(string) diff --git a/service/greengrassv2/serializers.go b/service/greengrassv2/serializers.go index 3e92343e935..c3742a52545 100644 --- a/service/greengrassv2/serializers.go +++ b/service/greengrassv2/serializers.go @@ -1577,6 +1577,10 @@ func awsRestjson1_serializeOpHttpBindingsListInstalledComponentsInput(v *ListIns encoder.SetQuery("nextToken").String(*v.NextToken) } + if len(v.TopologyFilter) > 0 { + encoder.SetQuery("topologyFilter").String(string(v.TopologyFilter)) + } + return nil } diff --git a/service/greengrassv2/types/enums.go b/service/greengrassv2/types/enums.go index e78b77d0ce3..a86d1924ef0 100644 --- a/service/greengrassv2/types/enums.go +++ b/service/greengrassv2/types/enums.go @@ -220,6 +220,25 @@ func (InstalledComponentLifecycleState) Values() []InstalledComponentLifecycleSt } } +type InstalledComponentTopologyFilter string + +// Enum values for InstalledComponentTopologyFilter +const ( + InstalledComponentTopologyFilterAll InstalledComponentTopologyFilter = "ALL" + InstalledComponentTopologyFilterRoot InstalledComponentTopologyFilter = "ROOT" +) + +// Values returns all known values for InstalledComponentTopologyFilter. 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 (InstalledComponentTopologyFilter) Values() []InstalledComponentTopologyFilter { + return []InstalledComponentTopologyFilter{ + "ALL", + "ROOT", + } +} + type IoTJobAbortAction string // Enum values for IoTJobAbortAction diff --git a/service/greengrassv2/types/types.go b/service/greengrassv2/types/types.go index 4ef11b794af..f90f93037e5 100644 --- a/service/greengrassv2/types/types.go +++ b/service/greengrassv2/types/types.go @@ -240,7 +240,7 @@ type ComponentLatestVersion struct { type ComponentPlatform struct { // A dictionary of attributes for the platform. The IoT Greengrass Core software - // defines the os and platform by default. You can specify additional platform + // defines the os and architecture by default. You can specify additional platform // attributes for a core device when you deploy the Greengrass nucleus component. // For more information, see the Greengrass nucleus component // (https://docs.aws.amazon.com/greengrass/v2/developerguide/greengrass-nucleus-component.html) @@ -581,6 +581,12 @@ type InstalledComponent struct { // Whether or not the component is a root component. IsRoot bool + // The status of how current the data is. This response is based off of component + // state changes. The status reflects component disruptions and deployments. If a + // component only sees a configuration update during a deployment, it might not + // undergo a state change and this status would not be updated. + LastStatusChangeTimestamp *time.Time + // The lifecycle state of the component. LifecycleState InstalledComponentLifecycleState diff --git a/service/identitystore/doc.go b/service/identitystore/doc.go index 4a40ee0e05a..1f6abad1d5e 100644 --- a/service/identitystore/doc.go +++ b/service/identitystore/doc.go @@ -3,14 +3,13 @@ // Package identitystore provides the API client, operations, and parameter types // for AWS SSO Identity Store. // -// The Identity Store service used by Amazon Web Services Single Sign On provides a -// single place to retrieve all of your identities (users and groups). For more -// information, see the Amazon Web Services SSO 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 Amazon Web Services 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 Amazon Web Services -// SSO rename +// 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. diff --git a/service/kinesis/internal/endpoints/endpoints.go b/service/kinesis/internal/endpoints/endpoints.go index 80dfa660418..239727367d6 100644 --- a/service/kinesis/internal/endpoints/endpoints.go +++ b/service/kinesis/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/kms/internal/endpoints/endpoints.go b/service/kms/internal/endpoints/endpoints.go index 2c7a2cb6aca..58dc054960b 100644 --- a/service/kms/internal/endpoints/endpoints.go +++ b/service/kms/internal/endpoints/endpoints.go @@ -423,6 +423,15 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "kms-fips.me-central-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "me-central-1-fips", }: endpoints.Endpoint{ diff --git a/service/lambda/internal/endpoints/endpoints.go b/service/lambda/internal/endpoints/endpoints.go index b93fbcd517f..40d17d66483 100644 --- a/service/lambda/internal/endpoints/endpoints.go +++ b/service/lambda/internal/endpoints/endpoints.go @@ -315,6 +315,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/lookoutequipment/api_op_CreateInferenceScheduler.go b/service/lookoutequipment/api_op_CreateInferenceScheduler.go index 05f910f3acf..0c1074ecd71 100644 --- a/service/lookoutequipment/api_op_CreateInferenceScheduler.go +++ b/service/lookoutequipment/api_op_CreateInferenceScheduler.go @@ -53,12 +53,13 @@ type CreateInferenceSchedulerInput struct { // This member is required. DataOutputConfiguration *types.InferenceOutputConfiguration - // How often data is uploaded to the source S3 bucket for the input data. The value - // chosen is the length of time between data uploads. For instance, if you select 5 - // minutes, Amazon Lookout for Equipment will upload the real-time data to the - // source bucket once every 5 minutes. This frequency also determines how often - // Amazon Lookout for Equipment starts a scheduled inference on your data. In this - // example, it starts once every 5 minutes. + // How often data is uploaded to the source Amazon S3 bucket for the input data. + // The value chosen is the length of time between data uploads. For instance, if + // you select 5 minutes, Amazon Lookout for Equipment will upload the real-time + // data to the source bucket once every 5 minutes. This frequency also determines + // how often Amazon Lookout for Equipment runs inference on your data. For more + // information, see Understanding the inference process + // (https://docs.aws.amazon.com/lookout-for-equipment/latest/ug/understanding-inference-process.html). // // This member is required. DataUploadFrequency types.DataUploadFrequency @@ -80,14 +81,16 @@ type CreateInferenceSchedulerInput struct { // This member is required. RoleArn *string - // A period of time (in minutes) by which inference on the data is delayed after - // the data starts. For instance, if you select an offset delay time of five - // minutes, inference will not begin on the data until the first data measurement - // after the five minute mark. For example, if five minutes is selected, the - // inference scheduler will wake up at the configured frequency with the additional - // five minute delay time to check the customer S3 bucket. The customer can upload - // data at the same frequency and they don't need to stop and restart the scheduler - // when uploading new data. + // The interval (in minutes) of planned delay at the start of each inference + // segment. For example, if inference is set to run every ten minutes, the delay is + // set to five minutes and the time is 09:08. The inference scheduler will wake up + // at the configured interval (which, without a delay configured, would be 09:10) + // plus the additional five minute delay time (so 09:15) to check your Amazon S3 + // bucket. The delay provides a buffer for you to upload data at the same + // frequency, so that you don't have to stop and restart the scheduler when + // uploading new data. For more information, see Understanding the inference + // process + // (https://docs.aws.amazon.com/lookout-for-equipment/latest/ug/understanding-inference-process.html). DataDelayOffsetInMinutes *int64 // Provides the identifier of the KMS key used to encrypt inference scheduler data diff --git a/service/lookoutequipment/api_op_CreateLabel.go b/service/lookoutequipment/api_op_CreateLabel.go new file mode 100644 index 00000000000..94970c56ca7 --- /dev/null +++ b/service/lookoutequipment/api_op_CreateLabel.go @@ -0,0 +1,196 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package lookoutequipment + +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/lookoutequipment/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" + "time" +) + +// Creates a label for an event. +func (c *Client) CreateLabel(ctx context.Context, params *CreateLabelInput, optFns ...func(*Options)) (*CreateLabelOutput, error) { + if params == nil { + params = &CreateLabelInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "CreateLabel", params, optFns, c.addOperationCreateLabelMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*CreateLabelOutput) + out.ResultMetadata = metadata + return out, nil +} + +type CreateLabelInput struct { + + // A unique identifier for the request to create a label. If you do not set the + // client request token, Lookout for Equipment generates one. + // + // This member is required. + ClientToken *string + + // The end time of the labeled event. + // + // This member is required. + EndTime *time.Time + + // The name of a group of labels. Data in this field will be retained for service + // usage. Follow best practices for the security of your data. + // + // This member is required. + LabelGroupName *string + + // Indicates whether a labeled event represents an anomaly. + // + // This member is required. + Rating types.LabelRating + + // The start time of the labeled event. + // + // This member is required. + StartTime *time.Time + + // Indicates that a label pertains to a particular piece of equipment. Data in this + // field will be retained for service usage. Follow best practices for the security + // of your data. + Equipment *string + + // Provides additional information about the label. The fault code must be defined + // in the FaultCodes attribute of the label group. Data in this field will be + // retained for service usage. Follow best practices for the security of your data. + FaultCode *string + + // Metadata providing additional information about the label. Data in this field + // will be retained for service usage. Follow best practices for the security of + // your data. + Notes *string + + noSmithyDocumentSerde +} + +type CreateLabelOutput struct { + + // The ID of the label that you have created. + LabelId *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationCreateLabelMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson10_serializeOpCreateLabel{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson10_deserializeOpCreateLabel{}, 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_opCreateLabelMiddleware(stack, options); err != nil { + return err + } + if err = addOpCreateLabelValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreateLabel(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_initializeOpCreateLabel struct { + tokenProvider IdempotencyTokenProvider +} + +func (*idempotencyToken_initializeOpCreateLabel) ID() string { + return "OperationIdempotencyTokenAutoFill" +} + +func (m *idempotencyToken_initializeOpCreateLabel) 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.(*CreateLabelInput) + if !ok { + return out, metadata, fmt.Errorf("expected middleware input to be of type *CreateLabelInput ") + } + + 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_opCreateLabelMiddleware(stack *middleware.Stack, cfg Options) error { + return stack.Initialize.Add(&idempotencyToken_initializeOpCreateLabel{tokenProvider: cfg.IdempotencyTokenProvider}, middleware.Before) +} + +func newServiceMetadataMiddleware_opCreateLabel(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "lookoutequipment", + OperationName: "CreateLabel", + } +} diff --git a/service/lookoutequipment/api_op_CreateLabelGroup.go b/service/lookoutequipment/api_op_CreateLabelGroup.go new file mode 100644 index 00000000000..859df7ecb26 --- /dev/null +++ b/service/lookoutequipment/api_op_CreateLabelGroup.go @@ -0,0 +1,179 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package lookoutequipment + +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/lookoutequipment/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Creates a group of labels. +func (c *Client) CreateLabelGroup(ctx context.Context, params *CreateLabelGroupInput, optFns ...func(*Options)) (*CreateLabelGroupOutput, error) { + if params == nil { + params = &CreateLabelGroupInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "CreateLabelGroup", params, optFns, c.addOperationCreateLabelGroupMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*CreateLabelGroupOutput) + out.ResultMetadata = metadata + return out, nil +} + +type CreateLabelGroupInput struct { + + // A unique identifier for the request to create a label group. If you do not set + // the client request token, Lookout for Equipment generates one. + // + // This member is required. + ClientToken *string + + // Names a group of labels. Data in this field will be retained for service usage. + // Follow best practices for the security of your data. + // + // This member is required. + LabelGroupName *string + + // The acceptable fault codes (indicating the type of anomaly associated with the + // label) that can be used with this label group. Data in this field will be + // retained for service usage. Follow best practices for the security of your data. + FaultCodes []string + + // Tags that provide metadata about the label group you are creating. Data in this + // field will be retained for service usage. Follow best practices for the security + // of your data. + Tags []types.Tag + + noSmithyDocumentSerde +} + +type CreateLabelGroupOutput struct { + + // The ARN of the label group that you have created. + LabelGroupArn *string + + // The name of the label group that you have created. Data in this field will be + // retained for service usage. Follow best practices for the security of your data. + LabelGroupName *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationCreateLabelGroupMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson10_serializeOpCreateLabelGroup{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson10_deserializeOpCreateLabelGroup{}, 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_opCreateLabelGroupMiddleware(stack, options); err != nil { + return err + } + if err = addOpCreateLabelGroupValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreateLabelGroup(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_initializeOpCreateLabelGroup struct { + tokenProvider IdempotencyTokenProvider +} + +func (*idempotencyToken_initializeOpCreateLabelGroup) ID() string { + return "OperationIdempotencyTokenAutoFill" +} + +func (m *idempotencyToken_initializeOpCreateLabelGroup) 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.(*CreateLabelGroupInput) + if !ok { + return out, metadata, fmt.Errorf("expected middleware input to be of type *CreateLabelGroupInput ") + } + + 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_opCreateLabelGroupMiddleware(stack *middleware.Stack, cfg Options) error { + return stack.Initialize.Add(&idempotencyToken_initializeOpCreateLabelGroup{tokenProvider: cfg.IdempotencyTokenProvider}, middleware.Before) +} + +func newServiceMetadataMiddleware_opCreateLabelGroup(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "lookoutequipment", + OperationName: "CreateLabelGroup", + } +} diff --git a/service/lookoutequipment/api_op_DeleteLabel.go b/service/lookoutequipment/api_op_DeleteLabel.go new file mode 100644 index 00000000000..46113bfe723 --- /dev/null +++ b/service/lookoutequipment/api_op_DeleteLabel.go @@ -0,0 +1,123 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package lookoutequipment + +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 label. +func (c *Client) DeleteLabel(ctx context.Context, params *DeleteLabelInput, optFns ...func(*Options)) (*DeleteLabelOutput, error) { + if params == nil { + params = &DeleteLabelInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DeleteLabel", params, optFns, c.addOperationDeleteLabelMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DeleteLabelOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DeleteLabelInput struct { + + // The name of the label group that contains the label that you want to delete. + // Data in this field will be retained for service usage. Follow best practices for + // the security of your data. + // + // This member is required. + LabelGroupName *string + + // The ID of the label that you want to delete. + // + // This member is required. + LabelId *string + + noSmithyDocumentSerde +} + +type DeleteLabelOutput struct { + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDeleteLabelMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson10_serializeOpDeleteLabel{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson10_deserializeOpDeleteLabel{}, 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 = addOpDeleteLabelValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteLabel(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_opDeleteLabel(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "lookoutequipment", + OperationName: "DeleteLabel", + } +} diff --git a/service/lookoutequipment/api_op_DeleteLabelGroup.go b/service/lookoutequipment/api_op_DeleteLabelGroup.go new file mode 100644 index 00000000000..6999df99637 --- /dev/null +++ b/service/lookoutequipment/api_op_DeleteLabelGroup.go @@ -0,0 +1,117 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package lookoutequipment + +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 group of labels. +func (c *Client) DeleteLabelGroup(ctx context.Context, params *DeleteLabelGroupInput, optFns ...func(*Options)) (*DeleteLabelGroupOutput, error) { + if params == nil { + params = &DeleteLabelGroupInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DeleteLabelGroup", params, optFns, c.addOperationDeleteLabelGroupMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DeleteLabelGroupOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DeleteLabelGroupInput struct { + + // The name of the label group that you want to delete. Data in this field will be + // retained for service usage. Follow best practices for the security of your data. + // + // This member is required. + LabelGroupName *string + + noSmithyDocumentSerde +} + +type DeleteLabelGroupOutput struct { + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDeleteLabelGroupMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson10_serializeOpDeleteLabelGroup{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson10_deserializeOpDeleteLabelGroup{}, 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 = addOpDeleteLabelGroupValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteLabelGroup(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_opDeleteLabelGroup(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "lookoutequipment", + OperationName: "DeleteLabelGroup", + } +} diff --git a/service/lookoutequipment/api_op_DescribeInferenceScheduler.go b/service/lookoutequipment/api_op_DescribeInferenceScheduler.go index 53f7eb17dcf..fa3b1f67a40 100644 --- a/service/lookoutequipment/api_op_DescribeInferenceScheduler.go +++ b/service/lookoutequipment/api_op_DescribeInferenceScheduler.go @@ -76,6 +76,10 @@ type DescribeInferenceSchedulerOutput struct { // The name of the inference scheduler being described. InferenceSchedulerName *string + // Indicates whether the latest execution for the inference scheduler was Anomalous + // (anomalous events found) or Normal (no anomalous events found). + LatestInferenceResult types.LatestInferenceResult + // The Amazon Resource Name (ARN) of the ML model of the inference scheduler being // described. ModelArn *string diff --git a/service/lookoutequipment/api_op_DescribeLabel.go b/service/lookoutequipment/api_op_DescribeLabel.go new file mode 100644 index 00000000000..22c23e93941 --- /dev/null +++ b/service/lookoutequipment/api_op_DescribeLabel.go @@ -0,0 +1,158 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package lookoutequipment + +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/lookoutequipment/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" + "time" +) + +// Returns the name of the label. +func (c *Client) DescribeLabel(ctx context.Context, params *DescribeLabelInput, optFns ...func(*Options)) (*DescribeLabelOutput, error) { + if params == nil { + params = &DescribeLabelInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DescribeLabel", params, optFns, c.addOperationDescribeLabelMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DescribeLabelOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DescribeLabelInput struct { + + // Returns the name of the group containing the label. + // + // This member is required. + LabelGroupName *string + + // Returns the ID of the label. + // + // This member is required. + LabelId *string + + noSmithyDocumentSerde +} + +type DescribeLabelOutput struct { + + // The time at which the label was created. + CreatedAt *time.Time + + // The end time of the requested label. + EndTime *time.Time + + // Indicates that a label pertains to a particular piece of equipment. + Equipment *string + + // Indicates the type of anomaly associated with the label. Data in this field will + // be retained for service usage. Follow best practices for the security of your + // data. + FaultCode *string + + // The ARN of the requested label group. + LabelGroupArn *string + + // The name of the requested label group. + LabelGroupName *string + + // The ID of the requested label. + LabelId *string + + // Metadata providing additional information about the label. Data in this field + // will be retained for service usage. Follow best practices for the security of + // your data. + Notes *string + + // Indicates whether a labeled event represents an anomaly. + Rating types.LabelRating + + // The start time of the requested label. + StartTime *time.Time + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDescribeLabelMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson10_serializeOpDescribeLabel{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson10_deserializeOpDescribeLabel{}, 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 = addOpDescribeLabelValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeLabel(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_opDescribeLabel(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "lookoutequipment", + OperationName: "DescribeLabel", + } +} diff --git a/service/lookoutequipment/api_op_DescribeLabelGroup.go b/service/lookoutequipment/api_op_DescribeLabelGroup.go new file mode 100644 index 00000000000..a22170f5c2f --- /dev/null +++ b/service/lookoutequipment/api_op_DescribeLabelGroup.go @@ -0,0 +1,134 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package lookoutequipment + +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" + "time" +) + +// Returns information about the label group. +func (c *Client) DescribeLabelGroup(ctx context.Context, params *DescribeLabelGroupInput, optFns ...func(*Options)) (*DescribeLabelGroupOutput, error) { + if params == nil { + params = &DescribeLabelGroupInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DescribeLabelGroup", params, optFns, c.addOperationDescribeLabelGroupMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DescribeLabelGroupOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DescribeLabelGroupInput struct { + + // Returns the name of the label group. + // + // This member is required. + LabelGroupName *string + + noSmithyDocumentSerde +} + +type DescribeLabelGroupOutput struct { + + // The time at which the label group was created. + CreatedAt *time.Time + + // Codes indicating the type of anomaly associated with the labels in the lagbel + // group. + FaultCodes []string + + // The ARN of the label group. + LabelGroupArn *string + + // The name of the label group. + LabelGroupName *string + + // The time at which the label group was updated. + UpdatedAt *time.Time + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDescribeLabelGroupMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson10_serializeOpDescribeLabelGroup{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson10_deserializeOpDescribeLabelGroup{}, 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 = addOpDescribeLabelGroupValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDescribeLabelGroup(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_opDescribeLabelGroup(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "lookoutequipment", + OperationName: "DescribeLabelGroup", + } +} diff --git a/service/lookoutequipment/api_op_ListInferenceEvents.go b/service/lookoutequipment/api_op_ListInferenceEvents.go index a3654cc32f2..021db42f7ad 100644 --- a/service/lookoutequipment/api_op_ListInferenceEvents.go +++ b/service/lookoutequipment/api_op_ListInferenceEvents.go @@ -37,14 +37,14 @@ type ListInferenceEventsInput struct { // This member is required. InferenceSchedulerName *string - // Lookout for Equipment will return all the inference events with end time equal - // to or less than the end time given. + // Returns all the inference events with an end start time equal to or greater than + // less than the end time given // // This member is required. IntervalEndTime *time.Time - // Lookout for Equipment will return all the inference events with start time equal - // to or greater than the start time given. + // Lookout for Equipment will return all the inference events with an end time + // equal to or greater than the start time given. // // This member is required. IntervalStartTime *time.Time diff --git a/service/lookoutequipment/api_op_ListLabelGroups.go b/service/lookoutequipment/api_op_ListLabelGroups.go new file mode 100644 index 00000000000..18f90ea7545 --- /dev/null +++ b/service/lookoutequipment/api_op_ListLabelGroups.go @@ -0,0 +1,218 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package lookoutequipment + +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/lookoutequipment/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Returns a list of the label groups. +func (c *Client) ListLabelGroups(ctx context.Context, params *ListLabelGroupsInput, optFns ...func(*Options)) (*ListLabelGroupsOutput, error) { + if params == nil { + params = &ListLabelGroupsInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "ListLabelGroups", params, optFns, c.addOperationListLabelGroupsMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*ListLabelGroupsOutput) + out.ResultMetadata = metadata + return out, nil +} + +type ListLabelGroupsInput struct { + + // The beginning of the name of the label groups to be listed. + LabelGroupNameBeginsWith *string + + // Specifies the maximum number of label groups to list. + MaxResults *int32 + + // An opaque pagination token indicating where to continue the listing of label + // groups. + NextToken *string + + noSmithyDocumentSerde +} + +type ListLabelGroupsOutput struct { + + // A summary of the label groups. + LabelGroupSummaries []types.LabelGroupSummary + + // An opaque pagination token indicating where to continue the listing of label + // groups. + NextToken *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationListLabelGroupsMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson10_serializeOpListLabelGroups{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson10_deserializeOpListLabelGroups{}, 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_opListLabelGroups(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 +} + +// ListLabelGroupsAPIClient is a client that implements the ListLabelGroups +// operation. +type ListLabelGroupsAPIClient interface { + ListLabelGroups(context.Context, *ListLabelGroupsInput, ...func(*Options)) (*ListLabelGroupsOutput, error) +} + +var _ ListLabelGroupsAPIClient = (*Client)(nil) + +// ListLabelGroupsPaginatorOptions is the paginator options for ListLabelGroups +type ListLabelGroupsPaginatorOptions struct { + // Specifies the maximum number of label groups to list. + 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 +} + +// ListLabelGroupsPaginator is a paginator for ListLabelGroups +type ListLabelGroupsPaginator struct { + options ListLabelGroupsPaginatorOptions + client ListLabelGroupsAPIClient + params *ListLabelGroupsInput + nextToken *string + firstPage bool +} + +// NewListLabelGroupsPaginator returns a new ListLabelGroupsPaginator +func NewListLabelGroupsPaginator(client ListLabelGroupsAPIClient, params *ListLabelGroupsInput, optFns ...func(*ListLabelGroupsPaginatorOptions)) *ListLabelGroupsPaginator { + if params == nil { + params = &ListLabelGroupsInput{} + } + + options := ListLabelGroupsPaginatorOptions{} + if params.MaxResults != nil { + options.Limit = *params.MaxResults + } + + for _, fn := range optFns { + fn(&options) + } + + return &ListLabelGroupsPaginator{ + options: options, + client: client, + params: params, + firstPage: true, + nextToken: params.NextToken, + } +} + +// HasMorePages returns a boolean indicating whether more pages are available +func (p *ListLabelGroupsPaginator) HasMorePages() bool { + return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0) +} + +// NextPage retrieves the next ListLabelGroups page. +func (p *ListLabelGroupsPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ListLabelGroupsOutput, 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.ListLabelGroups(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_opListLabelGroups(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "lookoutequipment", + OperationName: "ListLabelGroups", + } +} diff --git a/service/lookoutequipment/api_op_ListLabels.go b/service/lookoutequipment/api_op_ListLabels.go new file mode 100644 index 00000000000..a4b8dc4b787 --- /dev/null +++ b/service/lookoutequipment/api_op_ListLabels.go @@ -0,0 +1,235 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package lookoutequipment + +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/lookoutequipment/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" + "time" +) + +// Provides a list of labels. +func (c *Client) ListLabels(ctx context.Context, params *ListLabelsInput, optFns ...func(*Options)) (*ListLabelsOutput, error) { + if params == nil { + params = &ListLabelsInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "ListLabels", params, optFns, c.addOperationListLabelsMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*ListLabelsOutput) + out.ResultMetadata = metadata + return out, nil +} + +type ListLabelsInput struct { + + // Retruns the name of the label group. + // + // This member is required. + LabelGroupName *string + + // Lists the labels that pertain to a particular piece of equipment. + Equipment *string + + // Returns labels with a particular fault code. + FaultCode *string + + // Returns all labels with a start time earlier than the end time given. + IntervalEndTime *time.Time + + // Returns all the labels with a end time equal to or later than the start time + // given. + IntervalStartTime *time.Time + + // Specifies the maximum number of labels to list. + MaxResults *int32 + + // An opaque pagination token indicating where to continue the listing of label + // groups. + NextToken *string + + noSmithyDocumentSerde +} + +type ListLabelsOutput struct { + + // A summary of the items in the label group. + LabelSummaries []types.LabelSummary + + // An opaque pagination token indicating where to continue the listing of datasets. + NextToken *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationListLabelsMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson10_serializeOpListLabels{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson10_deserializeOpListLabels{}, 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 = addOpListLabelsValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opListLabels(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 +} + +// ListLabelsAPIClient is a client that implements the ListLabels operation. +type ListLabelsAPIClient interface { + ListLabels(context.Context, *ListLabelsInput, ...func(*Options)) (*ListLabelsOutput, error) +} + +var _ ListLabelsAPIClient = (*Client)(nil) + +// ListLabelsPaginatorOptions is the paginator options for ListLabels +type ListLabelsPaginatorOptions struct { + // Specifies the maximum number of labels to list. + 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 +} + +// ListLabelsPaginator is a paginator for ListLabels +type ListLabelsPaginator struct { + options ListLabelsPaginatorOptions + client ListLabelsAPIClient + params *ListLabelsInput + nextToken *string + firstPage bool +} + +// NewListLabelsPaginator returns a new ListLabelsPaginator +func NewListLabelsPaginator(client ListLabelsAPIClient, params *ListLabelsInput, optFns ...func(*ListLabelsPaginatorOptions)) *ListLabelsPaginator { + if params == nil { + params = &ListLabelsInput{} + } + + options := ListLabelsPaginatorOptions{} + if params.MaxResults != nil { + options.Limit = *params.MaxResults + } + + for _, fn := range optFns { + fn(&options) + } + + return &ListLabelsPaginator{ + options: options, + client: client, + params: params, + firstPage: true, + nextToken: params.NextToken, + } +} + +// HasMorePages returns a boolean indicating whether more pages are available +func (p *ListLabelsPaginator) HasMorePages() bool { + return p.firstPage || (p.nextToken != nil && len(*p.nextToken) != 0) +} + +// NextPage retrieves the next ListLabels page. +func (p *ListLabelsPaginator) NextPage(ctx context.Context, optFns ...func(*Options)) (*ListLabelsOutput, 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.ListLabels(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_opListLabels(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "lookoutequipment", + OperationName: "ListLabels", + } +} diff --git a/service/lookoutequipment/api_op_UpdateLabelGroup.go b/service/lookoutequipment/api_op_UpdateLabelGroup.go new file mode 100644 index 00000000000..8ef9bb2e9a2 --- /dev/null +++ b/service/lookoutequipment/api_op_UpdateLabelGroup.go @@ -0,0 +1,121 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package lookoutequipment + +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 label group. +func (c *Client) UpdateLabelGroup(ctx context.Context, params *UpdateLabelGroupInput, optFns ...func(*Options)) (*UpdateLabelGroupOutput, error) { + if params == nil { + params = &UpdateLabelGroupInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "UpdateLabelGroup", params, optFns, c.addOperationUpdateLabelGroupMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*UpdateLabelGroupOutput) + out.ResultMetadata = metadata + return out, nil +} + +type UpdateLabelGroupInput struct { + + // The name of the label group to be updated. + // + // This member is required. + LabelGroupName *string + + // Updates the code indicating the type of anomaly associated with the label. Data + // in this field will be retained for service usage. Follow best practices for the + // security of your data. + FaultCodes []string + + noSmithyDocumentSerde +} + +type UpdateLabelGroupOutput struct { + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationUpdateLabelGroupMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsAwsjson10_serializeOpUpdateLabelGroup{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsAwsjson10_deserializeOpUpdateLabelGroup{}, 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 = addOpUpdateLabelGroupValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opUpdateLabelGroup(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_opUpdateLabelGroup(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "lookoutequipment", + OperationName: "UpdateLabelGroup", + } +} diff --git a/service/lookoutequipment/deserializers.go b/service/lookoutequipment/deserializers.go index d1320f7f7b1..0fe9cfcf043 100644 --- a/service/lookoutequipment/deserializers.go +++ b/service/lookoutequipment/deserializers.go @@ -276,14 +276,14 @@ func awsAwsjson10_deserializeOpErrorCreateInferenceScheduler(response *smithyhtt } } -type awsAwsjson10_deserializeOpCreateModel struct { +type awsAwsjson10_deserializeOpCreateLabel struct { } -func (*awsAwsjson10_deserializeOpCreateModel) ID() string { +func (*awsAwsjson10_deserializeOpCreateLabel) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpCreateModel) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpCreateLabel) 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) @@ -297,9 +297,9 @@ func (m *awsAwsjson10_deserializeOpCreateModel) HandleDeserialize(ctx context.Co } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorCreateModel(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorCreateLabel(response, &metadata) } - output := &CreateModelOutput{} + output := &CreateLabelOutput{} out.Result = output var buff [1024]byte @@ -319,7 +319,7 @@ func (m *awsAwsjson10_deserializeOpCreateModel) HandleDeserialize(ctx context.Co return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentCreateModelOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentCreateLabelOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -333,7 +333,7 @@ func (m *awsAwsjson10_deserializeOpCreateModel) HandleDeserialize(ctx context.Co return out, metadata, err } -func awsAwsjson10_deserializeOpErrorCreateModel(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorCreateLabel(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)} @@ -405,14 +405,14 @@ func awsAwsjson10_deserializeOpErrorCreateModel(response *smithyhttp.Response, m } } -type awsAwsjson10_deserializeOpDeleteDataset struct { +type awsAwsjson10_deserializeOpCreateLabelGroup struct { } -func (*awsAwsjson10_deserializeOpDeleteDataset) ID() string { +func (*awsAwsjson10_deserializeOpCreateLabelGroup) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpDeleteDataset) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpCreateLabelGroup) 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) @@ -426,21 +426,43 @@ func (m *awsAwsjson10_deserializeOpDeleteDataset) HandleDeserialize(ctx context. } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorDeleteDataset(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorCreateLabelGroup(response, &metadata) } - output := &DeleteDatasetOutput{} + output := &CreateLabelGroupOutput{} 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), + 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 = awsAwsjson10_deserializeOpDocumentCreateLabelGroupOutput(&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 awsAwsjson10_deserializeOpErrorDeleteDataset(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorCreateLabelGroup(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)} @@ -490,12 +512,15 @@ func awsAwsjson10_deserializeOpErrorDeleteDataset(response *smithyhttp.Response, case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): - return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + case strings.EqualFold("ServiceQuotaExceededException", errorCode): + return awsAwsjson10_deserializeErrorServiceQuotaExceededException(response, errorBody) case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) + case strings.EqualFold("ValidationException", errorCode): + return awsAwsjson10_deserializeErrorValidationException(response, errorBody) + default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -506,14 +531,14 @@ func awsAwsjson10_deserializeOpErrorDeleteDataset(response *smithyhttp.Response, } } -type awsAwsjson10_deserializeOpDeleteInferenceScheduler struct { +type awsAwsjson10_deserializeOpCreateModel struct { } -func (*awsAwsjson10_deserializeOpDeleteInferenceScheduler) ID() string { +func (*awsAwsjson10_deserializeOpCreateModel) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpDeleteInferenceScheduler) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpCreateModel) 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) @@ -527,21 +552,43 @@ func (m *awsAwsjson10_deserializeOpDeleteInferenceScheduler) HandleDeserialize(c } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorDeleteInferenceScheduler(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorCreateModel(response, &metadata) } - output := &DeleteInferenceSchedulerOutput{} + output := &CreateModelOutput{} 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), + 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 = awsAwsjson10_deserializeOpDocumentCreateModelOutput(&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 awsAwsjson10_deserializeOpErrorDeleteInferenceScheduler(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorCreateModel(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)} @@ -594,6 +641,9 @@ func awsAwsjson10_deserializeOpErrorDeleteInferenceScheduler(response *smithyhtt case strings.EqualFold("ResourceNotFoundException", errorCode): return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + case strings.EqualFold("ServiceQuotaExceededException", errorCode): + return awsAwsjson10_deserializeErrorServiceQuotaExceededException(response, errorBody) + case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -610,14 +660,14 @@ func awsAwsjson10_deserializeOpErrorDeleteInferenceScheduler(response *smithyhtt } } -type awsAwsjson10_deserializeOpDeleteModel struct { +type awsAwsjson10_deserializeOpDeleteDataset struct { } -func (*awsAwsjson10_deserializeOpDeleteModel) ID() string { +func (*awsAwsjson10_deserializeOpDeleteDataset) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpDeleteModel) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDeleteDataset) 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) @@ -631,9 +681,9 @@ func (m *awsAwsjson10_deserializeOpDeleteModel) HandleDeserialize(ctx context.Co } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorDeleteModel(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDeleteDataset(response, &metadata) } - output := &DeleteModelOutput{} + output := &DeleteDatasetOutput{} out.Result = output if _, err = io.Copy(ioutil.Discard, response.Body); err != nil { @@ -645,7 +695,7 @@ func (m *awsAwsjson10_deserializeOpDeleteModel) HandleDeserialize(ctx context.Co return out, metadata, err } -func awsAwsjson10_deserializeOpErrorDeleteModel(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDeleteDataset(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)} @@ -711,14 +761,14 @@ func awsAwsjson10_deserializeOpErrorDeleteModel(response *smithyhttp.Response, m } } -type awsAwsjson10_deserializeOpDescribeDataIngestionJob struct { +type awsAwsjson10_deserializeOpDeleteInferenceScheduler struct { } -func (*awsAwsjson10_deserializeOpDescribeDataIngestionJob) ID() string { +func (*awsAwsjson10_deserializeOpDeleteInferenceScheduler) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpDescribeDataIngestionJob) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDeleteInferenceScheduler) 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) @@ -732,43 +782,21 @@ func (m *awsAwsjson10_deserializeOpDescribeDataIngestionJob) HandleDeserialize(c } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorDescribeDataIngestionJob(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDeleteInferenceScheduler(response, &metadata) } - output := &DescribeDataIngestionJobOutput{} + output := &DeleteInferenceSchedulerOutput{} 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 = awsAwsjson10_deserializeOpDocumentDescribeDataIngestionJobOutput(&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(), + 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 } return out, metadata, err } -func awsAwsjson10_deserializeOpErrorDescribeDataIngestionJob(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDeleteInferenceScheduler(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)} @@ -812,6 +840,9 @@ func awsAwsjson10_deserializeOpErrorDescribeDataIngestionJob(response *smithyhtt case strings.EqualFold("AccessDeniedException", errorCode): return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + case strings.EqualFold("ConflictException", errorCode): + return awsAwsjson10_deserializeErrorConflictException(response, errorBody) + case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) @@ -834,14 +865,14 @@ func awsAwsjson10_deserializeOpErrorDescribeDataIngestionJob(response *smithyhtt } } -type awsAwsjson10_deserializeOpDescribeDataset struct { +type awsAwsjson10_deserializeOpDeleteLabel struct { } -func (*awsAwsjson10_deserializeOpDescribeDataset) ID() string { +func (*awsAwsjson10_deserializeOpDeleteLabel) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpDescribeDataset) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDeleteLabel) 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) @@ -855,43 +886,21 @@ func (m *awsAwsjson10_deserializeOpDescribeDataset) HandleDeserialize(ctx contex } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorDescribeDataset(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDeleteLabel(response, &metadata) } - output := &DescribeDatasetOutput{} + output := &DeleteLabelOutput{} 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 = awsAwsjson10_deserializeOpDocumentDescribeDatasetOutput(&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(), + 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 } return out, metadata, err } -func awsAwsjson10_deserializeOpErrorDescribeDataset(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDeleteLabel(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)} @@ -935,6 +944,9 @@ func awsAwsjson10_deserializeOpErrorDescribeDataset(response *smithyhttp.Respons case strings.EqualFold("AccessDeniedException", errorCode): return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + case strings.EqualFold("ConflictException", errorCode): + return awsAwsjson10_deserializeErrorConflictException(response, errorBody) + case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) @@ -944,9 +956,6 @@ func awsAwsjson10_deserializeOpErrorDescribeDataset(response *smithyhttp.Respons case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) - case strings.EqualFold("ValidationException", errorCode): - return awsAwsjson10_deserializeErrorValidationException(response, errorBody) - default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -957,14 +966,14 @@ func awsAwsjson10_deserializeOpErrorDescribeDataset(response *smithyhttp.Respons } } -type awsAwsjson10_deserializeOpDescribeInferenceScheduler struct { +type awsAwsjson10_deserializeOpDeleteLabelGroup struct { } -func (*awsAwsjson10_deserializeOpDescribeInferenceScheduler) ID() string { +func (*awsAwsjson10_deserializeOpDeleteLabelGroup) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpDescribeInferenceScheduler) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDeleteLabelGroup) 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) @@ -978,43 +987,21 @@ func (m *awsAwsjson10_deserializeOpDescribeInferenceScheduler) HandleDeserialize } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorDescribeInferenceScheduler(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDeleteLabelGroup(response, &metadata) } - output := &DescribeInferenceSchedulerOutput{} + output := &DeleteLabelGroupOutput{} 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 = awsAwsjson10_deserializeOpDocumentDescribeInferenceSchedulerOutput(&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(), + 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 } return out, metadata, err } -func awsAwsjson10_deserializeOpErrorDescribeInferenceScheduler(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDeleteLabelGroup(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)} @@ -1058,6 +1045,9 @@ func awsAwsjson10_deserializeOpErrorDescribeInferenceScheduler(response *smithyh case strings.EqualFold("AccessDeniedException", errorCode): return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + case strings.EqualFold("ConflictException", errorCode): + return awsAwsjson10_deserializeErrorConflictException(response, errorBody) + case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) @@ -1067,9 +1057,6 @@ func awsAwsjson10_deserializeOpErrorDescribeInferenceScheduler(response *smithyh case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) - case strings.EqualFold("ValidationException", errorCode): - return awsAwsjson10_deserializeErrorValidationException(response, errorBody) - default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -1080,14 +1067,14 @@ func awsAwsjson10_deserializeOpErrorDescribeInferenceScheduler(response *smithyh } } -type awsAwsjson10_deserializeOpDescribeModel struct { +type awsAwsjson10_deserializeOpDeleteModel struct { } -func (*awsAwsjson10_deserializeOpDescribeModel) ID() string { +func (*awsAwsjson10_deserializeOpDeleteModel) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpDescribeModel) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDeleteModel) 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) @@ -1101,43 +1088,21 @@ func (m *awsAwsjson10_deserializeOpDescribeModel) HandleDeserialize(ctx context. } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorDescribeModel(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDeleteModel(response, &metadata) } - output := &DescribeModelOutput{} + output := &DeleteModelOutput{} 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(), + 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 - } - - err = awsAwsjson10_deserializeOpDocumentDescribeModelOutput(&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 awsAwsjson10_deserializeOpErrorDescribeModel(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDeleteModel(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)} @@ -1181,6 +1146,9 @@ func awsAwsjson10_deserializeOpErrorDescribeModel(response *smithyhttp.Response, case strings.EqualFold("AccessDeniedException", errorCode): return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + case strings.EqualFold("ConflictException", errorCode): + return awsAwsjson10_deserializeErrorConflictException(response, errorBody) + case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) @@ -1190,9 +1158,6 @@ func awsAwsjson10_deserializeOpErrorDescribeModel(response *smithyhttp.Response, case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) - case strings.EqualFold("ValidationException", errorCode): - return awsAwsjson10_deserializeErrorValidationException(response, errorBody) - default: genericError := &smithy.GenericAPIError{ Code: errorCode, @@ -1203,14 +1168,14 @@ func awsAwsjson10_deserializeOpErrorDescribeModel(response *smithyhttp.Response, } } -type awsAwsjson10_deserializeOpListDataIngestionJobs struct { +type awsAwsjson10_deserializeOpDescribeDataIngestionJob struct { } -func (*awsAwsjson10_deserializeOpListDataIngestionJobs) ID() string { +func (*awsAwsjson10_deserializeOpDescribeDataIngestionJob) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpListDataIngestionJobs) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDescribeDataIngestionJob) 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) @@ -1224,9 +1189,9 @@ func (m *awsAwsjson10_deserializeOpListDataIngestionJobs) HandleDeserialize(ctx } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorListDataIngestionJobs(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDescribeDataIngestionJob(response, &metadata) } - output := &ListDataIngestionJobsOutput{} + output := &DescribeDataIngestionJobOutput{} out.Result = output var buff [1024]byte @@ -1246,7 +1211,7 @@ func (m *awsAwsjson10_deserializeOpListDataIngestionJobs) HandleDeserialize(ctx return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentListDataIngestionJobsOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentDescribeDataIngestionJobOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1260,7 +1225,7 @@ func (m *awsAwsjson10_deserializeOpListDataIngestionJobs) HandleDeserialize(ctx return out, metadata, err } -func awsAwsjson10_deserializeOpErrorListDataIngestionJobs(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDescribeDataIngestionJob(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)} @@ -1307,6 +1272,9 @@ func awsAwsjson10_deserializeOpErrorListDataIngestionJobs(response *smithyhttp.R case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -1323,14 +1291,14 @@ func awsAwsjson10_deserializeOpErrorListDataIngestionJobs(response *smithyhttp.R } } -type awsAwsjson10_deserializeOpListDatasets struct { +type awsAwsjson10_deserializeOpDescribeDataset struct { } -func (*awsAwsjson10_deserializeOpListDatasets) ID() string { +func (*awsAwsjson10_deserializeOpDescribeDataset) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpListDatasets) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDescribeDataset) 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) @@ -1344,9 +1312,9 @@ func (m *awsAwsjson10_deserializeOpListDatasets) HandleDeserialize(ctx context.C } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorListDatasets(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDescribeDataset(response, &metadata) } - output := &ListDatasetsOutput{} + output := &DescribeDatasetOutput{} out.Result = output var buff [1024]byte @@ -1366,7 +1334,7 @@ func (m *awsAwsjson10_deserializeOpListDatasets) HandleDeserialize(ctx context.C return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentListDatasetsOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentDescribeDatasetOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1380,7 +1348,7 @@ func (m *awsAwsjson10_deserializeOpListDatasets) HandleDeserialize(ctx context.C return out, metadata, err } -func awsAwsjson10_deserializeOpErrorListDatasets(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDescribeDataset(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)} @@ -1427,6 +1395,9 @@ func awsAwsjson10_deserializeOpErrorListDatasets(response *smithyhttp.Response, case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -1443,14 +1414,14 @@ func awsAwsjson10_deserializeOpErrorListDatasets(response *smithyhttp.Response, } } -type awsAwsjson10_deserializeOpListInferenceEvents struct { +type awsAwsjson10_deserializeOpDescribeInferenceScheduler struct { } -func (*awsAwsjson10_deserializeOpListInferenceEvents) ID() string { +func (*awsAwsjson10_deserializeOpDescribeInferenceScheduler) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpListInferenceEvents) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDescribeInferenceScheduler) 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) @@ -1464,9 +1435,9 @@ func (m *awsAwsjson10_deserializeOpListInferenceEvents) HandleDeserialize(ctx co } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorListInferenceEvents(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDescribeInferenceScheduler(response, &metadata) } - output := &ListInferenceEventsOutput{} + output := &DescribeInferenceSchedulerOutput{} out.Result = output var buff [1024]byte @@ -1486,7 +1457,7 @@ func (m *awsAwsjson10_deserializeOpListInferenceEvents) HandleDeserialize(ctx co return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentListInferenceEventsOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentDescribeInferenceSchedulerOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1500,7 +1471,7 @@ func (m *awsAwsjson10_deserializeOpListInferenceEvents) HandleDeserialize(ctx co return out, metadata, err } -func awsAwsjson10_deserializeOpErrorListInferenceEvents(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDescribeInferenceScheduler(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)} @@ -1566,14 +1537,14 @@ func awsAwsjson10_deserializeOpErrorListInferenceEvents(response *smithyhttp.Res } } -type awsAwsjson10_deserializeOpListInferenceExecutions struct { +type awsAwsjson10_deserializeOpDescribeLabel struct { } -func (*awsAwsjson10_deserializeOpListInferenceExecutions) ID() string { +func (*awsAwsjson10_deserializeOpDescribeLabel) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpListInferenceExecutions) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDescribeLabel) 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) @@ -1587,9 +1558,9 @@ func (m *awsAwsjson10_deserializeOpListInferenceExecutions) HandleDeserialize(ct } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorListInferenceExecutions(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDescribeLabel(response, &metadata) } - output := &ListInferenceExecutionsOutput{} + output := &DescribeLabelOutput{} out.Result = output var buff [1024]byte @@ -1609,7 +1580,7 @@ func (m *awsAwsjson10_deserializeOpListInferenceExecutions) HandleDeserialize(ct return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentListInferenceExecutionsOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentDescribeLabelOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1623,7 +1594,7 @@ func (m *awsAwsjson10_deserializeOpListInferenceExecutions) HandleDeserialize(ct return out, metadata, err } -func awsAwsjson10_deserializeOpErrorListInferenceExecutions(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDescribeLabel(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)} @@ -1689,14 +1660,14 @@ func awsAwsjson10_deserializeOpErrorListInferenceExecutions(response *smithyhttp } } -type awsAwsjson10_deserializeOpListInferenceSchedulers struct { +type awsAwsjson10_deserializeOpDescribeLabelGroup struct { } -func (*awsAwsjson10_deserializeOpListInferenceSchedulers) ID() string { +func (*awsAwsjson10_deserializeOpDescribeLabelGroup) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpListInferenceSchedulers) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDescribeLabelGroup) 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) @@ -1710,9 +1681,9 @@ func (m *awsAwsjson10_deserializeOpListInferenceSchedulers) HandleDeserialize(ct } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorListInferenceSchedulers(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDescribeLabelGroup(response, &metadata) } - output := &ListInferenceSchedulersOutput{} + output := &DescribeLabelGroupOutput{} out.Result = output var buff [1024]byte @@ -1732,7 +1703,7 @@ func (m *awsAwsjson10_deserializeOpListInferenceSchedulers) HandleDeserialize(ct return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentListInferenceSchedulersOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentDescribeLabelGroupOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1746,7 +1717,7 @@ func (m *awsAwsjson10_deserializeOpListInferenceSchedulers) HandleDeserialize(ct return out, metadata, err } -func awsAwsjson10_deserializeOpErrorListInferenceSchedulers(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDescribeLabelGroup(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)} @@ -1793,6 +1764,9 @@ func awsAwsjson10_deserializeOpErrorListInferenceSchedulers(response *smithyhttp case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -1809,14 +1783,14 @@ func awsAwsjson10_deserializeOpErrorListInferenceSchedulers(response *smithyhttp } } -type awsAwsjson10_deserializeOpListModels struct { +type awsAwsjson10_deserializeOpDescribeModel struct { } -func (*awsAwsjson10_deserializeOpListModels) ID() string { +func (*awsAwsjson10_deserializeOpDescribeModel) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpListModels) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpDescribeModel) 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) @@ -1830,9 +1804,9 @@ func (m *awsAwsjson10_deserializeOpListModels) HandleDeserialize(ctx context.Con } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorListModels(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorDescribeModel(response, &metadata) } - output := &ListModelsOutput{} + output := &DescribeModelOutput{} out.Result = output var buff [1024]byte @@ -1852,7 +1826,7 @@ func (m *awsAwsjson10_deserializeOpListModels) HandleDeserialize(ctx context.Con return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentListModelsOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentDescribeModelOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1866,7 +1840,7 @@ func (m *awsAwsjson10_deserializeOpListModels) HandleDeserialize(ctx context.Con return out, metadata, err } -func awsAwsjson10_deserializeOpErrorListModels(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorDescribeModel(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)} @@ -1913,6 +1887,9 @@ func awsAwsjson10_deserializeOpErrorListModels(response *smithyhttp.Response, me case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -1929,14 +1906,14 @@ func awsAwsjson10_deserializeOpErrorListModels(response *smithyhttp.Response, me } } -type awsAwsjson10_deserializeOpListSensorStatistics struct { +type awsAwsjson10_deserializeOpListDataIngestionJobs struct { } -func (*awsAwsjson10_deserializeOpListSensorStatistics) ID() string { +func (*awsAwsjson10_deserializeOpListDataIngestionJobs) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpListSensorStatistics) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpListDataIngestionJobs) 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) @@ -1950,9 +1927,9 @@ func (m *awsAwsjson10_deserializeOpListSensorStatistics) HandleDeserialize(ctx c } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorListSensorStatistics(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorListDataIngestionJobs(response, &metadata) } - output := &ListSensorStatisticsOutput{} + output := &ListDataIngestionJobsOutput{} out.Result = output var buff [1024]byte @@ -1972,7 +1949,7 @@ func (m *awsAwsjson10_deserializeOpListSensorStatistics) HandleDeserialize(ctx c return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentListSensorStatisticsOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentListDataIngestionJobsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -1986,7 +1963,7 @@ func (m *awsAwsjson10_deserializeOpListSensorStatistics) HandleDeserialize(ctx c return out, metadata, err } -func awsAwsjson10_deserializeOpErrorListSensorStatistics(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorListDataIngestionJobs(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)} @@ -2033,9 +2010,6 @@ func awsAwsjson10_deserializeOpErrorListSensorStatistics(response *smithyhttp.Re case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): - return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) - case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -2052,14 +2026,14 @@ func awsAwsjson10_deserializeOpErrorListSensorStatistics(response *smithyhttp.Re } } -type awsAwsjson10_deserializeOpListTagsForResource struct { +type awsAwsjson10_deserializeOpListDatasets struct { } -func (*awsAwsjson10_deserializeOpListTagsForResource) ID() string { +func (*awsAwsjson10_deserializeOpListDatasets) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpListTagsForResource) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpListDatasets) 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) @@ -2073,9 +2047,9 @@ func (m *awsAwsjson10_deserializeOpListTagsForResource) HandleDeserialize(ctx co } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorListTagsForResource(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorListDatasets(response, &metadata) } - output := &ListTagsForResourceOutput{} + output := &ListDatasetsOutput{} out.Result = output var buff [1024]byte @@ -2095,7 +2069,7 @@ func (m *awsAwsjson10_deserializeOpListTagsForResource) HandleDeserialize(ctx co return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentListTagsForResourceOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentListDatasetsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -2109,7 +2083,7 @@ func (m *awsAwsjson10_deserializeOpListTagsForResource) HandleDeserialize(ctx co return out, metadata, err } -func awsAwsjson10_deserializeOpErrorListTagsForResource(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorListDatasets(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)} @@ -2156,9 +2130,6 @@ func awsAwsjson10_deserializeOpErrorListTagsForResource(response *smithyhttp.Res case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): - return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) - case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -2175,14 +2146,14 @@ func awsAwsjson10_deserializeOpErrorListTagsForResource(response *smithyhttp.Res } } -type awsAwsjson10_deserializeOpStartDataIngestionJob struct { +type awsAwsjson10_deserializeOpListInferenceEvents struct { } -func (*awsAwsjson10_deserializeOpStartDataIngestionJob) ID() string { +func (*awsAwsjson10_deserializeOpListInferenceEvents) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpStartDataIngestionJob) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpListInferenceEvents) 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) @@ -2196,9 +2167,9 @@ func (m *awsAwsjson10_deserializeOpStartDataIngestionJob) HandleDeserialize(ctx } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorStartDataIngestionJob(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorListInferenceEvents(response, &metadata) } - output := &StartDataIngestionJobOutput{} + output := &ListInferenceEventsOutput{} out.Result = output var buff [1024]byte @@ -2218,7 +2189,7 @@ func (m *awsAwsjson10_deserializeOpStartDataIngestionJob) HandleDeserialize(ctx return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentStartDataIngestionJobOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentListInferenceEventsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -2232,7 +2203,7 @@ func (m *awsAwsjson10_deserializeOpStartDataIngestionJob) HandleDeserialize(ctx return out, metadata, err } -func awsAwsjson10_deserializeOpErrorStartDataIngestionJob(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorListInferenceEvents(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)} @@ -2276,18 +2247,12 @@ func awsAwsjson10_deserializeOpErrorStartDataIngestionJob(response *smithyhttp.R case strings.EqualFold("AccessDeniedException", errorCode): return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) - case strings.EqualFold("ConflictException", errorCode): - return awsAwsjson10_deserializeErrorConflictException(response, errorBody) - case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) case strings.EqualFold("ResourceNotFoundException", errorCode): return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) - case strings.EqualFold("ServiceQuotaExceededException", errorCode): - return awsAwsjson10_deserializeErrorServiceQuotaExceededException(response, errorBody) - case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -2304,14 +2269,14 @@ func awsAwsjson10_deserializeOpErrorStartDataIngestionJob(response *smithyhttp.R } } -type awsAwsjson10_deserializeOpStartInferenceScheduler struct { +type awsAwsjson10_deserializeOpListInferenceExecutions struct { } -func (*awsAwsjson10_deserializeOpStartInferenceScheduler) ID() string { +func (*awsAwsjson10_deserializeOpListInferenceExecutions) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpStartInferenceScheduler) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpListInferenceExecutions) 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) @@ -2325,9 +2290,9 @@ func (m *awsAwsjson10_deserializeOpStartInferenceScheduler) HandleDeserialize(ct } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorStartInferenceScheduler(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorListInferenceExecutions(response, &metadata) } - output := &StartInferenceSchedulerOutput{} + output := &ListInferenceExecutionsOutput{} out.Result = output var buff [1024]byte @@ -2347,7 +2312,7 @@ func (m *awsAwsjson10_deserializeOpStartInferenceScheduler) HandleDeserialize(ct return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentStartInferenceSchedulerOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentListInferenceExecutionsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -2361,7 +2326,7 @@ func (m *awsAwsjson10_deserializeOpStartInferenceScheduler) HandleDeserialize(ct return out, metadata, err } -func awsAwsjson10_deserializeOpErrorStartInferenceScheduler(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorListInferenceExecutions(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)} @@ -2405,9 +2370,6 @@ func awsAwsjson10_deserializeOpErrorStartInferenceScheduler(response *smithyhttp case strings.EqualFold("AccessDeniedException", errorCode): return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) - case strings.EqualFold("ConflictException", errorCode): - return awsAwsjson10_deserializeErrorConflictException(response, errorBody) - case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) @@ -2430,14 +2392,14 @@ func awsAwsjson10_deserializeOpErrorStartInferenceScheduler(response *smithyhttp } } -type awsAwsjson10_deserializeOpStopInferenceScheduler struct { +type awsAwsjson10_deserializeOpListInferenceSchedulers struct { } -func (*awsAwsjson10_deserializeOpStopInferenceScheduler) ID() string { +func (*awsAwsjson10_deserializeOpListInferenceSchedulers) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpStopInferenceScheduler) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpListInferenceSchedulers) 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) @@ -2451,9 +2413,9 @@ func (m *awsAwsjson10_deserializeOpStopInferenceScheduler) HandleDeserialize(ctx } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorStopInferenceScheduler(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorListInferenceSchedulers(response, &metadata) } - output := &StopInferenceSchedulerOutput{} + output := &ListInferenceSchedulersOutput{} out.Result = output var buff [1024]byte @@ -2473,7 +2435,7 @@ func (m *awsAwsjson10_deserializeOpStopInferenceScheduler) HandleDeserialize(ctx return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentStopInferenceSchedulerOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentListInferenceSchedulersOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -2487,7 +2449,7 @@ func (m *awsAwsjson10_deserializeOpStopInferenceScheduler) HandleDeserialize(ctx return out, metadata, err } -func awsAwsjson10_deserializeOpErrorStopInferenceScheduler(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorListInferenceSchedulers(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)} @@ -2531,15 +2493,9 @@ func awsAwsjson10_deserializeOpErrorStopInferenceScheduler(response *smithyhttp. case strings.EqualFold("AccessDeniedException", errorCode): return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) - case strings.EqualFold("ConflictException", errorCode): - return awsAwsjson10_deserializeErrorConflictException(response, errorBody) - case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): - return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) - case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -2556,14 +2512,14 @@ func awsAwsjson10_deserializeOpErrorStopInferenceScheduler(response *smithyhttp. } } -type awsAwsjson10_deserializeOpTagResource struct { +type awsAwsjson10_deserializeOpListLabelGroups struct { } -func (*awsAwsjson10_deserializeOpTagResource) ID() string { +func (*awsAwsjson10_deserializeOpListLabelGroups) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpTagResource) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpListLabelGroups) 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) @@ -2577,9 +2533,9 @@ func (m *awsAwsjson10_deserializeOpTagResource) HandleDeserialize(ctx context.Co } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorTagResource(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorListLabelGroups(response, &metadata) } - output := &TagResourceOutput{} + output := &ListLabelGroupsOutput{} out.Result = output var buff [1024]byte @@ -2599,7 +2555,7 @@ func (m *awsAwsjson10_deserializeOpTagResource) HandleDeserialize(ctx context.Co return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentTagResourceOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentListLabelGroupsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -2613,7 +2569,7 @@ func (m *awsAwsjson10_deserializeOpTagResource) HandleDeserialize(ctx context.Co return out, metadata, err } -func awsAwsjson10_deserializeOpErrorTagResource(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorListLabelGroups(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)} @@ -2660,12 +2616,6 @@ func awsAwsjson10_deserializeOpErrorTagResource(response *smithyhttp.Response, m case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): - return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) - - case strings.EqualFold("ServiceQuotaExceededException", errorCode): - return awsAwsjson10_deserializeErrorServiceQuotaExceededException(response, errorBody) - case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -2682,14 +2632,14 @@ func awsAwsjson10_deserializeOpErrorTagResource(response *smithyhttp.Response, m } } -type awsAwsjson10_deserializeOpUntagResource struct { +type awsAwsjson10_deserializeOpListLabels struct { } -func (*awsAwsjson10_deserializeOpUntagResource) ID() string { +func (*awsAwsjson10_deserializeOpListLabels) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpUntagResource) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpListLabels) 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) @@ -2703,9 +2653,9 @@ func (m *awsAwsjson10_deserializeOpUntagResource) HandleDeserialize(ctx context. } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorUntagResource(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorListLabels(response, &metadata) } - output := &UntagResourceOutput{} + output := &ListLabelsOutput{} out.Result = output var buff [1024]byte @@ -2725,7 +2675,7 @@ func (m *awsAwsjson10_deserializeOpUntagResource) HandleDeserialize(ctx context. return out, metadata, err } - err = awsAwsjson10_deserializeOpDocumentUntagResourceOutput(&output, shape) + err = awsAwsjson10_deserializeOpDocumentListLabelsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -2739,7 +2689,7 @@ func (m *awsAwsjson10_deserializeOpUntagResource) HandleDeserialize(ctx context. return out, metadata, err } -func awsAwsjson10_deserializeOpErrorUntagResource(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorListLabels(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)} @@ -2786,9 +2736,6 @@ func awsAwsjson10_deserializeOpErrorUntagResource(response *smithyhttp.Response, case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): - return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) - case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -2805,14 +2752,14 @@ func awsAwsjson10_deserializeOpErrorUntagResource(response *smithyhttp.Response, } } -type awsAwsjson10_deserializeOpUpdateInferenceScheduler struct { +type awsAwsjson10_deserializeOpListModels struct { } -func (*awsAwsjson10_deserializeOpUpdateInferenceScheduler) ID() string { +func (*awsAwsjson10_deserializeOpListModels) ID() string { return "OperationDeserializer" } -func (m *awsAwsjson10_deserializeOpUpdateInferenceScheduler) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsAwsjson10_deserializeOpListModels) 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) @@ -2826,21 +2773,43 @@ func (m *awsAwsjson10_deserializeOpUpdateInferenceScheduler) HandleDeserialize(c } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsAwsjson10_deserializeOpErrorUpdateInferenceScheduler(response, &metadata) + return out, metadata, awsAwsjson10_deserializeOpErrorListModels(response, &metadata) } - output := &UpdateInferenceSchedulerOutput{} + output := &ListModelsOutput{} 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), + 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 = awsAwsjson10_deserializeOpDocumentListModelsOutput(&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 awsAwsjson10_deserializeOpErrorUpdateInferenceScheduler(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsAwsjson10_deserializeOpErrorListModels(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)} @@ -2884,14 +2853,1092 @@ func awsAwsjson10_deserializeOpErrorUpdateInferenceScheduler(response *smithyhtt case strings.EqualFold("AccessDeniedException", errorCode): return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) - case strings.EqualFold("ConflictException", errorCode): - return awsAwsjson10_deserializeErrorConflictException(response, errorBody) - case strings.EqualFold("InternalServerException", errorCode): return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): - return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsAwsjson10_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson10_deserializeOpListSensorStatistics struct { +} + +func (*awsAwsjson10_deserializeOpListSensorStatistics) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson10_deserializeOpListSensorStatistics) 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, awsAwsjson10_deserializeOpErrorListSensorStatistics(response, &metadata) + } + output := &ListSensorStatisticsOutput{} + 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 = awsAwsjson10_deserializeOpDocumentListSensorStatisticsOutput(&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 awsAwsjson10_deserializeOpErrorListSensorStatistics(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("AccessDeniedException", errorCode): + return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsAwsjson10_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson10_deserializeOpListTagsForResource struct { +} + +func (*awsAwsjson10_deserializeOpListTagsForResource) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson10_deserializeOpListTagsForResource) 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, awsAwsjson10_deserializeOpErrorListTagsForResource(response, &metadata) + } + output := &ListTagsForResourceOutput{} + 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 = awsAwsjson10_deserializeOpDocumentListTagsForResourceOutput(&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 awsAwsjson10_deserializeOpErrorListTagsForResource(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("AccessDeniedException", errorCode): + return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsAwsjson10_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson10_deserializeOpStartDataIngestionJob struct { +} + +func (*awsAwsjson10_deserializeOpStartDataIngestionJob) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson10_deserializeOpStartDataIngestionJob) 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, awsAwsjson10_deserializeOpErrorStartDataIngestionJob(response, &metadata) + } + output := &StartDataIngestionJobOutput{} + 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 = awsAwsjson10_deserializeOpDocumentStartDataIngestionJobOutput(&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 awsAwsjson10_deserializeOpErrorStartDataIngestionJob(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("AccessDeniedException", errorCode): + return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("ConflictException", errorCode): + return awsAwsjson10_deserializeErrorConflictException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ServiceQuotaExceededException", errorCode): + return awsAwsjson10_deserializeErrorServiceQuotaExceededException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsAwsjson10_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson10_deserializeOpStartInferenceScheduler struct { +} + +func (*awsAwsjson10_deserializeOpStartInferenceScheduler) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson10_deserializeOpStartInferenceScheduler) 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, awsAwsjson10_deserializeOpErrorStartInferenceScheduler(response, &metadata) + } + output := &StartInferenceSchedulerOutput{} + 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 = awsAwsjson10_deserializeOpDocumentStartInferenceSchedulerOutput(&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 awsAwsjson10_deserializeOpErrorStartInferenceScheduler(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("AccessDeniedException", errorCode): + return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("ConflictException", errorCode): + return awsAwsjson10_deserializeErrorConflictException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsAwsjson10_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson10_deserializeOpStopInferenceScheduler struct { +} + +func (*awsAwsjson10_deserializeOpStopInferenceScheduler) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson10_deserializeOpStopInferenceScheduler) 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, awsAwsjson10_deserializeOpErrorStopInferenceScheduler(response, &metadata) + } + output := &StopInferenceSchedulerOutput{} + 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 = awsAwsjson10_deserializeOpDocumentStopInferenceSchedulerOutput(&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 awsAwsjson10_deserializeOpErrorStopInferenceScheduler(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("AccessDeniedException", errorCode): + return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("ConflictException", errorCode): + return awsAwsjson10_deserializeErrorConflictException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsAwsjson10_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson10_deserializeOpTagResource struct { +} + +func (*awsAwsjson10_deserializeOpTagResource) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson10_deserializeOpTagResource) 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, awsAwsjson10_deserializeOpErrorTagResource(response, &metadata) + } + output := &TagResourceOutput{} + 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 = awsAwsjson10_deserializeOpDocumentTagResourceOutput(&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 awsAwsjson10_deserializeOpErrorTagResource(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("AccessDeniedException", errorCode): + return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ServiceQuotaExceededException", errorCode): + return awsAwsjson10_deserializeErrorServiceQuotaExceededException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsAwsjson10_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson10_deserializeOpUntagResource struct { +} + +func (*awsAwsjson10_deserializeOpUntagResource) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson10_deserializeOpUntagResource) 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, awsAwsjson10_deserializeOpErrorUntagResource(response, &metadata) + } + output := &UntagResourceOutput{} + 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 = awsAwsjson10_deserializeOpDocumentUntagResourceOutput(&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 awsAwsjson10_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("AccessDeniedException", errorCode): + return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsAwsjson10_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson10_deserializeOpUpdateInferenceScheduler struct { +} + +func (*awsAwsjson10_deserializeOpUpdateInferenceScheduler) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson10_deserializeOpUpdateInferenceScheduler) 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, awsAwsjson10_deserializeOpErrorUpdateInferenceScheduler(response, &metadata) + } + output := &UpdateInferenceSchedulerOutput{} + 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 awsAwsjson10_deserializeOpErrorUpdateInferenceScheduler(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("AccessDeniedException", errorCode): + return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("ConflictException", errorCode): + return awsAwsjson10_deserializeErrorConflictException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsAwsjson10_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsAwsjson10_deserializeOpUpdateLabelGroup struct { +} + +func (*awsAwsjson10_deserializeOpUpdateLabelGroup) ID() string { + return "OperationDeserializer" +} + +func (m *awsAwsjson10_deserializeOpUpdateLabelGroup) 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, awsAwsjson10_deserializeOpErrorUpdateLabelGroup(response, &metadata) + } + output := &UpdateLabelGroupOutput{} + 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 awsAwsjson10_deserializeOpErrorUpdateLabelGroup(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("AccessDeniedException", errorCode): + return awsAwsjson10_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("ConflictException", errorCode): + return awsAwsjson10_deserializeErrorConflictException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsAwsjson10_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsAwsjson10_deserializeErrorResourceNotFoundException(response, errorBody) case strings.EqualFold("ThrottlingException", errorCode): return awsAwsjson10_deserializeErrorThrottlingException(response, errorBody) @@ -3710,12 +4757,48 @@ func awsAwsjson10_deserializeDocumentDuplicateTimestamps(v **types.DuplicateTime sv.TotalNumberOfDuplicateTimestamps = ptr.Int32(int32(i64)) } - default: - _, _ = key, value + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson10_deserializeDocumentFaultCodes(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 FaultCode to be of type string, got %T instead", value) + } + col = jtv } + cv = append(cv, col) + } - *v = sv + *v = cv return nil } @@ -4376,6 +5459,15 @@ func awsAwsjson10_deserializeDocumentInferenceSchedulerSummary(v **types.Inferen sv.InferenceSchedulerName = ptr.String(jtv) } + case "LatestInferenceResult": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected LatestInferenceResult to be of type string, got %T instead", value) + } + sv.LatestInferenceResult = types.LatestInferenceResult(jtv) + } + case "ModelArn": if value != nil { jtv, ok := value.(string) @@ -4706,6 +5798,121 @@ func awsAwsjson10_deserializeDocumentInvalidSensorData(v **types.InvalidSensorDa return nil } +func awsAwsjson10_deserializeDocumentLabelGroupSummaries(v *[]types.LabelGroupSummary, 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.LabelGroupSummary + if *v == nil { + cv = []types.LabelGroupSummary{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.LabelGroupSummary + destAddr := &col + if err := awsAwsjson10_deserializeDocumentLabelGroupSummary(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsAwsjson10_deserializeDocumentLabelGroupSummary(v **types.LabelGroupSummary, 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.LabelGroupSummary + if *v == nil { + sv = &types.LabelGroupSummary{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "CreatedAt": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.CreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "LabelGroupArn": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected LabelGroupArn to be of type string, got %T instead", value) + } + sv.LabelGroupArn = ptr.String(jtv) + } + + case "LabelGroupName": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected LabelGroupName to be of type string, got %T instead", value) + } + sv.LabelGroupName = ptr.String(jtv) + } + + case "UpdatedAt": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.UpdatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson10_deserializeDocumentLabelsInputConfiguration(v **types.LabelsInputConfiguration, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -4728,6 +5935,15 @@ func awsAwsjson10_deserializeDocumentLabelsInputConfiguration(v **types.LabelsIn for key, value := range shape { switch key { + case "LabelGroupName": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected LabelGroupName to be of type string, got %T instead", value) + } + sv.LabelGroupName = ptr.String(jtv) + } + case "S3InputConfiguration": if err := awsAwsjson10_deserializeDocumentLabelsS3InputConfiguration(&sv.S3InputConfiguration, value); err != nil { return err @@ -4750,36 +5966,203 @@ func awsAwsjson10_deserializeDocumentLabelsS3InputConfiguration(v **types.Labels return nil } - shape, ok := value.(map[string]interface{}) - if !ok { - return fmt.Errorf("unexpected JSON type %v", value) - } + shape, ok := value.(map[string]interface{}) + if !ok { + return fmt.Errorf("unexpected JSON type %v", value) + } + + var sv *types.LabelsS3InputConfiguration + if *v == nil { + sv = &types.LabelsS3InputConfiguration{} + } 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 S3Bucket to be of type string, got %T instead", value) + } + sv.Bucket = ptr.String(jtv) + } + + case "Prefix": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected S3Prefix to be of type string, got %T instead", value) + } + sv.Prefix = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson10_deserializeDocumentLabelSummaries(v *[]types.LabelSummary, 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.LabelSummary + if *v == nil { + cv = []types.LabelSummary{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.LabelSummary + destAddr := &col + if err := awsAwsjson10_deserializeDocumentLabelSummary(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsAwsjson10_deserializeDocumentLabelSummary(v **types.LabelSummary, 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.LabelSummary + if *v == nil { + sv = &types.LabelSummary{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "CreatedAt": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.CreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "EndTime": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.EndTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "Equipment": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected Equipment to be of type string, got %T instead", value) + } + sv.Equipment = ptr.String(jtv) + } + + case "FaultCode": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected FaultCode to be of type string, got %T instead", value) + } + sv.FaultCode = ptr.String(jtv) + } - var sv *types.LabelsS3InputConfiguration - if *v == nil { - sv = &types.LabelsS3InputConfiguration{} - } else { - sv = *v - } + case "LabelGroupArn": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected LabelGroupArn to be of type string, got %T instead", value) + } + sv.LabelGroupArn = ptr.String(jtv) + } - for key, value := range shape { - switch key { - case "Bucket": + case "LabelGroupName": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected S3Bucket to be of type string, got %T instead", value) + return fmt.Errorf("expected LabelGroupName to be of type string, got %T instead", value) } - sv.Bucket = ptr.String(jtv) + sv.LabelGroupName = ptr.String(jtv) } - case "Prefix": + case "LabelId": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected S3Prefix to be of type string, got %T instead", value) + return fmt.Errorf("expected LabelId to be of type string, got %T instead", value) + } + sv.LabelId = ptr.String(jtv) + } + + case "Rating": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected LabelRating to be of type string, got %T instead", value) + } + sv.Rating = types.LabelRating(jtv) + } + + case "StartTime": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.StartTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + } - sv.Prefix = ptr.String(jtv) } default: @@ -5448,7 +6831,214 @@ func awsAwsjson10_deserializeDocumentSensorStatisticsSummary(v **types.SensorSta if !ok { return fmt.Errorf("expected SensorName to be of type string, got %T instead", value) } - sv.SensorName = ptr.String(jtv) + sv.SensorName = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson10_deserializeDocumentSensorsWithShortDateRange(v **types.SensorsWithShortDateRange, 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.SensorsWithShortDateRange + if *v == nil { + sv = &types.SensorsWithShortDateRange{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "AffectedSensorCount": + 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.AffectedSensorCount = ptr.Int32(int32(i64)) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson10_deserializeDocumentServiceQuotaExceededException(v **types.ServiceQuotaExceededException, 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.ServiceQuotaExceededException + if *v == nil { + sv = &types.ServiceQuotaExceededException{} + } 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 BoundedLengthString to be of type string, got %T instead", value) + } + sv.Message = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson10_deserializeDocumentTag(v **types.Tag, 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.Tag + if *v == nil { + sv = &types.Tag{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "Key": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected TagKey to be of type string, got %T instead", value) + } + sv.Key = ptr.String(jtv) + } + + case "Value": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected TagValue to be of type string, got %T instead", value) + } + sv.Value = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson10_deserializeDocumentTagList(v *[]types.Tag, 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.Tag + if *v == nil { + cv = []types.Tag{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.Tag + destAddr := &col + if err := awsAwsjson10_deserializeDocumentTag(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + +func awsAwsjson10_deserializeDocumentThrottlingException(v **types.ThrottlingException, 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.ThrottlingException + if *v == nil { + sv = &types.ThrottlingException{} + } 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 BoundedLengthString to be of type string, got %T instead", value) + } + sv.Message = ptr.String(jtv) } default: @@ -5460,7 +7050,7 @@ func awsAwsjson10_deserializeDocumentSensorStatisticsSummary(v **types.SensorSta return nil } -func awsAwsjson10_deserializeDocumentSensorsWithShortDateRange(v **types.SensorsWithShortDateRange, value interface{}) error { +func awsAwsjson10_deserializeDocumentUnsupportedTimestamps(v **types.UnsupportedTimestamps, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -5473,16 +7063,16 @@ func awsAwsjson10_deserializeDocumentSensorsWithShortDateRange(v **types.Sensors return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.SensorsWithShortDateRange + var sv *types.UnsupportedTimestamps if *v == nil { - sv = &types.SensorsWithShortDateRange{} + sv = &types.UnsupportedTimestamps{} } else { sv = *v } for key, value := range shape { switch key { - case "AffectedSensorCount": + case "TotalNumberOfUnsupportedTimestamps": if value != nil { jtv, ok := value.(json.Number) if !ok { @@ -5492,7 +7082,7 @@ func awsAwsjson10_deserializeDocumentSensorsWithShortDateRange(v **types.Sensors if err != nil { return err } - sv.AffectedSensorCount = ptr.Int32(int32(i64)) + sv.TotalNumberOfUnsupportedTimestamps = ptr.Int32(int32(i64)) } default: @@ -5504,7 +7094,7 @@ func awsAwsjson10_deserializeDocumentSensorsWithShortDateRange(v **types.Sensors return nil } -func awsAwsjson10_deserializeDocumentServiceQuotaExceededException(v **types.ServiceQuotaExceededException, value interface{}) error { +func awsAwsjson10_deserializeDocumentValidationException(v **types.ValidationException, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -5517,9 +7107,9 @@ func awsAwsjson10_deserializeDocumentServiceQuotaExceededException(v **types.Ser return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ServiceQuotaExceededException + var sv *types.ValidationException if *v == nil { - sv = &types.ServiceQuotaExceededException{} + sv = &types.ValidationException{} } else { sv = *v } @@ -5544,7 +7134,7 @@ func awsAwsjson10_deserializeDocumentServiceQuotaExceededException(v **types.Ser return nil } -func awsAwsjson10_deserializeDocumentTag(v **types.Tag, value interface{}) error { +func awsAwsjson10_deserializeOpDocumentCreateDatasetOutput(v **CreateDatasetOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -5557,31 +7147,40 @@ func awsAwsjson10_deserializeDocumentTag(v **types.Tag, value interface{}) error return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.Tag + var sv *CreateDatasetOutput if *v == nil { - sv = &types.Tag{} + sv = &CreateDatasetOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "Key": + case "DatasetArn": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected TagKey to be of type string, got %T instead", value) + return fmt.Errorf("expected DatasetArn to be of type string, got %T instead", value) } - sv.Key = ptr.String(jtv) + sv.DatasetArn = ptr.String(jtv) } - case "Value": + case "DatasetName": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected TagValue to be of type string, got %T instead", value) + return fmt.Errorf("expected DatasetName to be of type string, got %T instead", value) } - sv.Value = ptr.String(jtv) + sv.DatasetName = ptr.String(jtv) + } + + case "Status": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected DatasetStatus to be of type string, got %T instead", value) + } + sv.Status = types.DatasetStatus(jtv) } default: @@ -5593,7 +7192,7 @@ func awsAwsjson10_deserializeDocumentTag(v **types.Tag, value interface{}) error return nil } -func awsAwsjson10_deserializeDocumentTagList(v *[]types.Tag, value interface{}) error { +func awsAwsjson10_deserializeOpDocumentCreateInferenceSchedulerOutput(v **CreateInferenceSchedulerOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -5601,33 +7200,57 @@ func awsAwsjson10_deserializeDocumentTagList(v *[]types.Tag, value interface{}) 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.Tag + var sv *CreateInferenceSchedulerOutput if *v == nil { - cv = []types.Tag{} + sv = &CreateInferenceSchedulerOutput{} } else { - cv = *v + sv = *v } - for _, value := range shape { - var col types.Tag - destAddr := &col - if err := awsAwsjson10_deserializeDocumentTag(&destAddr, value); err != nil { - return err - } - col = *destAddr - cv = append(cv, col) + for key, value := range shape { + switch key { + case "InferenceSchedulerArn": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected InferenceSchedulerArn to be of type string, got %T instead", value) + } + sv.InferenceSchedulerArn = ptr.String(jtv) + } + + case "InferenceSchedulerName": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected InferenceSchedulerName to be of type string, got %T instead", value) + } + sv.InferenceSchedulerName = ptr.String(jtv) + } + + case "Status": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected InferenceSchedulerStatus to be of type string, got %T instead", value) + } + sv.Status = types.InferenceSchedulerStatus(jtv) + } + + default: + _, _ = key, value + } } - *v = cv + *v = sv return nil } -func awsAwsjson10_deserializeDocumentThrottlingException(v **types.ThrottlingException, value interface{}) error { +func awsAwsjson10_deserializeOpDocumentCreateLabelGroupOutput(v **CreateLabelGroupOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -5640,22 +7263,31 @@ func awsAwsjson10_deserializeDocumentThrottlingException(v **types.ThrottlingExc return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ThrottlingException + var sv *CreateLabelGroupOutput if *v == nil { - sv = &types.ThrottlingException{} + sv = &CreateLabelGroupOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "Message": + case "LabelGroupArn": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected BoundedLengthString to be of type string, got %T instead", value) + return fmt.Errorf("expected LabelGroupArn to be of type string, got %T instead", value) } - sv.Message = ptr.String(jtv) + sv.LabelGroupArn = ptr.String(jtv) + } + + case "LabelGroupName": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected LabelGroupName to be of type string, got %T instead", value) + } + sv.LabelGroupName = ptr.String(jtv) } default: @@ -5667,7 +7299,7 @@ func awsAwsjson10_deserializeDocumentThrottlingException(v **types.ThrottlingExc return nil } -func awsAwsjson10_deserializeDocumentUnsupportedTimestamps(v **types.UnsupportedTimestamps, value interface{}) error { +func awsAwsjson10_deserializeOpDocumentCreateLabelOutput(v **CreateLabelOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -5680,26 +7312,22 @@ func awsAwsjson10_deserializeDocumentUnsupportedTimestamps(v **types.Unsupported return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.UnsupportedTimestamps + var sv *CreateLabelOutput if *v == nil { - sv = &types.UnsupportedTimestamps{} + sv = &CreateLabelOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "TotalNumberOfUnsupportedTimestamps": + case "LabelId": if value != nil { - jtv, ok := value.(json.Number) + jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected Integer to be json.Number, got %T instead", value) - } - i64, err := jtv.Int64() - if err != nil { - return err + return fmt.Errorf("expected LabelId to be of type string, got %T instead", value) } - sv.TotalNumberOfUnsupportedTimestamps = ptr.Int32(int32(i64)) + sv.LabelId = ptr.String(jtv) } default: @@ -5711,7 +7339,7 @@ func awsAwsjson10_deserializeDocumentUnsupportedTimestamps(v **types.Unsupported return nil } -func awsAwsjson10_deserializeDocumentValidationException(v **types.ValidationException, value interface{}) error { +func awsAwsjson10_deserializeOpDocumentCreateModelOutput(v **CreateModelOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -5724,22 +7352,31 @@ func awsAwsjson10_deserializeDocumentValidationException(v **types.ValidationExc return fmt.Errorf("unexpected JSON type %v", value) } - var sv *types.ValidationException + var sv *CreateModelOutput if *v == nil { - sv = &types.ValidationException{} + sv = &CreateModelOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "Message": + case "ModelArn": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected BoundedLengthString to be of type string, got %T instead", value) + return fmt.Errorf("expected ModelArn to be of type string, got %T instead", value) } - sv.Message = ptr.String(jtv) + sv.ModelArn = ptr.String(jtv) + } + + case "Status": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ModelStatus to be of type string, got %T instead", value) + } + sv.Status = types.ModelStatus(jtv) } default: @@ -5751,7 +7388,7 @@ func awsAwsjson10_deserializeDocumentValidationException(v **types.ValidationExc return nil } -func awsAwsjson10_deserializeOpDocumentCreateDatasetOutput(v **CreateDatasetOutput, value interface{}) error { +func awsAwsjson10_deserializeOpDocumentDescribeDataIngestionJobOutput(v **DescribeDataIngestionJobOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -5764,15 +7401,52 @@ func awsAwsjson10_deserializeOpDocumentCreateDatasetOutput(v **CreateDatasetOutp return fmt.Errorf("unexpected JSON type %v", value) } - var sv *CreateDatasetOutput + var sv *DescribeDataIngestionJobOutput if *v == nil { - sv = &CreateDatasetOutput{} + sv = &DescribeDataIngestionJobOutput{} } else { sv = *v } for key, value := range shape { switch key { + case "CreatedAt": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.CreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "DataEndTime": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.DataEndTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "DataQualitySummary": + if err := awsAwsjson10_deserializeDocumentDataQualitySummary(&sv.DataQualitySummary, value); err != nil { + return err + } + case "DatasetArn": if value != nil { jtv, ok := value.(string) @@ -5782,22 +7456,88 @@ func awsAwsjson10_deserializeOpDocumentCreateDatasetOutput(v **CreateDatasetOutp sv.DatasetArn = ptr.String(jtv) } - case "DatasetName": + case "DataStartTime": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.DataStartTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "FailedReason": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected DatasetName to be of type string, got %T instead", value) + return fmt.Errorf("expected BoundedLengthString to be of type string, got %T instead", value) } - sv.DatasetName = ptr.String(jtv) + sv.FailedReason = ptr.String(jtv) + } + + case "IngestedDataSize": + if value != nil { + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected DataSizeInBytes to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err + } + sv.IngestedDataSize = ptr.Int64(i64) + } + + case "IngestedFilesSummary": + if err := awsAwsjson10_deserializeDocumentIngestedFilesSummary(&sv.IngestedFilesSummary, value); err != nil { + return err + } + + case "IngestionInputConfiguration": + if err := awsAwsjson10_deserializeDocumentIngestionInputConfiguration(&sv.IngestionInputConfiguration, value); err != nil { + return err + } + + case "JobId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected IngestionJobId to be of type string, got %T instead", value) + } + sv.JobId = ptr.String(jtv) + } + + case "RoleArn": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected IamRoleArn to be of type string, got %T instead", value) + } + sv.RoleArn = ptr.String(jtv) } case "Status": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected DatasetStatus to be of type string, got %T instead", value) + return fmt.Errorf("expected IngestionJobStatus to be of type string, got %T instead", value) + } + sv.Status = types.IngestionJobStatus(jtv) + } + + case "StatusDetail": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected BoundedLengthString to be of type string, got %T instead", value) } - sv.Status = types.DatasetStatus(jtv) + sv.StatusDetail = ptr.String(jtv) } default: @@ -5809,7 +7549,7 @@ func awsAwsjson10_deserializeOpDocumentCreateDatasetOutput(v **CreateDatasetOutp return nil } -func awsAwsjson10_deserializeOpDocumentCreateInferenceSchedulerOutput(v **CreateInferenceSchedulerOutput, value interface{}) error { +func awsAwsjson10_deserializeOpDocumentDescribeDatasetOutput(v **DescribeDatasetOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -5822,89 +7562,146 @@ func awsAwsjson10_deserializeOpDocumentCreateInferenceSchedulerOutput(v **Create return fmt.Errorf("unexpected JSON type %v", value) } - var sv *CreateInferenceSchedulerOutput + var sv *DescribeDatasetOutput if *v == nil { - sv = &CreateInferenceSchedulerOutput{} + sv = &DescribeDatasetOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "InferenceSchedulerArn": + case "CreatedAt": if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected InferenceSchedulerArn to be of type string, got %T instead", value) + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.CreatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + } - sv.InferenceSchedulerArn = ptr.String(jtv) } - case "InferenceSchedulerName": + case "DataEndTime": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.DataEndTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "DataQualitySummary": + if err := awsAwsjson10_deserializeDocumentDataQualitySummary(&sv.DataQualitySummary, value); err != nil { + return err + } + + case "DatasetArn": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected InferenceSchedulerName to be of type string, got %T instead", value) + return fmt.Errorf("expected DatasetArn to be of type string, got %T instead", value) } - sv.InferenceSchedulerName = ptr.String(jtv) + sv.DatasetArn = ptr.String(jtv) } - case "Status": + case "DatasetName": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected InferenceSchedulerStatus to be of type string, got %T instead", value) + return fmt.Errorf("expected DatasetName to be of type string, got %T instead", value) } - sv.Status = types.InferenceSchedulerStatus(jtv) + sv.DatasetName = ptr.String(jtv) } - default: - _, _ = key, value + case "DataStartTime": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.DataStartTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) - } - } - *v = sv - return nil -} + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) -func awsAwsjson10_deserializeOpDocumentCreateModelOutput(v **CreateModelOutput, 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) - } + case "IngestedFilesSummary": + if err := awsAwsjson10_deserializeDocumentIngestedFilesSummary(&sv.IngestedFilesSummary, value); err != nil { + return err + } - var sv *CreateModelOutput - if *v == nil { - sv = &CreateModelOutput{} - } else { - sv = *v - } + case "IngestionInputConfiguration": + if err := awsAwsjson10_deserializeDocumentIngestionInputConfiguration(&sv.IngestionInputConfiguration, value); err != nil { + return err + } - for key, value := range shape { - switch key { - case "ModelArn": + case "LastUpdatedAt": + if value != nil { + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.LastUpdatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + + } + } + + case "RoleArn": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ModelArn to be of type string, got %T instead", value) + return fmt.Errorf("expected IamRoleArn to be of type string, got %T instead", value) } - sv.ModelArn = ptr.String(jtv) + sv.RoleArn = ptr.String(jtv) + } + + case "Schema": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected SynthesizedJsonInlineDataSchema to be of type string, got %T instead", value) + } + sv.Schema = ptr.String(jtv) + } + + case "ServerSideKmsKeyId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected KmsKeyArn to be of type string, got %T instead", value) + } + sv.ServerSideKmsKeyId = ptr.String(jtv) } case "Status": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ModelStatus to be of type string, got %T instead", value) + return fmt.Errorf("expected DatasetStatus to be of type string, got %T instead", value) } - sv.Status = types.ModelStatus(jtv) + sv.Status = types.DatasetStatus(jtv) } default: @@ -5916,7 +7713,7 @@ func awsAwsjson10_deserializeOpDocumentCreateModelOutput(v **CreateModelOutput, return nil } -func awsAwsjson10_deserializeOpDocumentDescribeDataIngestionJobOutput(v **DescribeDataIngestionJobOutput, value interface{}) error { +func awsAwsjson10_deserializeOpDocumentDescribeInferenceSchedulerOutput(v **DescribeInferenceSchedulerOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -5929,9 +7726,9 @@ func awsAwsjson10_deserializeOpDocumentDescribeDataIngestionJobOutput(v **Descri return fmt.Errorf("unexpected JSON type %v", value) } - var sv *DescribeDataIngestionJobOutput + var sv *DescribeInferenceSchedulerOutput if *v == nil { - sv = &DescribeDataIngestionJobOutput{} + sv = &DescribeInferenceSchedulerOutput{} } else { sv = *v } @@ -5954,91 +7751,81 @@ func awsAwsjson10_deserializeOpDocumentDescribeDataIngestionJobOutput(v **Descri } } - case "DataEndTime": + case "DataDelayOffsetInMinutes": if value != nil { - switch jtv := value.(type) { - case json.Number: - f64, err := jtv.Float64() - if err != nil { - return err - } - sv.DataEndTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) - - default: - return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) - + jtv, ok := value.(json.Number) + if !ok { + return fmt.Errorf("expected DataDelayOffsetInMinutes to be json.Number, got %T instead", value) + } + i64, err := jtv.Int64() + if err != nil { + return err } + sv.DataDelayOffsetInMinutes = ptr.Int64(i64) } - case "DataQualitySummary": - if err := awsAwsjson10_deserializeDocumentDataQualitySummary(&sv.DataQualitySummary, value); err != nil { + case "DataInputConfiguration": + if err := awsAwsjson10_deserializeDocumentInferenceInputConfiguration(&sv.DataInputConfiguration, value); err != nil { return err } - case "DatasetArn": + case "DataOutputConfiguration": + if err := awsAwsjson10_deserializeDocumentInferenceOutputConfiguration(&sv.DataOutputConfiguration, value); err != nil { + return err + } + + case "DataUploadFrequency": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected DatasetArn to be of type string, got %T instead", value) + return fmt.Errorf("expected DataUploadFrequency to be of type string, got %T instead", value) } - sv.DatasetArn = ptr.String(jtv) + sv.DataUploadFrequency = types.DataUploadFrequency(jtv) } - case "DataStartTime": + case "InferenceSchedulerArn": if value != nil { - switch jtv := value.(type) { - case json.Number: - f64, err := jtv.Float64() - if err != nil { - return err - } - sv.DataStartTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) - - default: - return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) - + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected InferenceSchedulerArn to be of type string, got %T instead", value) } + sv.InferenceSchedulerArn = ptr.String(jtv) } - case "FailedReason": + case "InferenceSchedulerName": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected BoundedLengthString to be of type string, got %T instead", value) + return fmt.Errorf("expected InferenceSchedulerName to be of type string, got %T instead", value) } - sv.FailedReason = ptr.String(jtv) + sv.InferenceSchedulerName = ptr.String(jtv) } - case "IngestedDataSize": + case "LatestInferenceResult": if value != nil { - jtv, ok := value.(json.Number) + jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected DataSizeInBytes to be json.Number, got %T instead", value) - } - i64, err := jtv.Int64() - if err != nil { - return err + return fmt.Errorf("expected LatestInferenceResult to be of type string, got %T instead", value) } - sv.IngestedDataSize = ptr.Int64(i64) - } - - case "IngestedFilesSummary": - if err := awsAwsjson10_deserializeDocumentIngestedFilesSummary(&sv.IngestedFilesSummary, value); err != nil { - return err + sv.LatestInferenceResult = types.LatestInferenceResult(jtv) } - case "IngestionInputConfiguration": - if err := awsAwsjson10_deserializeDocumentIngestionInputConfiguration(&sv.IngestionInputConfiguration, value); err != nil { - return err + case "ModelArn": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected ModelArn to be of type string, got %T instead", value) + } + sv.ModelArn = ptr.String(jtv) } - case "JobId": + case "ModelName": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected IngestionJobId to be of type string, got %T instead", value) + return fmt.Errorf("expected ModelName to be of type string, got %T instead", value) } - sv.JobId = ptr.String(jtv) + sv.ModelName = ptr.String(jtv) } case "RoleArn": @@ -6047,25 +7834,41 @@ func awsAwsjson10_deserializeOpDocumentDescribeDataIngestionJobOutput(v **Descri if !ok { return fmt.Errorf("expected IamRoleArn to be of type string, got %T instead", value) } - sv.RoleArn = ptr.String(jtv) + sv.RoleArn = ptr.String(jtv) + } + + case "ServerSideKmsKeyId": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected KmsKeyArn to be of type string, got %T instead", value) + } + sv.ServerSideKmsKeyId = ptr.String(jtv) } case "Status": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected IngestionJobStatus to be of type string, got %T instead", value) + return fmt.Errorf("expected InferenceSchedulerStatus to be of type string, got %T instead", value) } - sv.Status = types.IngestionJobStatus(jtv) + sv.Status = types.InferenceSchedulerStatus(jtv) } - case "StatusDetail": + case "UpdatedAt": if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected BoundedLengthString to be of type string, got %T instead", value) + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.UpdatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64)) + + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) + } - sv.StatusDetail = ptr.String(jtv) } default: @@ -6077,7 +7880,7 @@ func awsAwsjson10_deserializeOpDocumentDescribeDataIngestionJobOutput(v **Descri return nil } -func awsAwsjson10_deserializeOpDocumentDescribeDatasetOutput(v **DescribeDatasetOutput, value interface{}) error { +func awsAwsjson10_deserializeOpDocumentDescribeLabelGroupOutput(v **DescribeLabelGroupOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -6090,9 +7893,9 @@ func awsAwsjson10_deserializeOpDocumentDescribeDatasetOutput(v **DescribeDataset return fmt.Errorf("unexpected JSON type %v", value) } - var sv *DescribeDatasetOutput + var sv *DescribeLabelGroupOutput if *v == nil { - sv = &DescribeDatasetOutput{} + sv = &DescribeLabelGroupOutput{} } else { sv = *v } @@ -6115,72 +7918,30 @@ func awsAwsjson10_deserializeOpDocumentDescribeDatasetOutput(v **DescribeDataset } } - case "DataEndTime": - if value != nil { - switch jtv := value.(type) { - case json.Number: - f64, err := jtv.Float64() - if err != nil { - return err - } - sv.DataEndTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) - - default: - return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) - - } - } - - case "DataQualitySummary": - if err := awsAwsjson10_deserializeDocumentDataQualitySummary(&sv.DataQualitySummary, value); err != nil { + case "FaultCodes": + if err := awsAwsjson10_deserializeDocumentFaultCodes(&sv.FaultCodes, value); err != nil { return err } - case "DatasetArn": + case "LabelGroupArn": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected DatasetArn to be of type string, got %T instead", value) + return fmt.Errorf("expected LabelGroupArn to be of type string, got %T instead", value) } - sv.DatasetArn = ptr.String(jtv) + sv.LabelGroupArn = ptr.String(jtv) } - case "DatasetName": + case "LabelGroupName": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected DatasetName to be of type string, got %T instead", value) - } - sv.DatasetName = ptr.String(jtv) - } - - case "DataStartTime": - if value != nil { - switch jtv := value.(type) { - case json.Number: - f64, err := jtv.Float64() - if err != nil { - return err - } - sv.DataStartTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) - - default: - return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) - + return fmt.Errorf("expected LabelGroupName to be of type string, got %T instead", value) } + sv.LabelGroupName = ptr.String(jtv) } - case "IngestedFilesSummary": - if err := awsAwsjson10_deserializeDocumentIngestedFilesSummary(&sv.IngestedFilesSummary, value); err != nil { - return err - } - - case "IngestionInputConfiguration": - if err := awsAwsjson10_deserializeDocumentIngestionInputConfiguration(&sv.IngestionInputConfiguration, value); err != nil { - return err - } - - case "LastUpdatedAt": + case "UpdatedAt": if value != nil { switch jtv := value.(type) { case json.Number: @@ -6188,7 +7949,7 @@ func awsAwsjson10_deserializeOpDocumentDescribeDatasetOutput(v **DescribeDataset if err != nil { return err } - sv.LastUpdatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64)) + sv.UpdatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64)) default: return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) @@ -6196,42 +7957,6 @@ func awsAwsjson10_deserializeOpDocumentDescribeDatasetOutput(v **DescribeDataset } } - case "RoleArn": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected IamRoleArn to be of type string, got %T instead", value) - } - sv.RoleArn = ptr.String(jtv) - } - - case "Schema": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected SynthesizedJsonInlineDataSchema to be of type string, got %T instead", value) - } - sv.Schema = ptr.String(jtv) - } - - case "ServerSideKmsKeyId": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected KmsKeyArn to be of type string, got %T instead", value) - } - sv.ServerSideKmsKeyId = ptr.String(jtv) - } - - case "Status": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected DatasetStatus to be of type string, got %T instead", value) - } - sv.Status = types.DatasetStatus(jtv) - } - default: _, _ = key, value @@ -6241,7 +7966,7 @@ func awsAwsjson10_deserializeOpDocumentDescribeDatasetOutput(v **DescribeDataset return nil } -func awsAwsjson10_deserializeOpDocumentDescribeInferenceSchedulerOutput(v **DescribeInferenceSchedulerOutput, value interface{}) error { +func awsAwsjson10_deserializeOpDocumentDescribeLabelOutput(v **DescribeLabelOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -6254,9 +7979,9 @@ func awsAwsjson10_deserializeOpDocumentDescribeInferenceSchedulerOutput(v **Desc return fmt.Errorf("unexpected JSON type %v", value) } - var sv *DescribeInferenceSchedulerOutput + var sv *DescribeLabelOutput if *v == nil { - sv = &DescribeInferenceSchedulerOutput{} + sv = &DescribeLabelOutput{} } else { sv = *v } @@ -6279,102 +8004,86 @@ func awsAwsjson10_deserializeOpDocumentDescribeInferenceSchedulerOutput(v **Desc } } - case "DataDelayOffsetInMinutes": + case "EndTime": if value != nil { - jtv, ok := value.(json.Number) - if !ok { - return fmt.Errorf("expected DataDelayOffsetInMinutes to be json.Number, got %T instead", value) - } - i64, err := jtv.Int64() - if err != nil { - return err - } - sv.DataDelayOffsetInMinutes = ptr.Int64(i64) - } - - case "DataInputConfiguration": - if err := awsAwsjson10_deserializeDocumentInferenceInputConfiguration(&sv.DataInputConfiguration, value); err != nil { - return err - } + switch jtv := value.(type) { + case json.Number: + f64, err := jtv.Float64() + if err != nil { + return err + } + sv.EndTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) - case "DataOutputConfiguration": - if err := awsAwsjson10_deserializeDocumentInferenceOutputConfiguration(&sv.DataOutputConfiguration, value); err != nil { - return err - } + default: + return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) - case "DataUploadFrequency": - if value != nil { - jtv, ok := value.(string) - if !ok { - return fmt.Errorf("expected DataUploadFrequency to be of type string, got %T instead", value) } - sv.DataUploadFrequency = types.DataUploadFrequency(jtv) } - case "InferenceSchedulerArn": + case "Equipment": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected InferenceSchedulerArn to be of type string, got %T instead", value) + return fmt.Errorf("expected Equipment to be of type string, got %T instead", value) } - sv.InferenceSchedulerArn = ptr.String(jtv) + sv.Equipment = ptr.String(jtv) } - case "InferenceSchedulerName": + case "FaultCode": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected InferenceSchedulerName to be of type string, got %T instead", value) + return fmt.Errorf("expected FaultCode to be of type string, got %T instead", value) } - sv.InferenceSchedulerName = ptr.String(jtv) + sv.FaultCode = ptr.String(jtv) } - case "ModelArn": + case "LabelGroupArn": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ModelArn to be of type string, got %T instead", value) + return fmt.Errorf("expected LabelGroupArn to be of type string, got %T instead", value) } - sv.ModelArn = ptr.String(jtv) + sv.LabelGroupArn = ptr.String(jtv) } - case "ModelName": + case "LabelGroupName": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected ModelName to be of type string, got %T instead", value) + return fmt.Errorf("expected LabelGroupName to be of type string, got %T instead", value) } - sv.ModelName = ptr.String(jtv) + sv.LabelGroupName = ptr.String(jtv) } - case "RoleArn": + case "LabelId": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected IamRoleArn to be of type string, got %T instead", value) + return fmt.Errorf("expected LabelId to be of type string, got %T instead", value) } - sv.RoleArn = ptr.String(jtv) + sv.LabelId = ptr.String(jtv) } - case "ServerSideKmsKeyId": + case "Notes": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected KmsKeyArn to be of type string, got %T instead", value) + return fmt.Errorf("expected Comments to be of type string, got %T instead", value) } - sv.ServerSideKmsKeyId = ptr.String(jtv) + sv.Notes = ptr.String(jtv) } - case "Status": + case "Rating": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected InferenceSchedulerStatus to be of type string, got %T instead", value) + return fmt.Errorf("expected LabelRating to be of type string, got %T instead", value) } - sv.Status = types.InferenceSchedulerStatus(jtv) + sv.Rating = types.LabelRating(jtv) } - case "UpdatedAt": + case "StartTime": if value != nil { switch jtv := value.(type) { case json.Number: @@ -6382,7 +8091,7 @@ func awsAwsjson10_deserializeOpDocumentDescribeInferenceSchedulerOutput(v **Desc if err != nil { return err } - sv.UpdatedAt = ptr.Time(smithytime.ParseEpochSeconds(f64)) + sv.StartTime = ptr.Time(smithytime.ParseEpochSeconds(f64)) default: return fmt.Errorf("expected Timestamp to be a JSON Number, got %T instead", value) @@ -6892,6 +8601,96 @@ func awsAwsjson10_deserializeOpDocumentListInferenceSchedulersOutput(v **ListInf return nil } +func awsAwsjson10_deserializeOpDocumentListLabelGroupsOutput(v **ListLabelGroupsOutput, 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 *ListLabelGroupsOutput + if *v == nil { + sv = &ListLabelGroupsOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "LabelGroupSummaries": + if err := awsAwsjson10_deserializeDocumentLabelGroupSummaries(&sv.LabelGroupSummaries, 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) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsAwsjson10_deserializeOpDocumentListLabelsOutput(v **ListLabelsOutput, 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 *ListLabelsOutput + if *v == nil { + sv = &ListLabelsOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "LabelSummaries": + if err := awsAwsjson10_deserializeDocumentLabelSummaries(&sv.LabelSummaries, 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) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsAwsjson10_deserializeOpDocumentListModelsOutput(v **ListModelsOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/lookoutequipment/generated.json b/service/lookoutequipment/generated.json index 42a0e15f8e1..13c7369c9f9 100644 --- a/service/lookoutequipment/generated.json +++ b/service/lookoutequipment/generated.json @@ -10,19 +10,27 @@ "api_client_test.go", "api_op_CreateDataset.go", "api_op_CreateInferenceScheduler.go", + "api_op_CreateLabel.go", + "api_op_CreateLabelGroup.go", "api_op_CreateModel.go", "api_op_DeleteDataset.go", "api_op_DeleteInferenceScheduler.go", + "api_op_DeleteLabel.go", + "api_op_DeleteLabelGroup.go", "api_op_DeleteModel.go", "api_op_DescribeDataIngestionJob.go", "api_op_DescribeDataset.go", "api_op_DescribeInferenceScheduler.go", + "api_op_DescribeLabel.go", + "api_op_DescribeLabelGroup.go", "api_op_DescribeModel.go", "api_op_ListDataIngestionJobs.go", "api_op_ListDatasets.go", "api_op_ListInferenceEvents.go", "api_op_ListInferenceExecutions.go", "api_op_ListInferenceSchedulers.go", + "api_op_ListLabelGroups.go", + "api_op_ListLabels.go", "api_op_ListModels.go", "api_op_ListSensorStatistics.go", "api_op_ListTagsForResource.go", @@ -32,6 +40,7 @@ "api_op_TagResource.go", "api_op_UntagResource.go", "api_op_UpdateInferenceScheduler.go", + "api_op_UpdateLabelGroup.go", "deserializers.go", "doc.go", "endpoints.go", diff --git a/service/lookoutequipment/serializers.go b/service/lookoutequipment/serializers.go index 9dc0d7a1d83..b1c6c75d214 100644 --- a/service/lookoutequipment/serializers.go +++ b/service/lookoutequipment/serializers.go @@ -126,6 +126,116 @@ func (m *awsAwsjson10_serializeOpCreateInferenceScheduler) HandleSerialize(ctx c return next.HandleSerialize(ctx, in) } +type awsAwsjson10_serializeOpCreateLabel struct { +} + +func (*awsAwsjson10_serializeOpCreateLabel) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson10_serializeOpCreateLabel) 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.(*CreateLabelInput) + _ = 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.0") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.CreateLabel") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson10_serializeOpDocumentCreateLabelInput(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 awsAwsjson10_serializeOpCreateLabelGroup struct { +} + +func (*awsAwsjson10_serializeOpCreateLabelGroup) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson10_serializeOpCreateLabelGroup) 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.(*CreateLabelGroupInput) + _ = 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.0") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.CreateLabelGroup") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson10_serializeOpDocumentCreateLabelGroupInput(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 awsAwsjson10_serializeOpCreateModel struct { } @@ -291,6 +401,116 @@ func (m *awsAwsjson10_serializeOpDeleteInferenceScheduler) HandleSerialize(ctx c return next.HandleSerialize(ctx, in) } +type awsAwsjson10_serializeOpDeleteLabel struct { +} + +func (*awsAwsjson10_serializeOpDeleteLabel) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson10_serializeOpDeleteLabel) 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.(*DeleteLabelInput) + _ = 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.0") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.DeleteLabel") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson10_serializeOpDocumentDeleteLabelInput(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 awsAwsjson10_serializeOpDeleteLabelGroup struct { +} + +func (*awsAwsjson10_serializeOpDeleteLabelGroup) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson10_serializeOpDeleteLabelGroup) 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.(*DeleteLabelGroupInput) + _ = 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.0") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.DeleteLabelGroup") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson10_serializeOpDocumentDeleteLabelGroupInput(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 awsAwsjson10_serializeOpDeleteModel struct { } @@ -511,6 +731,116 @@ func (m *awsAwsjson10_serializeOpDescribeInferenceScheduler) HandleSerialize(ctx return next.HandleSerialize(ctx, in) } +type awsAwsjson10_serializeOpDescribeLabel struct { +} + +func (*awsAwsjson10_serializeOpDescribeLabel) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson10_serializeOpDescribeLabel) 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.(*DescribeLabelInput) + _ = 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.0") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.DescribeLabel") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson10_serializeOpDocumentDescribeLabelInput(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 awsAwsjson10_serializeOpDescribeLabelGroup struct { +} + +func (*awsAwsjson10_serializeOpDescribeLabelGroup) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson10_serializeOpDescribeLabelGroup) 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.(*DescribeLabelGroupInput) + _ = 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.0") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.DescribeLabelGroup") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson10_serializeOpDocumentDescribeLabelGroupInput(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 awsAwsjson10_serializeOpDescribeModel struct { } @@ -566,14 +896,124 @@ func (m *awsAwsjson10_serializeOpDescribeModel) HandleSerialize(ctx context.Cont return next.HandleSerialize(ctx, in) } -type awsAwsjson10_serializeOpListDataIngestionJobs struct { +type awsAwsjson10_serializeOpListDataIngestionJobs struct { +} + +func (*awsAwsjson10_serializeOpListDataIngestionJobs) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson10_serializeOpListDataIngestionJobs) 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.(*ListDataIngestionJobsInput) + _ = 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.0") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListDataIngestionJobs") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson10_serializeOpDocumentListDataIngestionJobsInput(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 awsAwsjson10_serializeOpListDatasets struct { +} + +func (*awsAwsjson10_serializeOpListDatasets) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson10_serializeOpListDatasets) 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.(*ListDatasetsInput) + _ = 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.0") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListDatasets") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson10_serializeOpDocumentListDatasetsInput(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 awsAwsjson10_serializeOpListInferenceEvents struct { } -func (*awsAwsjson10_serializeOpListDataIngestionJobs) ID() string { +func (*awsAwsjson10_serializeOpListInferenceEvents) ID() string { return "OperationSerializer" } -func (m *awsAwsjson10_serializeOpListDataIngestionJobs) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsAwsjson10_serializeOpListInferenceEvents) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -581,7 +1021,7 @@ func (m *awsAwsjson10_serializeOpListDataIngestionJobs) HandleSerialize(ctx cont return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*ListDataIngestionJobsInput) + input, ok := in.Parameters.(*ListInferenceEventsInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} @@ -602,10 +1042,10 @@ func (m *awsAwsjson10_serializeOpListDataIngestionJobs) HandleSerialize(ctx cont return out, metadata, &smithy.SerializationError{Err: err} } httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.0") - httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListDataIngestionJobs") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListInferenceEvents") jsonEncoder := smithyjson.NewEncoder() - if err := awsAwsjson10_serializeOpDocumentListDataIngestionJobsInput(input, jsonEncoder.Value); err != nil { + if err := awsAwsjson10_serializeOpDocumentListInferenceEventsInput(input, jsonEncoder.Value); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -621,14 +1061,14 @@ func (m *awsAwsjson10_serializeOpListDataIngestionJobs) HandleSerialize(ctx cont return next.HandleSerialize(ctx, in) } -type awsAwsjson10_serializeOpListDatasets struct { +type awsAwsjson10_serializeOpListInferenceExecutions struct { } -func (*awsAwsjson10_serializeOpListDatasets) ID() string { +func (*awsAwsjson10_serializeOpListInferenceExecutions) ID() string { return "OperationSerializer" } -func (m *awsAwsjson10_serializeOpListDatasets) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsAwsjson10_serializeOpListInferenceExecutions) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -636,7 +1076,7 @@ func (m *awsAwsjson10_serializeOpListDatasets) HandleSerialize(ctx context.Conte return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*ListDatasetsInput) + input, ok := in.Parameters.(*ListInferenceExecutionsInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} @@ -657,10 +1097,10 @@ func (m *awsAwsjson10_serializeOpListDatasets) HandleSerialize(ctx context.Conte return out, metadata, &smithy.SerializationError{Err: err} } httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.0") - httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListDatasets") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListInferenceExecutions") jsonEncoder := smithyjson.NewEncoder() - if err := awsAwsjson10_serializeOpDocumentListDatasetsInput(input, jsonEncoder.Value); err != nil { + if err := awsAwsjson10_serializeOpDocumentListInferenceExecutionsInput(input, jsonEncoder.Value); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -676,14 +1116,14 @@ func (m *awsAwsjson10_serializeOpListDatasets) HandleSerialize(ctx context.Conte return next.HandleSerialize(ctx, in) } -type awsAwsjson10_serializeOpListInferenceEvents struct { +type awsAwsjson10_serializeOpListInferenceSchedulers struct { } -func (*awsAwsjson10_serializeOpListInferenceEvents) ID() string { +func (*awsAwsjson10_serializeOpListInferenceSchedulers) ID() string { return "OperationSerializer" } -func (m *awsAwsjson10_serializeOpListInferenceEvents) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsAwsjson10_serializeOpListInferenceSchedulers) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -691,7 +1131,7 @@ func (m *awsAwsjson10_serializeOpListInferenceEvents) HandleSerialize(ctx contex return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*ListInferenceEventsInput) + input, ok := in.Parameters.(*ListInferenceSchedulersInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} @@ -712,10 +1152,10 @@ func (m *awsAwsjson10_serializeOpListInferenceEvents) HandleSerialize(ctx contex return out, metadata, &smithy.SerializationError{Err: err} } httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.0") - httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListInferenceEvents") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListInferenceSchedulers") jsonEncoder := smithyjson.NewEncoder() - if err := awsAwsjson10_serializeOpDocumentListInferenceEventsInput(input, jsonEncoder.Value); err != nil { + if err := awsAwsjson10_serializeOpDocumentListInferenceSchedulersInput(input, jsonEncoder.Value); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -731,14 +1171,14 @@ func (m *awsAwsjson10_serializeOpListInferenceEvents) HandleSerialize(ctx contex return next.HandleSerialize(ctx, in) } -type awsAwsjson10_serializeOpListInferenceExecutions struct { +type awsAwsjson10_serializeOpListLabelGroups struct { } -func (*awsAwsjson10_serializeOpListInferenceExecutions) ID() string { +func (*awsAwsjson10_serializeOpListLabelGroups) ID() string { return "OperationSerializer" } -func (m *awsAwsjson10_serializeOpListInferenceExecutions) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsAwsjson10_serializeOpListLabelGroups) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -746,7 +1186,7 @@ func (m *awsAwsjson10_serializeOpListInferenceExecutions) HandleSerialize(ctx co return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*ListInferenceExecutionsInput) + input, ok := in.Parameters.(*ListLabelGroupsInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} @@ -767,10 +1207,10 @@ func (m *awsAwsjson10_serializeOpListInferenceExecutions) HandleSerialize(ctx co return out, metadata, &smithy.SerializationError{Err: err} } httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.0") - httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListInferenceExecutions") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListLabelGroups") jsonEncoder := smithyjson.NewEncoder() - if err := awsAwsjson10_serializeOpDocumentListInferenceExecutionsInput(input, jsonEncoder.Value); err != nil { + if err := awsAwsjson10_serializeOpDocumentListLabelGroupsInput(input, jsonEncoder.Value); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -786,14 +1226,14 @@ func (m *awsAwsjson10_serializeOpListInferenceExecutions) HandleSerialize(ctx co return next.HandleSerialize(ctx, in) } -type awsAwsjson10_serializeOpListInferenceSchedulers struct { +type awsAwsjson10_serializeOpListLabels struct { } -func (*awsAwsjson10_serializeOpListInferenceSchedulers) ID() string { +func (*awsAwsjson10_serializeOpListLabels) ID() string { return "OperationSerializer" } -func (m *awsAwsjson10_serializeOpListInferenceSchedulers) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( +func (m *awsAwsjson10_serializeOpListLabels) HandleSerialize(ctx context.Context, in middleware.SerializeInput, next middleware.SerializeHandler) ( out middleware.SerializeOutput, metadata middleware.Metadata, err error, ) { request, ok := in.Request.(*smithyhttp.Request) @@ -801,7 +1241,7 @@ func (m *awsAwsjson10_serializeOpListInferenceSchedulers) HandleSerialize(ctx co return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown transport type %T", in.Request)} } - input, ok := in.Parameters.(*ListInferenceSchedulersInput) + input, ok := in.Parameters.(*ListLabelsInput) _ = input if !ok { return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} @@ -822,10 +1262,10 @@ func (m *awsAwsjson10_serializeOpListInferenceSchedulers) HandleSerialize(ctx co return out, metadata, &smithy.SerializationError{Err: err} } httpBindingEncoder.SetHeader("Content-Type").String("application/x-amz-json-1.0") - httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListInferenceSchedulers") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.ListLabels") jsonEncoder := smithyjson.NewEncoder() - if err := awsAwsjson10_serializeOpDocumentListInferenceSchedulersInput(input, jsonEncoder.Value); err != nil { + if err := awsAwsjson10_serializeOpDocumentListLabelsInput(input, jsonEncoder.Value); err != nil { return out, metadata, &smithy.SerializationError{Err: err} } @@ -1335,6 +1775,61 @@ func (m *awsAwsjson10_serializeOpUpdateInferenceScheduler) HandleSerialize(ctx c return next.HandleSerialize(ctx, in) } + +type awsAwsjson10_serializeOpUpdateLabelGroup struct { +} + +func (*awsAwsjson10_serializeOpUpdateLabelGroup) ID() string { + return "OperationSerializer" +} + +func (m *awsAwsjson10_serializeOpUpdateLabelGroup) 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.(*UpdateLabelGroupInput) + _ = 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.0") + httpBindingEncoder.SetHeader("X-Amz-Target").String("AWSLookoutEquipmentFrontendService.UpdateLabelGroup") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsAwsjson10_serializeOpDocumentUpdateLabelGroupInput(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) +} func awsAwsjson10_serializeDocumentDataPreProcessingConfiguration(v *types.DataPreProcessingConfiguration, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -1359,6 +1854,17 @@ func awsAwsjson10_serializeDocumentDatasetSchema(v *types.DatasetSchema, value s return nil } +func awsAwsjson10_serializeDocumentFaultCodes(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 awsAwsjson10_serializeDocumentInferenceInputConfiguration(v *types.InferenceInputConfiguration, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -1495,6 +2001,11 @@ func awsAwsjson10_serializeDocumentLabelsInputConfiguration(v *types.LabelsInput object := value.Object() defer object.Close() + if v.LabelGroupName != nil { + ok := object.Key("LabelGroupName") + ok.String(*v.LabelGroupName) + } + if v.S3InputConfiguration != nil { ok := object.Key("S3InputConfiguration") if err := awsAwsjson10_serializeDocumentLabelsS3InputConfiguration(v.S3InputConfiguration, ok); err != nil { @@ -1662,6 +2173,84 @@ func awsAwsjson10_serializeOpDocumentCreateInferenceSchedulerInput(v *CreateInfe return nil } +func awsAwsjson10_serializeOpDocumentCreateLabelGroupInput(v *CreateLabelGroupInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.ClientToken != nil { + ok := object.Key("ClientToken") + ok.String(*v.ClientToken) + } + + if v.FaultCodes != nil { + ok := object.Key("FaultCodes") + if err := awsAwsjson10_serializeDocumentFaultCodes(v.FaultCodes, ok); err != nil { + return err + } + } + + if v.LabelGroupName != nil { + ok := object.Key("LabelGroupName") + ok.String(*v.LabelGroupName) + } + + if v.Tags != nil { + ok := object.Key("Tags") + if err := awsAwsjson10_serializeDocumentTagList(v.Tags, ok); err != nil { + return err + } + } + + return nil +} + +func awsAwsjson10_serializeOpDocumentCreateLabelInput(v *CreateLabelInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.ClientToken != nil { + ok := object.Key("ClientToken") + ok.String(*v.ClientToken) + } + + if v.EndTime != nil { + ok := object.Key("EndTime") + ok.Double(smithytime.FormatEpochSeconds(*v.EndTime)) + } + + if v.Equipment != nil { + ok := object.Key("Equipment") + ok.String(*v.Equipment) + } + + if v.FaultCode != nil { + ok := object.Key("FaultCode") + ok.String(*v.FaultCode) + } + + if v.LabelGroupName != nil { + ok := object.Key("LabelGroupName") + ok.String(*v.LabelGroupName) + } + + if v.Notes != nil { + ok := object.Key("Notes") + ok.String(*v.Notes) + } + + if len(v.Rating) > 0 { + ok := object.Key("Rating") + ok.String(string(v.Rating)) + } + + if v.StartTime != nil { + ok := object.Key("StartTime") + ok.Double(smithytime.FormatEpochSeconds(*v.StartTime)) + } + + return nil +} + func awsAwsjson10_serializeOpDocumentCreateModelInput(v *CreateModelInput, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -1771,6 +2360,35 @@ func awsAwsjson10_serializeOpDocumentDeleteInferenceSchedulerInput(v *DeleteInfe return nil } +func awsAwsjson10_serializeOpDocumentDeleteLabelGroupInput(v *DeleteLabelGroupInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.LabelGroupName != nil { + ok := object.Key("LabelGroupName") + ok.String(*v.LabelGroupName) + } + + return nil +} + +func awsAwsjson10_serializeOpDocumentDeleteLabelInput(v *DeleteLabelInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.LabelGroupName != nil { + ok := object.Key("LabelGroupName") + ok.String(*v.LabelGroupName) + } + + if v.LabelId != nil { + ok := object.Key("LabelId") + ok.String(*v.LabelId) + } + + return nil +} + func awsAwsjson10_serializeOpDocumentDeleteModelInput(v *DeleteModelInput, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -1819,6 +2437,35 @@ func awsAwsjson10_serializeOpDocumentDescribeInferenceSchedulerInput(v *Describe return nil } +func awsAwsjson10_serializeOpDocumentDescribeLabelGroupInput(v *DescribeLabelGroupInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.LabelGroupName != nil { + ok := object.Key("LabelGroupName") + ok.String(*v.LabelGroupName) + } + + return nil +} + +func awsAwsjson10_serializeOpDocumentDescribeLabelInput(v *DescribeLabelInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.LabelGroupName != nil { + ok := object.Key("LabelGroupName") + ok.String(*v.LabelGroupName) + } + + if v.LabelId != nil { + ok := object.Key("LabelId") + ok.String(*v.LabelId) + } + + return nil +} + func awsAwsjson10_serializeOpDocumentDescribeModelInput(v *DescribeModelInput, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -1976,6 +2623,70 @@ func awsAwsjson10_serializeOpDocumentListInferenceSchedulersInput(v *ListInferen return nil } +func awsAwsjson10_serializeOpDocumentListLabelGroupsInput(v *ListLabelGroupsInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.LabelGroupNameBeginsWith != nil { + ok := object.Key("LabelGroupNameBeginsWith") + ok.String(*v.LabelGroupNameBeginsWith) + } + + 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 awsAwsjson10_serializeOpDocumentListLabelsInput(v *ListLabelsInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Equipment != nil { + ok := object.Key("Equipment") + ok.String(*v.Equipment) + } + + if v.FaultCode != nil { + ok := object.Key("FaultCode") + ok.String(*v.FaultCode) + } + + if v.IntervalEndTime != nil { + ok := object.Key("IntervalEndTime") + ok.Double(smithytime.FormatEpochSeconds(*v.IntervalEndTime)) + } + + if v.IntervalStartTime != nil { + ok := object.Key("IntervalStartTime") + ok.Double(smithytime.FormatEpochSeconds(*v.IntervalStartTime)) + } + + if v.LabelGroupName != nil { + ok := object.Key("LabelGroupName") + ok.String(*v.LabelGroupName) + } + + 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 awsAwsjson10_serializeOpDocumentListModelsInput(v *ListModelsInput, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -2178,3 +2889,22 @@ func awsAwsjson10_serializeOpDocumentUpdateInferenceSchedulerInput(v *UpdateInfe return nil } + +func awsAwsjson10_serializeOpDocumentUpdateLabelGroupInput(v *UpdateLabelGroupInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.FaultCodes != nil { + ok := object.Key("FaultCodes") + if err := awsAwsjson10_serializeDocumentFaultCodes(v.FaultCodes, ok); err != nil { + return err + } + } + + if v.LabelGroupName != nil { + ok := object.Key("LabelGroupName") + ok.String(*v.LabelGroupName) + } + + return nil +} diff --git a/service/lookoutequipment/types/enums.go b/service/lookoutequipment/types/enums.go index 23ab8150e1a..12b8205da87 100644 --- a/service/lookoutequipment/types/enums.go +++ b/service/lookoutequipment/types/enums.go @@ -108,6 +108,44 @@ func (IngestionJobStatus) Values() []IngestionJobStatus { } } +type LabelRating string + +// Enum values for LabelRating +const ( + LabelRatingAnomaly LabelRating = "ANOMALY" + LabelRatingNoAnomaly LabelRating = "NO_ANOMALY" + LabelRatingNeutral LabelRating = "NEUTRAL" +) + +// Values returns all known values for LabelRating. 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 (LabelRating) Values() []LabelRating { + return []LabelRating{ + "ANOMALY", + "NO_ANOMALY", + "NEUTRAL", + } +} + +type LatestInferenceResult string + +// Enum values for LatestInferenceResult +const ( + LatestInferenceResultAnomalous LatestInferenceResult = "ANOMALOUS" + LatestInferenceResultNormal LatestInferenceResult = "NORMAL" +) + +// Values returns all known values for LatestInferenceResult. 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 (LatestInferenceResult) Values() []LatestInferenceResult { + return []LatestInferenceResult{ + "ANOMALOUS", + "NORMAL", + } +} + type ModelStatus string // Enum values for ModelStatus diff --git a/service/lookoutequipment/types/types.go b/service/lookoutequipment/types/types.go index 87446ac0b81..63464ecda08 100644 --- a/service/lookoutequipment/types/types.go +++ b/service/lookoutequipment/types/types.go @@ -344,6 +344,10 @@ type InferenceSchedulerSummary struct { // The name of the inference scheduler. InferenceSchedulerName *string + // Indicates whether the latest execution for the inference scheduler was Anomalous + // (anomalous events found) or Normal (no anomalous events found). + LatestInferenceResult LatestInferenceResult + // The Amazon Resource Name (ARN) of the ML model used by the inference scheduler. ModelArn *string @@ -447,13 +451,32 @@ type InvalidSensorData struct { noSmithyDocumentSerde } +// Contains information about the label group. +type LabelGroupSummary struct { + + // The time at which the label group was created. + CreatedAt *time.Time + + // The ARN of the label group. + LabelGroupArn *string + + // The name of the label group. + LabelGroupName *string + + // The time at which the label group was updated. + UpdatedAt *time.Time + + noSmithyDocumentSerde +} + // Contains the configuration information for the S3 location being used to hold // label data. type LabelsInputConfiguration struct { + // The name of the label group to be used for label data. + LabelGroupName *string + // Contains location information for the S3 location being used for label data. - // - // This member is required. S3InputConfiguration *LabelsS3InputConfiguration noSmithyDocumentSerde @@ -474,6 +497,41 @@ type LabelsS3InputConfiguration struct { noSmithyDocumentSerde } +// Information about the label. +type LabelSummary struct { + + // The time at which the label was created. + CreatedAt *time.Time + + // The timestamp indicating the end of the label. + EndTime *time.Time + + // Indicates that a label pertains to a particular piece of equipment. + Equipment *string + + // Indicates the type of anomaly associated with the label. Data in this field will + // be retained for service usage. Follow best practices for the security of your + // data. + FaultCode *string + + // The ARN of the label group. + LabelGroupArn *string + + // The name of the label group. + LabelGroupName *string + + // The ID of the label. + LabelId *string + + // Indicates whether a labeled event represents an anomaly. + Rating LabelRating + + // The timestamp indicating the start of the label. + StartTime *time.Time + + noSmithyDocumentSerde +} + // Entity that comprises information on large gaps between consecutive timestamps // in data. type LargeTimestampGaps struct { diff --git a/service/lookoutequipment/validators.go b/service/lookoutequipment/validators.go index e874b5f3b3a..8e0d441fb89 100644 --- a/service/lookoutequipment/validators.go +++ b/service/lookoutequipment/validators.go @@ -50,6 +50,46 @@ func (m *validateOpCreateInferenceScheduler) HandleInitialize(ctx context.Contex return next.HandleInitialize(ctx, in) } +type validateOpCreateLabelGroup struct { +} + +func (*validateOpCreateLabelGroup) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpCreateLabelGroup) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*CreateLabelGroupInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpCreateLabelGroupInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + +type validateOpCreateLabel struct { +} + +func (*validateOpCreateLabel) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpCreateLabel) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*CreateLabelInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpCreateLabelInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpCreateModel struct { } @@ -110,6 +150,46 @@ func (m *validateOpDeleteInferenceScheduler) HandleInitialize(ctx context.Contex return next.HandleInitialize(ctx, in) } +type validateOpDeleteLabelGroup struct { +} + +func (*validateOpDeleteLabelGroup) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDeleteLabelGroup) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DeleteLabelGroupInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDeleteLabelGroupInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + +type validateOpDeleteLabel struct { +} + +func (*validateOpDeleteLabel) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDeleteLabel) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DeleteLabelInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDeleteLabelInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpDeleteModel struct { } @@ -190,6 +270,46 @@ func (m *validateOpDescribeInferenceScheduler) HandleInitialize(ctx context.Cont return next.HandleInitialize(ctx, in) } +type validateOpDescribeLabelGroup struct { +} + +func (*validateOpDescribeLabelGroup) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDescribeLabelGroup) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DescribeLabelGroupInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDescribeLabelGroupInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + +type validateOpDescribeLabel struct { +} + +func (*validateOpDescribeLabel) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDescribeLabel) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DescribeLabelInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDescribeLabelInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpDescribeModel struct { } @@ -250,6 +370,26 @@ func (m *validateOpListInferenceExecutions) HandleInitialize(ctx context.Context return next.HandleInitialize(ctx, in) } +type validateOpListLabels struct { +} + +func (*validateOpListLabels) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpListLabels) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*ListLabelsInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpListLabelsInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpListSensorStatistics struct { } @@ -410,6 +550,26 @@ func (m *validateOpUpdateInferenceScheduler) HandleInitialize(ctx context.Contex return next.HandleInitialize(ctx, in) } +type validateOpUpdateLabelGroup struct { +} + +func (*validateOpUpdateLabelGroup) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpUpdateLabelGroup) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*UpdateLabelGroupInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpUpdateLabelGroupInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + func addOpCreateDatasetValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpCreateDataset{}, middleware.After) } @@ -418,6 +578,14 @@ func addOpCreateInferenceSchedulerValidationMiddleware(stack *middleware.Stack) return stack.Initialize.Add(&validateOpCreateInferenceScheduler{}, middleware.After) } +func addOpCreateLabelGroupValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpCreateLabelGroup{}, middleware.After) +} + +func addOpCreateLabelValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpCreateLabel{}, middleware.After) +} + func addOpCreateModelValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpCreateModel{}, middleware.After) } @@ -430,6 +598,14 @@ func addOpDeleteInferenceSchedulerValidationMiddleware(stack *middleware.Stack) return stack.Initialize.Add(&validateOpDeleteInferenceScheduler{}, middleware.After) } +func addOpDeleteLabelGroupValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDeleteLabelGroup{}, middleware.After) +} + +func addOpDeleteLabelValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDeleteLabel{}, middleware.After) +} + func addOpDeleteModelValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDeleteModel{}, middleware.After) } @@ -446,6 +622,14 @@ func addOpDescribeInferenceSchedulerValidationMiddleware(stack *middleware.Stack return stack.Initialize.Add(&validateOpDescribeInferenceScheduler{}, middleware.After) } +func addOpDescribeLabelGroupValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDescribeLabelGroup{}, middleware.After) +} + +func addOpDescribeLabelValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDescribeLabel{}, middleware.After) +} + func addOpDescribeModelValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDescribeModel{}, middleware.After) } @@ -458,6 +642,10 @@ func addOpListInferenceExecutionsValidationMiddleware(stack *middleware.Stack) e return stack.Initialize.Add(&validateOpListInferenceExecutions{}, middleware.After) } +func addOpListLabelsValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpListLabels{}, middleware.After) +} + func addOpListSensorStatisticsValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpListSensorStatistics{}, middleware.After) } @@ -490,6 +678,10 @@ func addOpUpdateInferenceSchedulerValidationMiddleware(stack *middleware.Stack) return stack.Initialize.Add(&validateOpUpdateInferenceScheduler{}, middleware.After) } +func addOpUpdateLabelGroupValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpUpdateLabelGroup{}, middleware.After) +} + func validateInferenceInputConfiguration(v *types.InferenceInputConfiguration) error { if v == nil { return nil @@ -595,9 +787,7 @@ func validateLabelsInputConfiguration(v *types.LabelsInputConfiguration) error { return nil } invalidParams := smithy.InvalidParamsError{Context: "LabelsInputConfiguration"} - if v.S3InputConfiguration == nil { - invalidParams.Add(smithy.NewErrParamRequired("S3InputConfiguration")) - } else if v.S3InputConfiguration != nil { + if v.S3InputConfiguration != nil { if err := validateLabelsS3InputConfiguration(v.S3InputConfiguration); err != nil { invalidParams.AddNested("S3InputConfiguration", err.(smithy.InvalidParamsError)) } @@ -728,6 +918,56 @@ func validateOpCreateInferenceSchedulerInput(v *CreateInferenceSchedulerInput) e } } +func validateOpCreateLabelGroupInput(v *CreateLabelGroupInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "CreateLabelGroupInput"} + if v.LabelGroupName == nil { + invalidParams.Add(smithy.NewErrParamRequired("LabelGroupName")) + } + if v.ClientToken == nil { + invalidParams.Add(smithy.NewErrParamRequired("ClientToken")) + } + if v.Tags != nil { + if err := validateTagList(v.Tags); err != nil { + invalidParams.AddNested("Tags", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateOpCreateLabelInput(v *CreateLabelInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "CreateLabelInput"} + if v.LabelGroupName == nil { + invalidParams.Add(smithy.NewErrParamRequired("LabelGroupName")) + } + if v.StartTime == nil { + invalidParams.Add(smithy.NewErrParamRequired("StartTime")) + } + if v.EndTime == nil { + invalidParams.Add(smithy.NewErrParamRequired("EndTime")) + } + if len(v.Rating) == 0 { + invalidParams.Add(smithy.NewErrParamRequired("Rating")) + } + if v.ClientToken == nil { + invalidParams.Add(smithy.NewErrParamRequired("ClientToken")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpCreateModelInput(v *CreateModelInput) error { if v == nil { return nil @@ -789,6 +1029,39 @@ func validateOpDeleteInferenceSchedulerInput(v *DeleteInferenceSchedulerInput) e } } +func validateOpDeleteLabelGroupInput(v *DeleteLabelGroupInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DeleteLabelGroupInput"} + if v.LabelGroupName == nil { + invalidParams.Add(smithy.NewErrParamRequired("LabelGroupName")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateOpDeleteLabelInput(v *DeleteLabelInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DeleteLabelInput"} + if v.LabelGroupName == nil { + invalidParams.Add(smithy.NewErrParamRequired("LabelGroupName")) + } + if v.LabelId == nil { + invalidParams.Add(smithy.NewErrParamRequired("LabelId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpDeleteModelInput(v *DeleteModelInput) error { if v == nil { return nil @@ -849,6 +1122,39 @@ func validateOpDescribeInferenceSchedulerInput(v *DescribeInferenceSchedulerInpu } } +func validateOpDescribeLabelGroupInput(v *DescribeLabelGroupInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DescribeLabelGroupInput"} + if v.LabelGroupName == nil { + invalidParams.Add(smithy.NewErrParamRequired("LabelGroupName")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + +func validateOpDescribeLabelInput(v *DescribeLabelInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DescribeLabelInput"} + if v.LabelGroupName == nil { + invalidParams.Add(smithy.NewErrParamRequired("LabelGroupName")) + } + if v.LabelId == nil { + invalidParams.Add(smithy.NewErrParamRequired("LabelId")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpDescribeModelInput(v *DescribeModelInput) error { if v == nil { return nil @@ -900,6 +1206,21 @@ func validateOpListInferenceExecutionsInput(v *ListInferenceExecutionsInput) err } } +func validateOpListLabelsInput(v *ListLabelsInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "ListLabelsInput"} + if v.LabelGroupName == nil { + invalidParams.Add(smithy.NewErrParamRequired("LabelGroupName")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpListSensorStatisticsInput(v *ListSensorStatisticsInput) error { if v == nil { return nil @@ -1052,3 +1373,18 @@ func validateOpUpdateInferenceSchedulerInput(v *UpdateInferenceSchedulerInput) e return nil } } + +func validateOpUpdateLabelGroupInput(v *UpdateLabelGroupInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "UpdateLabelGroupInput"} + if v.LabelGroupName == nil { + invalidParams.Add(smithy.NewErrParamRequired("LabelGroupName")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} diff --git a/service/macie2/api_op_CreateAllowList.go b/service/macie2/api_op_CreateAllowList.go new file mode 100644 index 00000000000..8744c877b7b --- /dev/null +++ b/service/macie2/api_op_CreateAllowList.go @@ -0,0 +1,186 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package macie2 + +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/macie2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Creates and defines the settings for an allow list. +func (c *Client) CreateAllowList(ctx context.Context, params *CreateAllowListInput, optFns ...func(*Options)) (*CreateAllowListOutput, error) { + if params == nil { + params = &CreateAllowListInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "CreateAllowList", params, optFns, c.addOperationCreateAllowListMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*CreateAllowListOutput) + out.ResultMetadata = metadata + return out, nil +} + +type CreateAllowListInput struct { + + // A unique, case-sensitive token that you provide to ensure the idempotency of the + // request. + // + // This member is required. + ClientToken *string + + // The criteria that specify the text or text pattern to ignore. The criteria can + // be the location and name of an S3 object that lists specific text to ignore + // (s3WordsList), or a regular expression (regex) that defines a text pattern to + // ignore. + // + // This member is required. + Criteria *types.AllowListCriteria + + // A custom name for the allow list. The name can contain as many as 128 + // characters. + // + // This member is required. + Name *string + + // A custom description of the allow list. The description can contain as many as + // 512 characters. + Description *string + + // A map of key-value pairs that specifies the tags to associate with the allow + // list. An allow list can have a maximum of 50 tags. Each tag consists of a tag + // key and an associated tag value. The maximum length of a tag key is 128 + // characters. The maximum length of a tag value is 256 characters. + Tags map[string]string + + noSmithyDocumentSerde +} + +type CreateAllowListOutput struct { + + // The Amazon Resource Name (ARN) of the allow list. + Arn *string + + // The unique identifier for the allow list. + Id *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationCreateAllowListMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpCreateAllowList{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpCreateAllowList{}, 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_opCreateAllowListMiddleware(stack, options); err != nil { + return err + } + if err = addOpCreateAllowListValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opCreateAllowList(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_initializeOpCreateAllowList struct { + tokenProvider IdempotencyTokenProvider +} + +func (*idempotencyToken_initializeOpCreateAllowList) ID() string { + return "OperationIdempotencyTokenAutoFill" +} + +func (m *idempotencyToken_initializeOpCreateAllowList) 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.(*CreateAllowListInput) + if !ok { + return out, metadata, fmt.Errorf("expected middleware input to be of type *CreateAllowListInput ") + } + + 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_opCreateAllowListMiddleware(stack *middleware.Stack, cfg Options) error { + return stack.Initialize.Add(&idempotencyToken_initializeOpCreateAllowList{tokenProvider: cfg.IdempotencyTokenProvider}, middleware.Before) +} + +func newServiceMetadataMiddleware_opCreateAllowList(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "macie2", + OperationName: "CreateAllowList", + } +} diff --git a/service/macie2/api_op_CreateClassificationJob.go b/service/macie2/api_op_CreateClassificationJob.go index ce23fd22cae..501bd4a2f17 100644 --- a/service/macie2/api_op_CreateClassificationJob.go +++ b/service/macie2/api_op_CreateClassificationJob.go @@ -60,6 +60,10 @@ type CreateClassificationJobInput struct { // This member is required. S3JobDefinition *types.S3JobDefinition + // An array of unique identifiers, one for each allow list for the job to use when + // it analyzes data. + AllowListIds []string + // An array of unique identifiers, one for each custom data identifier for the job // to use when it analyzes data. To use only managed data identifiers, don't // specify a value for this property and specify a value other than NONE for the @@ -73,14 +77,14 @@ type CreateClassificationJobInput struct { // For a recurring job, specifies whether to analyze all existing, eligible objects // immediately after the job is created (true). To analyze only those objects that // are created or changed after you create the job and before the job's first - // scheduled run, set this value to false.If you configure the job to run only + // scheduled run, set this value to false. If you configure the job to run only // once, don't specify a value for this property. InitialRun bool // An array of unique identifiers, one for each managed data identifier for the job // to include (use) or exclude (not use) when it analyzes data. Inclusion or // exclusion depends on the managed data identifier selection type that you specify - // for the job (managedDataIdentifierSelector).To retrieve a list of valid values + // for the job (managedDataIdentifierSelector). To retrieve a list of valid values // for this property, use the ListManagedDataIdentifiers operation. ManagedDataIdentifierIds []string diff --git a/service/macie2/api_op_DeleteAllowList.go b/service/macie2/api_op_DeleteAllowList.go new file mode 100644 index 00000000000..16ccfd9e011 --- /dev/null +++ b/service/macie2/api_op_DeleteAllowList.go @@ -0,0 +1,125 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package macie2 + +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 an allow list. +func (c *Client) DeleteAllowList(ctx context.Context, params *DeleteAllowListInput, optFns ...func(*Options)) (*DeleteAllowListOutput, error) { + if params == nil { + params = &DeleteAllowListInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "DeleteAllowList", params, optFns, c.addOperationDeleteAllowListMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*DeleteAllowListOutput) + out.ResultMetadata = metadata + return out, nil +} + +type DeleteAllowListInput struct { + + // The unique identifier for the Amazon Macie resource that the request applies to. + // + // This member is required. + Id *string + + // Specifies whether to force deletion of the allow list, even if active + // classification jobs are configured to use the list. When you try to delete an + // allow list, Amazon Macie checks for classification jobs that use the list and + // have a status other than COMPLETE or CANCELLED. By default, Macie rejects your + // request if any jobs meet these criteria. To skip these checks and delete the + // list, set this value to true. To delete the list only if no active jobs are + // configured to use it, set this value to false. + IgnoreJobChecks *string + + noSmithyDocumentSerde +} + +type DeleteAllowListOutput struct { + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationDeleteAllowListMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpDeleteAllowList{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpDeleteAllowList{}, 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 = addOpDeleteAllowListValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteAllowList(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_opDeleteAllowList(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "macie2", + OperationName: "DeleteAllowList", + } +} diff --git a/service/macie2/api_op_DeleteCustomDataIdentifier.go b/service/macie2/api_op_DeleteCustomDataIdentifier.go index 4d2be82a7bb..2a53c9c6392 100644 --- a/service/macie2/api_op_DeleteCustomDataIdentifier.go +++ b/service/macie2/api_op_DeleteCustomDataIdentifier.go @@ -28,8 +28,7 @@ func (c *Client) DeleteCustomDataIdentifier(ctx context.Context, params *DeleteC type DeleteCustomDataIdentifierInput struct { - // The unique identifier for the Amazon Macie resource or account that the request - // applies to. + // The unique identifier for the Amazon Macie resource that the request applies to. // // This member is required. Id *string diff --git a/service/macie2/api_op_DeleteFindingsFilter.go b/service/macie2/api_op_DeleteFindingsFilter.go index cc3b7b6cfd3..da687362094 100644 --- a/service/macie2/api_op_DeleteFindingsFilter.go +++ b/service/macie2/api_op_DeleteFindingsFilter.go @@ -28,8 +28,7 @@ func (c *Client) DeleteFindingsFilter(ctx context.Context, params *DeleteFinding type DeleteFindingsFilterInput struct { - // The unique identifier for the Amazon Macie resource or account that the request - // applies to. + // The unique identifier for the Amazon Macie resource that the request applies to. // // This member is required. Id *string diff --git a/service/macie2/api_op_DeleteMember.go b/service/macie2/api_op_DeleteMember.go index 4b05813d820..aa688e5bd4d 100644 --- a/service/macie2/api_op_DeleteMember.go +++ b/service/macie2/api_op_DeleteMember.go @@ -29,8 +29,7 @@ func (c *Client) DeleteMember(ctx context.Context, params *DeleteMemberInput, op type DeleteMemberInput struct { - // The unique identifier for the Amazon Macie resource or account that the request - // applies to. + // The unique identifier for the Amazon Macie resource that the request applies to. // // This member is required. Id *string diff --git a/service/macie2/api_op_DescribeClassificationJob.go b/service/macie2/api_op_DescribeClassificationJob.go index 976d706e960..2a8635f78bd 100644 --- a/service/macie2/api_op_DescribeClassificationJob.go +++ b/service/macie2/api_op_DescribeClassificationJob.go @@ -40,6 +40,10 @@ type DescribeClassificationJobInput struct { type DescribeClassificationJobOutput struct { + // An array of unique identifiers, one for each allow list that the job uses when + // it analyzes data. + AllowListIds []string + // The token that was provided to ensure the idempotency of the request to create // the job. ClientToken *string @@ -49,7 +53,7 @@ type DescribeClassificationJobOutput struct { CreatedAt *time.Time // An array of unique identifiers, one for each custom data identifier that the job - // uses to analyze data. This value is null if the job uses only managed data + // uses when it analyzes data. This value is null if the job uses only managed data // identifiers to analyze data. CustomDataIdentifierIds []string diff --git a/service/macie2/api_op_DisassociateMember.go b/service/macie2/api_op_DisassociateMember.go index d21a4e4a061..c53df1e1d73 100644 --- a/service/macie2/api_op_DisassociateMember.go +++ b/service/macie2/api_op_DisassociateMember.go @@ -28,8 +28,7 @@ func (c *Client) DisassociateMember(ctx context.Context, params *DisassociateMem type DisassociateMemberInput struct { - // The unique identifier for the Amazon Macie resource or account that the request - // applies to. + // The unique identifier for the Amazon Macie resource that the request applies to. // // This member is required. Id *string diff --git a/service/macie2/api_op_EnableMacie.go b/service/macie2/api_op_EnableMacie.go index d9e464cc107..94cf8d0d5b8 100644 --- a/service/macie2/api_op_EnableMacie.go +++ b/service/macie2/api_op_EnableMacie.go @@ -37,7 +37,7 @@ type EnableMacieInput struct { // Specifies how often to publish updates to policy findings for the account. This // includes publishing updates to Security Hub and Amazon EventBridge (formerly - // called Amazon CloudWatch Events). + // Amazon CloudWatch Events). FindingPublishingFrequency types.FindingPublishingFrequency // Specifies the new status for the account. To enable Amazon Macie and start all diff --git a/service/macie2/api_op_GetAllowList.go b/service/macie2/api_op_GetAllowList.go new file mode 100644 index 00000000000..b42438b9400 --- /dev/null +++ b/service/macie2/api_op_GetAllowList.go @@ -0,0 +1,153 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package macie2 + +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/macie2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" + "time" +) + +// Retrieves the settings and status of an allow list. +func (c *Client) GetAllowList(ctx context.Context, params *GetAllowListInput, optFns ...func(*Options)) (*GetAllowListOutput, error) { + if params == nil { + params = &GetAllowListInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "GetAllowList", params, optFns, c.addOperationGetAllowListMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*GetAllowListOutput) + out.ResultMetadata = metadata + return out, nil +} + +type GetAllowListInput struct { + + // The unique identifier for the Amazon Macie resource that the request applies to. + // + // This member is required. + Id *string + + noSmithyDocumentSerde +} + +type GetAllowListOutput struct { + + // The Amazon Resource Name (ARN) of the allow list. + Arn *string + + // The date and time, in UTC and extended ISO 8601 format, when the allow list was + // created in Amazon Macie. + CreatedAt *time.Time + + // The criteria that specify the text or text pattern to ignore. The criteria can + // be the location and name of an S3 object that lists specific text to ignore + // (s3WordsList), or a regular expression (regex) that defines a text pattern to + // ignore. + Criteria *types.AllowListCriteria + + // The custom description of the allow list. + Description *string + + // The unique identifier for the allow list. + Id *string + + // The custom name of the allow list. + Name *string + + // The current status of the allow list, which indicates whether Amazon Macie can + // access and use the list's criteria. + Status *types.AllowListStatus + + // A map of key-value pairs that specifies which tags (keys and values) are + // associated with the allow list. + Tags map[string]string + + // The date and time, in UTC and extended ISO 8601 format, when the allow list's + // settings were most recently changed in Amazon Macie. + UpdatedAt *time.Time + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationGetAllowListMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpGetAllowList{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpGetAllowList{}, 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 = addOpGetAllowListValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opGetAllowList(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_opGetAllowList(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "macie2", + OperationName: "GetAllowList", + } +} diff --git a/service/macie2/api_op_GetCustomDataIdentifier.go b/service/macie2/api_op_GetCustomDataIdentifier.go index dbebf7879b8..40ab7715063 100644 --- a/service/macie2/api_op_GetCustomDataIdentifier.go +++ b/service/macie2/api_op_GetCustomDataIdentifier.go @@ -30,8 +30,7 @@ func (c *Client) GetCustomDataIdentifier(ctx context.Context, params *GetCustomD type GetCustomDataIdentifierInput struct { - // The unique identifier for the Amazon Macie resource or account that the request - // applies to. + // The unique identifier for the Amazon Macie resource that the request applies to. // // This member is required. Id *string diff --git a/service/macie2/api_op_GetFindingsFilter.go b/service/macie2/api_op_GetFindingsFilter.go index beaeedfb3fc..c1dcece51dd 100644 --- a/service/macie2/api_op_GetFindingsFilter.go +++ b/service/macie2/api_op_GetFindingsFilter.go @@ -29,8 +29,7 @@ func (c *Client) GetFindingsFilter(ctx context.Context, params *GetFindingsFilte type GetFindingsFilterInput struct { - // The unique identifier for the Amazon Macie resource or account that the request - // applies to. + // The unique identifier for the Amazon Macie resource that the request applies to. // // This member is required. Id *string @@ -65,7 +64,7 @@ type GetFindingsFilterOutput struct { // findings, relative to other filters that are also applied to the findings. Position int32 - // A map of key-value pairs that identifies the tags (keys and values) that are + // A map of key-value pairs that specifies which tags (keys and values) are // associated with the filter. Tags map[string]string diff --git a/service/macie2/api_op_GetMacieSession.go b/service/macie2/api_op_GetMacieSession.go index e9371150068..a77cc380e83 100644 --- a/service/macie2/api_op_GetMacieSession.go +++ b/service/macie2/api_op_GetMacieSession.go @@ -41,7 +41,7 @@ type GetMacieSessionOutput struct { // The frequency with which Amazon Macie publishes updates to policy findings for // the account. This includes publishing updates to Security Hub and Amazon - // EventBridge (formerly called Amazon CloudWatch Events). + // EventBridge (formerly Amazon CloudWatch Events). FindingPublishingFrequency types.FindingPublishingFrequency // The Amazon Resource Name (ARN) of the service-linked role that allows Amazon diff --git a/service/macie2/api_op_GetMember.go b/service/macie2/api_op_GetMember.go index 769ef07f34a..440ed2facc6 100644 --- a/service/macie2/api_op_GetMember.go +++ b/service/macie2/api_op_GetMember.go @@ -31,8 +31,7 @@ func (c *Client) GetMember(ctx context.Context, params *GetMemberInput, optFns . type GetMemberInput struct { - // The unique identifier for the Amazon Macie resource or account that the request - // applies to. + // The unique identifier for the Amazon Macie resource that the request applies to. // // This member is required. Id *string @@ -68,8 +67,8 @@ type GetMemberOutput struct { // account. RelationshipStatus types.RelationshipStatus - // A map of key-value pairs that identifies the tags (keys and values) that are - // associated with the member account in Amazon Macie. + // A map of key-value pairs that specifies which tags (keys and values) are + // associated with the account in Amazon Macie. Tags map[string]string // The date and time, in UTC and extended ISO 8601 format, of the most recent diff --git a/service/macie2/api_op_GetRevealConfiguration.go b/service/macie2/api_op_GetRevealConfiguration.go index 52e7522e162..2fdf8e086da 100644 --- a/service/macie2/api_op_GetRevealConfiguration.go +++ b/service/macie2/api_op_GetRevealConfiguration.go @@ -11,8 +11,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Retrieves the status and configuration settings for retrieving (revealing) -// occurrences of sensitive data reported by findings. +// Retrieves the status and configuration settings for retrieving occurrences of +// sensitive data reported by findings. func (c *Client) GetRevealConfiguration(ctx context.Context, params *GetRevealConfigurationInput, optFns ...func(*Options)) (*GetRevealConfigurationOutput, error) { if params == nil { params = &GetRevealConfigurationInput{} diff --git a/service/macie2/api_op_GetSensitiveDataOccurrences.go b/service/macie2/api_op_GetSensitiveDataOccurrences.go index f91912a6aa4..283bfe6fc88 100644 --- a/service/macie2/api_op_GetSensitiveDataOccurrences.go +++ b/service/macie2/api_op_GetSensitiveDataOccurrences.go @@ -16,7 +16,7 @@ import ( "time" ) -// Retrieves (reveals) occurrences of sensitive data reported by a finding. +// Retrieves occurrences of sensitive data reported by a finding. func (c *Client) GetSensitiveDataOccurrences(ctx context.Context, params *GetSensitiveDataOccurrencesInput, optFns ...func(*Options)) (*GetSensitiveDataOccurrencesOutput, error) { if params == nil { params = &GetSensitiveDataOccurrencesInput{} diff --git a/service/macie2/api_op_GetSensitiveDataOccurrencesAvailability.go b/service/macie2/api_op_GetSensitiveDataOccurrencesAvailability.go index 36714980e80..d9f5428eec0 100644 --- a/service/macie2/api_op_GetSensitiveDataOccurrencesAvailability.go +++ b/service/macie2/api_op_GetSensitiveDataOccurrencesAvailability.go @@ -11,8 +11,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Checks whether occurrences of sensitive data can be retrieved (revealed) for a -// finding. +// Checks whether occurrences of sensitive data can be retrieved for a finding. func (c *Client) GetSensitiveDataOccurrencesAvailability(ctx context.Context, params *GetSensitiveDataOccurrencesAvailabilityInput, optFns ...func(*Options)) (*GetSensitiveDataOccurrencesAvailabilityOutput, error) { if params == nil { params = &GetSensitiveDataOccurrencesAvailabilityInput{} @@ -62,18 +61,18 @@ type GetSensitiveDataOccurrencesAvailabilityOutput struct { // // * // OBJECT_UNAVAILABLE - The affected S3 object isn't available. The object might - // have been renamed, moved, or deleted. Or the object was changed after Amazon - // Macie created the finding. + // have been renamed, moved, or deleted. Or the object was changed after Macie + // created the finding. // - // * UNSUPPORTED_FINDING_TYPE - The specified finding - // isn't a sensitive data finding. + // * UNSUPPORTED_FINDING_TYPE - The specified finding isn't a + // sensitive data finding. // - // * UNSUPPORTED_OBJECT_TYPE - The affected S3 - // object uses a file or storage format that Macie doesn't support for retrieving - // occurrences of sensitive data. + // * UNSUPPORTED_OBJECT_TYPE - The affected S3 object uses + // a file or storage format that Macie doesn't support for retrieving occurrences + // of sensitive data. // - // This value is null if sensitive data can be - // retrieved for the finding. + // This value is null if sensitive data can be retrieved for + // the finding. Reasons []types.UnavailabilityReasonCode // Metadata pertaining to the operation's result. diff --git a/service/macie2/api_op_ListAllowLists.go b/service/macie2/api_op_ListAllowLists.go new file mode 100644 index 00000000000..d940f9a64af --- /dev/null +++ b/service/macie2/api_op_ListAllowLists.go @@ -0,0 +1,124 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package macie2 + +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/macie2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Retrieves a subset of information about all the allow lists for an account. +func (c *Client) ListAllowLists(ctx context.Context, params *ListAllowListsInput, optFns ...func(*Options)) (*ListAllowListsOutput, error) { + if params == nil { + params = &ListAllowListsInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "ListAllowLists", params, optFns, c.addOperationListAllowListsMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*ListAllowListsOutput) + out.ResultMetadata = metadata + return out, nil +} + +type ListAllowListsInput struct { + + // The maximum number of items to include in each page of a paginated response. + MaxResults int32 + + // The nextToken string that specifies which page of results to return in a + // paginated response. + NextToken *string + + noSmithyDocumentSerde +} + +type ListAllowListsOutput struct { + + // An array of objects, one for each allow list. + AllowLists []types.AllowListSummary + + // The string to use in a subsequent request to get the next page of results in a + // paginated response. This value is null if there are no additional pages. + NextToken *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationListAllowListsMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpListAllowLists{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpListAllowLists{}, 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_opListAllowLists(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_opListAllowLists(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "macie2", + OperationName: "ListAllowLists", + } +} diff --git a/service/macie2/api_op_ListTagsForResource.go b/service/macie2/api_op_ListTagsForResource.go index 221f1ed4d2a..c60f56cf3bb 100644 --- a/service/macie2/api_op_ListTagsForResource.go +++ b/service/macie2/api_op_ListTagsForResource.go @@ -10,8 +10,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Retrieves the tags (keys and values) that are associated with a classification -// job, custom data identifier, findings filter, or member account. +// Retrieves the tags (keys and values) that are associated with an Amazon Macie +// resource. func (c *Client) ListTagsForResource(ctx context.Context, params *ListTagsForResourceInput, optFns ...func(*Options)) (*ListTagsForResourceOutput, error) { if params == nil { params = &ListTagsForResourceInput{} @@ -29,8 +29,7 @@ func (c *Client) ListTagsForResource(ctx context.Context, params *ListTagsForRes type ListTagsForResourceInput struct { - // The Amazon Resource Name (ARN) of the classification job, custom data - // identifier, findings filter, or member account. + // The Amazon Resource Name (ARN) of the resource. // // This member is required. ResourceArn *string @@ -40,7 +39,7 @@ type ListTagsForResourceInput struct { type ListTagsForResourceOutput struct { - // A map of key-value pairs that identifies the tags (keys and values) that are + // A map of key-value pairs that specifies which tags (keys and values) are // associated with the resource. Tags map[string]string diff --git a/service/macie2/api_op_TagResource.go b/service/macie2/api_op_TagResource.go index 0f6286bc2e7..ec5c51bb20e 100644 --- a/service/macie2/api_op_TagResource.go +++ b/service/macie2/api_op_TagResource.go @@ -10,8 +10,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Adds or updates one or more tags (keys and values) that are associated with a -// classification job, custom data identifier, findings filter, or member account. +// Adds or updates one or more tags (keys and values) that are associated with an +// Amazon Macie resource. func (c *Client) TagResource(ctx context.Context, params *TagResourceInput, optFns ...func(*Options)) (*TagResourceOutput, error) { if params == nil { params = &TagResourceInput{} @@ -29,8 +29,7 @@ func (c *Client) TagResource(ctx context.Context, params *TagResourceInput, optF type TagResourceInput struct { - // The Amazon Resource Name (ARN) of the classification job, custom data - // identifier, findings filter, or member account. + // The Amazon Resource Name (ARN) of the resource. // // This member is required. ResourceArn *string diff --git a/service/macie2/api_op_UntagResource.go b/service/macie2/api_op_UntagResource.go index 05ff4ca4d1c..df9299c7743 100644 --- a/service/macie2/api_op_UntagResource.go +++ b/service/macie2/api_op_UntagResource.go @@ -10,8 +10,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Removes one or more tags (keys and values) from a classification job, custom -// data identifier, findings filter, or member account. +// Removes one or more tags (keys and values) from an Amazon Macie resource. func (c *Client) UntagResource(ctx context.Context, params *UntagResourceInput, optFns ...func(*Options)) (*UntagResourceOutput, error) { if params == nil { params = &UntagResourceInput{} @@ -29,15 +28,14 @@ func (c *Client) UntagResource(ctx context.Context, params *UntagResourceInput, type UntagResourceInput struct { - // The Amazon Resource Name (ARN) of the classification job, custom data - // identifier, findings filter, or member account. + // The Amazon Resource Name (ARN) of the resource. // // This member is required. ResourceArn *string // One or more tags (keys) to remove from the resource. In an HTTP request to // remove multiple tags, append the tagKeys parameter and argument for each tag to - // remove, and separate them with an ampersand (&). + // remove, separated by an ampersand (&). // // This member is required. TagKeys []string diff --git a/service/macie2/api_op_UpdateAllowList.go b/service/macie2/api_op_UpdateAllowList.go new file mode 100644 index 00000000000..c4203317847 --- /dev/null +++ b/service/macie2/api_op_UpdateAllowList.go @@ -0,0 +1,144 @@ +// Code generated by smithy-go-codegen DO NOT EDIT. + +package macie2 + +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/macie2/types" + "github.com/aws/smithy-go/middleware" + smithyhttp "github.com/aws/smithy-go/transport/http" +) + +// Updates the settings for an allow list. +func (c *Client) UpdateAllowList(ctx context.Context, params *UpdateAllowListInput, optFns ...func(*Options)) (*UpdateAllowListOutput, error) { + if params == nil { + params = &UpdateAllowListInput{} + } + + result, metadata, err := c.invokeOperation(ctx, "UpdateAllowList", params, optFns, c.addOperationUpdateAllowListMiddlewares) + if err != nil { + return nil, err + } + + out := result.(*UpdateAllowListOutput) + out.ResultMetadata = metadata + return out, nil +} + +type UpdateAllowListInput struct { + + // The criteria that specify the text or text pattern to ignore. The criteria can + // be the location and name of an S3 object that lists specific text to ignore + // (s3WordsList), or a regular expression that defines a text pattern to ignore + // (regex). You can change a list's underlying criteria, such as the name of the S3 + // object or the regular expression to use. However, you can't change the type from + // s3WordsList to regex or the other way around. + // + // This member is required. + Criteria *types.AllowListCriteria + + // The unique identifier for the Amazon Macie resource that the request applies to. + // + // This member is required. + Id *string + + // A custom name for the allow list. The name can contain as many as 128 + // characters. + // + // This member is required. + Name *string + + // A custom description of the allow list. The description can contain as many as + // 512 characters. + Description *string + + noSmithyDocumentSerde +} + +type UpdateAllowListOutput struct { + + // The Amazon Resource Name (ARN) of the allow list. + Arn *string + + // The unique identifier for the allow list. + Id *string + + // Metadata pertaining to the operation's result. + ResultMetadata middleware.Metadata + + noSmithyDocumentSerde +} + +func (c *Client) addOperationUpdateAllowListMiddlewares(stack *middleware.Stack, options Options) (err error) { + err = stack.Serialize.Add(&awsRestjson1_serializeOpUpdateAllowList{}, middleware.After) + if err != nil { + return err + } + err = stack.Deserialize.Add(&awsRestjson1_deserializeOpUpdateAllowList{}, 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 = addOpUpdateAllowListValidationMiddleware(stack); err != nil { + return err + } + if err = stack.Initialize.Add(newServiceMetadataMiddleware_opUpdateAllowList(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_opUpdateAllowList(region string) *awsmiddleware.RegisterServiceMetadata { + return &awsmiddleware.RegisterServiceMetadata{ + Region: region, + ServiceID: ServiceID, + SigningName: "macie2", + OperationName: "UpdateAllowList", + } +} diff --git a/service/macie2/api_op_UpdateFindingsFilter.go b/service/macie2/api_op_UpdateFindingsFilter.go index e37da12b0b9..05a5d59fdcf 100644 --- a/service/macie2/api_op_UpdateFindingsFilter.go +++ b/service/macie2/api_op_UpdateFindingsFilter.go @@ -30,8 +30,7 @@ func (c *Client) UpdateFindingsFilter(ctx context.Context, params *UpdateFinding type UpdateFindingsFilterInput struct { - // The unique identifier for the Amazon Macie resource or account that the request - // applies to. + // The unique identifier for the Amazon Macie resource that the request applies to. // // This member is required. Id *string diff --git a/service/macie2/api_op_UpdateMacieSession.go b/service/macie2/api_op_UpdateMacieSession.go index 2bf5de24827..748aebb0425 100644 --- a/service/macie2/api_op_UpdateMacieSession.go +++ b/service/macie2/api_op_UpdateMacieSession.go @@ -32,7 +32,7 @@ type UpdateMacieSessionInput struct { // Specifies how often to publish updates to policy findings for the account. This // includes publishing updates to Security Hub and Amazon EventBridge (formerly - // called Amazon CloudWatch Events). + // Amazon CloudWatch Events). FindingPublishingFrequency types.FindingPublishingFrequency // Specifies a new status for the account. Valid values are: ENABLED, resume all diff --git a/service/macie2/api_op_UpdateMemberSession.go b/service/macie2/api_op_UpdateMemberSession.go index 0c2e144a263..f45a36250ec 100644 --- a/service/macie2/api_op_UpdateMemberSession.go +++ b/service/macie2/api_op_UpdateMemberSession.go @@ -30,8 +30,7 @@ func (c *Client) UpdateMemberSession(ctx context.Context, params *UpdateMemberSe type UpdateMemberSessionInput struct { - // The unique identifier for the Amazon Macie resource or account that the request - // applies to. + // The unique identifier for the Amazon Macie resource that the request applies to. // // This member is required. Id *string diff --git a/service/macie2/api_op_UpdateRevealConfiguration.go b/service/macie2/api_op_UpdateRevealConfiguration.go index 9afb08a0e45..072361e8f18 100644 --- a/service/macie2/api_op_UpdateRevealConfiguration.go +++ b/service/macie2/api_op_UpdateRevealConfiguration.go @@ -11,8 +11,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Updates the status and configuration settings for retrieving (revealing) -// occurrences of sensitive data reported by findings. +// Updates the status and configuration settings for retrieving occurrences of +// sensitive data reported by findings. func (c *Client) UpdateRevealConfiguration(ctx context.Context, params *UpdateRevealConfigurationInput, optFns ...func(*Options)) (*UpdateRevealConfigurationOutput, error) { if params == nil { params = &UpdateRevealConfigurationInput{} diff --git a/service/macie2/deserializers.go b/service/macie2/deserializers.go index 5984148ee10..17d809f184a 100644 --- a/service/macie2/deserializers.go +++ b/service/macie2/deserializers.go @@ -291,6 +291,184 @@ func awsRestjson1_deserializeOpDocumentBatchGetCustomDataIdentifiersOutput(v **B return nil } +type awsRestjson1_deserializeOpCreateAllowList struct { +} + +func (*awsRestjson1_deserializeOpCreateAllowList) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpCreateAllowList) 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_deserializeOpErrorCreateAllowList(response, &metadata) + } + output := &CreateAllowListOutput{} + 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_deserializeOpDocumentCreateAllowListOutput(&output, 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_deserializeOpErrorCreateAllowList(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("AccessDeniedException", errorCode): + return awsRestjson1_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("ConflictException", errorCode): + return awsRestjson1_deserializeErrorConflictException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ServiceQuotaExceededException", errorCode): + return awsRestjson1_deserializeErrorServiceQuotaExceededException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsRestjson1_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsRestjson1_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +func awsRestjson1_deserializeOpDocumentCreateAllowListOutput(v **CreateAllowListOutput, 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 *CreateAllowListOutput + if *v == nil { + sv = &CreateAllowListOutput{} + } 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 __stringMin71Max89PatternArnAwsAwsCnAwsUsGovMacie2AZ19920D12AllowListAZ0922 to be of type string, got %T instead", value) + } + sv.Arn = ptr.String(jtv) + } + + case "id": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin22Max22PatternAZ0922 to be of type string, got %T instead", value) + } + sv.Id = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + type awsRestjson1_deserializeOpCreateClassificationJob struct { } @@ -1416,6 +1594,101 @@ func awsRestjson1_deserializeOpDocumentDeclineInvitationsOutput(v **DeclineInvit return nil } +type awsRestjson1_deserializeOpDeleteAllowList struct { +} + +func (*awsRestjson1_deserializeOpDeleteAllowList) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpDeleteAllowList) 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_deserializeOpErrorDeleteAllowList(response, &metadata) + } + output := &DeleteAllowListOutput{} + out.Result = output + + return out, metadata, err +} + +func awsRestjson1_deserializeOpErrorDeleteAllowList(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("AccessDeniedException", errorCode): + return awsRestjson1_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsRestjson1_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsRestjson1_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + type awsRestjson1_deserializeOpDeleteCustomDataIdentifier struct { } @@ -2209,6 +2482,11 @@ func awsRestjson1_deserializeOpDocumentDescribeClassificationJobOutput(v **Descr for key, value := range shape { switch key { + case "allowListIds": + if err := awsRestjson1_deserializeDocument__listOf__string(&sv.AllowListIds, value); err != nil { + return err + } + case "clientToken": if value != nil { jtv, ok := value.(string) @@ -3266,11 +3544,176 @@ func awsRestjson1_deserializeOpErrorEnableOrganizationAdminAccount(response *smi type awsRestjson1_deserializeOpGetAdministratorAccount struct { } -func (*awsRestjson1_deserializeOpGetAdministratorAccount) ID() string { +func (*awsRestjson1_deserializeOpGetAdministratorAccount) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpGetAdministratorAccount) 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_deserializeOpErrorGetAdministratorAccount(response, &metadata) + } + output := &GetAdministratorAccountOutput{} + 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_deserializeOpDocumentGetAdministratorAccountOutput(&output, 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_deserializeOpErrorGetAdministratorAccount(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("AccessDeniedException", errorCode): + return awsRestjson1_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("ConflictException", errorCode): + return awsRestjson1_deserializeErrorConflictException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ServiceQuotaExceededException", errorCode): + return awsRestjson1_deserializeErrorServiceQuotaExceededException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsRestjson1_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsRestjson1_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +func awsRestjson1_deserializeOpDocumentGetAdministratorAccountOutput(v **GetAdministratorAccountOutput, 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 *GetAdministratorAccountOutput + if *v == nil { + sv = &GetAdministratorAccountOutput{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "administrator": + if err := awsRestjson1_deserializeDocumentInvitation(&sv.Administrator, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +type awsRestjson1_deserializeOpGetAllowList struct { +} + +func (*awsRestjson1_deserializeOpGetAllowList) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpGetAdministratorAccount) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpGetAllowList) 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) @@ -3284,9 +3727,9 @@ func (m *awsRestjson1_deserializeOpGetAdministratorAccount) HandleDeserialize(ct } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorGetAdministratorAccount(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorGetAllowList(response, &metadata) } - output := &GetAdministratorAccountOutput{} + output := &GetAllowListOutput{} out.Result = output var buff [1024]byte @@ -3307,7 +3750,7 @@ func (m *awsRestjson1_deserializeOpGetAdministratorAccount) HandleDeserialize(ct return out, metadata, err } - err = awsRestjson1_deserializeOpDocumentGetAdministratorAccountOutput(&output, shape) + err = awsRestjson1_deserializeOpDocumentGetAllowListOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -3320,7 +3763,7 @@ func (m *awsRestjson1_deserializeOpGetAdministratorAccount) HandleDeserialize(ct return out, metadata, err } -func awsRestjson1_deserializeOpErrorGetAdministratorAccount(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorGetAllowList(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)} @@ -3364,18 +3807,12 @@ func awsRestjson1_deserializeOpErrorGetAdministratorAccount(response *smithyhttp case strings.EqualFold("AccessDeniedException", errorCode): return awsRestjson1_deserializeErrorAccessDeniedException(response, errorBody) - case strings.EqualFold("ConflictException", errorCode): - return awsRestjson1_deserializeErrorConflictException(response, errorBody) - case strings.EqualFold("InternalServerException", errorCode): return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) case strings.EqualFold("ResourceNotFoundException", errorCode): return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) - case strings.EqualFold("ServiceQuotaExceededException", errorCode): - return awsRestjson1_deserializeErrorServiceQuotaExceededException(response, errorBody) - case strings.EqualFold("ThrottlingException", errorCode): return awsRestjson1_deserializeErrorThrottlingException(response, errorBody) @@ -3392,7 +3829,7 @@ func awsRestjson1_deserializeOpErrorGetAdministratorAccount(response *smithyhttp } } -func awsRestjson1_deserializeOpDocumentGetAdministratorAccountOutput(v **GetAdministratorAccountOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentGetAllowListOutput(v **GetAllowListOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -3405,20 +3842,92 @@ func awsRestjson1_deserializeOpDocumentGetAdministratorAccountOutput(v **GetAdmi return fmt.Errorf("unexpected JSON type %v", value) } - var sv *GetAdministratorAccountOutput + var sv *GetAllowListOutput if *v == nil { - sv = &GetAdministratorAccountOutput{} + sv = &GetAllowListOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "administrator": - if err := awsRestjson1_deserializeDocumentInvitation(&sv.Administrator, value); err != nil { + case "arn": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin71Max89PatternArnAwsAwsCnAwsUsGovMacie2AZ19920D12AllowListAZ0922 to be of type string, got %T instead", value) + } + sv.Arn = ptr.String(jtv) + } + + case "createdAt": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __timestampIso8601 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 "criteria": + if err := awsRestjson1_deserializeDocumentAllowListCriteria(&sv.Criteria, value); err != nil { + return err + } + + case "description": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin1Max512PatternSS to be of type string, got %T instead", value) + } + sv.Description = ptr.String(jtv) + } + + case "id": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin22Max22PatternAZ0922 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 __stringMin1Max128Pattern to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) + } + + case "status": + if err := awsRestjson1_deserializeDocumentAllowListStatus(&sv.Status, value); err != nil { + return err + } + + case "tags": + if err := awsRestjson1_deserializeDocumentTagMap(&sv.Tags, value); err != nil { return err } + case "updatedAt": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __timestampIso8601 to be of type string, got %T instead", value) + } + t, err := smithytime.ParseDateTime(jtv) + if err != nil { + return err + } + sv.UpdatedAt = ptr.Time(t) + } + default: _, _ = key, value @@ -6109,7 +6618,181 @@ func awsRestjson1_deserializeOpErrorGetSensitiveDataOccurrencesAvailability(resp } } -func awsRestjson1_deserializeOpDocumentGetSensitiveDataOccurrencesAvailabilityOutput(v **GetSensitiveDataOccurrencesAvailabilityOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentGetSensitiveDataOccurrencesAvailabilityOutput(v **GetSensitiveDataOccurrencesAvailabilityOutput, 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 *GetSensitiveDataOccurrencesAvailabilityOutput + if *v == nil { + sv = &GetSensitiveDataOccurrencesAvailabilityOutput{} + } 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 AvailabilityCode to be of type string, got %T instead", value) + } + sv.Code = types.AvailabilityCode(jtv) + } + + case "reasons": + if err := awsRestjson1_deserializeDocument__listOfUnavailabilityReasonCode(&sv.Reasons, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +type awsRestjson1_deserializeOpGetUsageStatistics struct { +} + +func (*awsRestjson1_deserializeOpGetUsageStatistics) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpGetUsageStatistics) 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_deserializeOpErrorGetUsageStatistics(response, &metadata) + } + output := &GetUsageStatisticsOutput{} + 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_deserializeOpDocumentGetUsageStatisticsOutput(&output, 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_deserializeOpErrorGetUsageStatistics(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("AccessDeniedException", errorCode): + return awsRestjson1_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("ConflictException", errorCode): + return awsRestjson1_deserializeErrorConflictException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ServiceQuotaExceededException", errorCode): + return awsRestjson1_deserializeErrorServiceQuotaExceededException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsRestjson1_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsRestjson1_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +func awsRestjson1_deserializeOpDocumentGetUsageStatisticsOutput(v **GetUsageStatisticsOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -6122,29 +6805,38 @@ func awsRestjson1_deserializeOpDocumentGetSensitiveDataOccurrencesAvailabilityOu return fmt.Errorf("unexpected JSON type %v", value) } - var sv *GetSensitiveDataOccurrencesAvailabilityOutput + var sv *GetUsageStatisticsOutput if *v == nil { - sv = &GetSensitiveDataOccurrencesAvailabilityOutput{} + sv = &GetUsageStatisticsOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "code": + case "nextToken": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected AvailabilityCode to be of type string, got %T instead", value) + return fmt.Errorf("expected __string to be of type string, got %T instead", value) } - sv.Code = types.AvailabilityCode(jtv) + sv.NextToken = ptr.String(jtv) } - case "reasons": - if err := awsRestjson1_deserializeDocument__listOfUnavailabilityReasonCode(&sv.Reasons, value); err != nil { + case "records": + if err := awsRestjson1_deserializeDocument__listOfUsageRecord(&sv.Records, value); err != nil { return err } + case "timeRange": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected TimeRange to be of type string, got %T instead", value) + } + sv.TimeRange = types.TimeRange(jtv) + } + default: _, _ = key, value @@ -6154,14 +6846,14 @@ func awsRestjson1_deserializeOpDocumentGetSensitiveDataOccurrencesAvailabilityOu return nil } -type awsRestjson1_deserializeOpGetUsageStatistics struct { +type awsRestjson1_deserializeOpGetUsageTotals struct { } -func (*awsRestjson1_deserializeOpGetUsageStatistics) ID() string { +func (*awsRestjson1_deserializeOpGetUsageTotals) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpGetUsageStatistics) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpGetUsageTotals) 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) @@ -6175,9 +6867,9 @@ func (m *awsRestjson1_deserializeOpGetUsageStatistics) HandleDeserialize(ctx con } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorGetUsageStatistics(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorGetUsageTotals(response, &metadata) } - output := &GetUsageStatisticsOutput{} + output := &GetUsageTotalsOutput{} out.Result = output var buff [1024]byte @@ -6198,7 +6890,7 @@ func (m *awsRestjson1_deserializeOpGetUsageStatistics) HandleDeserialize(ctx con return out, metadata, err } - err = awsRestjson1_deserializeOpDocumentGetUsageStatisticsOutput(&output, shape) + err = awsRestjson1_deserializeOpDocumentGetUsageTotalsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -6211,7 +6903,7 @@ func (m *awsRestjson1_deserializeOpGetUsageStatistics) HandleDeserialize(ctx con return out, metadata, err } -func awsRestjson1_deserializeOpErrorGetUsageStatistics(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorGetUsageTotals(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)} @@ -6283,7 +6975,7 @@ func awsRestjson1_deserializeOpErrorGetUsageStatistics(response *smithyhttp.Resp } } -func awsRestjson1_deserializeOpDocumentGetUsageStatisticsOutput(v **GetUsageStatisticsOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentGetUsageTotalsOutput(v **GetUsageTotalsOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -6296,29 +6988,15 @@ func awsRestjson1_deserializeOpDocumentGetUsageStatisticsOutput(v **GetUsageStat return fmt.Errorf("unexpected JSON type %v", value) } - var sv *GetUsageStatisticsOutput + var sv *GetUsageTotalsOutput if *v == nil { - sv = &GetUsageStatisticsOutput{} + sv = &GetUsageTotalsOutput{} } else { sv = *v } for key, value := range shape { switch key { - 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) - } - - case "records": - if err := awsRestjson1_deserializeDocument__listOfUsageRecord(&sv.Records, value); err != nil { - return err - } - case "timeRange": if value != nil { jtv, ok := value.(string) @@ -6328,6 +7006,11 @@ func awsRestjson1_deserializeOpDocumentGetUsageStatisticsOutput(v **GetUsageStat sv.TimeRange = types.TimeRange(jtv) } + case "usageTotals": + if err := awsRestjson1_deserializeDocument__listOfUsageTotal(&sv.UsageTotals, value); err != nil { + return err + } + default: _, _ = key, value @@ -6337,14 +7020,14 @@ func awsRestjson1_deserializeOpDocumentGetUsageStatisticsOutput(v **GetUsageStat return nil } -type awsRestjson1_deserializeOpGetUsageTotals struct { +type awsRestjson1_deserializeOpListAllowLists struct { } -func (*awsRestjson1_deserializeOpGetUsageTotals) ID() string { +func (*awsRestjson1_deserializeOpListAllowLists) ID() string { return "OperationDeserializer" } -func (m *awsRestjson1_deserializeOpGetUsageTotals) HandleDeserialize(ctx context.Context, in middleware.DeserializeInput, next middleware.DeserializeHandler) ( +func (m *awsRestjson1_deserializeOpListAllowLists) 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) @@ -6358,9 +7041,9 @@ func (m *awsRestjson1_deserializeOpGetUsageTotals) HandleDeserialize(ctx context } if response.StatusCode < 200 || response.StatusCode >= 300 { - return out, metadata, awsRestjson1_deserializeOpErrorGetUsageTotals(response, &metadata) + return out, metadata, awsRestjson1_deserializeOpErrorListAllowLists(response, &metadata) } - output := &GetUsageTotalsOutput{} + output := &ListAllowListsOutput{} out.Result = output var buff [1024]byte @@ -6381,7 +7064,7 @@ func (m *awsRestjson1_deserializeOpGetUsageTotals) HandleDeserialize(ctx context return out, metadata, err } - err = awsRestjson1_deserializeOpDocumentGetUsageTotalsOutput(&output, shape) + err = awsRestjson1_deserializeOpDocumentListAllowListsOutput(&output, shape) if err != nil { var snapshot bytes.Buffer io.Copy(&snapshot, ringBuffer) @@ -6394,7 +7077,7 @@ func (m *awsRestjson1_deserializeOpGetUsageTotals) HandleDeserialize(ctx context return out, metadata, err } -func awsRestjson1_deserializeOpErrorGetUsageTotals(response *smithyhttp.Response, metadata *middleware.Metadata) error { +func awsRestjson1_deserializeOpErrorListAllowLists(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)} @@ -6438,18 +7121,9 @@ func awsRestjson1_deserializeOpErrorGetUsageTotals(response *smithyhttp.Response case strings.EqualFold("AccessDeniedException", errorCode): return awsRestjson1_deserializeErrorAccessDeniedException(response, errorBody) - case strings.EqualFold("ConflictException", errorCode): - return awsRestjson1_deserializeErrorConflictException(response, errorBody) - case strings.EqualFold("InternalServerException", errorCode): return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) - case strings.EqualFold("ResourceNotFoundException", errorCode): - return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) - - case strings.EqualFold("ServiceQuotaExceededException", errorCode): - return awsRestjson1_deserializeErrorServiceQuotaExceededException(response, errorBody) - case strings.EqualFold("ThrottlingException", errorCode): return awsRestjson1_deserializeErrorThrottlingException(response, errorBody) @@ -6466,7 +7140,7 @@ func awsRestjson1_deserializeOpErrorGetUsageTotals(response *smithyhttp.Response } } -func awsRestjson1_deserializeOpDocumentGetUsageTotalsOutput(v **GetUsageTotalsOutput, value interface{}) error { +func awsRestjson1_deserializeOpDocumentListAllowListsOutput(v **ListAllowListsOutput, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) } @@ -6479,27 +7153,27 @@ func awsRestjson1_deserializeOpDocumentGetUsageTotalsOutput(v **GetUsageTotalsOu return fmt.Errorf("unexpected JSON type %v", value) } - var sv *GetUsageTotalsOutput + var sv *ListAllowListsOutput if *v == nil { - sv = &GetUsageTotalsOutput{} + sv = &ListAllowListsOutput{} } else { sv = *v } for key, value := range shape { switch key { - case "timeRange": + case "allowLists": + if err := awsRestjson1_deserializeDocument__listOfAllowListSummary(&sv.AllowLists, value); err != nil { + return err + } + + case "nextToken": if value != nil { jtv, ok := value.(string) if !ok { - return fmt.Errorf("expected TimeRange to be of type string, got %T instead", value) + return fmt.Errorf("expected __string to be of type string, got %T instead", value) } - sv.TimeRange = types.TimeRange(jtv) - } - - case "usageTotals": - if err := awsRestjson1_deserializeDocument__listOfUsageTotal(&sv.UsageTotals, value); err != nil { - return err + sv.NextToken = ptr.String(jtv) } default: @@ -8788,15 +9462,187 @@ func awsRestjson1_deserializeOpErrorUntagResource(response *smithyhttp.Response, errorMessage = message } - switch { - default: - genericError := &smithy.GenericAPIError{ - Code: errorCode, - Message: errorMessage, - } - return genericError + switch { + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +type awsRestjson1_deserializeOpUpdateAllowList struct { +} + +func (*awsRestjson1_deserializeOpUpdateAllowList) ID() string { + return "OperationDeserializer" +} + +func (m *awsRestjson1_deserializeOpUpdateAllowList) 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_deserializeOpErrorUpdateAllowList(response, &metadata) + } + output := &UpdateAllowListOutput{} + 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_deserializeOpDocumentUpdateAllowListOutput(&output, 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_deserializeOpErrorUpdateAllowList(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("AccessDeniedException", errorCode): + return awsRestjson1_deserializeErrorAccessDeniedException(response, errorBody) + + case strings.EqualFold("InternalServerException", errorCode): + return awsRestjson1_deserializeErrorInternalServerException(response, errorBody) + + case strings.EqualFold("ResourceNotFoundException", errorCode): + return awsRestjson1_deserializeErrorResourceNotFoundException(response, errorBody) + + case strings.EqualFold("ThrottlingException", errorCode): + return awsRestjson1_deserializeErrorThrottlingException(response, errorBody) + + case strings.EqualFold("ValidationException", errorCode): + return awsRestjson1_deserializeErrorValidationException(response, errorBody) + + default: + genericError := &smithy.GenericAPIError{ + Code: errorCode, + Message: errorMessage, + } + return genericError + + } +} + +func awsRestjson1_deserializeOpDocumentUpdateAllowListOutput(v **UpdateAllowListOutput, 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 *UpdateAllowListOutput + if *v == nil { + sv = &UpdateAllowListOutput{} + } 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 __stringMin71Max89PatternArnAwsAwsCnAwsUsGovMacie2AZ19920D12AllowListAZ0922 to be of type string, got %T instead", value) + } + sv.Arn = ptr.String(jtv) + } + + case "id": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin22Max22PatternAZ0922 to be of type string, got %T instead", value) + } + sv.Id = ptr.String(jtv) + } + + default: + _, _ = key, value + } } + *v = sv + return nil } type awsRestjson1_deserializeOpUpdateClassificationJob struct { @@ -9895,6 +10741,40 @@ func awsRestjson1_deserializeDocument__listOfAdminAccount(v *[]types.AdminAccoun return nil } +func awsRestjson1_deserializeDocument__listOfAllowListSummary(v *[]types.AllowListSummary, 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.AllowListSummary + if *v == nil { + cv = []types.AllowListSummary{} + } else { + cv = *v + } + + for _, value := range shape { + var col types.AllowListSummary + destAddr := &col + if err := awsRestjson1_deserializeDocumentAllowListSummary(&destAddr, value); err != nil { + return err + } + col = *destAddr + cv = append(cv, col) + + } + *v = cv + return nil +} + func awsRestjson1_deserializeDocument__listOfBatchGetCustomDataIdentifierSummary(v *[]types.BatchGetCustomDataIdentifierSummary, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -10853,6 +11733,193 @@ func awsRestjson1_deserializeDocumentAdminAccount(v **types.AdminAccount, value return nil } +func awsRestjson1_deserializeDocumentAllowListCriteria(v **types.AllowListCriteria, 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.AllowListCriteria + if *v == nil { + sv = &types.AllowListCriteria{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "regex": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin1Max512PatternSS to be of type string, got %T instead", value) + } + sv.Regex = ptr.String(jtv) + } + + case "s3WordsList": + if err := awsRestjson1_deserializeDocumentS3WordsList(&sv.S3WordsList, value); err != nil { + return err + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentAllowListStatus(v **types.AllowListStatus, 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.AllowListStatus + if *v == nil { + sv = &types.AllowListStatus{} + } 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 AllowListStatusCode to be of type string, got %T instead", value) + } + sv.Code = types.AllowListStatusCode(jtv) + } + + case "description": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin1Max1024PatternSS to be of type string, got %T instead", value) + } + sv.Description = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + +func awsRestjson1_deserializeDocumentAllowListSummary(v **types.AllowListSummary, 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.AllowListSummary + if *v == nil { + sv = &types.AllowListSummary{} + } 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 __stringMin71Max89PatternArnAwsAwsCnAwsUsGovMacie2AZ19920D12AllowListAZ0922 to be of type string, got %T instead", value) + } + sv.Arn = ptr.String(jtv) + } + + case "createdAt": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __timestampIso8601 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 "description": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin1Max512PatternSS to be of type string, got %T instead", value) + } + sv.Description = ptr.String(jtv) + } + + case "id": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin22Max22PatternAZ0922 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 __stringMin1Max128Pattern to be of type string, got %T instead", value) + } + sv.Name = ptr.String(jtv) + } + + case "updatedAt": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __timestampIso8601 to be of type string, got %T instead", value) + } + t, err := smithytime.ParseDateTime(jtv) + if err != nil { + return err + } + sv.UpdatedAt = ptr.Time(t) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentApiCallDetails(v **types.ApiCallDetails, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) @@ -16078,6 +17145,55 @@ func awsRestjson1_deserializeDocumentS3Object(v **types.S3Object, value interfac return nil } +func awsRestjson1_deserializeDocumentS3WordsList(v **types.S3WordsList, 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.S3WordsList + if *v == nil { + sv = &types.S3WordsList{} + } else { + sv = *v + } + + for key, value := range shape { + switch key { + case "bucketName": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin3Max255PatternAZaZ093255 to be of type string, got %T instead", value) + } + sv.BucketName = ptr.String(jtv) + } + + case "objectKey": + if value != nil { + jtv, ok := value.(string) + if !ok { + return fmt.Errorf("expected __stringMin1Max1024PatternSS to be of type string, got %T instead", value) + } + sv.ObjectKey = ptr.String(jtv) + } + + default: + _, _ = key, value + + } + } + *v = sv + return nil +} + func awsRestjson1_deserializeDocumentScoping(v **types.Scoping, value interface{}) error { if v == nil { return fmt.Errorf("unexpected nil of type %T", v) diff --git a/service/macie2/generated.json b/service/macie2/generated.json index 965d9a2263a..f58472d259b 100644 --- a/service/macie2/generated.json +++ b/service/macie2/generated.json @@ -11,6 +11,7 @@ "api_client_test.go", "api_op_AcceptInvitation.go", "api_op_BatchGetCustomDataIdentifiers.go", + "api_op_CreateAllowList.go", "api_op_CreateClassificationJob.go", "api_op_CreateCustomDataIdentifier.go", "api_op_CreateFindingsFilter.go", @@ -18,6 +19,7 @@ "api_op_CreateMember.go", "api_op_CreateSampleFindings.go", "api_op_DeclineInvitations.go", + "api_op_DeleteAllowList.go", "api_op_DeleteCustomDataIdentifier.go", "api_op_DeleteFindingsFilter.go", "api_op_DeleteInvitations.go", @@ -33,6 +35,7 @@ "api_op_EnableMacie.go", "api_op_EnableOrganizationAdminAccount.go", "api_op_GetAdministratorAccount.go", + "api_op_GetAllowList.go", "api_op_GetBucketStatistics.go", "api_op_GetClassificationExportConfiguration.go", "api_op_GetCustomDataIdentifier.go", @@ -49,6 +52,7 @@ "api_op_GetSensitiveDataOccurrencesAvailability.go", "api_op_GetUsageStatistics.go", "api_op_GetUsageTotals.go", + "api_op_ListAllowLists.go", "api_op_ListClassificationJobs.go", "api_op_ListCustomDataIdentifiers.go", "api_op_ListFindings.go", @@ -64,6 +68,7 @@ "api_op_TagResource.go", "api_op_TestCustomDataIdentifier.go", "api_op_UntagResource.go", + "api_op_UpdateAllowList.go", "api_op_UpdateClassificationJob.go", "api_op_UpdateFindingsFilter.go", "api_op_UpdateMacieSession.go", diff --git a/service/macie2/serializers.go b/service/macie2/serializers.go index e38fa937f4f..61f8b3d71de 100644 --- a/service/macie2/serializers.go +++ b/service/macie2/serializers.go @@ -162,6 +162,98 @@ func awsRestjson1_serializeOpDocumentBatchGetCustomDataIdentifiersInput(v *Batch return nil } +type awsRestjson1_serializeOpCreateAllowList struct { +} + +func (*awsRestjson1_serializeOpCreateAllowList) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpCreateAllowList) 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.(*CreateAllowListInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/allow-lists") + 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} + } + + restEncoder.SetHeader("Content-Type").String("application/json") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsRestjson1_serializeOpDocumentCreateAllowListInput(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 = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsCreateAllowListInput(v *CreateAllowListInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + return nil +} + +func awsRestjson1_serializeOpDocumentCreateAllowListInput(v *CreateAllowListInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.ClientToken != nil { + ok := object.Key("clientToken") + ok.String(*v.ClientToken) + } + + if v.Criteria != nil { + ok := object.Key("criteria") + if err := awsRestjson1_serializeDocumentAllowListCriteria(v.Criteria, ok); err != nil { + return err + } + } + + if v.Description != nil { + ok := object.Key("description") + ok.String(*v.Description) + } + + if v.Name != nil { + ok := object.Key("name") + ok.String(*v.Name) + } + + if v.Tags != nil { + ok := object.Key("tags") + if err := awsRestjson1_serializeDocumentTagMap(v.Tags, ok); err != nil { + return err + } + } + + return nil +} + type awsRestjson1_serializeOpCreateClassificationJob struct { } @@ -222,6 +314,13 @@ func awsRestjson1_serializeOpDocumentCreateClassificationJobInput(v *CreateClass object := value.Object() defer object.Close() + if v.AllowListIds != nil { + ok := object.Key("allowListIds") + if err := awsRestjson1_serializeDocument__listOf__string(v.AllowListIds, ok); err != nil { + return err + } + } + if v.ClientToken != nil { ok := object.Key("clientToken") ok.String(*v.ClientToken) @@ -810,6 +909,68 @@ func awsRestjson1_serializeOpDocumentDeclineInvitationsInput(v *DeclineInvitatio return nil } +type awsRestjson1_serializeOpDeleteAllowList struct { +} + +func (*awsRestjson1_serializeOpDeleteAllowList) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpDeleteAllowList) 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.(*DeleteAllowListInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/allow-lists/{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_serializeOpHttpBindingsDeleteAllowListInput(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_serializeOpHttpBindingsDeleteAllowListInput(v *DeleteAllowListInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + 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.IgnoreJobChecks != nil { + encoder.SetQuery("ignoreJobChecks").String(*v.IgnoreJobChecks) + } + + return nil +} + type awsRestjson1_serializeOpDeleteCustomDataIdentifier struct { } @@ -1686,6 +1847,64 @@ func awsRestjson1_serializeOpHttpBindingsGetAdministratorAccountInput(v *GetAdmi return nil } +type awsRestjson1_serializeOpGetAllowList struct { +} + +func (*awsRestjson1_serializeOpGetAllowList) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpGetAllowList) 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.(*GetAllowListInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/allow-lists/{id}") + 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_serializeOpHttpBindingsGetAllowListInput(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_serializeOpHttpBindingsGetAllowListInput(v *GetAllowListInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + 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_serializeOpGetBucketStatistics struct { } @@ -2623,6 +2842,63 @@ func awsRestjson1_serializeOpHttpBindingsGetUsageTotalsInput(v *GetUsageTotalsIn return nil } +type awsRestjson1_serializeOpListAllowLists struct { +} + +func (*awsRestjson1_serializeOpListAllowLists) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpListAllowLists) 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.(*ListAllowListsInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/allow-lists") + 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_serializeOpHttpBindingsListAllowListsInput(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_serializeOpHttpBindingsListAllowListsInput(v *ListAllowListsInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + if v.MaxResults != 0 { + encoder.SetQuery("maxResults").Integer(v.MaxResults) + } + + if v.NextToken != nil { + encoder.SetQuery("nextToken").String(*v.NextToken) + } + + return nil +} + type awsRestjson1_serializeOpListClassificationJobs struct { } @@ -3699,6 +3975,99 @@ func awsRestjson1_serializeOpHttpBindingsUntagResourceInput(v *UntagResourceInpu return nil } +type awsRestjson1_serializeOpUpdateAllowList struct { +} + +func (*awsRestjson1_serializeOpUpdateAllowList) ID() string { + return "OperationSerializer" +} + +func (m *awsRestjson1_serializeOpUpdateAllowList) 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.(*UpdateAllowListInput) + _ = input + if !ok { + return out, metadata, &smithy.SerializationError{Err: fmt.Errorf("unknown input parameters type %T", in.Parameters)} + } + + opPath, opQuery := httpbinding.SplitURI("/allow-lists/{id}") + request.URL.Path = smithyhttp.JoinPath(request.URL.Path, opPath) + request.URL.RawQuery = smithyhttp.JoinRawQuery(request.URL.RawQuery, opQuery) + 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_serializeOpHttpBindingsUpdateAllowListInput(input, restEncoder); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + + restEncoder.SetHeader("Content-Type").String("application/json") + + jsonEncoder := smithyjson.NewEncoder() + if err := awsRestjson1_serializeOpDocumentUpdateAllowListInput(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 = restEncoder.Encode(request.Request); err != nil { + return out, metadata, &smithy.SerializationError{Err: err} + } + in.Request = request + + return next.HandleSerialize(ctx, in) +} +func awsRestjson1_serializeOpHttpBindingsUpdateAllowListInput(v *UpdateAllowListInput, encoder *httpbinding.Encoder) error { + if v == nil { + return fmt.Errorf("unsupported serialization of nil %T", v) + } + + 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_serializeOpDocumentUpdateAllowListInput(v *UpdateAllowListInput, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Criteria != nil { + ok := object.Key("criteria") + if err := awsRestjson1_serializeDocumentAllowListCriteria(v.Criteria, ok); err != nil { + return err + } + } + + if v.Description != nil { + ok := object.Key("description") + ok.String(*v.Description) + } + + if v.Name != nil { + ok := object.Key("name") + ok.String(*v.Name) + } + + return nil +} + type awsRestjson1_serializeOpUpdateClassificationJob struct { } @@ -4336,6 +4705,25 @@ func awsRestjson1_serializeDocumentAccountDetail(v *types.AccountDetail, value s return nil } +func awsRestjson1_serializeDocumentAllowListCriteria(v *types.AllowListCriteria, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.Regex != nil { + ok := object.Key("regex") + ok.String(*v.Regex) + } + + if v.S3WordsList != nil { + ok := object.Key("s3WordsList") + if err := awsRestjson1_serializeDocumentS3WordsList(v.S3WordsList, ok); err != nil { + return err + } + } + + return nil +} + func awsRestjson1_serializeDocumentBucketCriteria(v map[string]types.BucketCriteriaAdditionalProperties, value smithyjson.Value) error { object := value.Object() defer object.Close() @@ -4806,6 +5194,23 @@ func awsRestjson1_serializeDocumentS3JobDefinition(v *types.S3JobDefinition, val return nil } +func awsRestjson1_serializeDocumentS3WordsList(v *types.S3WordsList, value smithyjson.Value) error { + object := value.Object() + defer object.Close() + + if v.BucketName != nil { + ok := object.Key("bucketName") + ok.String(*v.BucketName) + } + + if v.ObjectKey != nil { + ok := object.Key("objectKey") + ok.String(*v.ObjectKey) + } + + return nil +} + func awsRestjson1_serializeDocumentScoping(v *types.Scoping, value smithyjson.Value) error { object := value.Object() defer object.Close() diff --git a/service/macie2/types/enums.go b/service/macie2/types/enums.go index 9f56b5f7c83..c7a17636693 100644 --- a/service/macie2/types/enums.go +++ b/service/macie2/types/enums.go @@ -20,6 +20,36 @@ func (AdminStatus) Values() []AdminStatus { } } +type AllowListStatusCode string + +// Enum values for AllowListStatusCode +const ( + AllowListStatusCodeOk AllowListStatusCode = "OK" + AllowListStatusCodeS3ObjectNotFound AllowListStatusCode = "S3_OBJECT_NOT_FOUND" + AllowListStatusCodeS3UserAccessDenied AllowListStatusCode = "S3_USER_ACCESS_DENIED" + AllowListStatusCodeS3ObjectAccessDenied AllowListStatusCode = "S3_OBJECT_ACCESS_DENIED" + AllowListStatusCodeS3Throttled AllowListStatusCode = "S3_THROTTLED" + AllowListStatusCodeS3ObjectOversize AllowListStatusCode = "S3_OBJECT_OVERSIZE" + AllowListStatusCodeS3ObjectEmpty AllowListStatusCode = "S3_OBJECT_EMPTY" + AllowListStatusCodeUnknownError AllowListStatusCode = "UNKNOWN_ERROR" +) + +// Values returns all known values for AllowListStatusCode. 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 (AllowListStatusCode) Values() []AllowListStatusCode { + return []AllowListStatusCode{ + "OK", + "S3_OBJECT_NOT_FOUND", + "S3_USER_ACCESS_DENIED", + "S3_OBJECT_ACCESS_DENIED", + "S3_THROTTLED", + "S3_OBJECT_OVERSIZE", + "S3_OBJECT_EMPTY", + "UNKNOWN_ERROR", + } +} + type AllowsUnencryptedObjectUploads string // Enum values for AllowsUnencryptedObjectUploads diff --git a/service/macie2/types/types.go b/service/macie2/types/types.go index d7cc7041c73..d3895ced900 100644 --- a/service/macie2/types/types.go +++ b/service/macie2/types/types.go @@ -64,6 +64,107 @@ type AdminAccount struct { noSmithyDocumentSerde } +// Specifies the criteria for an allow list. The criteria must specify a regular +// expression (regex) or an S3 object (s3WordsList). It can't specify both. +type AllowListCriteria struct { + + // The regular expression (regex) that defines the text pattern to ignore. The + // expression can contain as many as 512 characters. + Regex *string + + // The location and name of the S3 object that lists specific text to ignore. + S3WordsList *S3WordsList + + noSmithyDocumentSerde +} + +// Provides information about the current status of an allow list, which indicates +// whether Amazon Macie can access and use the list's criteria. +type AllowListStatus struct { + + // The current status of the allow list. If the list's criteria specify a regular + // expression (regex), this value is typically OK. Amazon Macie can compile the + // expression. If the list's criteria specify an S3 object, possible values are: + // + // * + // OK - Macie can retrieve and parse the contents of the object. + // + // * + // S3_OBJECT_ACCESS_DENIED - Macie isn't allowed to access the object or the object + // is encrypted with a customer managed KMS key that Macie isn't allowed to use. + // Check the bucket policy and other permissions settings for the bucket and the + // object. If the object is encrypted, also ensure that it's encrypted with a key + // that Macie is allowed to use. + // + // * S3_OBJECT_EMPTY - Macie can retrieve the object + // but the object doesn't contain any content. Ensure that the object contains the + // correct entries. Also ensure that the list's criteria specify the correct bucket + // and object names. + // + // * S3_OBJECT_NOT_FOUND - The object doesn't exist in Amazon + // S3. Ensure that the list's criteria specify the correct bucket and object + // names. + // + // * S3_OBJECT_OVERSIZE - Macie can retrieve the object. However, the + // object contains too many entries or its storage size exceeds the quota for an + // allow list. Try breaking the list into multiple files and ensure that each file + // doesn't exceed any quotas. Then configure list settings in Macie for each + // file. + // + // * S3_THROTTLED - Amazon S3 throttled the request to retrieve the object. + // Wait a few minutes and then try again. + // + // * S3_USER_ACCESS_DENIED - Amazon S3 + // denied the request to retrieve the object. If the specified object exists, + // you're not allowed to access it or it's encrypted with an KMS key that you're + // not allowed to use. Work with your Amazon Web Services administrator to ensure + // that the list's criteria specify the correct bucket and object names, and you + // have read access to the bucket and the object. If the object is encrypted, also + // ensure that it's encrypted with a key that you're allowed to use. + // + // * + // UNKNOWN_ERROR - A transient or internal error occurred when Macie attempted to + // retrieve or parse the object. Wait a few minutes and then try again. A list can + // also have this status if it's encrypted with a key that Amazon S3 and Macie + // can't access or use. + // + // This member is required. + Code AllowListStatusCode + + // A brief description of the status of the allow list. Amazon Macie uses this + // value to provide additional information about an error that occurred when Macie + // tried to access and use the list's criteria. + Description *string + + noSmithyDocumentSerde +} + +// Provides a subset of information about an allow list. +type AllowListSummary struct { + + // The Amazon Resource Name (ARN) of the allow list. + Arn *string + + // The date and time, in UTC and extended ISO 8601 format, when the allow list was + // created in Amazon Macie. + CreatedAt *time.Time + + // The custom description of the allow list. + Description *string + + // The unique identifier for the allow list. + Id *string + + // The custom name of the allow list. + Name *string + + // The date and time, in UTC and extended ISO 8601 format, when the allow list's + // settings were most recently changed in Amazon Macie. + UpdatedAt *time.Time + + noSmithyDocumentSerde +} + // Provides information about an API operation that an entity invoked for an // affected resource. type ApiCallDetails struct { @@ -1146,7 +1247,7 @@ type FindingsFilterListItem struct { // The custom name of the filter. Name *string - // A map of key-value pairs that identifies the tags (keys and values) that are + // A map of key-value pairs that specifies which tags (keys and values) are // associated with the filter. Tags map[string]string @@ -1704,7 +1805,7 @@ type Member struct { // account. RelationshipStatus RelationshipStatus - // A map of key-value pairs that identifies the tags (keys and values) that are + // A map of key-value pairs that specifies which tags (keys and values) are // associated with the account in Amazon Macie. Tags map[string]string @@ -1787,14 +1888,12 @@ type ObjectLevelStatistics struct { // Specifies the location of 1-15 occurrences of sensitive data that was detected // by a managed data identifier or a custom data identifier and produced a -// sensitive data finding. Depending on the file or storage format of the affected -// S3 object, you can optionally retrieve (reveal) sample occurrences of the -// sensitive data that was detected. +// sensitive data finding. type Occurrences struct { // An array of objects, one for each occurrence of sensitive data in a Microsoft // Excel workbook, CSV file, or TSV file. This value is null for all other types of - // files.Each Cell object specifies a cell or field that contains the sensitive + // files. Each Cell object specifies a cell or field that contains the sensitive // data. Cells []Cell @@ -1813,8 +1912,8 @@ type Occurrences struct { OffsetRanges []Range // An array of objects, one for each occurrence of sensitive data in an Adobe - // Portable Document Format file. This value is null for all other types of - // files.Each Page object specifies a page that contains the sensitive data. + // Portable Document Format file. This value is null for all other types of files. + // Each Page object specifies a page that contains the sensitive data. Pages []Page // An array of objects, one for each occurrence of sensitive data in an Apache Avro @@ -1939,9 +2038,9 @@ type ResourcesAffected struct { // Specifies the configuration settings for retrieving occurrences of sensitive // data reported by findings, and the status of the configuration for an Amazon // Macie account. When you enable the configuration for the first time, your -// request must specify an AWS Key Management Service (AWS KMS) key. Otherwise, an -// error occurs. Macie uses the specified key to encrypt the sensitive data that -// you retrieve. +// request must specify an Key Management Service (KMS) key. Otherwise, an error +// occurs. Macie uses the specified key to encrypt the sensitive data that you +// retrieve. type RevealConfiguration struct { // The status of the configuration for the Amazon Macie account. In a request, @@ -2161,6 +2260,22 @@ type S3Object struct { noSmithyDocumentSerde } +// Provides information about an S3 object that lists specific text to ignore. +type S3WordsList struct { + + // The full name of the S3 bucket that contains the object. + // + // This member is required. + BucketName *string + + // The full name (key) of the object. + // + // This member is required. + ObjectKey *string + + noSmithyDocumentSerde +} + // Specifies one or more property- and tag-based conditions that define criteria // for including or excluding S3 objects from a classification job. Exclude // conditions take precedence over include conditions. diff --git a/service/macie2/validators.go b/service/macie2/validators.go index 7877ace6231..93ede353d0a 100644 --- a/service/macie2/validators.go +++ b/service/macie2/validators.go @@ -30,6 +30,26 @@ func (m *validateOpAcceptInvitation) HandleInitialize(ctx context.Context, in mi return next.HandleInitialize(ctx, in) } +type validateOpCreateAllowList struct { +} + +func (*validateOpCreateAllowList) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpCreateAllowList) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*CreateAllowListInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpCreateAllowListInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpCreateClassificationJob struct { } @@ -150,6 +170,26 @@ func (m *validateOpDeclineInvitations) HandleInitialize(ctx context.Context, in return next.HandleInitialize(ctx, in) } +type validateOpDeleteAllowList struct { +} + +func (*validateOpDeleteAllowList) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpDeleteAllowList) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*DeleteAllowListInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpDeleteAllowListInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpDeleteCustomDataIdentifier struct { } @@ -310,6 +350,26 @@ func (m *validateOpEnableOrganizationAdminAccount) HandleInitialize(ctx context. return next.HandleInitialize(ctx, in) } +type validateOpGetAllowList struct { +} + +func (*validateOpGetAllowList) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpGetAllowList) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*GetAllowListInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpGetAllowListInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpGetCustomDataIdentifier struct { } @@ -570,6 +630,26 @@ func (m *validateOpUntagResource) HandleInitialize(ctx context.Context, in middl return next.HandleInitialize(ctx, in) } +type validateOpUpdateAllowList struct { +} + +func (*validateOpUpdateAllowList) ID() string { + return "OperationInputValidation" +} + +func (m *validateOpUpdateAllowList) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + input, ok := in.Parameters.(*UpdateAllowListInput) + if !ok { + return out, metadata, fmt.Errorf("unknown input parameters type %T", in.Parameters) + } + if err := validateOpUpdateAllowListInput(input); err != nil { + return out, metadata, err + } + return next.HandleInitialize(ctx, in) +} + type validateOpUpdateClassificationJob struct { } @@ -674,6 +754,10 @@ func addOpAcceptInvitationValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpAcceptInvitation{}, middleware.After) } +func addOpCreateAllowListValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpCreateAllowList{}, middleware.After) +} + func addOpCreateClassificationJobValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpCreateClassificationJob{}, middleware.After) } @@ -698,6 +782,10 @@ func addOpDeclineInvitationsValidationMiddleware(stack *middleware.Stack) error return stack.Initialize.Add(&validateOpDeclineInvitations{}, middleware.After) } +func addOpDeleteAllowListValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpDeleteAllowList{}, middleware.After) +} + func addOpDeleteCustomDataIdentifierValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpDeleteCustomDataIdentifier{}, middleware.After) } @@ -730,6 +818,10 @@ func addOpEnableOrganizationAdminAccountValidationMiddleware(stack *middleware.S return stack.Initialize.Add(&validateOpEnableOrganizationAdminAccount{}, middleware.After) } +func addOpGetAllowListValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpGetAllowList{}, middleware.After) +} + func addOpGetCustomDataIdentifierValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpGetCustomDataIdentifier{}, middleware.After) } @@ -782,6 +874,10 @@ func addOpUntagResourceValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpUntagResource{}, middleware.After) } +func addOpUpdateAllowListValidationMiddleware(stack *middleware.Stack) error { + return stack.Initialize.Add(&validateOpUpdateAllowList{}, middleware.After) +} + func addOpUpdateClassificationJobValidationMiddleware(stack *middleware.Stack) error { return stack.Initialize.Add(&validateOpUpdateClassificationJob{}, middleware.After) } @@ -837,6 +933,23 @@ func validateAccountDetail(v *types.AccountDetail) error { } } +func validateAllowListCriteria(v *types.AllowListCriteria) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "AllowListCriteria"} + if v.S3WordsList != nil { + if err := validateS3WordsList(v.S3WordsList); err != nil { + invalidParams.AddNested("S3WordsList", err.(smithy.InvalidParamsError)) + } + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateClassificationExportConfiguration(v *types.ClassificationExportConfiguration) error { if v == nil { return nil @@ -922,6 +1035,24 @@ func validateS3JobDefinition(v *types.S3JobDefinition) error { } } +func validateS3WordsList(v *types.S3WordsList) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "S3WordsList"} + if v.BucketName == nil { + invalidParams.Add(smithy.NewErrParamRequired("BucketName")) + } + if v.ObjectKey == nil { + invalidParams.Add(smithy.NewErrParamRequired("ObjectKey")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateSecurityHubConfiguration(v *types.SecurityHubConfiguration) error { if v == nil { return nil @@ -981,6 +1112,31 @@ func validateOpAcceptInvitationInput(v *AcceptInvitationInput) error { } } +func validateOpCreateAllowListInput(v *CreateAllowListInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "CreateAllowListInput"} + if v.ClientToken == nil { + invalidParams.Add(smithy.NewErrParamRequired("ClientToken")) + } + if v.Criteria == nil { + invalidParams.Add(smithy.NewErrParamRequired("Criteria")) + } else if v.Criteria != nil { + if err := validateAllowListCriteria(v.Criteria); err != nil { + invalidParams.AddNested("Criteria", err.(smithy.InvalidParamsError)) + } + } + if v.Name == nil { + invalidParams.Add(smithy.NewErrParamRequired("Name")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpCreateClassificationJobInput(v *CreateClassificationJobInput) error { if v == nil { return nil @@ -1102,6 +1258,21 @@ func validateOpDeclineInvitationsInput(v *DeclineInvitationsInput) error { } } +func validateOpDeleteAllowListInput(v *DeleteAllowListInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "DeleteAllowListInput"} + if v.Id == nil { + invalidParams.Add(smithy.NewErrParamRequired("Id")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpDeleteCustomDataIdentifierInput(v *DeleteCustomDataIdentifierInput) error { if v == nil { return nil @@ -1222,6 +1393,21 @@ func validateOpEnableOrganizationAdminAccountInput(v *EnableOrganizationAdminAcc } } +func validateOpGetAllowListInput(v *GetAllowListInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "GetAllowListInput"} + if v.Id == nil { + invalidParams.Add(smithy.NewErrParamRequired("Id")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpGetCustomDataIdentifierInput(v *GetCustomDataIdentifierInput) error { if v == nil { return nil @@ -1432,6 +1618,31 @@ func validateOpUntagResourceInput(v *UntagResourceInput) error { } } +func validateOpUpdateAllowListInput(v *UpdateAllowListInput) error { + if v == nil { + return nil + } + invalidParams := smithy.InvalidParamsError{Context: "UpdateAllowListInput"} + if v.Criteria == nil { + invalidParams.Add(smithy.NewErrParamRequired("Criteria")) + } else if v.Criteria != nil { + if err := validateAllowListCriteria(v.Criteria); err != nil { + invalidParams.AddNested("Criteria", err.(smithy.InvalidParamsError)) + } + } + if v.Id == nil { + invalidParams.Add(smithy.NewErrParamRequired("Id")) + } + if v.Name == nil { + invalidParams.Add(smithy.NewErrParamRequired("Name")) + } + if invalidParams.Len() > 0 { + return invalidParams + } else { + return nil + } +} + func validateOpUpdateClassificationJobInput(v *UpdateClassificationJobInput) error { if v == nil { return nil diff --git a/service/marketplacemetering/internal/endpoints/endpoints.go b/service/marketplacemetering/internal/endpoints/endpoints.go index ba8b88f99e5..165106d941d 100644 --- a/service/marketplacemetering/internal/endpoints/endpoints.go +++ b/service/marketplacemetering/internal/endpoints/endpoints.go @@ -195,6 +195,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/neptune/internal/endpoints/endpoints.go b/service/neptune/internal/endpoints/endpoints.go index 4c513065dcd..7f42a2313ea 100644 --- a/service/neptune/internal/endpoints/endpoints.go +++ b/service/neptune/internal/endpoints/endpoints.go @@ -198,6 +198,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/opensearch/internal/endpoints/endpoints.go b/service/opensearch/internal/endpoints/endpoints.go index 0a9206e57c3..bd2a81682b7 100644 --- a/service/opensearch/internal/endpoints/endpoints.go +++ b/service/opensearch/internal/endpoints/endpoints.go @@ -192,6 +192,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/pi/internal/endpoints/endpoints.go b/service/pi/internal/endpoints/endpoints.go index 82aef74af08..1e2f11be728 100644 --- a/service/pi/internal/endpoints/endpoints.go +++ b/service/pi/internal/endpoints/endpoints.go @@ -183,6 +183,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/rbin/internal/endpoints/endpoints.go b/service/rbin/internal/endpoints/endpoints.go index 139aff5b734..fb3329a34a9 100644 --- a/service/rbin/internal/endpoints/endpoints.go +++ b/service/rbin/internal/endpoints/endpoints.go @@ -162,6 +162,12 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "ca-central-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "ca-central-1", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "rbin-fips.ca-central-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "eu-central-1", }: endpoints.Endpoint{}, @@ -180,6 +186,54 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "fips-ca-central-1", + }: endpoints.Endpoint{ + Hostname: "rbin-fips.ca-central-1.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "ca-central-1", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-east-1", + }: endpoints.Endpoint{ + Hostname: "rbin-fips.us-east-1.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-east-1", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-east-2", + }: endpoints.Endpoint{ + Hostname: "rbin-fips.us-east-2.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-east-2", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-west-1", + }: endpoints.Endpoint{ + Hostname: "rbin-fips.us-west-1.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-west-1", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "fips-us-west-2", + }: endpoints.Endpoint{ + Hostname: "rbin-fips.us-west-2.amazonaws.com", + CredentialScope: endpoints.CredentialScope{ + Region: "us-west-2", + }, + Deprecated: aws.TrueTernary, + }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, @@ -189,15 +243,39 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "us-east-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-east-1", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "rbin-fips.us-east-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "us-east-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-east-2", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "rbin-fips.us-east-2.amazonaws.com", + }, endpoints.EndpointKey{ Region: "us-west-1", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-west-1", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "rbin-fips.us-west-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "us-west-2", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "us-west-2", + Variant: endpoints.FIPSVariant, + }: { + Hostname: "rbin-fips.us-west-2.amazonaws.com", + }, }, }, { diff --git a/service/rds/internal/endpoints/endpoints.go b/service/rds/internal/endpoints/endpoints.go index fcd3167d5fd..7430ad6d8ef 100644 --- a/service/rds/internal/endpoints/endpoints.go +++ b/service/rds/internal/endpoints/endpoints.go @@ -198,6 +198,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/redshift/internal/endpoints/endpoints.go b/service/redshift/internal/endpoints/endpoints.go index 712958313d1..ca40d3a89cc 100644 --- a/service/redshift/internal/endpoints/endpoints.go +++ b/service/redshift/internal/endpoints/endpoints.go @@ -234,6 +234,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/resourcegroupstaggingapi/internal/endpoints/endpoints.go b/service/resourcegroupstaggingapi/internal/endpoints/endpoints.go index fb44154c51c..64cbe40b7da 100644 --- a/service/resourcegroupstaggingapi/internal/endpoints/endpoints.go +++ b/service/resourcegroupstaggingapi/internal/endpoints/endpoints.go @@ -183,6 +183,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/s3/internal/endpoints/endpoints.go b/service/s3/internal/endpoints/endpoints.go index cd09031f413..4b8457ebfad 100644 --- a/service/s3/internal/endpoints/endpoints.go +++ b/service/s3/internal/endpoints/endpoints.go @@ -363,6 +363,15 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "s3.dualstack.me-central-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/s3control/internal/endpoints/s3/endpoints.go b/service/s3control/internal/endpoints/s3/endpoints.go index 690dfbdddbf..e88d72c9565 100644 --- a/service/s3control/internal/endpoints/s3/endpoints.go +++ b/service/s3control/internal/endpoints/s3/endpoints.go @@ -361,6 +361,15 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + Variant: endpoints.DualStackVariant, + }: { + Hostname: "s3.dualstack.me-central-1.amazonaws.com", + }, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/secretsmanager/internal/endpoints/endpoints.go b/service/secretsmanager/internal/endpoints/endpoints.go index b0cd71c1a89..6f8471503fd 100644 --- a/service/secretsmanager/internal/endpoints/endpoints.go +++ b/service/secretsmanager/internal/endpoints/endpoints.go @@ -198,6 +198,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/sfn/internal/endpoints/endpoints.go b/service/sfn/internal/endpoints/endpoints.go index aeec886c098..92972225c3c 100644 --- a/service/sfn/internal/endpoints/endpoints.go +++ b/service/sfn/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/sns/internal/endpoints/endpoints.go b/service/sns/internal/endpoints/endpoints.go index 26384185b5b..cd3b4105f24 100644 --- a/service/sns/internal/endpoints/endpoints.go +++ b/service/sns/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/sqs/internal/endpoints/endpoints.go b/service/sqs/internal/endpoints/endpoints.go index 3423cd863fc..1edbb35ac5a 100644 --- a/service/sqs/internal/endpoints/endpoints.go +++ b/service/sqs/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/ssm/internal/endpoints/endpoints.go b/service/ssm/internal/endpoints/endpoints.go index 07938a609e9..abd6f430cea 100644 --- a/service/ssm/internal/endpoints/endpoints.go +++ b/service/ssm/internal/endpoints/endpoints.go @@ -234,6 +234,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/sso/api_op_GetRoleCredentials.go b/service/sso/api_op_GetRoleCredentials.go index 96ec264acbe..1c2b7499d58 100644 --- a/service/sso/api_op_GetRoleCredentials.go +++ b/service/sso/api_op_GetRoleCredentials.go @@ -32,12 +32,12 @@ type GetRoleCredentialsInput struct { // The token issued by the CreateToken API call. For more information, see // CreateToken // (https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html) - // in the Amazon Web Services SSO OIDC API Reference Guide. + // in the IAM Identity Center OIDC API Reference Guide. // // This member is required. AccessToken *string - // The identifier for the Amazon Web Services account that is assigned to the user. + // The identifier for the AWS account that is assigned to the user. // // This member is required. AccountId *string diff --git a/service/sso/api_op_ListAccountRoles.go b/service/sso/api_op_ListAccountRoles.go index 69a9109faa7..4fffc77af54 100644 --- a/service/sso/api_op_ListAccountRoles.go +++ b/service/sso/api_op_ListAccountRoles.go @@ -11,8 +11,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists all roles that are assigned to the user for a given Amazon Web Services -// account. +// Lists all roles that are assigned to the user for a given AWS account. func (c *Client) ListAccountRoles(ctx context.Context, params *ListAccountRolesInput, optFns ...func(*Options)) (*ListAccountRolesOutput, error) { if params == nil { params = &ListAccountRolesInput{} @@ -33,12 +32,12 @@ type ListAccountRolesInput struct { // The token issued by the CreateToken API call. For more information, see // CreateToken // (https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html) - // in the Amazon Web Services SSO OIDC API Reference Guide. + // in the IAM Identity Center OIDC API Reference Guide. // // This member is required. AccessToken *string - // The identifier for the Amazon Web Services account that is assigned to the user. + // The identifier for the AWS account that is assigned to the user. // // This member is required. AccountId *string diff --git a/service/sso/api_op_ListAccounts.go b/service/sso/api_op_ListAccounts.go index a504b98c526..e717a426c54 100644 --- a/service/sso/api_op_ListAccounts.go +++ b/service/sso/api_op_ListAccounts.go @@ -11,11 +11,10 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists all Amazon Web Services accounts assigned to the user. These Amazon Web -// Services accounts are assigned by the administrator of the account. For more -// information, see Assign User Access +// Lists all AWS accounts assigned to the user. These AWS accounts are assigned by +// the administrator of the account. For more information, see Assign User Access // (https://docs.aws.amazon.com/singlesignon/latest/userguide/useraccess.html#assignusers) -// in the Amazon Web Services SSO User Guide. This operation returns a paginated +// in the IAM Identity Center User Guide. This operation returns a paginated // response. func (c *Client) ListAccounts(ctx context.Context, params *ListAccountsInput, optFns ...func(*Options)) (*ListAccountsOutput, error) { if params == nil { @@ -37,7 +36,7 @@ type ListAccountsInput struct { // The token issued by the CreateToken API call. For more information, see // CreateToken // (https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html) - // in the Amazon Web Services SSO OIDC API Reference Guide. + // in the IAM Identity Center OIDC API Reference Guide. // // This member is required. AccessToken *string diff --git a/service/sso/api_op_Logout.go b/service/sso/api_op_Logout.go index 2d6049d8d89..8b9b44745e7 100644 --- a/service/sso/api_op_Logout.go +++ b/service/sso/api_op_Logout.go @@ -10,18 +10,18 @@ import ( ) // Removes the locally stored SSO tokens from the client-side cache and sends an -// API call to the Amazon Web Services SSO service to invalidate the corresponding -// server-side Amazon Web Services SSO sign in session. If a user uses Amazon Web -// Services SSO to access the AWS CLI, the user’s Amazon Web Services SSO sign in -// session is used to obtain an IAM session, as specified in the corresponding -// Amazon Web Services SSO permission set. More specifically, Amazon Web Services -// SSO assumes an IAM role in the target account on behalf of the user, and the -// corresponding temporary Amazon Web Services credentials are returned to the -// client. After user logout, any existing IAM role sessions that were created by -// using Amazon Web Services SSO permission sets continue based on the duration -// configured in the permission set. For more information, see User authentications +// API call to the IAM Identity Center service to invalidate the corresponding +// server-side IAM Identity Center sign in session. If a user uses IAM Identity +// Center to access the AWS CLI, the user’s IAM Identity Center sign in session is +// used to obtain an IAM session, as specified in the corresponding IAM Identity +// Center permission set. More specifically, IAM Identity Center assumes an IAM +// role in the target account on behalf of the user, and the corresponding +// temporary AWS credentials are returned to the client. After user logout, any +// existing IAM role sessions that were created by using IAM Identity Center +// permission sets continue based on the duration configured in the permission set. +// For more information, see User authentications // (https://docs.aws.amazon.com/singlesignon/latest/userguide/authconcept.html) in -// the Amazon Web Services SSO User Guide. +// the IAM Identity Center User Guide. func (c *Client) Logout(ctx context.Context, params *LogoutInput, optFns ...func(*Options)) (*LogoutOutput, error) { if params == nil { params = &LogoutInput{} @@ -42,7 +42,7 @@ type LogoutInput struct { // The token issued by the CreateToken API call. For more information, see // CreateToken // (https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateToken.html) - // in the Amazon Web Services SSO OIDC API Reference Guide. + // in the IAM Identity Center OIDC API Reference Guide. // // This member is required. AccessToken *string diff --git a/service/sso/doc.go b/service/sso/doc.go index 40012670859..f981b154fb4 100644 --- a/service/sso/doc.go +++ b/service/sso/doc.go @@ -3,21 +3,20 @@ // Package sso provides the API client, operations, and parameter types for AWS // Single Sign-On. // -// Amazon Web Services Single Sign On Portal is a web service that makes it easy -// for you to assign user access to Amazon Web Services SSO resources such as the -// AWS access portal. Users can get Amazon Web Services account applications and -// roles assigned to them and get federated into the application. Although Amazon -// Web Services 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 Amazon Web Services SSO rename +// AWS IAM Identity Center (successor to AWS Single Sign-On) Portal is a web +// service that makes it easy for you to assign user access to IAM Identity Center +// resources such as the AWS access portal. Users can get AWS account applications +// and roles assigned to them and get federated into the application. 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 Amazon Web Services SSO Portal operations -// that you can call programatically and includes detailed information on data -// types and errors. Amazon Web Services provides SDKs that consist of libraries -// and sample code for various programming languages and platforms, such as Java, -// Ruby, .Net, iOS, or Android. The SDKs provide a convenient way to create -// programmatic access to Amazon Web Services SSO and other Amazon Web Services -// services. For more information about the Amazon Web Services SDKs, including how -// to download and install them, see Tools for Amazon Web Services +// This reference guide describes the IAM Identity Center Portal operations that +// you can call programatically and includes detailed information on data types and +// errors. AWS provides SDKs that consist of libraries and sample code for various +// programming languages and platforms, such as Java, Ruby, .Net, iOS, or Android. +// The SDKs provide a convenient way to create programmatic access to IAM Identity +// Center and other AWS services. For more information about the AWS SDKs, +// including how to download and install them, see Tools for Amazon Web Services // (http://aws.amazon.com/tools/). package sso diff --git a/service/sso/types/types.go b/service/sso/types/types.go index 4f589fe6382..051056b7598 100644 --- a/service/sso/types/types.go +++ b/service/sso/types/types.go @@ -6,18 +6,16 @@ import ( smithydocument "github.com/aws/smithy-go/document" ) -// Provides information about your Amazon Web Services account. +// Provides information about your AWS account. type AccountInfo struct { - // The identifier of the Amazon Web Services account that is assigned to the user. + // The identifier of the AWS account that is assigned to the user. AccountId *string - // The display name of the Amazon Web Services account that is assigned to the - // user. + // The display name of the AWS account that is assigned to the user. AccountName *string - // The email address of the Amazon Web Services account that is assigned to the - // user. + // The email address of the AWS account that is assigned to the user. EmailAddress *string noSmithyDocumentSerde @@ -27,27 +25,25 @@ type AccountInfo struct { type RoleCredentials struct { // The identifier used for the temporary security credentials. For more - // information, see Using Temporary Security Credentials to Request Access to - // Amazon Web Services Resources + // information, see Using Temporary Security Credentials to Request Access to AWS + // Resources // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_use-resources.html) - // in the Amazon Web Services IAM User Guide. + // in the AWS IAM User Guide. AccessKeyId *string // The date on which temporary security credentials expire. Expiration int64 // The key that is used to sign the request. For more information, see Using - // Temporary Security Credentials to Request Access to Amazon Web Services - // Resources + // Temporary Security Credentials to Request Access to AWS Resources // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_use-resources.html) - // in the Amazon Web Services IAM User Guide. + // in the AWS IAM User Guide. SecretAccessKey *string // The token used for temporary credentials. For more information, see Using - // Temporary Security Credentials to Request Access to Amazon Web Services - // Resources + // Temporary Security Credentials to Request Access to AWS Resources // (https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_use-resources.html) - // in the Amazon Web Services IAM User Guide. + // in the AWS IAM User Guide. SessionToken *string noSmithyDocumentSerde @@ -56,7 +52,7 @@ type RoleCredentials struct { // Provides information about the role that is assigned to the user. type RoleInfo struct { - // The identifier of the Amazon Web Services account assigned to the user. + // The identifier of the AWS account assigned to the user. AccountId *string // The friendly name of the role that is assigned to the user. diff --git a/service/ssoadmin/api_op_AttachCustomerManagedPolicyReferenceToPermissionSet.go b/service/ssoadmin/api_op_AttachCustomerManagedPolicyReferenceToPermissionSet.go index 5be40dc11ed..c3a9e1babbc 100644 --- a/service/ssoadmin/api_op_AttachCustomerManagedPolicyReferenceToPermissionSet.go +++ b/service/ssoadmin/api_op_AttachCustomerManagedPolicyReferenceToPermissionSet.go @@ -30,14 +30,14 @@ func (c *Client) AttachCustomerManagedPolicyReferenceToPermissionSet(ctx context type AttachCustomerManagedPolicyReferenceToPermissionSetInput struct { // Specifies the name and path of a customer managed policy. You must have an IAM - // policy that matches the name and path in each Amazon Web Services account where - // you want to deploy your permission set. + // policy that matches the name and path in each AWS account where you want to + // deploy your permission set. // // This member is required. CustomerManagedPolicyReference *types.CustomerManagedPolicyReference - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_AttachManagedPolicyToPermissionSet.go b/service/ssoadmin/api_op_AttachManagedPolicyToPermissionSet.go index cb8ef107718..559e8d1565c 100644 --- a/service/ssoadmin/api_op_AttachManagedPolicyToPermissionSet.go +++ b/service/ssoadmin/api_op_AttachManagedPolicyToPermissionSet.go @@ -10,11 +10,10 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Attaches an Amazon Web Services managed policy ARN to a permission set. If the -// permission set is already referenced by one or more account assignments, you -// will need to call ProvisionPermissionSet after this operation. Calling -// ProvisionPermissionSet applies the corresponding IAM policy updates to all -// assigned accounts. +// Attaches an AWS managed policy ARN to a permission set. If the permission set is +// already referenced by one or more account assignments, you will need to call +// ProvisionPermissionSet after this operation. Calling ProvisionPermissionSet +// applies the corresponding IAM policy updates to all assigned accounts. func (c *Client) AttachManagedPolicyToPermissionSet(ctx context.Context, params *AttachManagedPolicyToPermissionSetInput, optFns ...func(*Options)) (*AttachManagedPolicyToPermissionSetOutput, error) { if params == nil { params = &AttachManagedPolicyToPermissionSetInput{} @@ -32,15 +31,14 @@ func (c *Client) AttachManagedPolicyToPermissionSet(ctx context.Context, params type AttachManagedPolicyToPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string - // The Amazon Web Services managed policy ARN to be attached to a permission set. + // The AWS managed policy ARN to be attached to a permission set. // // This member is required. ManagedPolicyArn *string diff --git a/service/ssoadmin/api_op_CreateAccountAssignment.go b/service/ssoadmin/api_op_CreateAccountAssignment.go index 56244ff7931..a54461535d5 100644 --- a/service/ssoadmin/api_op_CreateAccountAssignment.go +++ b/service/ssoadmin/api_op_CreateAccountAssignment.go @@ -11,15 +11,15 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Assigns access to a principal for a specified Amazon Web Services account using -// a specified permission set. The term principal here refers to a user or group -// that is defined in Amazon Web Services SSO. As part of a successful -// CreateAccountAssignment call, the specified permission set will automatically be -// provisioned to the account in the form of an IAM policy. That policy is attached -// to the IAM role created in Amazon Web Services SSO. If the permission set is -// subsequently updated, the corresponding IAM policies attached to roles in your -// accounts will not be updated automatically. In this case, you must call -// ProvisionPermissionSet to make these updates. After a successful response, call +// Assigns access to a principal for a specified AWS account using a specified +// permission set. The term principal here refers to a user or group that is +// defined in IAM Identity Center. As part of a successful CreateAccountAssignment +// call, the specified permission set will automatically be provisioned to the +// account in the form of an IAM policy. That policy is attached to the IAM role +// created in IAM Identity Center. If the permission set is subsequently updated, +// the corresponding IAM policies attached to roles in your accounts will not be +// updated automatically. In this case, you must call ProvisionPermissionSet to +// make these updates. After a successful response, call // DescribeAccountAssignmentCreationStatus to describe the status of an assignment // creation request. func (c *Client) CreateAccountAssignment(ctx context.Context, params *CreateAccountAssignmentInput, optFns ...func(*Options)) (*CreateAccountAssignmentOutput, error) { @@ -39,10 +39,9 @@ func (c *Client) CreateAccountAssignment(ctx context.Context, params *CreateAcco type CreateAccountAssignmentInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string @@ -53,10 +52,10 @@ type CreateAccountAssignmentInput struct { // This member is required. PermissionSetArn *string - // An identifier for an object in Amazon Web Services SSO, such as a user or group. + // An identifier for an object in IAM Identity Center, such as a user or group. // PrincipalIds are GUIDs (For example, f81d4fae-7dec-11d0-a765-00a0c91e6bf6). For - // more information about PrincipalIds in Amazon Web Services SSO, see the Amazon - // Web Services SSO Identity Store API Reference. + // more information about PrincipalIds in IAM Identity Center, see the IAM Identity + // Center Identity Store API Reference. // // This member is required. PrincipalId *string @@ -66,8 +65,8 @@ type CreateAccountAssignmentInput struct { // This member is required. PrincipalType types.PrincipalType - // TargetID is an Amazon Web Services account identifier, typically a 10-12 digit - // string (For example, 123456789012). + // TargetID is an AWS account identifier, typically a 10-12 digit string (For + // example, 123456789012). // // This member is required. TargetId *string diff --git a/service/ssoadmin/api_op_CreateInstanceAccessControlAttributeConfiguration.go b/service/ssoadmin/api_op_CreateInstanceAccessControlAttributeConfiguration.go index 56ba404ecf1..7e9dab4f1fa 100644 --- a/service/ssoadmin/api_op_CreateInstanceAccessControlAttributeConfiguration.go +++ b/service/ssoadmin/api_op_CreateInstanceAccessControlAttributeConfiguration.go @@ -11,13 +11,12 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Enables the attributes-based access control (ABAC) feature for the specified -// Amazon Web Services SSO instance. You can also specify new attributes to add to -// your ABAC configuration during the enabling process. For more information about -// ABAC, see Attribute-Based Access Control in the Amazon Web Services SSO User -// Guide. After a successful response, call -// DescribeInstanceAccessControlAttributeConfiguration to validate that -// InstanceAccessControlAttributeConfiguration was created. +// Enables the attributes-based access control (ABAC) feature for the specified IAM +// Identity Center instance. You can also specify new attributes to add to your +// ABAC configuration during the enabling process. For more information about ABAC, +// see Attribute-Based Access Control in the IAM Identity Center User Guide. After +// a successful response, call DescribeInstanceAccessControlAttributeConfiguration +// to validate that InstanceAccessControlAttributeConfiguration was created. func (c *Client) CreateInstanceAccessControlAttributeConfiguration(ctx context.Context, params *CreateInstanceAccessControlAttributeConfigurationInput, optFns ...func(*Options)) (*CreateInstanceAccessControlAttributeConfigurationOutput, error) { if params == nil { params = &CreateInstanceAccessControlAttributeConfigurationInput{} @@ -35,19 +34,19 @@ func (c *Client) CreateInstanceAccessControlAttributeConfiguration(ctx context.C type CreateInstanceAccessControlAttributeConfigurationInput struct { - // Specifies the Amazon Web Services SSO identity store attributes to add to your - // ABAC configuration. When using an external identity provider as an identity - // source, you can pass attributes through the SAML assertion. Doing so provides an - // alternative to configuring attributes from the Amazon Web Services SSO identity - // store. If a SAML assertion passes any of these attributes, Amazon Web Services - // SSO will replace the attribute value with the value from the Amazon Web Services - // SSO identity store. + // Specifies the IAM Identity Center identity store attributes to add to your ABAC + // configuration. When using an external identity provider as an identity source, + // you can pass attributes through the SAML assertion. Doing so provides an + // alternative to configuring attributes from the IAM Identity Center identity + // store. If a SAML assertion passes any of these attributes, IAM Identity Center + // will replace the attribute value with the value from the IAM Identity Center + // identity store. // // This member is required. InstanceAccessControlAttributeConfiguration *types.InstanceAccessControlAttributeConfiguration - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_CreatePermissionSet.go b/service/ssoadmin/api_op_CreatePermissionSet.go index bdae6db8ab2..56f65e099c2 100644 --- a/service/ssoadmin/api_op_CreatePermissionSet.go +++ b/service/ssoadmin/api_op_CreatePermissionSet.go @@ -11,8 +11,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Creates a permission set within a specified Amazon Web Services SSO instance. To -// grant users and groups access to Amazon Web Services account resources, use +// Creates a permission set within a specified IAM Identity Center instance. To +// grant users and groups access to AWS account resources, use // CreateAccountAssignment. func (c *Client) CreatePermissionSet(ctx context.Context, params *CreatePermissionSetInput, optFns ...func(*Options)) (*CreatePermissionSetOutput, error) { if params == nil { @@ -31,10 +31,9 @@ func (c *Client) CreatePermissionSet(ctx context.Context, params *CreatePermissi type CreatePermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string @@ -63,7 +62,7 @@ type CreatePermissionSetInput struct { type CreatePermissionSetOutput struct { - // Defines the level of access on an Amazon Web Services account. + // Defines the level of access on an AWS account. PermissionSet *types.PermissionSet // Metadata pertaining to the operation's result. diff --git a/service/ssoadmin/api_op_DeleteAccountAssignment.go b/service/ssoadmin/api_op_DeleteAccountAssignment.go index 4105f56f625..816ea17dbb6 100644 --- a/service/ssoadmin/api_op_DeleteAccountAssignment.go +++ b/service/ssoadmin/api_op_DeleteAccountAssignment.go @@ -11,8 +11,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Deletes a principal's access from a specified Amazon Web Services account using -// a specified permission set. After a successful response, call +// Deletes a principal's access from a specified AWS account using a specified +// permission set. After a successful response, call // DescribeAccountAssignmentCreationStatus to describe the status of an assignment // deletion request. func (c *Client) DeleteAccountAssignment(ctx context.Context, params *DeleteAccountAssignmentInput, optFns ...func(*Options)) (*DeleteAccountAssignmentOutput, error) { @@ -32,10 +32,9 @@ func (c *Client) DeleteAccountAssignment(ctx context.Context, params *DeleteAcco type DeleteAccountAssignmentInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string @@ -45,10 +44,10 @@ type DeleteAccountAssignmentInput struct { // This member is required. PermissionSetArn *string - // An identifier for an object in Amazon Web Services SSO, such as a user or group. + // An identifier for an object in IAM Identity Center, such as a user or group. // PrincipalIds are GUIDs (For example, f81d4fae-7dec-11d0-a765-00a0c91e6bf6). For - // more information about PrincipalIds in Amazon Web Services SSO, see the Amazon - // Web Services SSO Identity Store API Reference. + // more information about PrincipalIds in IAM Identity Center, see the IAM Identity + // Center Identity Store API Reference. // // This member is required. PrincipalId *string @@ -58,8 +57,8 @@ type DeleteAccountAssignmentInput struct { // This member is required. PrincipalType types.PrincipalType - // TargetID is an Amazon Web Services account identifier, typically a 10-12 digit - // string (For example, 123456789012). + // TargetID is an AWS account identifier, typically a 10-12 digit string (For + // example, 123456789012). // // This member is required. TargetId *string diff --git a/service/ssoadmin/api_op_DeleteInlinePolicyFromPermissionSet.go b/service/ssoadmin/api_op_DeleteInlinePolicyFromPermissionSet.go index 4dc458b2f12..2fb1f1e1a02 100644 --- a/service/ssoadmin/api_op_DeleteInlinePolicyFromPermissionSet.go +++ b/service/ssoadmin/api_op_DeleteInlinePolicyFromPermissionSet.go @@ -28,10 +28,9 @@ func (c *Client) DeleteInlinePolicyFromPermissionSet(ctx context.Context, params type DeleteInlinePolicyFromPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_DeleteInstanceAccessControlAttributeConfiguration.go b/service/ssoadmin/api_op_DeleteInstanceAccessControlAttributeConfiguration.go index ab44d6a1498..069073f5553 100644 --- a/service/ssoadmin/api_op_DeleteInstanceAccessControlAttributeConfiguration.go +++ b/service/ssoadmin/api_op_DeleteInstanceAccessControlAttributeConfiguration.go @@ -11,11 +11,11 @@ import ( ) // Disables the attributes-based access control (ABAC) feature for the specified -// Amazon Web Services SSO instance and deletes all of the attribute mappings that -// have been configured. Once deleted, any attributes that are received from an -// identity source and any custom attributes you have previously configured will -// not be passed. For more information about ABAC, see Attribute-Based Access -// Control in the Amazon Web Services SSO User Guide. +// IAM Identity Center instance and deletes all of the attribute mappings that have +// been configured. Once deleted, any attributes that are received from an identity +// source and any custom attributes you have previously configured will not be +// passed. For more information about ABAC, see Attribute-Based Access Control in +// the IAM Identity Center User Guide. func (c *Client) DeleteInstanceAccessControlAttributeConfiguration(ctx context.Context, params *DeleteInstanceAccessControlAttributeConfigurationInput, optFns ...func(*Options)) (*DeleteInstanceAccessControlAttributeConfigurationOutput, error) { if params == nil { params = &DeleteInstanceAccessControlAttributeConfigurationInput{} @@ -33,8 +33,8 @@ func (c *Client) DeleteInstanceAccessControlAttributeConfiguration(ctx context.C type DeleteInstanceAccessControlAttributeConfigurationInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_DeletePermissionSet.go b/service/ssoadmin/api_op_DeletePermissionSet.go index 1cd6d9d66c9..22c453eb1dd 100644 --- a/service/ssoadmin/api_op_DeletePermissionSet.go +++ b/service/ssoadmin/api_op_DeletePermissionSet.go @@ -28,10 +28,9 @@ func (c *Client) DeletePermissionSet(ctx context.Context, params *DeletePermissi type DeletePermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_DeletePermissionsBoundaryFromPermissionSet.go b/service/ssoadmin/api_op_DeletePermissionsBoundaryFromPermissionSet.go index 92c919d2bbe..0f5e43ef83d 100644 --- a/service/ssoadmin/api_op_DeletePermissionsBoundaryFromPermissionSet.go +++ b/service/ssoadmin/api_op_DeletePermissionsBoundaryFromPermissionSet.go @@ -28,8 +28,8 @@ func (c *Client) DeletePermissionsBoundaryFromPermissionSet(ctx context.Context, type DeletePermissionsBoundaryFromPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_DescribeAccountAssignmentCreationStatus.go b/service/ssoadmin/api_op_DescribeAccountAssignmentCreationStatus.go index 8b59d8a002f..c5245b3f3d0 100644 --- a/service/ssoadmin/api_op_DescribeAccountAssignmentCreationStatus.go +++ b/service/ssoadmin/api_op_DescribeAccountAssignmentCreationStatus.go @@ -34,10 +34,9 @@ type DescribeAccountAssignmentCreationStatusInput struct { // This member is required. AccountAssignmentCreationRequestId *string - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_DescribeAccountAssignmentDeletionStatus.go b/service/ssoadmin/api_op_DescribeAccountAssignmentDeletionStatus.go index 390e135df61..fa24e91f5eb 100644 --- a/service/ssoadmin/api_op_DescribeAccountAssignmentDeletionStatus.go +++ b/service/ssoadmin/api_op_DescribeAccountAssignmentDeletionStatus.go @@ -34,10 +34,9 @@ type DescribeAccountAssignmentDeletionStatusInput struct { // This member is required. AccountAssignmentDeletionRequestId *string - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_DescribeInstanceAccessControlAttributeConfiguration.go b/service/ssoadmin/api_op_DescribeInstanceAccessControlAttributeConfiguration.go index 9a0271ce26e..a09a0e43117 100644 --- a/service/ssoadmin/api_op_DescribeInstanceAccessControlAttributeConfiguration.go +++ b/service/ssoadmin/api_op_DescribeInstanceAccessControlAttributeConfiguration.go @@ -11,12 +11,11 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Returns the list of Amazon Web Services SSO identity store attributes that have -// been configured to work with attributes-based access control (ABAC) for the -// specified Amazon Web Services SSO instance. This will not return attributes -// configured and sent by an external identity provider. For more information about -// ABAC, see Attribute-Based Access Control in the Amazon Web Services SSO User -// Guide. +// Returns the list of IAM Identity Center identity store attributes that have been +// configured to work with attributes-based access control (ABAC) for the specified +// IAM Identity Center instance. This will not return attributes configured and +// sent by an external identity provider. For more information about ABAC, see +// Attribute-Based Access Control in the IAM Identity Center User Guide. func (c *Client) DescribeInstanceAccessControlAttributeConfiguration(ctx context.Context, params *DescribeInstanceAccessControlAttributeConfigurationInput, optFns ...func(*Options)) (*DescribeInstanceAccessControlAttributeConfigurationOutput, error) { if params == nil { params = &DescribeInstanceAccessControlAttributeConfigurationInput{} @@ -34,8 +33,8 @@ func (c *Client) DescribeInstanceAccessControlAttributeConfiguration(ctx context type DescribeInstanceAccessControlAttributeConfigurationInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. // // This member is required. InstanceArn *string @@ -45,8 +44,8 @@ type DescribeInstanceAccessControlAttributeConfigurationInput struct { type DescribeInstanceAccessControlAttributeConfigurationOutput struct { - // Gets the list of Amazon Web Services SSO identity store attributes that have - // been added to your ABAC configuration. + // Gets the list of IAM Identity Center identity store attributes that have been + // added to your ABAC configuration. InstanceAccessControlAttributeConfiguration *types.InstanceAccessControlAttributeConfiguration // The status of the attribute configuration process. diff --git a/service/ssoadmin/api_op_DescribePermissionSet.go b/service/ssoadmin/api_op_DescribePermissionSet.go index 5a383fb78e8..d0a013358ab 100644 --- a/service/ssoadmin/api_op_DescribePermissionSet.go +++ b/service/ssoadmin/api_op_DescribePermissionSet.go @@ -29,10 +29,9 @@ func (c *Client) DescribePermissionSet(ctx context.Context, params *DescribePerm type DescribePermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string @@ -47,7 +46,7 @@ type DescribePermissionSetInput struct { type DescribePermissionSetOutput struct { - // Describes the level of access on an Amazon Web Services account. + // Describes the level of access on an AWS account. PermissionSet *types.PermissionSet // Metadata pertaining to the operation's result. diff --git a/service/ssoadmin/api_op_DescribePermissionSetProvisioningStatus.go b/service/ssoadmin/api_op_DescribePermissionSetProvisioningStatus.go index f6d4efffab4..2fc67d5f055 100644 --- a/service/ssoadmin/api_op_DescribePermissionSetProvisioningStatus.go +++ b/service/ssoadmin/api_op_DescribePermissionSetProvisioningStatus.go @@ -29,10 +29,9 @@ func (c *Client) DescribePermissionSetProvisioningStatus(ctx context.Context, pa type DescribePermissionSetProvisioningStatusInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_DetachCustomerManagedPolicyReferenceFromPermissionSet.go b/service/ssoadmin/api_op_DetachCustomerManagedPolicyReferenceFromPermissionSet.go index 98463c3708a..eb48280132a 100644 --- a/service/ssoadmin/api_op_DetachCustomerManagedPolicyReferenceFromPermissionSet.go +++ b/service/ssoadmin/api_op_DetachCustomerManagedPolicyReferenceFromPermissionSet.go @@ -30,14 +30,14 @@ func (c *Client) DetachCustomerManagedPolicyReferenceFromPermissionSet(ctx conte type DetachCustomerManagedPolicyReferenceFromPermissionSetInput struct { // Specifies the name and path of a customer managed policy. You must have an IAM - // policy that matches the name and path in each Amazon Web Services account where - // you want to deploy your permission set. + // policy that matches the name and path in each AWS account where you want to + // deploy your permission set. // // This member is required. CustomerManagedPolicyReference *types.CustomerManagedPolicyReference - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_DetachManagedPolicyFromPermissionSet.go b/service/ssoadmin/api_op_DetachManagedPolicyFromPermissionSet.go index 806afe5bb3f..9c6926d1b91 100644 --- a/service/ssoadmin/api_op_DetachManagedPolicyFromPermissionSet.go +++ b/service/ssoadmin/api_op_DetachManagedPolicyFromPermissionSet.go @@ -10,8 +10,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Detaches the attached Amazon Web Services managed policy ARN from the specified -// permission set. +// Detaches the attached AWS managed policy ARN from the specified permission set. func (c *Client) DetachManagedPolicyFromPermissionSet(ctx context.Context, params *DetachManagedPolicyFromPermissionSetInput, optFns ...func(*Options)) (*DetachManagedPolicyFromPermissionSetOutput, error) { if params == nil { params = &DetachManagedPolicyFromPermissionSetInput{} @@ -29,15 +28,14 @@ func (c *Client) DetachManagedPolicyFromPermissionSet(ctx context.Context, param type DetachManagedPolicyFromPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string - // The Amazon Web Services managed policy ARN to be detached from a permission set. + // The AWS managed policy ARN to be detached from a permission set. // // This member is required. ManagedPolicyArn *string diff --git a/service/ssoadmin/api_op_GetInlinePolicyForPermissionSet.go b/service/ssoadmin/api_op_GetInlinePolicyForPermissionSet.go index a66b6ab5ee2..f59a72f3e7e 100644 --- a/service/ssoadmin/api_op_GetInlinePolicyForPermissionSet.go +++ b/service/ssoadmin/api_op_GetInlinePolicyForPermissionSet.go @@ -28,10 +28,9 @@ func (c *Client) GetInlinePolicyForPermissionSet(ctx context.Context, params *Ge type GetInlinePolicyForPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_GetPermissionsBoundaryForPermissionSet.go b/service/ssoadmin/api_op_GetPermissionsBoundaryForPermissionSet.go index 3f0ea1946b9..7ff24433f9d 100644 --- a/service/ssoadmin/api_op_GetPermissionsBoundaryForPermissionSet.go +++ b/service/ssoadmin/api_op_GetPermissionsBoundaryForPermissionSet.go @@ -29,8 +29,8 @@ func (c *Client) GetPermissionsBoundaryForPermissionSet(ctx context.Context, par type GetPermissionsBoundaryForPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_ListAccountAssignmentCreationStatus.go b/service/ssoadmin/api_op_ListAccountAssignmentCreationStatus.go index a910ab57652..8908553710d 100644 --- a/service/ssoadmin/api_op_ListAccountAssignmentCreationStatus.go +++ b/service/ssoadmin/api_op_ListAccountAssignmentCreationStatus.go @@ -12,8 +12,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists the status of the Amazon Web Services account assignment creation requests -// for a specified Amazon Web Services SSO instance. +// Lists the status of the AWS account assignment creation requests for a specified +// IAM Identity Center instance. func (c *Client) ListAccountAssignmentCreationStatus(ctx context.Context, params *ListAccountAssignmentCreationStatusInput, optFns ...func(*Options)) (*ListAccountAssignmentCreationStatusOutput, error) { if params == nil { params = &ListAccountAssignmentCreationStatusInput{} @@ -31,10 +31,9 @@ func (c *Client) ListAccountAssignmentCreationStatus(ctx context.Context, params type ListAccountAssignmentCreationStatusInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_ListAccountAssignmentDeletionStatus.go b/service/ssoadmin/api_op_ListAccountAssignmentDeletionStatus.go index 25cb8dec3aa..e8c5ba3f3f2 100644 --- a/service/ssoadmin/api_op_ListAccountAssignmentDeletionStatus.go +++ b/service/ssoadmin/api_op_ListAccountAssignmentDeletionStatus.go @@ -12,8 +12,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists the status of the Amazon Web Services account assignment deletion requests -// for a specified Amazon Web Services SSO instance. +// Lists the status of the AWS account assignment deletion requests for a specified +// IAM Identity Center instance. func (c *Client) ListAccountAssignmentDeletionStatus(ctx context.Context, params *ListAccountAssignmentDeletionStatusInput, optFns ...func(*Options)) (*ListAccountAssignmentDeletionStatusOutput, error) { if params == nil { params = &ListAccountAssignmentDeletionStatusInput{} @@ -31,10 +31,9 @@ func (c *Client) ListAccountAssignmentDeletionStatus(ctx context.Context, params type ListAccountAssignmentDeletionStatusInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_ListAccountAssignments.go b/service/ssoadmin/api_op_ListAccountAssignments.go index d3e2fb9402e..6ca5f1f63e4 100644 --- a/service/ssoadmin/api_op_ListAccountAssignments.go +++ b/service/ssoadmin/api_op_ListAccountAssignments.go @@ -12,8 +12,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists the assignee of the specified Amazon Web Services account with the -// specified permission set. +// Lists the assignee of the specified AWS account with the specified permission +// set. func (c *Client) ListAccountAssignments(ctx context.Context, params *ListAccountAssignmentsInput, optFns ...func(*Options)) (*ListAccountAssignmentsOutput, error) { if params == nil { params = &ListAccountAssignmentsInput{} @@ -31,16 +31,14 @@ func (c *Client) ListAccountAssignments(ctx context.Context, params *ListAccount type ListAccountAssignmentsInput struct { - // The identifier of the Amazon Web Services account from which to list the - // assignments. + // The identifier of the AWS account from which to list the assignments. // // This member is required. AccountId *string - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string @@ -62,8 +60,7 @@ type ListAccountAssignmentsInput struct { type ListAccountAssignmentsOutput struct { - // The list of assignments that match the input Amazon Web Services account and - // permission set. + // The list of assignments that match the input AWS account and permission set. AccountAssignments []types.AccountAssignment // The pagination token for the list API. Initially the value is null. Use the diff --git a/service/ssoadmin/api_op_ListAccountsForProvisionedPermissionSet.go b/service/ssoadmin/api_op_ListAccountsForProvisionedPermissionSet.go index 5533ac6af5e..23800441e2d 100644 --- a/service/ssoadmin/api_op_ListAccountsForProvisionedPermissionSet.go +++ b/service/ssoadmin/api_op_ListAccountsForProvisionedPermissionSet.go @@ -12,8 +12,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists all the Amazon Web Services accounts where the specified permission set is -// provisioned. +// Lists all the AWS accounts where the specified permission set is provisioned. func (c *Client) ListAccountsForProvisionedPermissionSet(ctx context.Context, params *ListAccountsForProvisionedPermissionSetInput, optFns ...func(*Options)) (*ListAccountsForProvisionedPermissionSetOutput, error) { if params == nil { params = &ListAccountsForProvisionedPermissionSetInput{} @@ -31,16 +30,15 @@ func (c *Client) ListAccountsForProvisionedPermissionSet(ctx context.Context, pa type ListAccountsForProvisionedPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string - // The ARN of the PermissionSet from which the associated Amazon Web Services - // accounts will be listed. + // The ARN of the PermissionSet from which the associated AWS accounts will be + // listed. // // This member is required. PermissionSetArn *string @@ -52,7 +50,7 @@ type ListAccountsForProvisionedPermissionSetInput struct { // output of previous API calls to make subsequent calls. NextToken *string - // The permission set provisioning status for an Amazon Web Services account. + // The permission set provisioning status for an AWS account. ProvisioningStatus types.ProvisioningStatus noSmithyDocumentSerde @@ -60,7 +58,7 @@ type ListAccountsForProvisionedPermissionSetInput struct { type ListAccountsForProvisionedPermissionSetOutput struct { - // The list of Amazon Web Services AccountIds. + // The list of AWS AccountIds. AccountIds []string // The pagination token for the list API. Initially the value is null. Use the diff --git a/service/ssoadmin/api_op_ListCustomerManagedPolicyReferencesInPermissionSet.go b/service/ssoadmin/api_op_ListCustomerManagedPolicyReferencesInPermissionSet.go index 70be8d0680d..a351bd50d48 100644 --- a/service/ssoadmin/api_op_ListCustomerManagedPolicyReferencesInPermissionSet.go +++ b/service/ssoadmin/api_op_ListCustomerManagedPolicyReferencesInPermissionSet.go @@ -30,8 +30,8 @@ func (c *Client) ListCustomerManagedPolicyReferencesInPermissionSet(ctx context. type ListCustomerManagedPolicyReferencesInPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_ListInstances.go b/service/ssoadmin/api_op_ListInstances.go index 934df79c07f..9ff6296b379 100644 --- a/service/ssoadmin/api_op_ListInstances.go +++ b/service/ssoadmin/api_op_ListInstances.go @@ -12,7 +12,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists the Amazon Web Services SSO instances that the caller has access to. +// Lists the IAM Identity Center instances that the caller has access to. func (c *Client) ListInstances(ctx context.Context, params *ListInstancesInput, optFns ...func(*Options)) (*ListInstancesOutput, error) { if params == nil { params = &ListInstancesInput{} @@ -42,7 +42,7 @@ type ListInstancesInput struct { type ListInstancesOutput struct { - // Lists the Amazon Web Services SSO instances that the caller has access to. + // Lists the IAM Identity Center instances that the caller has access to. Instances []types.InstanceMetadata // The pagination token for the list API. Initially the value is null. Use the diff --git a/service/ssoadmin/api_op_ListManagedPoliciesInPermissionSet.go b/service/ssoadmin/api_op_ListManagedPoliciesInPermissionSet.go index 9f9be3ca95d..709f8113631 100644 --- a/service/ssoadmin/api_op_ListManagedPoliciesInPermissionSet.go +++ b/service/ssoadmin/api_op_ListManagedPoliciesInPermissionSet.go @@ -12,8 +12,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists the Amazon Web Services managed policy that is attached to a specified -// permission set. +// Lists the AWS managed policy that is attached to a specified permission set. func (c *Client) ListManagedPoliciesInPermissionSet(ctx context.Context, params *ListManagedPoliciesInPermissionSetInput, optFns ...func(*Options)) (*ListManagedPoliciesInPermissionSetOutput, error) { if params == nil { params = &ListManagedPoliciesInPermissionSetInput{} @@ -31,10 +30,9 @@ func (c *Client) ListManagedPoliciesInPermissionSet(ctx context.Context, params type ListManagedPoliciesInPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_ListPermissionSetProvisioningStatus.go b/service/ssoadmin/api_op_ListPermissionSetProvisioningStatus.go index 20b17fa812d..871b858fe0f 100644 --- a/service/ssoadmin/api_op_ListPermissionSetProvisioningStatus.go +++ b/service/ssoadmin/api_op_ListPermissionSetProvisioningStatus.go @@ -12,8 +12,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists the status of the permission set provisioning requests for a specified -// Amazon Web Services SSO instance. +// Lists the status of the permission set provisioning requests for a specified IAM +// Identity Center instance. func (c *Client) ListPermissionSetProvisioningStatus(ctx context.Context, params *ListPermissionSetProvisioningStatusInput, optFns ...func(*Options)) (*ListPermissionSetProvisioningStatusOutput, error) { if params == nil { params = &ListPermissionSetProvisioningStatusInput{} @@ -31,10 +31,9 @@ func (c *Client) ListPermissionSetProvisioningStatus(ctx context.Context, params type ListPermissionSetProvisioningStatusInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_ListPermissionSets.go b/service/ssoadmin/api_op_ListPermissionSets.go index bc76fe86b73..8ca16cd84bd 100644 --- a/service/ssoadmin/api_op_ListPermissionSets.go +++ b/service/ssoadmin/api_op_ListPermissionSets.go @@ -11,7 +11,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists the PermissionSets in an Amazon Web Services SSO instance. +// Lists the PermissionSets in an IAM Identity Center instance. func (c *Client) ListPermissionSets(ctx context.Context, params *ListPermissionSetsInput, optFns ...func(*Options)) (*ListPermissionSetsOutput, error) { if params == nil { params = &ListPermissionSetsInput{} @@ -29,10 +29,9 @@ func (c *Client) ListPermissionSets(ctx context.Context, params *ListPermissionS type ListPermissionSetsInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string @@ -53,7 +52,7 @@ type ListPermissionSetsOutput struct { // output of previous API calls to make subsequent calls. NextToken *string - // Defines the level of access on an Amazon Web Services account. + // Defines the level of access on an AWS account. PermissionSets []string // Metadata pertaining to the operation's result. diff --git a/service/ssoadmin/api_op_ListPermissionSetsProvisionedToAccount.go b/service/ssoadmin/api_op_ListPermissionSetsProvisionedToAccount.go index 1d5e86b7bd5..c019feb997c 100644 --- a/service/ssoadmin/api_op_ListPermissionSetsProvisionedToAccount.go +++ b/service/ssoadmin/api_op_ListPermissionSetsProvisionedToAccount.go @@ -12,8 +12,7 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Lists all the permission sets that are provisioned to a specified Amazon Web -// Services account. +// Lists all the permission sets that are provisioned to a specified AWS account. func (c *Client) ListPermissionSetsProvisionedToAccount(ctx context.Context, params *ListPermissionSetsProvisionedToAccountInput, optFns ...func(*Options)) (*ListPermissionSetsProvisionedToAccountOutput, error) { if params == nil { params = &ListPermissionSetsProvisionedToAccountInput{} @@ -31,16 +30,14 @@ func (c *Client) ListPermissionSetsProvisionedToAccount(ctx context.Context, par type ListPermissionSetsProvisionedToAccountInput struct { - // The identifier of the Amazon Web Services account from which to list the - // assignments. + // The identifier of the AWS account from which to list the assignments. // // This member is required. AccountId *string - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string @@ -64,7 +61,7 @@ type ListPermissionSetsProvisionedToAccountOutput struct { // output of previous API calls to make subsequent calls. NextToken *string - // Defines the level of access that an Amazon Web Services account has. + // Defines the level of access that an AWS account has. PermissionSets []string // Metadata pertaining to the operation's result. diff --git a/service/ssoadmin/api_op_ListTagsForResource.go b/service/ssoadmin/api_op_ListTagsForResource.go index e4bb383d1a9..e97882a5123 100644 --- a/service/ssoadmin/api_op_ListTagsForResource.go +++ b/service/ssoadmin/api_op_ListTagsForResource.go @@ -30,10 +30,9 @@ func (c *Client) ListTagsForResource(ctx context.Context, params *ListTagsForRes type ListTagsForResourceInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_ProvisionPermissionSet.go b/service/ssoadmin/api_op_ProvisionPermissionSet.go index 6d83ef0d1f6..3580c13bf42 100644 --- a/service/ssoadmin/api_op_ProvisionPermissionSet.go +++ b/service/ssoadmin/api_op_ProvisionPermissionSet.go @@ -30,10 +30,9 @@ func (c *Client) ProvisionPermissionSet(ctx context.Context, params *ProvisionPe type ProvisionPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string @@ -48,8 +47,8 @@ type ProvisionPermissionSetInput struct { // This member is required. TargetType types.ProvisionTargetType - // TargetID is an Amazon Web Services account identifier, typically a 10-12 digit - // string (For example, 123456789012). + // TargetID is an AWS account identifier, typically a 10-12 digit string (For + // example, 123456789012). TargetId *string noSmithyDocumentSerde diff --git a/service/ssoadmin/api_op_PutInlinePolicyToPermissionSet.go b/service/ssoadmin/api_op_PutInlinePolicyToPermissionSet.go index 4602ab417f1..aadef2fa8ee 100644 --- a/service/ssoadmin/api_op_PutInlinePolicyToPermissionSet.go +++ b/service/ssoadmin/api_op_PutInlinePolicyToPermissionSet.go @@ -36,10 +36,9 @@ type PutInlinePolicyToPermissionSetInput struct { // This member is required. InlinePolicy *string - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_PutPermissionsBoundaryToPermissionSet.go b/service/ssoadmin/api_op_PutPermissionsBoundaryToPermissionSet.go index b340bb7ae78..ee7175a9a78 100644 --- a/service/ssoadmin/api_op_PutPermissionsBoundaryToPermissionSet.go +++ b/service/ssoadmin/api_op_PutPermissionsBoundaryToPermissionSet.go @@ -11,8 +11,8 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Attaches an Amazon Web Services managed or customer managed policy to the -// specified PermissionSet as a permissions boundary. +// Attaches an AWS managed or customer managed policy to the specified +// PermissionSet as a permissions boundary. func (c *Client) PutPermissionsBoundaryToPermissionSet(ctx context.Context, params *PutPermissionsBoundaryToPermissionSetInput, optFns ...func(*Options)) (*PutPermissionsBoundaryToPermissionSetOutput, error) { if params == nil { params = &PutPermissionsBoundaryToPermissionSetInput{} @@ -30,8 +30,8 @@ func (c *Client) PutPermissionsBoundaryToPermissionSet(ctx context.Context, para type PutPermissionsBoundaryToPermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_TagResource.go b/service/ssoadmin/api_op_TagResource.go index f9e473c3a88..f67a76eaad0 100644 --- a/service/ssoadmin/api_op_TagResource.go +++ b/service/ssoadmin/api_op_TagResource.go @@ -29,10 +29,9 @@ func (c *Client) TagResource(ctx context.Context, params *TagResourceInput, optF type TagResourceInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_UntagResource.go b/service/ssoadmin/api_op_UntagResource.go index 8551e2ca460..6d51d6fae1d 100644 --- a/service/ssoadmin/api_op_UntagResource.go +++ b/service/ssoadmin/api_op_UntagResource.go @@ -28,10 +28,9 @@ func (c *Client) UntagResource(ctx context.Context, params *UntagResourceInput, type UntagResourceInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_UpdateInstanceAccessControlAttributeConfiguration.go b/service/ssoadmin/api_op_UpdateInstanceAccessControlAttributeConfiguration.go index ffed1292606..df40c0d684d 100644 --- a/service/ssoadmin/api_op_UpdateInstanceAccessControlAttributeConfiguration.go +++ b/service/ssoadmin/api_op_UpdateInstanceAccessControlAttributeConfiguration.go @@ -11,15 +11,15 @@ import ( smithyhttp "github.com/aws/smithy-go/transport/http" ) -// Updates the Amazon Web Services SSO identity store attributes that you can use -// with the Amazon Web Services SSO instance for attributes-based access control -// (ABAC). When using an external identity provider as an identity source, you can -// pass attributes through the SAML assertion as an alternative to configuring -// attributes from the Amazon Web Services SSO identity store. If a SAML assertion -// passes any of these attributes, Amazon Web Services SSO replaces the attribute -// value with the value from the Amazon Web Services SSO identity store. For more -// information about ABAC, see Attribute-Based Access Control in the Amazon Web -// Services SSO User Guide. +// Updates the IAM Identity Center identity store attributes that you can use with +// the IAM Identity Center instance for attributes-based access control (ABAC). +// When using an external identity provider as an identity source, you can pass +// attributes through the SAML assertion as an alternative to configuring +// attributes from the IAM Identity Center identity store. If a SAML assertion +// passes any of these attributes, IAM Identity Center replaces the attribute value +// with the value from the IAM Identity Center identity store. For more information +// about ABAC, see Attribute-Based Access Control in the IAM Identity Center User +// Guide. func (c *Client) UpdateInstanceAccessControlAttributeConfiguration(ctx context.Context, params *UpdateInstanceAccessControlAttributeConfigurationInput, optFns ...func(*Options)) (*UpdateInstanceAccessControlAttributeConfigurationOutput, error) { if params == nil { params = &UpdateInstanceAccessControlAttributeConfigurationInput{} @@ -42,8 +42,8 @@ type UpdateInstanceAccessControlAttributeConfigurationInput struct { // This member is required. InstanceAccessControlAttributeConfiguration *types.InstanceAccessControlAttributeConfiguration - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/api_op_UpdatePermissionSet.go b/service/ssoadmin/api_op_UpdatePermissionSet.go index e70f1862718..c468bc6fa09 100644 --- a/service/ssoadmin/api_op_UpdatePermissionSet.go +++ b/service/ssoadmin/api_op_UpdatePermissionSet.go @@ -28,10 +28,9 @@ func (c *Client) UpdatePermissionSet(ctx context.Context, params *UpdatePermissi type UpdatePermissionSetInput struct { - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. // // This member is required. InstanceArn *string diff --git a/service/ssoadmin/doc.go b/service/ssoadmin/doc.go index c45b67d1e48..5022cdf70b8 100644 --- a/service/ssoadmin/doc.go +++ b/service/ssoadmin/doc.go @@ -3,29 +3,28 @@ // Package ssoadmin provides the API client, operations, and parameter types for // AWS Single Sign-On Admin. // -// Amazon Web Services Single Sign On helps you securely create, or connect, your -// workforce identities and manage their access centrally across Amazon Web -// Services accounts and applications. Amazon Web Services SSO is the recommended -// approach for workforce authentication and authorization in Amazon Web Services, -// for organizations of any size and type. Although Amazon Web Services 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 Amazon Web Services SSO rename +// AWS IAM Identity Center (successor to AWS Single Sign-On) helps you securely +// create, or connect, your workforce identities and manage their access centrally +// across AWS accounts and applications. IAM Identity Center is the recommended +// approach for workforce authentication and authorization in AWS, for +// organizations of any size and type. 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 provides information on single sign-on operations which -// could be used for access management of Amazon Web Services accounts. For -// information about Amazon Web Services SSO features, see the Amazon Web Services -// SSO User Guide +// could be used for access management of AWS accounts. For information about IAM +// Identity Center features, see the IAM Identity Center User Guide // (https://docs.aws.amazon.com/singlesignon/latest/userguide/what-is.html). Many -// operations in the Amazon Web Services SSO APIs rely on identifiers for users and +// operations in the IAM Identity Center APIs rely on identifiers for users and // groups, known as principals. For more information about how to work with -// principals and principal IDs in Amazon Web Services SSO, see the Identity Store -// API Reference +// principals and principal IDs in IAM Identity Center, see the Identity Store API +// Reference // (https://docs.aws.amazon.com/singlesignon/latest/IdentityStoreAPIReference/welcome.html). -// Amazon Web Services provides SDKs that consist of libraries and sample code for -// various programming languages and platforms (Java, Ruby, .Net, iOS, Android, and -// more). The SDKs provide a convenient way to create programmatic access to Amazon -// Web Services SSO and other Amazon Web Services services. For more information -// about the Amazon Web Services SDKs, including how to download and install them, -// see Tools for Amazon Web Services (http://aws.amazon.com/tools/). +// AWS provides SDKs that consist of libraries and sample code for various +// programming languages and platforms (Java, Ruby, .Net, iOS, Android, and more). +// The SDKs provide a convenient way to create programmatic access to IAM Identity +// Center and other AWS services. For more information about the AWS SDKs, +// including how to download and install them, see Tools for Amazon Web Services +// (http://aws.amazon.com/tools/). package ssoadmin diff --git a/service/ssoadmin/types/types.go b/service/ssoadmin/types/types.go index 03b55ec4dfd..1e018b78295 100644 --- a/service/ssoadmin/types/types.go +++ b/service/ssoadmin/types/types.go @@ -7,17 +7,17 @@ import ( "time" ) -// These are Amazon Web Services SSO identity store attributes that you can -// configure for use in attributes-based access control (ABAC). You can create -// permissions policies that determine who can access your Amazon Web Services -// resources based upon the configured attribute values. When you enable ABAC and -// specify AccessControlAttributes, Amazon Web Services SSO passes the attribute -// values of the authenticated user into IAM for use in policy evaluation. +// These are IAM Identity Center identity store attributes that you can configure +// for use in attributes-based access control (ABAC). You can create permissions +// policies that determine who can access your AWS resources based upon the +// configured attribute values. When you enable ABAC and specify +// AccessControlAttributes, IAM Identity Center passes the attribute values of the +// authenticated user into IAM for use in policy evaluation. type AccessControlAttribute struct { // The name of the attribute associated with your identities in your identity // source. This is used to map a specified attribute in your identity source with - // an attribute in Amazon Web Services SSO. + // an attribute in IAM Identity Center. // // This member is required. Key *string @@ -33,11 +33,11 @@ type AccessControlAttribute struct { // The value used for mapping a specified attribute to an identity source. For more // information, see Attribute mappings // (https://docs.aws.amazon.com/singlesignon/latest/userguide/attributemappingsconcept.html) -// in the Amazon Web Services SSO User Guide. +// in the IAM Identity Center User Guide. type AccessControlAttributeValue struct { - // The identity source to use when mapping a specified attribute to Amazon Web - // Services SSO. + // The identity source to use when mapping a specified attribute to IAM Identity + // Center. // // This member is required. Source []string @@ -45,23 +45,22 @@ type AccessControlAttributeValue struct { noSmithyDocumentSerde } -// The assignment that indicates a principal's limited access to a specified Amazon -// Web Services account with a specified permission set. The term principal here -// refers to a user or group that is defined in Amazon Web Services SSO. +// The assignment that indicates a principal's limited access to a specified AWS +// account with a specified permission set. The term principal here refers to a +// user or group that is defined in IAM Identity Center. type AccountAssignment struct { - // The identifier of the Amazon Web Services account. + // The identifier of the AWS account. AccountId *string // The ARN of the permission set. For more information about ARNs, see Amazon - // Resource Names (ARNs) and Amazon Web Services Service Namespaces in the Amazon - // Web Services General Reference. + // Resource Names (ARNs) and AWS Service Namespaces in the AWS General Reference. PermissionSetArn *string - // An identifier for an object in Amazon Web Services SSO, such as a user or group. + // An identifier for an object in IAM Identity Center, such as a user or group. // PrincipalIds are GUIDs (For example, f81d4fae-7dec-11d0-a765-00a0c91e6bf6). For - // more information about PrincipalIds in Amazon Web Services SSO, see the Amazon - // Web Services SSO Identity Store API Reference. + // more information about PrincipalIds in IAM Identity Center, see the IAM Identity + // Center Identity Store API Reference. PrincipalId *string // The entity type for which the assignment will be created. @@ -81,14 +80,13 @@ type AccountAssignmentOperationStatus struct { FailureReason *string // The ARN of the permission set. For more information about ARNs, see Amazon - // Resource Names (ARNs) and Amazon Web Services Service Namespaces in the Amazon - // Web Services General Reference. + // Resource Names (ARNs) and AWS Service Namespaces in the AWS General Reference. PermissionSetArn *string - // An identifier for an object in Amazon Web Services SSO, such as a user or group. + // An identifier for an object in IAM Identity Center, such as a user or group. // PrincipalIds are GUIDs (For example, f81d4fae-7dec-11d0-a765-00a0c91e6bf6). For - // more information about PrincipalIds in Amazon Web Services SSO, see the Amazon - // Web Services SSO Identity Store API Reference. + // more information about PrincipalIds in IAM Identity Center, see the IAM Identity + // Center Identity Store API Reference. PrincipalId *string // The entity type for which the assignment will be created. @@ -101,8 +99,8 @@ type AccountAssignmentOperationStatus struct { // The status of the permission set provisioning process. Status StatusValues - // TargetID is an Amazon Web Services account identifier, typically a 10-12 digit - // string (For example, 123456789012). + // TargetID is an AWS account identifier, typically a 10-12 digit string (For + // example, 123456789012). TargetId *string // The entity type for which the assignment will be created. @@ -127,23 +125,22 @@ type AccountAssignmentOperationStatusMetadata struct { noSmithyDocumentSerde } -// A structure that stores the details of the Amazon Web Services managed policy. +// A structure that stores the details of the AWS managed policy. type AttachedManagedPolicy struct { - // The ARN of the Amazon Web Services managed policy. For more information about - // ARNs, see Amazon Resource Names (ARNs) and Amazon Web Services Service - // Namespaces in the Amazon Web Services General Reference. + // The ARN of the AWS managed policy. For more information about ARNs, see Amazon + // Resource Names (ARNs) and AWS Service Namespaces in the AWS General Reference. Arn *string - // The name of the Amazon Web Services managed policy. + // The name of the AWS managed policy. Name *string noSmithyDocumentSerde } // Specifies the name and path of a customer managed policy. You must have an IAM -// policy that matches the name and path in each Amazon Web Services account where -// you want to deploy your permission set. +// policy that matches the name and path in each AWS account where you want to +// deploy your permission set. type CustomerManagedPolicyReference struct { // The name of the IAM policy that you have configured in each account where you @@ -156,7 +153,7 @@ type CustomerManagedPolicyReference struct { // want to deploy your permission set. The default is /. For more information, see // Friendly names and paths // (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_identifiers.html#identifiers-friendly-names) - // in the Identity and Access Management User Guide. + // in the IAM User Guide. Path *string noSmithyDocumentSerde @@ -166,8 +163,8 @@ type CustomerManagedPolicyReference struct { // configuration. type InstanceAccessControlAttributeConfiguration struct { - // Lists the attributes that are configured for ABAC in the specified Amazon Web - // Services SSO instance. + // Lists the attributes that are configured for ABAC in the specified IAM Identity + // Center instance. // // This member is required. AccessControlAttributes []AccessControlAttribute @@ -175,17 +172,16 @@ type InstanceAccessControlAttributeConfiguration struct { noSmithyDocumentSerde } -// Provides information about the Amazon Web Services SSO instance. +// Provides information about the IAM Identity Center instance. type InstanceMetadata struct { - // The identifier of the identity store that is connected to the Amazon Web - // Services SSO instance. + // The identifier of the identity store that is connected to the IAM Identity + // Center instance. IdentityStoreId *string - // The ARN of the Amazon Web Services SSO instance under which the operation will - // be executed. For more information about ARNs, see Amazon Resource Names (ARNs) - // and Amazon Web Services Service Namespaces in the Amazon Web Services General - // Reference. + // The ARN of the IAM Identity Center instance under which the operation will be + // executed. For more information about ARNs, see Amazon Resource Names (ARNs) and + // AWS Service Namespaces in the AWS General Reference. InstanceArn *string noSmithyDocumentSerde @@ -200,29 +196,29 @@ type OperationStatusFilter struct { noSmithyDocumentSerde } -// Specifies the configuration of the Amazon Web Services managed or customer -// managed policy that you want to set as a permissions boundary. Specify either +// Specifies the configuration of the AWS managed or customer managed policy that +// you want to set as a permissions boundary. Specify either // CustomerManagedPolicyReference to use the name and path of a customer managed -// policy, or ManagedPolicyArn to use the ARN of an Amazon Web Services managed -// policy. A permissions boundary represents the maximum permissions that any -// policy can grant your role. For more information, see Permissions boundaries for -// IAM entities +// policy, or ManagedPolicyArn to use the ARN of an AWS managed policy. A +// permissions boundary represents the maximum permissions that any policy can +// grant your role. For more information, see Permissions boundaries for IAM +// entities // (https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies_boundaries.html) -// in the Identity and Access Management User Guide. Policies used as permissions -// boundaries don't provide permissions. You must also attach an IAM policy to the -// role. To learn how the effective permissions for a role are evaluated, see IAM -// JSON policy evaluation logic +// in the IAM User Guide. Policies used as permissions boundaries don't provide +// permissions. You must also attach an IAM policy to the role. To learn how the +// effective permissions for a role are evaluated, see IAM JSON policy evaluation +// logic // (https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_evaluation-logic.html) -// in the Identity and Access Management User Guide. +// in the IAM User Guide. type PermissionsBoundary struct { // Specifies the name and path of a customer managed policy. You must have an IAM - // policy that matches the name and path in each Amazon Web Services account where - // you want to deploy your permission set. + // policy that matches the name and path in each AWS account where you want to + // deploy your permission set. CustomerManagedPolicyReference *CustomerManagedPolicyReference - // The Amazon Web Services managed policy ARN that you want to attach to a - // permission set as a permissions boundary. + // The AWS managed policy ARN that you want to attach to a permission set as a + // permissions boundary. ManagedPolicyArn *string noSmithyDocumentSerde @@ -241,8 +237,7 @@ type PermissionSet struct { Name *string // The ARN of the permission set. For more information about ARNs, see Amazon - // Resource Names (ARNs) and Amazon Web Services Service Namespaces in the Amazon - // Web Services General Reference. + // Resource Names (ARNs) and AWS Service Namespaces in the AWS General Reference. PermissionSetArn *string // Used to redirect users within the application during the federation @@ -260,8 +255,7 @@ type PermissionSet struct { // a specified permission set. type PermissionSetProvisioningStatus struct { - // The identifier of the Amazon Web Services account from which to list the - // assignments. + // The identifier of the AWS account from which to list the assignments. AccountId *string // The date that the permission set was created. @@ -271,8 +265,8 @@ type PermissionSetProvisioningStatus struct { FailureReason *string // The ARN of the permission set that is being provisioned. For more information - // about ARNs, see Amazon Resource Names (ARNs) and Amazon Web Services Service - // Namespaces in the Amazon Web Services General Reference. + // about ARNs, see Amazon Resource Names (ARNs) and AWS Service Namespaces in the + // AWS General Reference. PermissionSetArn *string // The identifier for tracking the request operation that is generated by the @@ -302,8 +296,8 @@ type PermissionSetProvisioningStatusMetadata struct { } // A set of key-value pairs that are used to manage the resource. Tags can only be -// applied to permission sets and cannot be applied to corresponding roles that -// Amazon Web Services SSO creates in Amazon Web Services accounts. +// applied to permission sets and cannot be applied to corresponding roles that IAM +// Identity Center creates in AWS accounts. type Tag struct { // The key for the tag. diff --git a/service/sts/internal/endpoints/endpoints.go b/service/sts/internal/endpoints/endpoints.go index 28ed441bf8e..d061a4e9926 100644 --- a/service/sts/internal/endpoints/endpoints.go +++ b/service/sts/internal/endpoints/endpoints.go @@ -191,6 +191,9 @@ var defaultPartitions = endpoints.Partitions{ endpoints.EndpointKey{ Region: "eu-west-3", }: endpoints.Endpoint{}, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/swf/internal/endpoints/endpoints.go b/service/swf/internal/endpoints/endpoints.go index 7f42cad0b84..8b3e623291d 100644 --- a/service/swf/internal/endpoints/endpoints.go +++ b/service/swf/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/synthetics/internal/endpoints/endpoints.go b/service/synthetics/internal/endpoints/endpoints.go index ce47a850b0c..c976523ceca 100644 --- a/service/synthetics/internal/endpoints/endpoints.go +++ b/service/synthetics/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{}, diff --git a/service/xray/internal/endpoints/endpoints.go b/service/xray/internal/endpoints/endpoints.go index eec723b955b..f2fc86ba0e4 100644 --- a/service/xray/internal/endpoints/endpoints.go +++ b/service/xray/internal/endpoints/endpoints.go @@ -219,6 +219,9 @@ var defaultPartitions = endpoints.Partitions{ }, Deprecated: aws.TrueTernary, }, + endpoints.EndpointKey{ + Region: "me-central-1", + }: endpoints.Endpoint{}, endpoints.EndpointKey{ Region: "me-south-1", }: endpoints.Endpoint{},